예제 #1
0
        /// <summary>Ctor. </summary>
        /// <param name="specification">configuration</param>
        /// <param name="engineUri">engine URI</param>
        public MetricReportingServiceImpl(ConfigurationMetricsReporting specification, String engineUri)
        {
            _specification = specification;
            _engineUri     = engineUri;
            _schedule      = new MetricScheduleService();

            _stmtMetricRepository     = new StatementMetricRepository(engineUri, specification);
            _statementGroupExecutions = new LinkedHashMap <String, MetricExecStatement>();
            _statementMetricHandles   = new Dictionary <String, StatementMetricHandle>();
            StatementOutputHooks      = new CopyOnWriteArraySet <StatementResultListener>();

            if (specification.IsThreading)
            {
                _metricsExecutor = new MetricsExecutorThreaded(engineUri);
            }
            else
            {
                _metricsExecutor = new MetricsExecutorUnthreaded();
            }
        }
예제 #2
0
 /// <summary>Ctor. </summary>
 /// <param name="epServicesContext">services context</param>
 /// <param name="runtime">for routing events</param>
 /// <param name="statementMetricRepository">for getting statement data</param>
 public MetricExecutionContext(EPServicesContext epServicesContext, EPRuntime runtime, StatementMetricRepository statementMetricRepository)
 {
     Services = epServicesContext;
     Runtime  = runtime;
     StatementMetricRepository = statementMetricRepository;
 }