[ 
https://issues.apache.org/jira/browse/BEAM-3545?focusedWorklogId=85031&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-85031
 ]

ASF GitHub Bot logged work on BEAM-3545:
----------------------------------------

                Author: ASF GitHub Bot
            Created on: 27/Mar/18 21:31
            Start Date: 27/Mar/18 21:31
    Worklog Time Spent: 10m 
      Work Description: lostluck commented on a change in pull request #4899: 
[BEAM-3545] Go SDK UserCounters
URL: https://github.com/apache/beam/pull/4899#discussion_r177579031
 
 

 ##########
 File path: sdks/go/pkg/beam/core/runtime/harness/harness.go
 ##########
 @@ -203,20 +204,44 @@ func (c *control) handleInstruction(ctx context.Context, 
req *fnpb.InstructionRe
 
                err := plan.Execute(ctx, id, c.data)
 
+               snapshot := plan.ProgressReport()
+               planID := plan.ID()
                // Move the plan back to the candidate state
                c.mu.Lock()
                c.plans[plan.ID()] = plan
                delete(c.active, id)
                c.mu.Unlock()
 
+               transforms := map[string]*fnpb.Metrics_PTransform{
 
 Review comment:
   The ProgressReport is forwarded from the Datasource, which is also the file 
that defines the ProgressReport. It would be weird to have a "sidecar" field 
defined in a file that doesn't know or care about those ParDoIDs only to have 
it populated if the ProgressReport method is called from something else. It 
feels less maintainable than the current implementation, which leverages that 
we know a Plan is that type, rather than by an interface type, allowing access 
to exported fields.
   Having an exported field is preferable to a Getter function in Go IIRC, 
unless we are particularly concerned about abuse of these opaque per bundle 
PTransform identifiers leaking out.

----------------------------------------------------------------
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: 85031)
    Time Spent: 8h 10m  (was: 8h)

> Fn API metrics in Go SDK harness
> --------------------------------
>
>                 Key: BEAM-3545
>                 URL: https://issues.apache.org/jira/browse/BEAM-3545
>             Project: Beam
>          Issue Type: Sub-task
>          Components: sdk-go
>            Reporter: Kenneth Knowles
>            Assignee: Robert Burke
>            Priority: Major
>              Labels: portability
>          Time Spent: 8h 10m
>  Remaining Estimate: 0h
>




--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to