Commit 30eaa28f6ccdcb889b4044977628bd8fac039b0b

Authored by YevhenBondarenko
Committed by Andrew Shvayka
1 parent 54b0de0c

added rest-client dependencies

@@ -221,6 +221,11 @@ @@ -221,6 +221,11 @@
221 <scope>test</scope> 221 <scope>test</scope>
222 </dependency> 222 </dependency>
223 <dependency> 223 <dependency>
  224 + <groupId>org.thingsboard</groupId>
  225 + <artifactId>rest-client</artifactId>
  226 + <scope>test</scope>
  227 + </dependency>
  228 + <dependency>
224 <groupId>org.springframework.boot</groupId> 229 <groupId>org.springframework.boot</groupId>
225 <artifactId>spring-boot-starter-test</artifactId> 230 <artifactId>spring-boot-starter-test</artifactId>
226 <scope>test</scope> 231 <scope>test</scope>
@@ -38,7 +38,7 @@ import org.junit.rules.TestRule; @@ -38,7 +38,7 @@ import org.junit.rules.TestRule;
38 import org.junit.rules.TestWatcher; 38 import org.junit.rules.TestWatcher;
39 import org.junit.runner.Description; 39 import org.junit.runner.Description;
40 import org.springframework.http.client.HttpComponentsClientHttpRequestFactory; 40 import org.springframework.http.client.HttpComponentsClientHttpRequestFactory;
41 -import org.thingsboard.client.tools.RestClient; 41 +import org.thingsboard.rest.client.RestClient;
42 import org.thingsboard.server.common.data.Device; 42 import org.thingsboard.server.common.data.Device;
43 import org.thingsboard.server.common.data.EntityType; 43 import org.thingsboard.server.common.data.EntityType;
44 import org.thingsboard.server.common.data.id.DeviceId; 44 import org.thingsboard.server.common.data.id.DeviceId;
@@ -434,6 +434,12 @@ @@ -434,6 +434,12 @@
434 </dependency> 434 </dependency>
435 <dependency> 435 <dependency>
436 <groupId>org.thingsboard</groupId> 436 <groupId>org.thingsboard</groupId>
  437 + <artifactId>rest-client</artifactId>
  438 + <version>${project.version}</version>
  439 + <scope>test</scope>
  440 + </dependency>
  441 + <dependency>
  442 + <groupId>org.thingsboard</groupId>
437 <artifactId>dao</artifactId> 443 <artifactId>dao</artifactId>
438 <version>${project.version}</version> 444 <version>${project.version}</version>
439 <type>test-jar</type> 445 <type>test-jar</type>
1 -<?xml version="1.0" encoding="UTF-8"?>  
2 -<project xmlns="http://maven.apache.org/POM/4.0.0"  
3 - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 1 +<!--
  2 +
  3 + Copyright © 2016-2020 The Thingsboard Authors
  4 +
  5 + Licensed under the Apache License, Version 2.0 (the "License");
  6 + you may not use this file except in compliance with the License.
  7 + You may obtain a copy of the License at
  8 +
  9 + http://www.apache.org/licenses/LICENSE-2.0
  10 +
  11 + Unless required by applicable law or agreed to in writing, software
  12 + distributed under the License is distributed on an "AS IS" BASIS,
  13 + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  14 + See the License for the specific language governing permissions and
  15 + limitations under the License.
  16 +
  17 +-->
  18 +<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 19 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
  20 + <modelVersion>4.0.0</modelVersion>
5 <parent> 21 <parent>
6 - <artifactId>thingsboard</artifactId>  
7 <groupId>org.thingsboard</groupId> 22 <groupId>org.thingsboard</groupId>
8 <version>2.5.0-SNAPSHOT</version> 23 <version>2.5.0-SNAPSHOT</version>
  24 + <artifactId>thingsboard</artifactId>
9 </parent> 25 </parent>
10 - <modelVersion>4.0.0</modelVersion>  
11 -  
12 <artifactId>rest-client</artifactId> 26 <artifactId>rest-client</artifactId>
13 <packaging>jar</packaging> 27 <packaging>jar</packaging>
14 28
@@ -31,4 +45,4 @@ @@ -31,4 +45,4 @@
31 </dependency> 45 </dependency>
32 </dependencies> 46 </dependencies>
33 47
34 -</project>  
  48 +</project>
rest-client/src/main/java/org/thingsboard/rest/client/RestClient.java renamed from rest-client/src/main/java/org/thingsboard/client/RestClient.java
@@ -13,7 +13,7 @@ @@ -13,7 +13,7 @@
13 * See the License for the specific language governing permissions and 13 * See the License for the specific language governing permissions and
14 * limitations under the License. 14 * limitations under the License.
15 */ 15 */
16 -package org.thingsboard.client; 16 +package org.thingsboard.rest.client;
17 17
18 import com.fasterxml.jackson.databind.JsonNode; 18 import com.fasterxml.jackson.databind.JsonNode;
19 import com.fasterxml.jackson.databind.ObjectMapper; 19 import com.fasterxml.jackson.databind.ObjectMapper;
@@ -31,7 +31,7 @@ import org.springframework.http.client.support.HttpRequestWrapper; @@ -31,7 +31,7 @@ import org.springframework.http.client.support.HttpRequestWrapper;
31 import org.springframework.util.StringUtils; 31 import org.springframework.util.StringUtils;
32 import org.springframework.web.client.HttpClientErrorException; 32 import org.springframework.web.client.HttpClientErrorException;
33 import org.springframework.web.client.RestTemplate; 33 import org.springframework.web.client.RestTemplate;
34 -import org.thingsboard.client.utils.RestJsonConverter; 34 +import org.thingsboard.rest.client.utils.RestJsonConverter;
35 import org.thingsboard.server.common.data.AdminSettings; 35 import org.thingsboard.server.common.data.AdminSettings;
36 import org.thingsboard.server.common.data.ClaimRequest; 36 import org.thingsboard.server.common.data.ClaimRequest;
37 import org.thingsboard.server.common.data.Customer; 37 import org.thingsboard.server.common.data.Customer;
rest-client/src/main/java/org/thingsboard/rest/client/utils/RestJsonConverter.java renamed from rest-client/src/main/java/org/thingsboard/client/utils/RestJsonConverter.java
@@ -13,7 +13,7 @@ @@ -13,7 +13,7 @@
13 * See the License for the specific language governing permissions and 13 * See the License for the specific language governing permissions and
14 * limitations under the License. 14 * limitations under the License.
15 */ 15 */
16 -package org.thingsboard.client.utils; 16 +package org.thingsboard.rest.client.utils;
17 17
18 import com.fasterxml.jackson.databind.JsonNode; 18 import com.fasterxml.jackson.databind.JsonNode;
19 import org.springframework.util.CollectionUtils; 19 import org.springframework.util.CollectionUtils;