1 package com.griddynamics.jagger.engine.e1.collector.invocation;
3 import com.griddynamics.jagger.engine.e1.Provider;
4 import com.griddynamics.jagger.engine.e1.collector.MetricDescription;
5 import com.griddynamics.jagger.engine.e1.collector.SumMetricAggregatorProvider;
6 import com.griddynamics.jagger.engine.e1.services.ServicesAware;
7 import com.griddynamics.jagger.invoker.InvocationException;
20 private final String metricName =
"not-null-responses";
25 displayName(
"Number of not null responses").
33 return new InvocationListener() {
35 public void onStart(InvocationInfo invocationInfo) {
39 public void onSuccess(InvocationInfo invocationInfo) {
40 if (invocationInfo.getResult() != null){
41 getMetricService().saveValue(metricName, 1);
46 public void onFail(InvocationInfo invocationInfo, InvocationException e) {
50 public void onError(InvocationInfo invocationInfo, Throwable error) {