| Chunk |
|---|
| Conflicting content |
|---|
final ExceptionMetered metered = method.getAnnotation(ExceptionMetered.class);
final String methodName = method.getName();
<<<<<<< HEAD
final String meterName = metered.name().isEmpty() ?
methodName + ExceptionMetered.DEFAULT_NAME_SUFFIX :
metered.name();
final Meter meter = metrics.newMeter(targetClass,
meterName,
scope,
metered.eventType(),
metered.rateUnit());
=======
final String group = MetricName.chooseGroup(metered.group(), targetClass);
final String type = MetricName.chooseType(metered.type(), targetClass);
final String name = metered.name() == null || metered.name().equals("") ? methodName + ExceptionMetered.DEFAULT_NAME_SUFFIX : metered.name();
final MetricName metricName = new MetricName(group, type, name);
final Meter meter = metrics.newMeter(metricName, metered.eventType(), metered.rateUnit());
>>>>>>> d796d21fb11eb1c3d2244cc77fdbb6b107767a04
meters.put(methodName, meter);
causes.put(methodName, metered.cause());
} |
| Solution content |
|---|
final ExceptionMetered metered = method.getAnnotation(ExceptionMetered.class);
final String methodName = method.getName();
final String group = MetricName.chooseGroup(metered.group(), targetClass);
final String type = MetricName.chooseType(metered.type(), targetClass);
final String name = metered.name() == null || metered.name().equals("") ? methodName + ExceptionMetered.DEFAULT_NAME_SUFFIX : metered.name();
final MetricName metricName = new MetricName(group, type, name, scope);
final Meter meter = metrics.newMeter(metricName, metered.eventType(), metered.rateUnit());
meters.put(methodName, meter);
causes.put(methodName, metered.cause());
} |
| File |
|---|
| ExceptionMeteredMethodInterceptor.java |
| Developer's decision |
|---|
| Manual |
| Kind of conflict |
|---|
| Method invocation |
| Variable |
| Chunk |
|---|
| Conflicting content |
|---|
if (method.getParameterTypes().length == 0) {
final Gauge gauge = method.getAnnotation(Gauge.class);
final String name = gauge.name().isEmpty() ? method.getName() : gauge.name();
<<<<<<< HEAD
metrics.newGauge(method.getDeclaringClass(),
}
scope,
name,
new GaugeMethod(bean, method));
=======
final String group = MetricName.chooseGroup(gauge.group(), method.getDeclaringClass());
final String type = MetricName.chooseType(gauge.type(), method.getDeclaringClass());
final MetricName metricName = new MetricName(group, type, name);
metrics.newGauge(metricName, new GaugeMethod(bean, method));
>>>>>>> d796d21fb11eb1c3d2244cc77fdbb6b107767a04
} else {
throw new IllegalStateException("Method " + method.getName() + " is annotated with @Gauge but requires parameters."); |
| Solution content |
|---|
if (method.getParameterTypes().length == 0) {
final Gauge gauge = method.getAnnotation(Gauge.class);
final String name = gauge.name().isEmpty() ? method.getName() : gauge.name();
final String group = MetricName.chooseGroup(gauge.group(), method.getDeclaringClass());
final String type = MetricName.chooseType(gauge.type(), method.getDeclaringClass());
final MetricName metricName = new MetricName(group, type, name, scope);
metrics.newGauge(metricName, new GaugeMethod(bean, method));
} else {
throw new IllegalStateException("Method " + method.getName() + " is annotated with @Gauge but requires parameters.");
} |
| File |
|---|
| GaugeAnnotationBeanPostProcessor.java |
| Developer's decision |
|---|
| Manual |
| Kind of conflict |
|---|
| Method invocation |
| Variable |
| Chunk |
|---|
| Conflicting content |
|---|
<<<<<<< HEAD
final Metered metered = method.getAnnotation(Metered.class);
final String methodName = method.getName();
final String meterName = metered.name().isEmpty() ? methodName : metered.name();
final Meter meter = metrics.newMeter(targetClass,
meterName,
scope,
metered.eventType(),
metered.rateUnit());
=======
final String group = MetricName.chooseGroup(metered.group(), targetClass);
final String type = MetricName.chooseType(metered.type(), targetClass);
final String name = metered.name() == null || metered.name().equals("") ? methodName : metered.name();
final MetricName metricName = new MetricName(group, type, name);
final Meter meter = metrics.newMeter(metricName, metered.eventType(), metered.rateUnit());
>>>>>>> d796d21fb11eb1c3d2244cc77fdbb6b107767a04
meters.put(methodName, meter);
}
|
| Solution content |
|---|
final Metered metered = method.getAnnotation(Metered.class);
final String methodName = method.getName();
final String group = MetricName.chooseGroup(metered.group(), targetClass);
final String type = MetricName.chooseType(metered.type(), targetClass);
final String name = metered.name() == null || metered.name().equals("") ? methodName : metered.name();
final MetricName metricName = new MetricName(group, type, name, scope);
final Meter meter = metrics.newMeter(metricName, metered.eventType(), metered.rateUnit());
meters.put(methodName, meter);
} |
| File |
|---|
| MeteredMethodInterceptor.java |
| Developer's decision |
|---|
| Manual |
| Kind of conflict |
|---|
| Method invocation |
| Variable |
| Chunk |
|---|
| Conflicting content |
|---|
final Timed timed = method.getAnnotation(Timed.class);
final String methodName = method.getName();
<<<<<<< HEAD
final String timerName = timed.name().isEmpty() ? methodName : timed.name();
final Timer timer = metrics.newTimer(targetClass,
timerName,
scope,
=======
final String group = MetricName.chooseGroup(timed.group(), targetClass);
final String type = MetricName.chooseType(timed.type(), targetClass);
final String name = timed.name() == null || timed.name().equals("") ? methodName : timed.name();
final MetricName metricName = new MetricName(group, type, name);
final Timer timer = metrics.newTimer(metricName,
>>>>>>> d796d21fb11eb1c3d2244cc77fdbb6b107767a04
timed.durationUnit(),
timed.rateUnit());
timers.put(methodName, timer); |
| Solution content |
|---|
final Timed timed = method.getAnnotation(Timed.class);
final String methodName = method.getName();
final String group = MetricName.chooseGroup(timed.group(), targetClass);
final String type = MetricName.chooseType(timed.type(), targetClass);
final String name = timed.name() == null || timed.name().equals("") ? methodName : timed.name();
final MetricName metricName = new MetricName(group, type, name, scope);
final Timer timer = metrics.newTimer(metricName,
timed.durationUnit(),
timed.rateUnit());
timers.put(methodName, timer); |
| File |
|---|
| TimedMethodInterceptor.java |
| Developer's decision |
|---|
| Manual |
| Kind of conflict |
|---|
| Method invocation |
| Variable |