Skip to content

chore: demo 20% of changes compute fix#31516

Draft
diegomarquezp wants to merge 2 commits intomainfrom
demo-20pct-generation
Draft

chore: demo 20% of changes compute fix#31516
diegomarquezp wants to merge 2 commits intomainfrom
demo-20pct-generation

Conversation

@diegomarquezp
Copy link
Copy Markdown
Contributor

@diegomarquezp diegomarquezp commented Apr 15, 2026

Tested with Main class for compute v1, alpha and beta.

System.out.println("Executing Alpha compute.instances().list() server call on " + projectId + "...");
try {
InstanceList instances = computeService.instances().list(projectId, zone).execute();
System.out.println("Total Alpha items: " + (instances.getItems() == null ? 0 : instances.getItems().size()));
if (instances.getItems() != null) {
for (com.google.api.services.compute.model.Instance instance : instances.getItems()) {
if (instance.getPartnerMetadata() != null) {
for (java.util.Map.Entry<String, com.google.api.services.compute.model.StructuredEntries> entry : instance.getPartnerMetadata().entrySet()) {
com.google.api.services.compute.model.StructuredEntries se = entry.getValue();
System.out.println("Alpha StructuredEntries inspection (" + entry.getKey() + "): " + se);
}
}
}
}

Obtained output was:

[INFO] --- exec:3.6.3:java (default-cli) @ google-api-services-compute ---
Initializing GoogleCredential via google-api-client natively...
StructuredEntries instantiated independently: GenericData{classInfo=[entries], {}}
Executing compute.instances().list() server call on diegomarquezp-sandbox...
Total items retrieved: 1
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS

@diegomarquezp diegomarquezp added the do not merge Indicates a pull request not ready for merge, due to either quality or timing. label Apr 15, 2026
@diegomarquezp diegomarquezp force-pushed the demo-20pct-generation branch from 87dceef to a346f56 Compare April 22, 2026 14:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

do not merge Indicates a pull request not ready for merge, due to either quality or timing.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant