Examples of BindingScope


Examples of org.platformlayer.ops.BindingScope

        getProjectAuthorization());

    return OpsContext.runInContext(opsContext, new CheckedCallable<MetricInfoCollection, Exception>() {
      @Override
      public MetricInfoCollection call() throws Exception {
        BindingScope bindingScope = BindingScope.push(managedItem, managedItem);
        try {
          Object controller = serviceProvider.getController(managedItem);
          MetricConfig metricConfig = opsContext.getMetricInfo(controller);

          return MetricCollector.toMetricInfo(metricConfig);
        } finally {
          bindingScope.pop();
        }
      }
    });
  }
View Full Code Here

Examples of org.platformlayer.ops.BindingScope

        getProjectAuthorization());

    return OpsContext.runInContext(opsContext, new CheckedCallable<MetricDataSource, Exception>() {
      @Override
      public MetricDataSource call() throws Exception {
        BindingScope bindingScope = BindingScope.push(managedItem, managedItem);
        try {
          MetricDataSource metrics = serviceProvider.getMetricValues(managedItem, query);
          return metrics;
        } finally {
          bindingScope.pop();
        }
      }
    });
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.