You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@beam.apache.org by GitBox <gi...@apache.org> on 2020/02/28 01:50:39 UTC

[GitHub] [beam] ihji commented on a change in pull request #10621: [BEAM-9056] Staging artifacts from environment

ihji commented on a change in pull request #10621: [BEAM-9056] Staging artifacts from environment
URL: https://github.com/apache/beam/pull/10621#discussion_r385469668
 
 

 ##########
 File path: runners/core-construction-java/src/main/java/org/apache/beam/runners/core/construction/SdkComponents.java
 ##########
 @@ -88,11 +88,13 @@ public static SdkComponents create(RunnerApi.Components components) {
   public static SdkComponents create(PipelineOptions options) {
     SdkComponents sdkComponents = new SdkComponents(RunnerApi.Components.getDefaultInstance(), "");
     PortablePipelineOptions portablePipelineOptions = options.as(PortablePipelineOptions.class);
-    sdkComponents.defaultEnvironmentId =
-        sdkComponents.registerEnvironment(
-            Environments.createOrGetDefaultEnvironment(
+    sdkComponents.registerEnvironment(
+        Environments.createOrGetDefaultEnvironment(
                 portablePipelineOptions.getDefaultEnvironmentType(),
-                portablePipelineOptions.getDefaultEnvironmentConfig()));
+                portablePipelineOptions.getDefaultEnvironmentConfig())
+            .toBuilder()
+            .addAllDependencies(Environments.getArtifacts(options))
 
 Review comment:
   agreed. moved to createOrGetDefaultEnvironment.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services