use of org.apache.nifi.atlas.emulator.Node in project nifi by apache.
the class ITReportLineageToAtlas method testMultipleProcessGroups.
@Test
public void testMultipleProcessGroups() throws Exception {
final TestConfiguration tc = new TestConfiguration("MultipleProcessGroups");
final ProvenanceRecords prs = tc.provenanceRecords;
prs.add(pr("989dabb7-54b9-3c78", "ConsumeKafka_0_11", RECEIVE, "PLAINTEXT://0.kafka.example.com:6667/nifi-test"));
prs.add(pr("767c7bd6-75e3-3f32", "PutHDFS", SEND, "hdfs://nn1.example.com:8020/user/nifi/5262553828219"));
test(tc);
waitNotificationsGetDelivered();
final Lineage lineage = getLineage();
final Node flow = lineage.findNode("nifi_flow", "MultipleProcessGroups", "MultipleProcessGroups@example");
final Node path = lineage.findNode("nifi_flow_path", "ConsumeKafka_0_11, UpdateAttribute, PutHDFS", "989dabb7-54b9-3c78");
final Node kafkaTopic = lineage.findNode("kafka_topic", "nifi-test@example");
final Node hdfsPath = lineage.findNode("hdfs_path", "/user/nifi/5262553828219@example");
lineage.assertLink(flow, path);
lineage.assertLink(kafkaTopic, path);
lineage.assertLink(path, hdfsPath);
}
use of org.apache.nifi.atlas.emulator.Node in project nifi by apache.
the class ITReportLineageToAtlas method testMultiInAndOuts.
@Test
public void testMultiInAndOuts() throws Exception {
final TestConfiguration tc = new TestConfiguration("MultiInAndOuts");
final ProvenanceRecords prs = tc.provenanceRecords;
test(tc);
waitNotificationsGetDelivered();
final Lineage lineage = getLineage();
final Node gen1 = lineage.findNode("nifi_flow_path", "Gen1", "a4bfe4ec-570b-3126");
final Node gen2 = lineage.findNode("nifi_flow_path", "Gen2", "894218d5-dfe9-3ee5");
final Node ua1 = lineage.findNode("nifi_flow_path", "UA1", "5609cb4f-8a95-3b7a");
final Node ua2 = lineage.findNode("nifi_flow_path", "UA2", "6f88b3d9-5723-356a");
final Node ua3 = lineage.findNode("nifi_flow_path", "UA3, UA4, LogAttribute", "3250aeb6-4026-3969");
final Node ua1Q = lineage.findNode("nifi_queue", "queue", "5609cb4f-8a95-3b7a");
final Node ua2Q = lineage.findNode("nifi_queue", "queue", "6f88b3d9-5723-356a");
final Node ua3Q = lineage.findNode("nifi_queue", "queue", "3250aeb6-4026-3969");
lineage.assertLink(gen1, ua1Q);
lineage.assertLink(gen1, ua2Q);
lineage.assertLink(gen2, ua2Q);
lineage.assertLink(ua1Q, ua1);
lineage.assertLink(ua2Q, ua2);
lineage.assertLink(ua1, ua3Q);
lineage.assertLink(ua2, ua3Q);
lineage.assertLink(ua3Q, ua3);
}
Aggregations