[
https://issues.apache.org/jira/browse/BEAM-4125?focusedWorklogId=94892&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-94892
]
ASF GitHub Bot logged work on BEAM-4125:
----------------------------------------
Author: ASF GitHub Bot
Created on: 25/Apr/18 00:15
Start Date: 25/Apr/18 00:15
Worklog Time Spent: 10m
Work Description: youngoli commented on a change in pull request #5172:
[BEAM-4125] Add ProtoOverrides
URL: https://github.com/apache/beam/pull/5172#discussion_r183908747
##########
File path:
runners/core-construction-java/src/main/java/org/apache/beam/runners/core/construction/graph/ProtoOverrides.java
##########
@@ -0,0 +1,103 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.beam.runners.core.construction.graph;
+
+import static com.google.common.base.Preconditions.checkArgument;
+
+import java.util.List;
+import java.util.Map;
+import org.apache.beam.model.pipeline.v1.RunnerApi.Components;
+import org.apache.beam.model.pipeline.v1.RunnerApi.ComponentsOrBuilder;
+import org.apache.beam.model.pipeline.v1.RunnerApi.MessageWithComponents;
+import org.apache.beam.model.pipeline.v1.RunnerApi.PTransform;
+import org.apache.beam.model.pipeline.v1.RunnerApi.Pipeline;
+import org.apache.beam.sdk.annotations.Experimental;
+import org.apache.beam.sdk.runners.PTransformOverride;
+
+/**
+ * A way to apply a Proto-based {@link PTransformOverride}.
+ *
+ * <p>This should generally be used to replace runner-executed transforms with
runner-executed
+ * composites and simpler runner-executed primitives. It is generically less
powerful than the
+ * native {@link org.apache.beam.sdk.Pipeline#replaceAll(List)} and more
error-prone, so should only
+ * be used for relatively simple replacements.
+ */
+@Experimental
+public class ProtoOverrides {
+ /**
+ * Update all composites present in the {@code originalPipeline} have an URN
equal to the provided
Review comment:
This description is awkwardly worded, sounds like there's some small typos.
Specifically:
`{@code originalPipeline} have` -> `{@code originalPipeline} that have`
`the provide {@link TransformReplacement}` -> `the provided {@link
TransformReplacement}`
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
Issue Time Tracking
-------------------
Worklog Id: (was: 94892)
Time Spent: 1h (was: 50m)
> Add a library to manipulate the proto representation of a pipeline
> ------------------------------------------------------------------
>
> Key: BEAM-4125
> URL: https://issues.apache.org/jira/browse/BEAM-4125
> Project: Beam
> Issue Type: New Feature
> Components: runner-core
> Reporter: Thomas Groh
> Assignee: Thomas Groh
> Priority: Major
> Labels: portability
> Time Spent: 1h
> Remaining Estimate: 0h
>
> This is important for a transform which includes in-environment transforms
> (such as a lifted Combine), or for runners which use the beam representation
> as their internal representation (such as the directrunner)
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)