• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

Java TraversalMetrics类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Java中org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics的典型用法代码示例。如果您正苦于以下问题:Java TraversalMetrics类的具体用法?Java TraversalMetrics怎么用?Java TraversalMetrics使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



TraversalMetrics类属于org.apache.tinkerpop.gremlin.process.traversal.util包,在下文中一共展示了TraversalMetrics类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: deserializersTestsTraversalMetrics

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
@Test
public void deserializersTestsTraversalMetrics() {
    final TinkerGraph tg = TinkerFactory.createModern();

    final GraphWriter writer = getWriter(defaultMapperV2d0);
    final GraphReader reader = getReader(defaultMapperV2d0);

    final TraversalMetrics tm = tg.traversal().V(1).as("a").has("name").as("b").
            out("knows").out("created").as("c").
            has("name", "ripple").values("name").as("d").
            identity().as("e").profile().next();

    try (final ByteArrayOutputStream out = new ByteArrayOutputStream()) {
        writer.writeObject(out, tm);
        final String json = out.toString();

        final TraversalMetrics traversalMetricsRead = (TraversalMetrics)reader.readObject(new ByteArrayInputStream(json.getBytes()), Object.class);
        // toString should be enough to compare TraversalMetrics
        assertTrue(tm.toString().equals(traversalMetricsRead.toString()));
    } catch (IOException e) {
        e.printStackTrace();
        fail("Should not have thrown exception: " + e.getMessage());
    }
}
 
开发者ID:ShiftLeftSecurity,项目名称:tinkergraph-gremlin,代码行数:25,代码来源:TinkerGraphGraphSONSerializerV2d0Test.java


示例2: shouldSerializeTraversalMetrics

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
@Ignore
@Test
@LoadGraphWith(LoadGraphWith.GraphData.MODERN)
public void shouldSerializeTraversalMetrics() throws Exception {
    final ObjectMapper mapper = graph.io(GraphSONIo.build()).mapper().create().createMapper();
    final TraversalMetrics tm = (TraversalMetrics) g.V().both().profile().next();
    final String json = mapper.writeValueAsString(tm);
    final Map<String, Object> m = mapper.readValue(json, mapTypeReference);

    assertTrue(m.containsKey(GraphSONTokens.DURATION));
    assertTrue(m.containsKey(GraphSONTokens.METRICS));

    final List<Map<String, Object>> metrics = (List<Map<String, Object>>) m.get(GraphSONTokens.METRICS);
    assertEquals(2, metrics.size());

    final Map<String, Object> metrics0 = metrics.get(0);
    assertTrue(metrics0.containsKey(GraphSONTokens.ID));
    assertTrue(metrics0.containsKey(GraphSONTokens.NAME));
    assertTrue(metrics0.containsKey(GraphSONTokens.COUNTS));
    assertTrue(metrics0.containsKey(GraphSONTokens.DURATION));
}
 
开发者ID:rayokota,项目名称:hgraphdb,代码行数:22,代码来源:CustomTest.java


示例3: shouldSerializeTraversalMetrics

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
@Test
@LoadGraphWith(LoadGraphWith.GraphData.MODERN)
public void shouldSerializeTraversalMetrics() throws Exception {
    final GryoIo gryoIo = graph.io(GryoIo.build());
    final GryoWriter gryoWriter = gryoIo.writer().create();
    final GryoReader gryoReader = gryoIo.reader().create();

    final TraversalMetrics before = (TraversalMetrics) g.V().both().profile().next();
    final ByteArrayOutputStream outputStream = new ByteArrayOutputStream();
    gryoWriter.writeObject(outputStream, before);

    final ByteArrayInputStream inputStream = new ByteArrayInputStream(outputStream.toByteArray());
    final TraversalMetrics after = gryoReader.readObject(inputStream, TraversalMetrics.class);
    assertNotNull(after);
    assertEquals(before.getMetrics().size(), after.getMetrics().size());
    assertEquals(before.getDuration(TimeUnit.MILLISECONDS), after.getDuration(TimeUnit.MILLISECONDS));
    assertEquals(before.getMetrics(0).getCounts(), after.getMetrics(0).getCounts());
}
 
开发者ID:PKUSilvester,项目名称:LiteGraph,代码行数:19,代码来源:SerializationTest.java


示例4: validate_g_V_out_out_profile_modern

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
private void validate_g_V_out_out_profile_modern(final Traversal traversal, final TraversalMetrics traversalMetrics) {
    traversalMetrics.toString(); // ensure no exceptions are thrown

    Metrics metrics = traversalMetrics.getMetrics(0);
    assertEquals(6, metrics.getCount(TraversalMetrics.TRAVERSER_COUNT_ID).longValue());
    assertEquals(6, metrics.getCount(TraversalMetrics.ELEMENT_COUNT_ID).longValue());

    metrics = traversalMetrics.getMetrics(1);
    assertEquals(6, metrics.getCount(TraversalMetrics.ELEMENT_COUNT_ID).longValue());
    assertNotEquals(0, metrics.getCount(TraversalMetrics.TRAVERSER_COUNT_ID).longValue());

    metrics = traversalMetrics.getMetrics(2);
    assertEquals(2, metrics.getCount(TraversalMetrics.ELEMENT_COUNT_ID).longValue());
    assertNotEquals(0, metrics.getCount(TraversalMetrics.TRAVERSER_COUNT_ID).longValue());

    if (!onGraphComputer(traversal.asAdmin())) {
        // Every other step should be a Profile step
        List<Step> steps = traversal.asAdmin().getSteps();
        for (int ii = 1; ii <= 6; ii += 2) {
            assertEquals("Every other Step should be a ProfileStep.", ProfileStep.class, steps.get(ii).getClass());
        }
    }
}
 
开发者ID:PKUSilvester,项目名称:LiteGraph,代码行数:24,代码来源:ProfileTest.java


示例5: validate_g_V_sideEffectXThread_sleepX10XX_sideEffectXThread_sleepX5XX_profile

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
private void validate_g_V_sideEffectXThread_sleepX10XX_sideEffectXThread_sleepX5XX_profile(TraversalMetrics traversalMetrics) {
    traversalMetrics.toString(); // ensure no exceptions are thrown

    // Grab the second (sideEffect{sleep}) step and check the times.
    Metrics metrics = traversalMetrics.getMetrics(1);
    // 6 elements w/ a 10ms sleep each = 60ms with 10ms for other computation.
    assertTrue("Duration should be at least the length of the sleep (59ms): " + metrics.getDuration(TimeUnit.MILLISECONDS),
            metrics.getDuration(TimeUnit.MILLISECONDS) >= 59);

    // 6 elements w/ a 5ms sleep each = 30ms plus 20ms for other computation
    metrics = traversalMetrics.getMetrics(2);
    assertTrue("Duration should be at least the length of the sleep (29ms): " + metrics.getDuration(TimeUnit.MILLISECONDS),
            metrics.getDuration(TimeUnit.MILLISECONDS) >= 29);

    double totalPercentDuration = 0;
    for (Metrics m : traversalMetrics.getMetrics()) {
        totalPercentDuration += (Double) m.getAnnotation(TraversalMetrics.PERCENT_DURATION_KEY);
    }
    assertEquals(100, totalPercentDuration, 0.000001);
}
 
开发者ID:PKUSilvester,项目名称:LiteGraph,代码行数:21,代码来源:ProfileTest.java


示例6: validate_g_V_whereXinXcreatedX_count_isX1XX_name_profile

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
private void validate_g_V_whereXinXcreatedX_count_isX1XX_name_profile(Traversal traversal, TraversalMetrics traversalMetrics) {
    traversalMetrics.toString(); // ensure no exceptions are thrown

    assertEquals("There should be 3 top-level metrics.", 3, traversalMetrics.getMetrics().size());

    Metrics metrics = traversalMetrics.getMetrics(0);
    assertEquals(6, metrics.getCount(TraversalMetrics.TRAVERSER_COUNT_ID).longValue());
    assertEquals(6, metrics.getCount(TraversalMetrics.ELEMENT_COUNT_ID).longValue());

    metrics = traversalMetrics.getMetrics(1);
    assertEquals(1, metrics.getCount(TraversalMetrics.TRAVERSER_COUNT_ID).longValue());
    assertEquals(1, metrics.getCount(TraversalMetrics.ELEMENT_COUNT_ID).longValue());

    if (traversal.asAdmin().getStrategies().toList().stream().anyMatch(s -> s instanceof RangeByIsCountStrategy)) {
        assertEquals("Metrics 1 should have 4 nested metrics.", 4, metrics.getNested().size());
    } else {
        assertEquals("Metrics 1 should have 3 nested metrics.", 3, metrics.getNested().size());
    }
}
 
