rdblue commented on code in PR #6058: URL: https://github.com/apache/iceberg/pull/6058#discussion_r1018469473
########## spark/v3.3/spark/src/main/java/org/apache/iceberg/spark/SparkCatalog.java: ########## @@ -532,6 +537,24 @@ public final void initialize(String name, CaseInsensitiveStringMap options) { Splitter.on('.').splitToList(options.get("default-namespace")).toArray(new String[0]); } } + + EnvironmentContext.put(EnvironmentContext.ENGINE_NAME, "spark"); + EnvironmentContext.put( + EnvironmentContext.ENGINE_VERSION, sparkSession.sparkContext().version()); + EnvironmentContext.put(CatalogProperties.APP_ID, sparkSession.sparkContext().applicationId()); + sparkSession Review Comment: I think this can be replaced with something simpler: ```java String sqlQueryIdKey = SQLExecution.EXECUTION_ID_KEY() EnvironmentContext.putLocal(sqlQueryIdKey, () -> sparkSession.sparkContext().getLocalProperty(sqlQueryIdKey)); ``` -- 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: issues-unsubscr...@iceberg.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org For additional commands, e-mail: issues-h...@iceberg.apache.org