Skip to content
This repository was archived by the owner on Nov 13, 2019. It is now read-only.

Commit 7f6822e

Browse files
authored
Merge pull request #9 from hhiden/parameter_pass_through
Parameter pass through
2 parents 423ae40 + 66fd01a commit 7f6822e

File tree

3 files changed

+48
-0
lines changed

3 files changed

+48
-0
lines changed

manager/src/main/webapp/js/ui.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,8 @@ function exportJson(flowName) {
154154

155155
processorJson = {
156156
imageName: block._template.imageName,
157+
templateId: block._template.id,
158+
templateName: block._template.name,
157159
uuid: block._uuid,
158160
settings: settings,
159161
inputs: inputsArray,

model/src/main/java/io/streamzi/openshift/dataflow/model/ProcessorNode.java

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,12 @@ public class ProcessorNode extends ProcessorObject {
2323
/** Unique ID of the node */
2424
private String uuid;
2525

26+
/** Name of the node taken from the template */
27+
private String templateName;
28+
29+
/** ID of the node template */
30+
private String templateId;
31+
2632
/** Runtime settings */
2733
private Map<String, String> settings = new HashMap<>();
2834

@@ -97,4 +103,20 @@ public Map<String, String> getSettings() {
97103
public void setSettings(Map<String, String> settings) {
98104
this.settings = settings;
99105
}
106+
107+
public String getTemplateId() {
108+
return templateId;
109+
}
110+
111+
public void setTemplateId(String templateId) {
112+
this.templateId = templateId;
113+
}
114+
115+
public String getTemplateName() {
116+
return templateName;
117+
}
118+
119+
public void setTemplateName(String templateName) {
120+
this.templateName = templateName;
121+
}
100122
}

model/src/main/java/io/streamzi/openshift/dataflow/model/serialization/SerializedNode.java

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@ public class SerializedNode {
1818
private ProcessorNode node;
1919

2020
private String uuid;
21+
private String templateName;
22+
private String templateId;
2123
private List<String> inputs = new ArrayList<>();
2224
private List<String> outputs = new ArrayList<>();
2325
private String imageName;
@@ -29,6 +31,9 @@ public SerializedNode() {
2931
public SerializedNode(ProcessorNode node) {
3032
this.node = node;
3133
uuid = node.getUuid();
34+
templateId = node.getTemplateId();
35+
templateName = node.getTemplateName();
36+
3237
this.imageName = node.getImageName();
3338
for(String key : node.getSettings().keySet()){
3439
settings.put(key, node.getSettings().get(key));
@@ -49,6 +54,8 @@ public ProcessorNode createNode(){
4954
node.setUuid(uuid);
5055
node.setImageName(imageName);
5156
node.setSettings(settings);
57+
node.setTemplateId(templateId);
58+
node.setTemplateName(templateName);
5259
for(String input : inputs){
5360
node.addInput(new ProcessorInputPort(input));
5461
}
@@ -98,4 +105,21 @@ public Map<String, String> getSettings() {
98105
public void setSettings(Map<String, String> settings) {
99106
this.settings = settings;
100107
}
108+
109+
public String getTemplateId() {
110+
return templateId;
111+
}
112+
113+
public void setTemplateId(String templateId) {
114+
this.templateId = templateId;
115+
}
116+
117+
public String getTemplateName() {
118+
return templateName;
119+
}
120+
121+
public void setTemplateName(String templateName) {
122+
this.templateName = templateName;
123+
}
124+
101125
}

0 commit comments

Comments
 (0)