protected TransportProtocol protocol(SpDataStream stream) { return stream .getEventGrounding() .getTransportProtocol(); }
protected TransportProtocol protocol(SpDataStream stream) { return stream .getEventGrounding() .getTransportProtocol(); }
public static String extractBroker(AdapterDescription adapterDescription) { EventGrounding eventGrounding = getEventGrounding(adapterDescription); String host = eventGrounding.getTransportProtocol().getBrokerHostname(); int port = ((KafkaTransportProtocol) eventGrounding.getTransportProtocol()).getKafkaPort(); return host + ":" + port; }
public static String extractBroker(AdapterDescription adapterDescription) { String host = adapterDescription.getEventGrounding().getTransportProtocol().getBrokerHostname(); int port = ((KafkaTransportProtocol) adapterDescription.getEventGrounding().getTransportProtocol()).getKafkaPort(); return host + ":" + port; }
public String getBrokerHostname() { if (getEventGrounding() == null || getEventGrounding().getTransportProtocol() == null || getEventGrounding().getTransportProtocol().getBrokerHostname() == null) { return ""; } else { return getEventGrounding().getTransportProtocol().getBrokerHostname(); } }
public String getActualTopicName() { if (getEventGrounding() == null || getEventGrounding().getTransportProtocol() == null || getEventGrounding().getTransportProtocol().getTopicDefinition() == null) { return ""; } else { return getEventGrounding().getTransportProtocol().getTopicDefinition() .getActualTopicName(); } }
private String getOutputTopic() { return spDataStream .getEventGrounding() .getTransportProtocol() .getTopicDefinition() .getActualTopicName(); }
public String getCurrentData() throws SpRuntimeException { if (spDataStream.getEventGrounding().getTransportProtocol() instanceof KafkaTransportProtocol) { return getLatestEventFromKafka(); } else { return getLatestEventFromJms(); } }
public String inputTopic(Integer streamIndex) { return sepaElement .getInputStreams() .get(streamIndex) .getEventGrounding() .getTransportProtocol() .getTopicDefinition() .getActualTopicName(); }
private TransportProtocol protocol() { return params .getGraph() .getOutputStream() .getEventGrounding() .getTransportProtocol(); }
@Override public List<SpInputCollector> getInputCollectors() throws SpRuntimeException { List<SpInputCollector> inputCollectors = new ArrayList<>(); for (SpDataStream is : bindingParams.getGraph().getInputStreams()) { inputCollectors.add(ProtocolManager.findInputCollector(is.getEventGrounding() .getTransportProtocol(), is.getEventGrounding().getTransportFormats().get(0), singletonEngine)); } return inputCollectors; }
public String getCurrentData() throws SpRuntimeException { if (spDataStream.getEventGrounding().getTransportProtocol() instanceof KafkaTransportProtocol) { return getLatestEventFromKafka(); } else { return getLatestEventFromJms(); } }
@Override public List<SpInputCollector> getInputCollectors() throws SpRuntimeException { List<SpInputCollector> inputCollectors = new ArrayList<>(); for (SpDataStream is : bindingParams.getGraph().getInputStreams()) { inputCollectors.add(ProtocolManager.findInputCollector(is.getEventGrounding() .getTransportProtocol(), is.getEventGrounding().getTransportFormats().get(0), singletonEngine)); } return inputCollectors; }
private String getOutputTopic() { return spDataStream .getEventGrounding() .getTransportProtocol() .getTopicDefinition() .getActualTopicName(); }
BindingParams(I graph) { this.graph = graph; this.inEventTypes = new HashMap<>(); graph.getInputStreams().forEach(is -> inEventTypes.put(is.getEventGrounding().getTransportProtocol().getTopicDefinition().getActualTopicName(), SchemaUtils .toRuntimeMap (is.getEventSchema().getEventProperties()))); graph.getInputStreams().forEach(s -> inputStreamParams.add(new InputStreamParams(s))); }
BindingParams(I graph) { this.graph = graph; this.inEventTypes = new HashMap<>(); graph.getInputStreams().forEach(is -> inEventTypes.put(is.getEventGrounding().getTransportProtocol().getTopicDefinition().getActualTopicName(), SchemaUtils .toRuntimeMap (is.getEventSchema().getEventProperties()))); graph.getInputStreams().forEach(s -> inputStreamParams.add(new InputStreamParams(s))); }
public InputStreamParams(SpDataStream inputStream) { super(); this.eventGrounding = inputStream.getEventGrounding(); this.inName = eventGrounding.getTransportProtocol().getTopicDefinition().getActualTopicName(); this.eventSchema = inputStream.getEventSchema(); }
@Override public SpOutputCollector getOutputCollector() throws SpRuntimeException { return ProtocolManager.findOutputCollector(bindingParams.getGraph().getOutputStream() .getEventGrounding().getTransportProtocol(), bindingParams.getGraph().getOutputStream ().getEventGrounding().getTransportFormats().get(0)); }
public EventProcessorBindingParams(DataProcessorInvocation graph) { super(new DataProcessorInvocation(graph)); this.outEventType = SchemaUtils.toRuntimeMap(graph.getOutputStream().getEventSchema().getEventProperties()); outputStream = graph.getOutputStream(); EventGrounding outputGrounding = outputStream.getEventGrounding(); outName = outputGrounding.getTransportProtocol().getTopicDefinition().getActualTopicName(); }
public EventProcessorBindingParams(DataProcessorInvocation graph) { super(new DataProcessorInvocation(graph)); this.outEventType = SchemaUtils.toRuntimeMap(graph.getOutputStream().getEventSchema().getEventProperties()); outputStream = graph.getOutputStream(); EventGrounding outputGrounding = outputStream.getEventGrounding(); outName = outputGrounding.getTransportProtocol().getTopicDefinition().getActualTopicName(); }