Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prisma Cloud Minimal Response 2 #32714

Merged
merged 50 commits into from Feb 5, 2024
Merged

Conversation

tkatzir
Copy link
Contributor

@tkatzir tkatzir commented Feb 5, 2024

Support minimizing Prisma Cloud output size in prisma-cloud-config-search

fixes: https://jira-dc.paloaltonetworks.com/browse/CIAC-9646

tkatzir and others added 30 commits February 1, 2024 14:54
Co-authored-by: ShirleyDenkberg <62508050+ShirleyDenkberg@users.noreply.github.com>
Co-authored-by: ShirleyDenkberg <62508050+ShirleyDenkberg@users.noreply.github.com>
Co-authored-by: ShirleyDenkberg <62508050+ShirleyDenkberg@users.noreply.github.com>
Co-authored-by: Adi Bamberger Edri <72088126+BEAdi@users.noreply.github.com>
@tkatzir tkatzir marked this pull request as ready for review February 5, 2024 16:11
items = demisto.get(input_dict, 'data.items')
if items:
for current_item in list(items):
data = current_item['data']
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use get instead of []

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

metadata = data['metadata']
metadata_items = metadata['items']
if metadata_items:
for current_metadata_item in list(metadata_items):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why do you convert to list? list(metadata_items)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because I don't want to change the list I'm iterating on.

@@ -0,0 +1,4 @@
{
"breakingChanges": true,
"breakingChangesNotes": "The output now lacks the folowing 2 values by default: ***data.items.data.disks.shieldedInstanceInitialState***, ***data.items.data.metadata.items.configure-sh***. Use the argument ****include_additional_resource_fields=true**** to include their values in the output."
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Explain here, if a user needs one those values, what they should do

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's there:
Use the argument include_additional_resource_fields=true to include their values in the output.

@ShirleyDenkberg
Copy link
Contributor

@BEAdi @anara123 Doc review completed.

tkatzir and others added 2 commits February 5, 2024 20:27
Co-authored-by: ShirleyDenkberg <62508050+ShirleyDenkberg@users.noreply.github.com>
Co-authored-by: ShirleyDenkberg <62508050+ShirleyDenkberg@users.noreply.github.com>
@tkatzir tkatzir merged commit 09085e1 into master Feb 5, 2024
15 of 16 checks passed
@tkatzir tkatzir deleted the prisma-cloud-minimal-response-2 branch February 5, 2024 19:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants