Package com.springsource.insight.intercept.trace

Examples of com.springsource.insight.intercept.trace.Trace


    public void testLocateDatabaseURI() throws Exception {
        String jdbcUri = "jdbc:foobar://huh:8080";

        Operation op = createJdbcOperation(jdbcUri);
        Frame frame = createJdbcFrame(op);
        Trace trace = createJdbcTrace(frame);

        List<ExternalResourceDescriptor> descList =
                (List<ExternalResourceDescriptor>) dbAnalyzer.locateExternalResourceName(trace);
        assertEquals("Mismatched num of descriptors", 1, descList.size());
        ExternalResourceDescriptor externalResourceDescriptor = descList.get(0);
View Full Code Here


        this.isIncoming = analyzerInstance.isIncoming;
    }

    @Test
    public void testLocateExternalResourceName() {
        Trace trace = createValidTrace();
        String label = "Queue#test.queue";

        assertExternalResource(trace, label);
    }
View Full Code Here

        assertExternalResource(trace, label);
    }

    @Test
    public void testLocateExternalResourceNameWithTemporaryQueue() {
        Trace trace = createValidTrace(DestinationType.TemporaryQueue);
        String label = DestinationType.TemporaryQueue.getLabel();

        assertExternalResource(trace, label);
    }
View Full Code Here

        builder.enter(dummyOp);
        builder.enter(op1);
        builder.exit();
        builder.exit();
        Frame frame = builder.exit();
        Trace trace = Trace.newInstance(ApplicationName.valueOf("app"), TraceId.valueOf("0"), frame);

        List<ExternalResourceDescriptor> externalResourceDescriptors =
                (List<ExternalResourceDescriptor>) analyzer.locateExternalResourceName(trace);

        assertEquals(2, externalResourceDescriptors.size());
View Full Code Here

                null,
                op,
                TimeRange.milliTimeRange(0, 1),
                Collections.<Frame>emptyList());

        Trace trace = new Trace(ServerName.valueOf("fake-server"),
                ApplicationName.valueOf("fake-app"),
                new Date(),
                TraceId.valueOf("fake-id"),
                frame);
View Full Code Here

                null,
                op,
                TimeRange.milliTimeRange(0, 1),
                frames);

        Trace trace = new Trace(ServerName.valueOf("fake-server"),
                ApplicationName.valueOf("fake-app"),
                new Date(),
                TraceId.valueOf("fake-id"),
                frame);
View Full Code Here

    }

    @Test
    public void testLocateExternalResourceName() {
        final String HOST = "test.example.com";
        Trace trace = createValidTrace(HOST);
        List<ExternalResourceDescriptor> externalResourceDescriptors =
                (List<ExternalResourceDescriptor>) analyzer.locateExternalResourceName(trace);

        assertEquals("Mismatched number of descriptors", 1, externalResourceDescriptors.size());
        ExternalResourceDescriptor descriptor = externalResourceDescriptors.get(0);

        assertSame("Mismatched root frame", trace.getRootFrame(), descriptor.getFrame());
        assertDescriptorContents("testLocateExternalResourceName", HOST, descriptor);
    }
View Full Code Here

        builder.enter(new Operation().type(OperationType.METHOD));
        builder.enter(op1);
        builder.exit();
        builder.exit();
        Frame frame = builder.exit();
        Trace trace = Trace.newInstance(ApplicationName.valueOf("app"), TraceId.valueOf("0"), frame);

        List<ExternalResourceDescriptor> externalResourceDescriptors =
                (List<ExternalResourceDescriptor>) analyzer.locateExternalResourceName(trace);
        assertEquals("Mismatched number of descriptors", 2, externalResourceDescriptors.size());
View Full Code Here

                null,
                op,
                TimeRange.milliTimeRange(0, 1),
                Collections.<Frame>emptyList());

        Trace trace = new Trace(ServerName.valueOf("fake-server"),
                ApplicationName.valueOf("fake-app"),
                new Date(),
                TraceId.valueOf("fake-id"),
                frame);
View Full Code Here

        builder.enter(dummyOp);
        builder.enter(op1);
        builder.exit();
        builder.exit();
        Frame frame = builder.exit();
        Trace trace = Trace.newInstance(ApplicationName.valueOf("app"), TraceId.valueOf("0"), frame);

        List<ExternalResourceDescriptor> externalResourceDescriptors =
                (List<ExternalResourceDescriptor>) analyzer.locateExternalResourceName(trace);

        assertEquals(2, externalResourceDescriptors.size());
View Full Code Here

TOP

Related Classes of com.springsource.insight.intercept.trace.Trace

Copyright © 2018 www.massapicom. 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.