Skip to content

Commit

Permalink
Merge pull request apache#7533 from lukaz-sampaio/issue-7275
Browse files Browse the repository at this point in the history
Docker - Load images
  • Loading branch information
matthiasblaesing authored Jul 8, 2024
2 parents cd0bb01 + 7816b34 commit 1a1a3ac
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -148,9 +148,9 @@ public List<DockerImage> getImages() {
JSONObject json = (JSONObject) o;
JSONArray repoTags = (JSONArray) json.get("RepoTags");
String id = (String) json.get("Id");
long created = (long) json.get("Created");
long size = (long) json.get("Size");
long virtualSize = (long) json.get("VirtualSize");
long created = (long) json.getOrDefault("Created", 0L);
long size = (long) json.getOrDefault("Size", 0L);
long virtualSize = (long) json.getOrDefault("VirtualSize", size);
ret.add(new DockerImage(instance, repoTags, id, created, size, virtualSize));
}
return ret;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,11 @@ public long getSize() {
return size;
}

/**
* @deprecated Removed from Docker Engine in v1.44. Return size value.
* @return
*/
@Deprecated
public long getVirtualSize() {
return virtualSize;
}
Expand Down

0 comments on commit 1a1a3ac

Please sign in to comment.