@Override
    public String getOperationName(Exchange exchange, Endpoint endpoint) {
        return getPath(endpoint.getEndpointUri());
    }
@Test
    public void testGetOperation() {
        String path = "/persons/{personId}";
        String uri = "rest://put:/persons:/%7BpersonId%7D?routeId=route4";

        Endpoint endpoint = Mockito.mock(Endpoint.class);
        Exchange exchange = Mockito.mock(Exchange.class);

        Mockito.when(endpoint.getEndpointUri()).thenReturn(uri);
        Mockito.when(exchange.getFromEndpoint()).thenReturn(endpoint);

        SpanDecorator decorator = new RestSpanDecorator();

        assertEquals(path, decorator.getOperationName(exchange, endpoint));
    }