开发者ID:PKUSilvester,项目名称:LiteGraph,代码行数:20,代码来源:ProfileTest.java


示例7: verifyMetrics

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
private static void verifyMetrics(Metrics metric, boolean fromCache, boolean multiQuery) {
    assertTrue(metric.getDuration(TimeUnit.MICROSECONDS) > 0);
    assertTrue(metric.getCount(TraversalMetrics.ELEMENT_COUNT_ID) > 0);
    String hasMultiQuery = (String) metric.getAnnotation(QueryProfiler.MULTIQUERY_ANNOTATION);
    assertTrue(multiQuery ? hasMultiQuery.equalsIgnoreCase("true") : hasMultiQuery == null);
    for (Metrics submetric : metric.getNested()) {
        assertTrue(submetric.getDuration(TimeUnit.MICROSECONDS) > 0);
        switch (submetric.getName()) {
            case "optimization":
                assertNull(submetric.getCount(TraversalMetrics.ELEMENT_COUNT_ID));
                break;
            case "backend-query":
                if (fromCache) assertFalse("Should not execute backend-queries when cached", true);
                assertTrue(submetric.getCount(TraversalMetrics.ELEMENT_COUNT_ID) > 0);
                break;
            default:
                assertFalse("Unrecognized nested query: " + submetric.getName(), true);
        }

    }

}
 
开发者ID:graben1437,项目名称:titan1withtp3.1,代码行数:23,代码来源:TitanGraphTest.java


示例8: verifyMetrics

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
private static void verifyMetrics(Metrics metric, boolean fromCache, boolean multiQuery) {
    assertTrue(metric.getDuration(TimeUnit.MICROSECONDS) > 0);
    assertTrue(metric.getCount(TraversalMetrics.ELEMENT_COUNT_ID) > 0);
    String hasMultiQuery = (String) metric.getAnnotation(QueryProfiler.MULTIQUERY_ANNOTATION);
    assertTrue(multiQuery?hasMultiQuery.equalsIgnoreCase("true"):hasMultiQuery==null);
    for (Metrics submetric : metric.getNested()) {
        assertTrue(submetric.getDuration(TimeUnit.MICROSECONDS) > 0);
        switch (submetric.getName()) {
            case "optimization":
                assertNull(submetric.getCount(TraversalMetrics.ELEMENT_COUNT_ID));
                break;
            case "backend-query":
                if (fromCache) assertFalse("Should not execute backend-queries when cached",true);
                assertTrue(submetric.getCount(TraversalMetrics.ELEMENT_COUNT_ID) > 0);
                break;
            default: assertFalse("Unrecognized nested query: " + submetric.getName(),true);
        }

    }

}
 
开发者ID:graben1437,项目名称:titan1.0.1.kafka,代码行数:22,代码来源:TitanGraphTest.java


示例9: workerIterationEnd

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
@Override
public void workerIterationEnd(final Memory memory) {
    // store profile metrics in proper ProfileStep metrics
    if (this.profile) {
        List<ProfileStep> profileSteps = TraversalHelper.getStepsOfAssignableClassRecursively(ProfileStep.class, this.traversal.get());
        // guess the profile step to store data
        int profileStepIndex = memory.getIteration();
        // if we guess wrongly write timing into last step
        profileStepIndex = profileStepIndex >= profileSteps.size() ? profileSteps.size() - 1 : profileStepIndex;
        this.iterationMetrics.finish(0);
        // reset counts
        this.iterationMetrics.setCount(TraversalMetrics.TRAVERSER_COUNT_ID,0);
        if (null != MemoryTraversalSideEffects.getMemorySideEffectsPhase(this.traversal.get())) {
            this.traversal.get().getSideEffects().add(profileSteps.get(profileStepIndex).getId(), this.iterationMetrics);
        }
        this.iterationMetrics = null;
    }
}
 
开发者ID:apache,项目名称:tinkerpop,代码行数:19,代码来源:TraversalVertexProgram.java


示例10: shouldSerializeTraversalMetrics

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
@Test
@LoadGraphWith(LoadGraphWith.GraphData.MODERN)
public void shouldSerializeTraversalMetrics() throws Exception {
    final GryoIo gryoIo = graph.io(GryoIo.build(GryoVersion.V1_0));
    final GryoWriter gryoWriter = gryoIo.writer().create();
    final GryoReader gryoReader = gryoIo.reader().create();

    final TraversalMetrics before = g.V().both().profile().next();
    final ByteArrayOutputStream outputStream = new ByteArrayOutputStream();
    gryoWriter.writeObject(outputStream, before);

    final ByteArrayInputStream inputStream = new ByteArrayInputStream(outputStream.toByteArray());
    final TraversalMetrics after = gryoReader.readObject(inputStream, TraversalMetrics.class);
    assertNotNull(after);
    assertEquals(before.getMetrics().size(), after.getMetrics().size());
    assertEquals(before.getDuration(TimeUnit.MILLISECONDS), after.getDuration(TimeUnit.MILLISECONDS));
    assertEquals(before.getMetrics(0).getCounts(), after.getMetrics().stream().findFirst().get().getCounts());
}
 
开发者ID:apache,项目名称:tinkerpop,代码行数:19,代码来源:SerializationTest.java


示例11: validate_g_V_out_out_profile_modern

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
private void validate_g_V_out_out_profile_modern(final Traversal traversal, final TraversalMetrics traversalMetrics) {
    traversalMetrics.toString(); // ensure no exceptions are thrown

    assumeThat("The following assertions apply to TinkerGraph only as provider strategies can alter the steps to not comply with expectations",
            graph.getClass().getSimpleName(), equalTo("TinkerGraph"));

    Metrics metrics = traversalMetrics.getMetrics(0);
    assertEquals(6, metrics.getCount(TraversalMetrics.TRAVERSER_COUNT_ID).longValue());
    assertEquals(6, metrics.getCount(TraversalMetrics.ELEMENT_COUNT_ID).longValue());

    metrics = traversalMetrics.getMetrics(1);
    assertEquals(6, metrics.getCount(TraversalMetrics.ELEMENT_COUNT_ID).longValue());
    assertNotEquals(0, metrics.getCount(TraversalMetrics.TRAVERSER_COUNT_ID).longValue());

    metrics = traversalMetrics.getMetrics(2);
    assertEquals(2, metrics.getCount(TraversalMetrics.ELEMENT_COUNT_ID).longValue());
    assertNotEquals(0, metrics.getCount(TraversalMetrics.TRAVERSER_COUNT_ID).longValue());

    if (!onGraphComputer(traversal.asAdmin())) {
        // Every other step should be a Profile step
        List<Step> steps = traversal.asAdmin().getSteps();
        for (int ii = 1; ii <= 6; ii += 2) {
            assertEquals("Every other Step should be a ProfileStep.", ProfileStep.class, steps.get(ii).getClass());
        }
    }
}
 
开发者ID:apache,项目名称:tinkerpop,代码行数:27,代码来源:ProfileTest.java


示例12: validate_g_V_sideEffectXThread_sleepX10XX_sideEffectXThread_sleepX5XX_profile

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
private void validate_g_V_sideEffectXThread_sleepX10XX_sideEffectXThread_sleepX5XX_profile(final TraversalMetrics traversalMetrics) {
    traversalMetrics.toString(); // ensure no exceptions are thrown

    assumeThat("The following assertions apply to TinkerGraph only as provider strategies can alter the steps to not comply with expectations",
            graph.getClass().getSimpleName(), equalTo("TinkerGraph"));

    // Grab the second (sideEffect{sleep}) step and check the times.
    Metrics metrics = traversalMetrics.getMetrics(1);
    // 6 elements w/ a 10ms sleep each = 60ms with 10ms for other computation.
    assertTrue("Duration should be at least the length of the sleep (59ms): " + metrics.getDuration(TimeUnit.MILLISECONDS),
            metrics.getDuration(TimeUnit.MILLISECONDS) >= 59);

    // 6 elements w/ a 5ms sleep each = 30ms plus 20ms for other computation
    metrics = traversalMetrics.getMetrics(2);
    assertTrue("Duration should be at least the length of the sleep (29ms): " + metrics.getDuration(TimeUnit.MILLISECONDS),
            metrics.getDuration(TimeUnit.MILLISECONDS) >= 29);

    double totalPercentDuration = 0;
    for (Metrics m : traversalMetrics.getMetrics()) {
        totalPercentDuration += (Double) m.getAnnotation(TraversalMetrics.PERCENT_DURATION_KEY);
    }
    assertEquals(100, totalPercentDuration, 0.000001);
}
 
开发者ID:apache,项目名称:tinkerpop,代码行数:24,代码来源:ProfileTest.java


示例13: validate_g_V_whereXinXcreatedX_count_isX1XX_name_profile

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
private void validate_g_V_whereXinXcreatedX_count_isX1XX_name_profile(final Traversal traversal, final TraversalMetrics traversalMetrics) {
    traversalMetrics.toString(); // ensure no exceptions are thrown

    assumeThat("The following assertions apply to TinkerGraph only as provider strategies can alter the steps to not comply with expectations",
            graph.getClass().getSimpleName(), equalTo("TinkerGraph"));

    assertEquals("There should be 3 top-level metrics.", 3, traversalMetrics.getMetrics().size());

    Metrics metrics = traversalMetrics.getMetrics(0);
    assertEquals(6, metrics.getCount(TraversalMetrics.TRAVERSER_COUNT_ID).longValue());
    assertEquals(6, metrics.getCount(TraversalMetrics.ELEMENT_COUNT_ID).longValue());

    metrics = traversalMetrics.getMetrics(1);
    assertEquals(1, metrics.getCount(TraversalMetrics.TRAVERSER_COUNT_ID).longValue());
    assertEquals(1, metrics.getCount(TraversalMetrics.ELEMENT_COUNT_ID).longValue());

    if (traversal.asAdmin().getStrategies().toList().stream().anyMatch(s -> s instanceof CountStrategy)) {
        assertEquals("Metrics 1 should have 4 nested metrics.", 4, metrics.getNested().size());
    } else {
        assertEquals("Metrics 1 should have 3 nested metrics.", 3, metrics.getNested().size());
    }
}
 
开发者ID:apache,项目名称:tinkerpop,代码行数:23,代码来源:ProfileTest.java


示例14: shouldReadWriteTraversalMetrics

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
@Test
public void shouldReadWriteTraversalMetrics() throws Exception {
    final String resourceName = "traversalmetrics";
    assumeCompatibility(resourceName);

    final TraversalMetrics resource = findModelEntryObject(resourceName);
    final TraversalMetrics fromStatic = (TraversalMetrics) read(getCompatibility().readFromResource(resourceName), getCompatibility().resolve(TraversalMetrics.class));
    final TraversalMetrics recycled = (TraversalMetrics) read(write(fromStatic, TraversalMetrics.class), getCompatibility().resolve(TraversalMetrics.class));
    assertNotSame(fromStatic, recycled);

    // need to assert against each other since the model version can change between test runs as it is dynamically
    // generated
    assertEquals(recycled.getDuration(TimeUnit.MILLISECONDS), fromStatic.getDuration(TimeUnit.MILLISECONDS));
    final Collection<? extends Metrics> resourceMetrics = resource.getMetrics();
    resourceMetrics.forEach(m -> {
        assertEquals(recycled.getMetrics(m.getId()).getAnnotations(), fromStatic.getMetrics(m.getId()).getAnnotations());
        assertEquals(recycled.getMetrics(m.getId()).getName(), fromStatic.getMetrics(m.getId()).getName());
        assertEquals(recycled.getMetrics(m.getId()).getCounts(), fromStatic.getMetrics(m.getId()).getCounts());
    });
}
 
开发者ID:apache,项目名称:tinkerpop,代码行数:21,代码来源:AbstractTypedCompatibilityTest.java


示例15: deserializersTestsMetrics

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
@Test
public void deserializersTestsMetrics() {
    final TinkerGraph tg = TinkerFactory.createModern();

    final GraphWriter writer = getWriter(defaultMapperV2d0);
    final GraphReader reader = getReader(defaultMapperV2d0);

    final TraversalMetrics tm = tg.traversal().V(1).as("a").has("name").as("b").
            out("knows").out("created").as("c").
            has("name", "ripple").values("name").as("d").
            identity().as("e").profile().next();

    final MutableMetrics m = new MutableMetrics(tm.getMetrics(0));
    // making sure nested metrics are included in serde
    m.addNested(new MutableMetrics(tm.getMetrics(1)));

    try (final ByteArrayOutputStream out = new ByteArrayOutputStream()) {
        writer.writeObject(out, m);
        final String json = out.toString();

        final Metrics metricsRead = (Metrics)reader.readObject(new ByteArrayInputStream(json.getBytes()), Object.class);
        // toString should be enough to compare Metrics
        assertTrue(m.toString().equals(metricsRead.toString()));
    } catch (IOException e) {
        e.printStackTrace();
        fail("Should not have thrown exception: " + e.getMessage());
    }
}
 
开发者ID:ShiftLeftSecurity,项目名称:tinkergraph-gremlin,代码行数:29,代码来源:TinkerGraphGraphSONSerializerV2d0Test.java


示例16: serializeInternal

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
private static void serializeInternal(final TraversalMetrics traversalMetrics, final JsonGenerator jsonGenerator) throws IOException {
    // creation of the map enables all the fields to be properly written with their type if required
    final Map<String, Object> m = new HashMap<>();
    m.put(GraphSONTokens.DURATION, traversalMetrics.getDuration(TimeUnit.NANOSECONDS) / 1000000d);
    final List<Map<String, Object>> metrics = new ArrayList<>();
    traversalMetrics.getMetrics().forEach(it -> metrics.add(metricsToMap(it)));
    m.put(GraphSONTokens.METRICS, metrics);

    jsonGenerator.writeObject(m);
}
 
开发者ID:PKUSilvester,项目名称:LiteGraph,代码行数:11,代码来源:GraphSONSerializers.java


示例17: modern_V_out_out_profile

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
@Test
@LoadGraphWith(MODERN)
public void modern_V_out_out_profile() {
    final Traversal<Vertex, TraversalMetrics> traversal = get_g_V_out_out_profile();
    printTraversalForm(traversal);
    validate_g_V_out_out_profile_modern(traversal, traversal.next());
}
 
开发者ID:PKUSilvester,项目名称:LiteGraph,代码行数:8,代码来源:ProfileTest.java


示例18: modern_V_out_out_profileXmetricsX

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
@Test
@LoadGraphWith(MODERN)
public void modern_V_out_out_profileXmetricsX() {
    final Traversal<Vertex, Vertex> traversal = get_g_V_out_out_profileXmetricsX();
    printTraversalForm(traversal);
    traversal.iterate();
    validate_g_V_out_out_profile_modern(traversal, traversal.asAdmin().getSideEffects().<TraversalMetrics>get(METRICS_KEY));
}
 
开发者ID:PKUSilvester,项目名称:LiteGraph,代码行数:9,代码来源:ProfileTest.java


示例19: grateful_V_out_out_profile

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
@Test
@LoadGraphWith(GRATEFUL)
public void grateful_V_out_out_profile() {
    final Traversal<Vertex, TraversalMetrics> traversal = get_g_V_out_out_profile();
    printTraversalForm(traversal);
    final TraversalMetrics traversalMetrics = traversal.next();
    validate_g_V_out_out_profile_grateful(traversalMetrics);
}
 
开发者ID:PKUSilvester,项目名称:LiteGraph,代码行数:9,代码来源:ProfileTest.java


示例20: grateful_V_out_out_profileXmetricsX

import org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics; //导入依赖的package包/类
@Test
@LoadGraphWith(GRATEFUL)
public void grateful_V_out_out_profileXmetricsX() {
    final Traversal<Vertex, Vertex> traversal = get_g_V_out_out_profileXmetricsX();
    printTraversalForm(traversal);
    traversal.iterate();
    final TraversalMetrics traversalMetrics = traversal.asAdmin().getSideEffects().<TraversalMetrics>get(METRICS_KEY);
    validate_g_V_out_out_profile_grateful(traversalMetrics);
}
 
开发者ID:PKUSilvester,项目名称:LiteGraph,代码行数:10,代码来源:ProfileTest.java



注:本文中的org.apache.tinkerpop.gremlin.process.traversal.util.TraversalMetrics类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java ShaderProgramException类代码示例发布时间:2022-05-23
下一篇:
Java ListStore类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap