lostluck commented on a change in pull request #12628:
URL: https://github.com/apache/beam/pull/12628#discussion_r473145499
##########
File path: sdks/go/pkg/beam/core/graph/fn.go
##########
@@ -167,6 +167,23 @@ const (
// TODO: ViewFn, etc.
)
+var methodNames = []string{
Review comment:
Consider using a map[string]struct{} instead instead of looping over a
slice.
Alternatively, given that this is a combination of both doFnNames and
sdfNames, consider
var methodNames = append(append(nil, doFnNames...), sdfNames...)
which avoids duplicating the constant lists.
----------------------------------------------------------------
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:
[email protected]