Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-63153

Create ShardingDataTransformMetrics Individual Metrics Stub Class

    • Fully Compatible
    • Sharding 2022-02-21
    • 2

      This will a per-instance class that will handle all interactions between the Resharding/Global indexes metrics and external callers.

      This is a simple example of what it could look like:

      class IndividualMetrics {
      	std::atomic<counter> _onlyIndividualsNeed;
      	SharedMetricsPtr _sharedMetrics;
      	CumulativeMetricsPtr _parent;
      	
      	IndividualMetrics(OperationContext* opCtx) {
      		_parent = CumulativeMetrics::get(opCtx->getServiceContext());
              _sharedMetrics = _parent.createRegisteredSharedMetrics()
      	}
      	
      	~IndividualMetrics() {
      		_parent.deregisterSharedMetrics(_sharedMetrics);
      	}
      }
      

            Assignee:
            brett.nawrocki@mongodb.com Brett Nawrocki
            Reporter:
            luis.osta@mongodb.com Luis Osta (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: