lostluck commented on code in PR #23990:
URL: https://github.com/apache/beam/pull/23990#discussion_r1015991231


##########
sdks/go/pkg/beam/options/jobopts/options.go:
##########
@@ -169,3 +179,49 @@ func GetExperiments() []string {
        }
        return strings.Split(*Experiments, ",")
 }
+
+// GetPipelineResourceHints parses known standard hints and returns the flag 
set hints for the pipeline.
+// In case of duplicate hint URNs, the last value specified will be used.
+func GetPipelineResourceHints() resource.Hints {
+       hints := make([]resource.Hint, 0, len(ResourceHints))
+       for _, hint := range ResourceHints {
+               name, val, ok := strings.Cut(hint, "=")
+               if !ok {
+                       panic(fmt.Sprintf("unparsable resource hint: %q", hint))
+               }
+               var h resource.Hint
+               switch name {
+               case "min_ram":

Review Comment:
   To be clear here, it seems reasonable to maintain the correct semantics SDK 
side if we're able to, and it's not hard to add them to the switch statement. 
Also updated the test cases to ensure they're overriding as described in the 
flag.



-- 
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]

Reply via email to