Merge pull request #48 from thingsboard/release-1.1
Release 1.1 to master branch
This commit is contained in:
		
						commit
						efb03e4954
					
				@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard</groupId>
 | 
			
		||||
 | 
			
		||||
@ -23,6 +23,7 @@ import java.util.concurrent.ConcurrentHashMap;
 | 
			
		||||
import java.util.concurrent.ConcurrentMap;
 | 
			
		||||
 | 
			
		||||
import lombok.extern.slf4j.Slf4j;
 | 
			
		||||
import org.springframework.beans.factory.BeanCreationNotAllowedException;
 | 
			
		||||
import org.springframework.context.annotation.Lazy;
 | 
			
		||||
import org.springframework.web.bind.annotation.RequestMapping;
 | 
			
		||||
import org.springframework.web.bind.annotation.RestController;
 | 
			
		||||
@ -57,10 +58,12 @@ public class PluginWebSocketHandler extends TextWebSocketHandler implements Plug
 | 
			
		||||
    private static final ConcurrentMap<String, SessionMetaData> internalSessionMap = new ConcurrentHashMap<>();
 | 
			
		||||
    private static final ConcurrentMap<String, String> externalSessionMap = new ConcurrentHashMap<>();
 | 
			
		||||
 | 
			
		||||
    @Autowired @Lazy
 | 
			
		||||
    @Autowired
 | 
			
		||||
    @Lazy
 | 
			
		||||
    private ActorService actorService;
 | 
			
		||||
 | 
			
		||||
    @Autowired @Lazy
 | 
			
		||||
    @Autowired
 | 
			
		||||
    @Lazy
 | 
			
		||||
    private PluginService pluginService;
 | 
			
		||||
 | 
			
		||||
    @Override
 | 
			
		||||
@ -105,7 +108,7 @@ public class PluginWebSocketHandler extends TextWebSocketHandler implements Plug
 | 
			
		||||
        super.handleTransportError(session, tError);
 | 
			
		||||
        SessionMetaData sessionMd = internalSessionMap.get(session.getId());
 | 
			
		||||
        if (sessionMd != null) {
 | 
			
		||||
            actorService.process(new SessionEventPluginWebSocketMsg(sessionMd.sessionRef, SessionEvent.onError(tError)));
 | 
			
		||||
            processInActorService(new SessionEventPluginWebSocketMsg(sessionMd.sessionRef, SessionEvent.onError(tError)));
 | 
			
		||||
        } else {
 | 
			
		||||
            log.warn("[{}] Failed to find session", session.getId());
 | 
			
		||||
        }
 | 
			
		||||
