kevinjqliu commented on code in PR #16258:
URL: https://github.com/apache/iceberg/pull/16258#discussion_r3211791747
##########
gcp/src/main/java/org/apache/iceberg/gcp/gcs/PrefixedStorage.java:
##########
@@ -45,11 +41,11 @@ class PrefixedStorage implements AutoCloseable {
private static final String GCS_FILE_IO_USER_AGENT = "gcsfileio/" +
EnvironmentContext.get();
private final String storagePrefix;
private final GCPProperties gcpProperties;
+ private final Map<String, String> propertiesWithUserAgent;
private SerializableSupplier<Storage> storage;
private CloseableGroup closeableGroup;
private transient volatile Storage storageClient;
Review Comment:
nit: The `storageClient` field is only used in gcsFileSystem() when
analytics-core is enabled, but it's allocated for every PrefixedStorage
instance. The old code built this map only inside the supplier. Consider
building it lazily inside gcsFileSystem() or only when
gcpProperties.isGcsAnalyticsCoreEnabled() is true
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]