private Map < String , String > defaultMetadata ( ) { final Builder < String , String > builder = ImmutableMap . builder ( ) ; final Map < String , String > envVars = envVarSupplier . get ( ) ; for ( final Map . Entry < String , String > entry : DEFAULT_METADATA_ENVVARS . entrySet ( ) ) { final String envKey = entry . getKey ( ) ; final String metadataKey = entry . getValue ( ) ; final String envValue = envVars . get ( envKey ) ; if ( envValue != null ) { builder . put ( metadataKey , envValue ) ; } } return builder . build ( ) ; }
Metadata to associate with jobs by default . Currently sets some metadata based upon environment variables set when the CLI command is run .