@ -118,11 +121,19 @@ public class PluginWebSocketHandler extends TextWebSocketHandler implements Plug
 | 
			
		||||
        SessionMetaData sessionMd = internalSessionMap.remove(session.getId());
 | 
			
		||||
        if (sessionMd != null) {
 | 
			
		||||
            externalSessionMap.remove(sessionMd.sessionRef.getSessionId());
 | 
			
		||||
            actorService.process(new SessionEventPluginWebSocketMsg(sessionMd.sessionRef, SessionEvent.onClosed()));
 | 
			
		||||
            processInActorService(new SessionEventPluginWebSocketMsg(sessionMd.sessionRef, SessionEvent.onClosed()));
 | 
			
		||||
        }
 | 
			
		||||
        log.info("[{}] Session is closed", session.getId());
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    private void processInActorService(SessionEventPluginWebSocketMsg msg) {
 | 
			
		||||
        try {
 | 
			
		||||
            actorService.process(msg);
 | 
			
		||||
        } catch (BeanCreationNotAllowedException e) {
 | 
			
		||||
            log.warn("[{}] Failed to close session due to possible shutdown state", msg.getSessionRef().getSessionId());
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    private PluginWebsocketSessionRef toRef(WebSocketSession session) throws IOException {
 | 
			
		||||
        URI sessionUri = session.getUri();
 | 
			
		||||
        String path = sessionUri.getPath();
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>common</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.common</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>common</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.common</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>common</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.common</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard</groupId>
 | 
			
		||||
 | 
			
		||||
@ -18,7 +18,7 @@ version: '2'
 | 
			
		||||
 | 
			
		||||
services:
 | 
			
		||||
  thingsboard:
 | 
			
		||||
    image: "thingsboard/application:1.0.1"
 | 
			
		||||
    image: "thingsboard/application:1.1.0"
 | 
			
		||||
    ports:
 | 
			
		||||
      - "8080:8080"
 | 
			
		||||
      - "1883:1883"
 | 
			
		||||
@ -27,7 +27,7 @@ services:
 | 
			
		||||
      - thingsboard.env
 | 
			
		||||
    entrypoint: ./run_thingsboard.sh
 | 
			
		||||
  thingsboard-db-schema:
 | 
			
		||||
    image: "thingsboard/thingsboard-db-schema:1.0.1"
 | 
			
		||||
    image: "thingsboard/thingsboard-db-schema:1.1.0"
 | 
			
		||||
    env_file:
 | 
			
		||||
      - thingsboard-db-schema.env
 | 
			
		||||
    entrypoint: ./install_schema.sh
 | 
			
		||||
 | 
			
		||||
@ -20,8 +20,9 @@ cp ../../dao/src/main/resources/schema.cql schema.cql
 | 
			
		||||
cp ../../dao/src/main/resources/demo-data.cql demo-data.cql
 | 
			
		||||
cp ../../dao/src/main/resources/system-data.cql system-data.cql
 | 
			
		||||
 | 
			
		||||
docker build -t thingsboard/thingsboard-db-schema:1.0.1 .
 | 
			
		||||
docker build -t thingsboard/thingsboard-db-schema:1.1.0 -t thingsboard/thingsboard-db-schema:latest .
 | 
			
		||||
 | 
			
		||||
docker login
 | 
			
		||||
 | 
			
		||||
docker push thingsboard/thingsboard-db-schema:1.0.1
 | 
			
		||||
docker push thingsboard/thingsboard-db-schema:1.1.0
 | 
			
		||||
docker push thingsboard/thingsboard-db-schema:latest
 | 
			
		||||
@ -18,8 +18,9 @@
 | 
			
		||||
 | 
			
		||||
cp ../../application/target/thingsboard.deb thingsboard.deb
 | 
			
		||||
 | 
			
		||||
docker build -t thingsboard/application:1.0.1 .
 | 
			
		||||
docker build -t thingsboard/application:1.1.0 -t thingsboard/application:latest .
 | 
			
		||||
 | 
			
		||||
docker login
 | 
			
		||||
 | 
			
		||||
docker push thingsboard/application:1.0.1
 | 
			
		||||
docker push thingsboard/application:1.1.0
 | 
			
		||||
docker push thingsboard/application:latest
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard</groupId>
 | 
			
		||||
 | 
			
		||||
@ -22,7 +22,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>extensions</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.extensions</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>extensions</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.extensions</groupId>
 | 
			
		||||
 | 
			
		||||
@ -22,7 +22,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>extensions</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.extensions</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard</groupId>
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										2
									
								
								pom.xml
									
									
									
									
									
								
							
							
						
						
									
										2
									
								
								pom.xml
									
									
									
									
									
								
							@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <groupId>org.thingsboard</groupId>
 | 
			
		||||
    <artifactId>thingsboard</artifactId>
 | 
			
		||||
    <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
    <version>1.1.0</version>
 | 
			
		||||
    <packaging>pom</packaging>
 | 
			
		||||
 | 
			
		||||
    <name>Thingsboard</name>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>transport</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.transport</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>transport</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.transport</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>transport</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.transport</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>1.1.0-SNAPSHOT</version>
 | 
			
		||||
        <version>1.1.0</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard</groupId>
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user