Commit 32b608e10d701f7679b9a925ffbe99587d9f50eb

Authored by Volodymyr Babak
2 parents a1d6cee7 b52d2aae

Merge remote-tracking branch 'origin/develop/2.6-edge' into develop/3.3-edge

@@ -59,7 +59,6 @@ CREATE TABLE IF NOT EXISTS thingsboard.edge ( @@ -59,7 +59,6 @@ CREATE TABLE IF NOT EXISTS thingsboard.edge (
59 secret text, 59 secret text,
60 edge_license_key text, 60 edge_license_key text,
61 cloud_endpoint text, 61 cloud_endpoint text,
62 - configuration text,  
63 additional_info text, 62 additional_info text,
64 PRIMARY KEY (id, tenant_id, customer_id, type) 63 PRIMARY KEY (id, tenant_id, customer_id, type)
65 ); 64 );
@@ -19,7 +19,6 @@ CREATE TABLE IF NOT EXISTS edge ( @@ -19,7 +19,6 @@ CREATE TABLE IF NOT EXISTS edge (
19 additional_info varchar, 19 additional_info varchar,
20 customer_id varchar(31), 20 customer_id varchar(31),
21 root_rule_chain_id varchar(31), 21 root_rule_chain_id varchar(31),
22 - configuration varchar(10000000),  
23 type varchar(255), 22 type varchar(255),
24 name varchar(255), 23 name varchar(255),
25 label varchar(255), 24 label varchar(255),
@@ -976,7 +976,7 @@ public final class EdgeGrpcSession implements Closeable { @@ -976,7 +976,7 @@ public final class EdgeGrpcSession implements Closeable {
976 .setSecret(edge.getSecret()) 976 .setSecret(edge.getSecret())
977 .setEdgeLicenseKey(edge.getEdgeLicenseKey()) 977 .setEdgeLicenseKey(edge.getEdgeLicenseKey())
978 .setCloudEndpoint(edge.getCloudEndpoint()) 978 .setCloudEndpoint(edge.getCloudEndpoint())
979 - .setConfiguration(JacksonUtil.toString(edge.getConfiguration())) 979 + .setAdditionalInfo(JacksonUtil.toString(edge.getAdditionalInfo()))
980 .setCloudType("CE"); 980 .setCloudType("CE");
981 if (edge.getCustomerId() != null) { 981 if (edge.getCustomerId() != null) {
982 builder.setCustomerIdMSB(edge.getCustomerId().getId().getMostSignificantBits()) 982 builder.setCustomerIdMSB(edge.getCustomerId().getId().getMostSignificantBits())
@@ -47,7 +47,6 @@ public class Edge extends SearchTextBasedWithAdditionalInfo<EdgeId> implements H @@ -47,7 +47,6 @@ public class Edge extends SearchTextBasedWithAdditionalInfo<EdgeId> implements H
47 private String secret; 47 private String secret;
48 private String edgeLicenseKey; 48 private String edgeLicenseKey;
49 private String cloudEndpoint; 49 private String cloudEndpoint;
50 - private transient JsonNode configuration;  
51 50
52 public Edge() { 51 public Edge() {
53 super(); 52 super();
@@ -68,7 +67,6 @@ public class Edge extends SearchTextBasedWithAdditionalInfo<EdgeId> implements H @@ -68,7 +67,6 @@ public class Edge extends SearchTextBasedWithAdditionalInfo<EdgeId> implements H
68 this.secret = edge.getSecret(); 67 this.secret = edge.getSecret();
69 this.edgeLicenseKey = edge.getEdgeLicenseKey(); 68 this.edgeLicenseKey = edge.getEdgeLicenseKey();
70 this.cloudEndpoint = edge.getCloudEndpoint(); 69 this.cloudEndpoint = edge.getCloudEndpoint();
71 - this.configuration = edge.getConfiguration();  
72 } 70 }
73 71
74 @Override 72 @Override
@@ -87,7 +87,7 @@ message EdgeConfiguration { @@ -87,7 +87,7 @@ message EdgeConfiguration {
87 string secret = 10; 87 string secret = 10;
88 string edgeLicenseKey = 11; 88 string edgeLicenseKey = 11;
89 string cloudEndpoint = 12; 89 string cloudEndpoint = 12;
90 - string configuration = 13; 90 + string additionalInfo = 13;
91 string cloudType = 14; 91 string cloudType = 14;
92 } 92 }
93 93
@@ -465,7 +465,6 @@ public class ModelConstants { @@ -465,7 +465,6 @@ public class ModelConstants {
465 public static final String EDGE_NAME_PROPERTY = "name"; 465 public static final String EDGE_NAME_PROPERTY = "name";
466 public static final String EDGE_LABEL_PROPERTY = "label"; 466 public static final String EDGE_LABEL_PROPERTY = "label";
467 public static final String EDGE_TYPE_PROPERTY = "type"; 467 public static final String EDGE_TYPE_PROPERTY = "type";
468 - public static final String EDGE_CONFIGURATION_PROPERTY = "configuration";  
469 public static final String EDGE_ADDITIONAL_INFO_PROPERTY = ADDITIONAL_INFO_PROPERTY; 468 public static final String EDGE_ADDITIONAL_INFO_PROPERTY = ADDITIONAL_INFO_PROPERTY;
470 public static final String EDGE_BY_TENANT_AND_SEARCH_TEXT_COLUMN_FAMILY_NAME = "edge_by_tenant_and_search_text"; 469 public static final String EDGE_BY_TENANT_AND_SEARCH_TEXT_COLUMN_FAMILY_NAME = "edge_by_tenant_and_search_text";
471 public static final String EDGE_BY_TENANT_BY_TYPE_AND_SEARCH_TEXT_COLUMN_FAMILY_NAME = "edge_by_tenant_by_type_and_search_text"; 470 public static final String EDGE_BY_TENANT_BY_TYPE_AND_SEARCH_TEXT_COLUMN_FAMILY_NAME = "edge_by_tenant_by_type_and_search_text";
@@ -87,10 +87,6 @@ public abstract class AbstractEdgeEntity<T extends Edge> extends BaseSqlEntity<T @@ -87,10 +87,6 @@ public abstract class AbstractEdgeEntity<T extends Edge> extends BaseSqlEntity<T
87 private String cloudEndpoint; 87 private String cloudEndpoint;
88 88
89 @Type(type = "json") 89 @Type(type = "json")
90 - @Column(name = ModelConstants.EDGE_CONFIGURATION_PROPERTY)  
91 - private JsonNode configuration;  
92 -  
93 - @Type(type = "json")  
94 @Column(name = ModelConstants.EDGE_ADDITIONAL_INFO_PROPERTY) 90 @Column(name = ModelConstants.EDGE_ADDITIONAL_INFO_PROPERTY)
95 private JsonNode additionalInfo; 91 private JsonNode additionalInfo;
96 92
@@ -118,7 +114,6 @@ public abstract class AbstractEdgeEntity<T extends Edge> extends BaseSqlEntity<T @@ -118,7 +114,6 @@ public abstract class AbstractEdgeEntity<T extends Edge> extends BaseSqlEntity<T
118 this.secret = edge.getSecret(); 114 this.secret = edge.getSecret();
119 this.edgeLicenseKey = edge.getEdgeLicenseKey(); 115 this.edgeLicenseKey = edge.getEdgeLicenseKey();
120 this.cloudEndpoint = edge.getCloudEndpoint(); 116 this.cloudEndpoint = edge.getCloudEndpoint();
121 - this.configuration = edge.getConfiguration();  
122 this.additionalInfo = edge.getAdditionalInfo(); 117 this.additionalInfo = edge.getAdditionalInfo();
123 } 118 }
124 119
@@ -135,7 +130,6 @@ public abstract class AbstractEdgeEntity<T extends Edge> extends BaseSqlEntity<T @@ -135,7 +130,6 @@ public abstract class AbstractEdgeEntity<T extends Edge> extends BaseSqlEntity<T
135 this.secret = edgeEntity.getSecret(); 130 this.secret = edgeEntity.getSecret();
136 this.edgeLicenseKey = edgeEntity.getEdgeLicenseKey(); 131 this.edgeLicenseKey = edgeEntity.getEdgeLicenseKey();
137 this.cloudEndpoint = edgeEntity.getCloudEndpoint(); 132 this.cloudEndpoint = edgeEntity.getCloudEndpoint();
138 - this.configuration = edgeEntity.getConfiguration();  
139 this.additionalInfo = edgeEntity.getAdditionalInfo(); 133 this.additionalInfo = edgeEntity.getAdditionalInfo();
140 } 134 }
141 135
@@ -172,7 +166,6 @@ public abstract class AbstractEdgeEntity<T extends Edge> extends BaseSqlEntity<T @@ -172,7 +166,6 @@ public abstract class AbstractEdgeEntity<T extends Edge> extends BaseSqlEntity<T
172 edge.setSecret(secret); 166 edge.setSecret(secret);
173 edge.setEdgeLicenseKey(edgeLicenseKey); 167 edge.setEdgeLicenseKey(edgeLicenseKey);
174 edge.setCloudEndpoint(cloudEndpoint); 168 edge.setCloudEndpoint(cloudEndpoint);
175 - edge.setConfiguration(configuration);  
176 edge.setAdditionalInfo(additionalInfo); 169 edge.setAdditionalInfo(additionalInfo);
177 return edge; 170 return edge;
178 } 171 }
@@ -427,7 +427,6 @@ CREATE TABLE IF NOT EXISTS edge ( @@ -427,7 +427,6 @@ CREATE TABLE IF NOT EXISTS edge (
427 additional_info varchar, 427 additional_info varchar,
428 customer_id uuid, 428 customer_id uuid,
429 root_rule_chain_id uuid, 429 root_rule_chain_id uuid,
430 - configuration varchar(10000000),  
431 type varchar(255), 430 type varchar(255),
432 name varchar(255), 431 name varchar(255),
433 label varchar(255), 432 label varchar(255),
@@ -454,7 +454,6 @@ CREATE TABLE IF NOT EXISTS edge ( @@ -454,7 +454,6 @@ CREATE TABLE IF NOT EXISTS edge (
454 additional_info varchar, 454 additional_info varchar,
455 customer_id uuid, 455 customer_id uuid,
456 root_rule_chain_id uuid, 456 root_rule_chain_id uuid,
457 - configuration varchar(10000000),  
458 type varchar(255), 457 type varchar(255),
459 name varchar(255), 458 name varchar(255),
460 label varchar(255), 459 label varchar(255),