Merge branch 'develop/2.5.1' into oauth2-default-dashboard
This commit is contained in:
		
						commit
						4ed334a5d5
					
				@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <artifactId>application</artifactId>
 | 
			
		||||
 | 
			
		||||
@ -56,6 +56,7 @@ import org.thingsboard.server.dao.audit.AuditLogService;
 | 
			
		||||
import org.thingsboard.server.dao.cassandra.CassandraCluster;
 | 
			
		||||
import org.thingsboard.server.dao.customer.CustomerService;
 | 
			
		||||
import org.thingsboard.server.dao.dashboard.DashboardService;
 | 
			
		||||
import org.thingsboard.server.dao.device.ClaimDevicesService;
 | 
			
		||||
import org.thingsboard.server.dao.device.DeviceService;
 | 
			
		||||
import org.thingsboard.server.dao.entityview.EntityViewService;
 | 
			
		||||
import org.thingsboard.server.dao.event.EventService;
 | 
			
		||||
@ -218,6 +219,10 @@ public class ActorSystemContext {
 | 
			
		||||
    @Getter
 | 
			
		||||
    private MailService mailService;
 | 
			
		||||
 | 
			
		||||
    @Autowired
 | 
			
		||||
    @Getter
 | 
			
		||||
    private ClaimDevicesService claimDevicesService;
 | 
			
		||||
 | 
			
		||||
    //TODO: separate context for TbCore and TbRuleEngine
 | 
			
		||||
    @Autowired(required = false)
 | 
			
		||||
    @Getter
 | 
			
		||||
 | 
			
		||||
@ -39,6 +39,7 @@ import org.thingsboard.server.common.msg.TbMsgMetaData;
 | 
			
		||||
import org.thingsboard.server.common.msg.queue.TbCallback;
 | 
			
		||||
import org.thingsboard.server.common.msg.rpc.ToDeviceRpcRequest;
 | 
			
		||||
import org.thingsboard.server.common.msg.timeout.DeviceActorServerSideRpcTimeoutMsg;
 | 
			
		||||
import org.thingsboard.server.gen.transport.TransportProtos;
 | 
			
		||||
import org.thingsboard.server.gen.transport.TransportProtos.AttributeUpdateNotificationMsg;
 | 
			
		||||
import org.thingsboard.server.gen.transport.TransportProtos.DeviceSessionsCacheEntry;
 | 
			
		||||
import org.thingsboard.server.gen.transport.TransportProtos.GetAttributeRequestMsg;
 | 
			
		||||
@ -232,9 +233,17 @@ class DeviceActorMessageProcessor extends AbstractContextAwareMsgProcessor {
 | 
			
		||||
        if (msg.hasSubscriptionInfo()) {
 | 
			
		||||
            handleSessionActivity(context, msg.getSessionInfo(), msg.getSubscriptionInfo());
 | 
			
		||||
        }
 | 
			
		||||
        if (msg.hasClaimDevice()) {
 | 
			
		||||
            handleClaimDeviceMsg(context, msg.getSessionInfo(), msg.getClaimDevice());
 | 
			
		||||
        }
 | 
			
		||||
        callback.onSuccess();
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    private void handleClaimDeviceMsg(ActorContext context, SessionInfoProto sessionInfo, TransportProtos.ClaimDeviceMsg msg) {
 | 
			
		||||
        DeviceId deviceId = new DeviceId(new UUID(msg.getDeviceIdMSB(), msg.getDeviceIdLSB()));
 | 
			
		||||
        systemContext.getClaimDevicesService().registerClaimingInfo(tenantId, deviceId, msg.getSecretKey(), msg.getDurationMs());
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    private void reportSessionOpen() {
 | 
			
		||||
        systemContext.getDeviceStateService().onDeviceConnect(deviceId);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
@ -131,6 +131,7 @@ public class DefaultSystemDataLoaderService implements SystemDataLoaderService {
 | 
			
		||||
        node.put("username", "");
 | 
			
		||||
        node.put("password", "");
 | 
			
		||||
        node.put("tlsVersion", "TLSv1.2");//NOSONAR, key used to identify password field (not password value itself)
 | 
			
		||||
        node.put("enableProxy", false);
 | 
			
		||||
        mailSettings.setJsonValue(node);
 | 
			
		||||
        adminSettingsService.saveAdminSettings(TenantId.SYS_TENANT_ID, mailSettings);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
@ -115,6 +115,21 @@ public class DefaultMailService implements MailService {
 | 
			
		||||
        if (enableTls && jsonConfig.has("tlsVersion") && StringUtils.isNoneEmpty(jsonConfig.get("tlsVersion").asText())) {
 | 
			
		||||
            javaMailProperties.put(MAIL_PROP + protocol + ".ssl.protocols", jsonConfig.get("tlsVersion").asText());
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        boolean enableProxy = jsonConfig.has("enableProxy") && jsonConfig.get("enableProxy").asBoolean();
 | 
			
		||||
 | 
			
		||||
        if (enableProxy) {
 | 
			
		||||
            javaMailProperties.put(MAIL_PROP + protocol + ".proxy.host", jsonConfig.get("proxyHost").asText());
 | 
			
		||||
            javaMailProperties.put(MAIL_PROP + protocol + ".proxy.port", jsonConfig.get("proxyPort").asText());
 | 
			
		||||
            String proxyUser = jsonConfig.get("proxyUser").asText();
 | 
			
		||||
            if (StringUtils.isNoneEmpty(proxyUser)) {
 | 
			
		||||
                javaMailProperties.put(MAIL_PROP + protocol + ".proxy.user", proxyUser);
 | 
			
		||||
            }
 | 
			
		||||
            String proxyPassword = jsonConfig.get("proxyPassword").asText();
 | 
			
		||||
            if (StringUtils.isNoneEmpty(proxyPassword)) {
 | 
			
		||||
                javaMailProperties.put(MAIL_PROP + protocol + ".proxy.password", proxyPassword);
 | 
			
		||||
            }
 | 
			
		||||
        }
 | 
			
		||||
        return javaMailProperties;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@ -46,6 +46,9 @@ import java.util.concurrent.atomic.AtomicInteger;
 | 
			
		||||
@Service
 | 
			
		||||
public class RemoteJsInvokeService extends AbstractJsInvokeService {
 | 
			
		||||
 | 
			
		||||
    @Value("${queue.js.max_eval_requests_timeout}")
 | 
			
		||||
    private long maxEvalRequestsTimeout;
 | 
			
		||||
 | 
			
		||||
    @Value("${queue.js.max_requests_timeout}")
 | 
			
		||||
    private long maxRequestsTimeout;
 | 
			
		||||
 | 
			
		||||
@ -59,22 +62,22 @@ public class RemoteJsInvokeService extends AbstractJsInvokeService {
 | 
			
		||||
    @Value("${js.remote.stats.enabled:false}")
 | 
			
		||||
    private boolean statsEnabled;
 | 
			
		||||
 | 
			
		||||
    private final AtomicInteger kafkaPushedMsgs = new AtomicInteger(0);
 | 
			
		||||
    private final AtomicInteger kafkaInvokeMsgs = new AtomicInteger(0);
 | 
			
		||||
    private final AtomicInteger kafkaEvalMsgs = new AtomicInteger(0);
 | 
			
		||||
    private final AtomicInteger kafkaFailedMsgs = new AtomicInteger(0);
 | 
			
		||||
    private final AtomicInteger kafkaTimeoutMsgs = new AtomicInteger(0);
 | 
			
		||||
    private final AtomicInteger queuePushedMsgs = new AtomicInteger(0);
 | 
			
		||||
    private final AtomicInteger queueInvokeMsgs = new AtomicInteger(0);
 | 
			
		||||
    private final AtomicInteger queueEvalMsgs = new AtomicInteger(0);
 | 
			
		||||
    private final AtomicInteger queueFailedMsgs = new AtomicInteger(0);
 | 
			
		||||
    private final AtomicInteger queueTimeoutMsgs = new AtomicInteger(0);
 | 
			
		||||
 | 
			
		||||
    @Scheduled(fixedDelayString = "${js.remote.stats.print_interval_ms}")
 | 
			
		||||
    public void printStats() {
 | 
			
		||||
        if (statsEnabled) {
 | 
			
		||||
            int pushedMsgs = kafkaPushedMsgs.getAndSet(0);
 | 
			
		||||
            int invokeMsgs = kafkaInvokeMsgs.getAndSet(0);
 | 
			
		||||
            int evalMsgs = kafkaEvalMsgs.getAndSet(0);
 | 
			
		||||
            int failed = kafkaFailedMsgs.getAndSet(0);
 | 
			
		||||
            int timedOut = kafkaTimeoutMsgs.getAndSet(0);
 | 
			
		||||
            int pushedMsgs = queuePushedMsgs.getAndSet(0);
 | 
			
		||||
            int invokeMsgs = queueInvokeMsgs.getAndSet(0);
 | 
			
		||||
            int evalMsgs = queueEvalMsgs.getAndSet(0);
 | 
			
		||||
            int failed = queueFailedMsgs.getAndSet(0);
 | 
			
		||||
            int timedOut = queueTimeoutMsgs.getAndSet(0);
 | 
			
		||||
            if (pushedMsgs > 0 || invokeMsgs > 0 || evalMsgs > 0 || failed > 0 || timedOut > 0) {
 | 
			
		||||
                log.info("Kafka JS Invoke Stats: pushed [{}] received [{}] invoke [{}] eval [{}] failed [{}] timedOut [{}]",
 | 
			
		||||
                log.info("Queue JS Invoke Stats: pushed [{}] received [{}] invoke [{}] eval [{}] failed [{}] timedOut [{}]",
 | 
			
		||||
                        pushedMsgs, invokeMsgs + evalMsgs, invokeMsgs, evalMsgs, failed, timedOut);
 | 
			
		||||
            }
 | 
			
		||||
        }
 | 
			
		||||
@ -113,22 +116,22 @@ public class RemoteJsInvokeService extends AbstractJsInvokeService {
 | 
			
		||||
 | 
			
		||||
        log.trace("Post compile request for scriptId [{}]", scriptId);
 | 
			
		||||
        ListenableFuture<TbProtoQueueMsg<JsInvokeProtos.RemoteJsResponse>> future = requestTemplate.send(new TbProtoJsQueueMsg<>(UUID.randomUUID(), jsRequestWrapper));
 | 
			
		||||
        if (maxRequestsTimeout > 0) {
 | 
			
		||||
            future = Futures.withTimeout(future, maxRequestsTimeout, TimeUnit.MILLISECONDS, timeoutExecutorService);
 | 
			
		||||
        if (maxEvalRequestsTimeout > 0) {
 | 
			
		||||
            future = Futures.withTimeout(future, maxEvalRequestsTimeout, TimeUnit.MILLISECONDS, timeoutExecutorService);
 | 
			
		||||
        }
 | 
			
		||||
        kafkaPushedMsgs.incrementAndGet();
 | 
			
		||||
        queuePushedMsgs.incrementAndGet();
 | 
			
		||||
        Futures.addCallback(future, new FutureCallback<TbProtoQueueMsg<JsInvokeProtos.RemoteJsResponse>>() {
 | 
			
		||||
            @Override
 | 
			
		||||
            public void onSuccess(@Nullable TbProtoQueueMsg<JsInvokeProtos.RemoteJsResponse> result) {
 | 
			
		||||
                kafkaEvalMsgs.incrementAndGet();
 | 
			
		||||
                queueEvalMsgs.incrementAndGet();
 | 
			
		||||
            }
 | 
			
		||||
 | 
			
		||||
            @Override
 | 
			
		||||
            public void onFailure(Throwable t) {
 | 
			
		||||
                if (t instanceof TimeoutException || (t.getCause() != null && t.getCause() instanceof TimeoutException)) {
 | 
			
		||||
                    kafkaTimeoutMsgs.incrementAndGet();
 | 
			
		||||
                    queueTimeoutMsgs.incrementAndGet();
 | 
			
		||||
                }
 | 
			
		||||
                kafkaFailedMsgs.incrementAndGet();
 | 
			
		||||
                queueFailedMsgs.incrementAndGet();
 | 
			
		||||
            }
 | 
			
		||||
        }, MoreExecutors.directExecutor());
 | 
			
		||||
        return Futures.transform(future, response -> {
 | 
			
		||||
@ -170,20 +173,20 @@ public class RemoteJsInvokeService extends AbstractJsInvokeService {
 | 
			
		||||
        if (maxRequestsTimeout > 0) {
 | 
			
		||||
            future = Futures.withTimeout(future, maxRequestsTimeout, TimeUnit.MILLISECONDS, timeoutExecutorService);
 | 
			
		||||
        }
 | 
			
		||||
        kafkaPushedMsgs.incrementAndGet();
 | 
			
		||||
        queuePushedMsgs.incrementAndGet();
 | 
			
		||||
        Futures.addCallback(future, new FutureCallback<TbProtoQueueMsg<JsInvokeProtos.RemoteJsResponse>>() {
 | 
			
		||||
            @Override
 | 
			
		||||
            public void onSuccess(@Nullable TbProtoQueueMsg<JsInvokeProtos.RemoteJsResponse> result) {
 | 
			
		||||
                kafkaInvokeMsgs.incrementAndGet();
 | 
			
		||||
                queueInvokeMsgs.incrementAndGet();
 | 
			
		||||
            }
 | 
			
		||||
 | 
			
		||||
            @Override
 | 
			
		||||
            public void onFailure(Throwable t) {
 | 
			
		||||
                onScriptExecutionError(scriptId);
 | 
			
		||||
                if (t instanceof TimeoutException || (t.getCause() != null && t.getCause() instanceof TimeoutException)) {
 | 
			
		||||
                    kafkaTimeoutMsgs.incrementAndGet();
 | 
			
		||||
                    queueTimeoutMsgs.incrementAndGet();
 | 
			
		||||
                }
 | 
			
		||||
                kafkaFailedMsgs.incrementAndGet();
 | 
			
		||||
                queueFailedMsgs.incrementAndGet();
 | 
			
		||||
            }
 | 
			
		||||
        }, MoreExecutors.directExecutor());
 | 
			
		||||
        return Futures.transform(future, response -> {
 | 
			
		||||
 | 
			
		||||
@ -224,7 +224,7 @@ public class DefaultSubscriptionManagerService implements SubscriptionManagerSer
 | 
			
		||||
                        return null;
 | 
			
		||||
                    }
 | 
			
		||||
                },
 | 
			
		||||
                s -> (StringUtils.isEmpty(s.getScope()) || scope.equals(s.getScope().name())),
 | 
			
		||||
                s -> (TbAttributeSubscriptionScope.ANY_SCOPE.equals(s.getScope()) || scope.equals(s.getScope().name())),
 | 
			
		||||
                s -> {
 | 
			
		||||
                    List<TsKvEntry> subscriptionUpdate = null;
 | 
			
		||||
                    for (AttributeKvEntry kv : attributes) {
 | 
			
		||||
 | 
			
		||||
@ -17,6 +17,6 @@ package org.thingsboard.server.service.subscription;
 | 
			
		||||
 | 
			
		||||
public enum TbAttributeSubscriptionScope {
 | 
			
		||||
 | 
			
		||||
    CLIENT_SCOPE, SHARED_SCOPE, SERVER_SCOPE
 | 
			
		||||
    ANY_SCOPE, CLIENT_SCOPE, SHARED_SCOPE, SERVER_SCOPE
 | 
			
		||||
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
@ -345,7 +345,7 @@ public class DefaultTelemetryWebSocketService implements TelemetryWebSocketServi
 | 
			
		||||
                keys.forEach(key -> subState.put(key, 0L));
 | 
			
		||||
                attributesData.forEach(v -> subState.put(v.getKey(), v.getTs()));
 | 
			
		||||
 | 
			
		||||
                TbAttributeSubscriptionScope scope = StringUtils.isEmpty(cmd.getScope()) ? TbAttributeSubscriptionScope.SERVER_SCOPE : TbAttributeSubscriptionScope.valueOf(cmd.getScope());
 | 
			
		||||
                TbAttributeSubscriptionScope scope = StringUtils.isEmpty(cmd.getScope()) ? TbAttributeSubscriptionScope.ANY_SCOPE : TbAttributeSubscriptionScope.valueOf(cmd.getScope());
 | 
			
		||||
 | 
			
		||||
                TbAttributeSubscription sub = TbAttributeSubscription.builder()
 | 
			
		||||
                        .serviceId(serviceId)
 | 
			
		||||
@ -442,7 +442,7 @@ public class DefaultTelemetryWebSocketService implements TelemetryWebSocketServi
 | 
			
		||||
                Map<String, Long> subState = new HashMap<>(attributesData.size());
 | 
			
		||||
                attributesData.forEach(v -> subState.put(v.getKey(), v.getTs()));
 | 
			
		||||
 | 
			
		||||
                TbAttributeSubscriptionScope scope = StringUtils.isEmpty(cmd.getScope()) ? TbAttributeSubscriptionScope.SERVER_SCOPE : TbAttributeSubscriptionScope.valueOf(cmd.getScope());
 | 
			
		||||
                TbAttributeSubscriptionScope scope = StringUtils.isEmpty(cmd.getScope()) ? TbAttributeSubscriptionScope.ANY_SCOPE : TbAttributeSubscriptionScope.valueOf(cmd.getScope());
 | 
			
		||||
 | 
			
		||||
                TbAttributeSubscription sub = TbAttributeSubscription.builder()
 | 
			
		||||
                        .serviceId(serviceId)
 | 
			
		||||
 | 
			
		||||
@ -673,6 +673,8 @@ queue:
 | 
			
		||||
    # JS Eval max pending requests
 | 
			
		||||
    max_pending_requests: "${REMOTE_JS_MAX_PENDING_REQUESTS:10000}"
 | 
			
		||||
    # JS Eval max request timeout
 | 
			
		||||
    max_eval_requests_timeout: "${REMOTE_JS_MAX_EVAL_REQUEST_TIMEOUT:60000}"
 | 
			
		||||
    # JS max request timeout
 | 
			
		||||
    max_requests_timeout: "${REMOTE_JS_MAX_REQUEST_TIMEOUT:10000}"
 | 
			
		||||
    # JS response poll interval
 | 
			
		||||
    response_poll_interval: "${REMOTE_JS_RESPONSE_POLL_INTERVAL_MS:25}"
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</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>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</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>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</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>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <artifactId>common</artifactId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>common</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.common</groupId>
 | 
			
		||||
 | 
			
		||||
@ -200,7 +200,7 @@ public class KafkaMonolithQueueFactory implements TbCoreQueueFactory, TbRuleEngi
 | 
			
		||||
        consumerBuilder.settings(kafkaSettings);
 | 
			
		||||
        consumerBuilder.topic(transportApiSettings.getRequestsTopic());
 | 
			
		||||
        consumerBuilder.clientId("monolith-transport-api-consumer-" + serviceInfoProvider.getServiceId());
 | 
			
		||||
        consumerBuilder.groupId("monolith-transport-api-consumer-" + serviceInfoProvider.getServiceId());
 | 
			
		||||
        consumerBuilder.groupId("monolith-transport-api-consumer");
 | 
			
		||||
        consumerBuilder.decoder(msg -> new TbProtoQueueMsg<>(msg.getKey(), TransportApiRequestMsg.parseFrom(msg.getData()), msg.getHeaders()));
 | 
			
		||||
        consumerBuilder.admin(transportApiAdmin);
 | 
			
		||||
        return consumerBuilder.build();
 | 
			
		||||
 | 
			
		||||
@ -170,7 +170,7 @@ public class KafkaTbCoreQueueFactory implements TbCoreQueueFactory {
 | 
			
		||||
        consumerBuilder.settings(kafkaSettings);
 | 
			
		||||
        consumerBuilder.topic(transportApiSettings.getRequestsTopic());
 | 
			
		||||
        consumerBuilder.clientId("tb-core-transport-api-consumer-" + serviceInfoProvider.getServiceId());
 | 
			
		||||
        consumerBuilder.groupId("tb-core-transport-api-consumer-" + serviceInfoProvider.getServiceId());
 | 
			
		||||
        consumerBuilder.groupId("tb-core-transport-api-consumer");
 | 
			
		||||
        consumerBuilder.decoder(msg -> new TbProtoQueueMsg<>(msg.getKey(), TransportApiRequestMsg.parseFrom(msg.getData()), msg.getHeaders()));
 | 
			
		||||
        consumerBuilder.admin(transportApiAdmin);
 | 
			
		||||
        return consumerBuilder.build();
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard.common</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>transport</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.common.transport</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard.common</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>transport</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.common.transport</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard.common</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>transport</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.common.transport</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>common</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.common</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard.common</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>transport</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.common.transport</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</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>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <artifactId>dao</artifactId>
 | 
			
		||||
 | 
			
		||||
@ -19,10 +19,10 @@ version: '2.2'
 | 
			
		||||
services:
 | 
			
		||||
  tb-js-executor:
 | 
			
		||||
    env_file:
 | 
			
		||||
      - queue-pubsub.env.env
 | 
			
		||||
      - queue-pubsub.env
 | 
			
		||||
  tb-core1:
 | 
			
		||||
    env_file:
 | 
			
		||||
      - queue-pubsub.env.env
 | 
			
		||||
      - queue-pubsub.env
 | 
			
		||||
    depends_on:
 | 
			
		||||
      - zookeeper
 | 
			
		||||
      - redis
 | 
			
		||||
 | 
			
		||||
@ -1,3 +1,3 @@
 | 
			
		||||
TB_QUEUE_TYPE=pubsub
 | 
			
		||||
TB_QUEUE_PUBSUB_PROJECT_ID=YOUR_PROJECT_ID
 | 
			
		||||
TB_QUEUE_PUBSUB_SERVICE_ACCOUNT=YOUR_SERVICE_ACCOUNT
 | 
			
		||||
TB_QUEUE_PUBSUB_SERVICE_ACCOUNT=YOUR_SERVICE_ACCOUNT
 | 
			
		||||
 | 
			
		||||
@ -1,4 +1,4 @@
 | 
			
		||||
TB_QUEUE_TYPE=service-bus
 | 
			
		||||
TB_QUEUE_SERVICE_BUS_NAMESPACE_NAME=YOUR_NAMESPACE_NAME
 | 
			
		||||
TB_QUEUE_SERVICE_BUS_SAS_KEY_NAME=YOUR_SAS_KEY_NAME
 | 
			
		||||
TB_QUEUE_SERVICE_BUS_SAS_KEY=YOUR_SAS_KEY
 | 
			
		||||
TB_QUEUE_SERVICE_BUS_SAS_KEY=YOUR_SAS_KEY
 | 
			
		||||
 | 
			
		||||
@ -21,7 +21,7 @@
 | 
			
		||||
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>msa</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.msa</groupId>
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										1319
									
								
								msa/js-executor/package-lock.json
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										1319
									
								
								msa/js-executor/package-lock.json
									
									
									
										generated
									
									
									
								
							
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>msa</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.msa</groupId>
 | 
			
		||||
 | 
			
		||||
@ -100,7 +100,7 @@ function AwsSqsProducer() {
 | 
			
		||||
        const params = {
 | 
			
		||||
            MaxNumberOfMessages: 10,
 | 
			
		||||
            QueueUrl: requestQueueURL,
 | 
			
		||||
            WaitTimeSeconds: poolInterval / 1000
 | 
			
		||||
            WaitTimeSeconds: pollInterval / 1000
 | 
			
		||||
        };
 | 
			
		||||
        while (!stopped) {
 | 
			
		||||
            let pollStartTs = new Date().getTime();
 | 
			
		||||
 | 
			
		||||
@ -68,9 +68,8 @@ function RabbitMqProducer() {
 | 
			
		||||
(async () => {
 | 
			
		||||
    try {
 | 
			
		||||
        logger.info('Starting ThingsBoard JavaScript Executor Microservice...');
 | 
			
		||||
        const url = `amqp://${host}:${port}${vhost}`;
 | 
			
		||||
        const url = `amqp://${username}:${password}@${host}:${port}${vhost}`;
 | 
			
		||||
 | 
			
		||||
        amqp.credentials.amqplain(username, password);
 | 
			
		||||
        connection = await new Promise((resolve, reject) => {
 | 
			
		||||
            amqp.connect(url, function (err, connection) {
 | 
			
		||||
                if (err) {
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <artifactId>msa</artifactId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>msa</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.msa</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>msa</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.msa</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard.msa</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>transport</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.msa.transport</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard.msa</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>transport</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.msa.transport</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard.msa</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>transport</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.msa.transport</groupId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>msa</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.msa</groupId>
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										2
									
								
								msa/web-ui/package-lock.json
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										2
									
								
								msa/web-ui/package-lock.json
									
									
									
										generated
									
									
									
								
							@ -1,6 +1,6 @@
 | 
			
		||||
{
 | 
			
		||||
  "name": "thingsboard-web-ui",
 | 
			
		||||
  "version": "2.4.3",
 | 
			
		||||
  "version": "2.5.0",
 | 
			
		||||
  "lockfileVersion": 1,
 | 
			
		||||
  "requires": true,
 | 
			
		||||
  "dependencies": {
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>msa</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.msa</groupId>
 | 
			
		||||
 | 
			
		||||
@ -19,12 +19,12 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard</groupId>
 | 
			
		||||
    <artifactId>netty-mqtt</artifactId>
 | 
			
		||||
    <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
    <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
    <packaging>jar</packaging>
 | 
			
		||||
 | 
			
		||||
    <name>Netty MQTT Client</name>
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										2
									
								
								pom.xml
									
									
									
									
									
								
							
							
						
						
									
										2
									
								
								pom.xml
									
									
									
									
									
								
							@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <groupId>org.thingsboard</groupId>
 | 
			
		||||
    <artifactId>thingsboard</artifactId>
 | 
			
		||||
    <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
    <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
    <packaging>pom</packaging>
 | 
			
		||||
 | 
			
		||||
    <name>Thingsboard</name>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <artifactId>rest-client</artifactId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <artifactId>rule-engine</artifactId>
 | 
			
		||||
 | 
			
		||||
@ -22,7 +22,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>rule-engine</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.rule-engine</groupId>
 | 
			
		||||
 | 
			
		||||
@ -22,7 +22,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>rule-engine</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.rule-engine</groupId>
 | 
			
		||||
 | 
			
		||||
@ -147,6 +147,16 @@ public class TbSendEmailNode implements TbNode {
 | 
			
		||||
        if (this.config.isEnableTls() && StringUtils.isNoneEmpty(this.config.getTlsVersion())) {
 | 
			
		||||
            javaMailProperties.put(MAIL_PROP + protocol + ".ssl.protocols", this.config.getTlsVersion());
 | 
			
		||||
        }
 | 
			
		||||
        if (this.config.isEnableProxy()) {
 | 
			
		||||
            javaMailProperties.put(MAIL_PROP + protocol + ".proxy.host", config.getProxyHost());
 | 
			
		||||
            javaMailProperties.put(MAIL_PROP + protocol + ".proxy.port", config.getProxyPort());
 | 
			
		||||
            if (StringUtils.isNoneEmpty(config.getProxyUser())) {
 | 
			
		||||
                javaMailProperties.put(MAIL_PROP + protocol + ".proxy.user", config.getProxyUser());
 | 
			
		||||
            }
 | 
			
		||||
            if (StringUtils.isNoneEmpty(config.getProxyPassword())) {
 | 
			
		||||
                javaMailProperties.put(MAIL_PROP + protocol + ".proxy.password", config.getProxyPassword());
 | 
			
		||||
            }
 | 
			
		||||
        }
 | 
			
		||||
        return javaMailProperties;
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
@ -30,6 +30,11 @@ public class TbSendEmailNodeConfiguration implements NodeConfiguration {
 | 
			
		||||
    private int timeout;
 | 
			
		||||
    private boolean enableTls;
 | 
			
		||||
    private String tlsVersion;
 | 
			
		||||
    private boolean enableProxy;
 | 
			
		||||
    private String proxyHost;
 | 
			
		||||
    private String proxyPort;
 | 
			
		||||
    private String proxyUser;
 | 
			
		||||
    private String proxyPassword;
 | 
			
		||||
 | 
			
		||||
    @Override
 | 
			
		||||
    public TbSendEmailNodeConfiguration defaultConfiguration() {
 | 
			
		||||
@ -41,6 +46,7 @@ public class TbSendEmailNodeConfiguration implements NodeConfiguration {
 | 
			
		||||
        configuration.setTimeout(10000);
 | 
			
		||||
        configuration.setEnableTls(false);
 | 
			
		||||
        configuration.setTlsVersion("TLSv1.2");
 | 
			
		||||
        configuration.setEnableProxy(false);
 | 
			
		||||
        return configuration;
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
@ -48,7 +48,7 @@ public class TbSynchronizationBeginNode implements TbNode {
 | 
			
		||||
 | 
			
		||||
    @Override
 | 
			
		||||
    public void onMsg(TbContext ctx, TbMsg msg) {
 | 
			
		||||
        log.warn("Synchronization Start/End nodes are deprecated since TB 2.5. Use queue with submit strategy SEQUENTIAL_WITHIN_ORIGINATOR instead.");
 | 
			
		||||
        log.warn("Synchronization Start/End nodes are deprecated since TB 2.5. Use queue with submit strategy SEQUENTIAL_BY_ORIGINATOR instead.");
 | 
			
		||||
        ctx.tellSuccess(msg);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@ -49,7 +49,7 @@ public class TbSynchronizationEndNode implements TbNode {
 | 
			
		||||
 | 
			
		||||
    @Override
 | 
			
		||||
    public void onMsg(TbContext ctx, TbMsg msg) {
 | 
			
		||||
        log.warn("Synchronization Start/End nodes are deprecated since TB 2.5. Use queue with submit strategy SEQUENTIAL_WITHIN_ORIGINATOR instead.");
 | 
			
		||||
        log.warn("Synchronization Start/End nodes are deprecated since TB 2.5. Use queue with submit strategy SEQUENTIAL_BY_ORIGINATOR instead.");
 | 
			
		||||
        ctx.tellSuccess(msg);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
										
											
												File diff suppressed because one or more lines are too long
											
										
									
								
							@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <artifactId>tools</artifactId>
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>transport</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.transport</groupId>
 | 
			
		||||
 | 
			
		||||
@ -155,19 +155,19 @@ queue:
 | 
			
		||||
    pack-processing-timeout: "${TB_QUEUE_RULE_ENGINE_PACK_PROCESSING_TIMEOUT_MS:60000}"
 | 
			
		||||
    stats:
 | 
			
		||||
      enabled: "${TB_QUEUE_RULE_ENGINE_STATS_ENABLED:true}"
 | 
			
		||||
      print-interval-ms: "${TB_QUEUE_RULE_ENGINE_STATS_PRINT_INTERVAL_MS:10000}"
 | 
			
		||||
      print-interval-ms: "${TB_QUEUE_RULE_ENGINE_STATS_PRINT_INTERVAL_MS:60000}"
 | 
			
		||||
    queues:
 | 
			
		||||
      - name: "Main"
 | 
			
		||||
      - name: "${TB_QUEUE_RE_MAIN_QUEUE_NAME:Main}"
 | 
			
		||||
        topic: "${TB_QUEUE_RE_MAIN_TOPIC:tb_rule_engine.main}"
 | 
			
		||||
        poll-interval: "${TB_QUEUE_RE_MAIN_POLL_INTERVAL_MS:25}"
 | 
			
		||||
        partitions: "${TB_QUEUE_RE_MAIN_PARTITIONS:10}"
 | 
			
		||||
        pack-processing-timeout: "${TB_QUEUE_RE_MAIN_PACK_PROCESSING_TIMEOUT_MS:60000}"
 | 
			
		||||
        submit-strategy:
 | 
			
		||||
          type: "${TB_QUEUE_RE_MAIN_SUBMIT_STRATEGY_TYPE:BURST}" # BURST, BATCH, SEQUENTIAL_WITHIN_ORIGINATOR, SEQUENTIAL_WITHIN_TENANT, SEQUENTIAL
 | 
			
		||||
          type: "${TB_QUEUE_RE_MAIN_SUBMIT_STRATEGY_TYPE:BURST}" # BURST, BATCH, SEQUENTIAL_BY_ORIGINATOR, SEQUENTIAL_BY_TENANT, SEQUENTIAL
 | 
			
		||||
          # For BATCH only
 | 
			
		||||
          batch-size: "${TB_QUEUE_RE_MAIN_SUBMIT_STRATEGY_BATCH_SIZE:1000}" # Maximum number of messages in batch
 | 
			
		||||
        processing-strategy:
 | 
			
		||||
          type: "${TB_QUEUE_RE_MAIN_PROCESSING_STRATEGY_TYPE:RETRY_FAILED_AND_TIMED_OUT}" # SKIP_ALL_FAILURES, RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT
 | 
			
		||||
          type: "${TB_QUEUE_RE_MAIN_PROCESSING_STRATEGY_TYPE:SKIP_ALL_FAILURES}" # SKIP_ALL_FAILURES, RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT
 | 
			
		||||
          # For RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT
 | 
			
		||||
          retries: "${TB_QUEUE_RE_MAIN_PROCESSING_STRATEGY_RETRIES:3}" # Number of retries, 0 is unlimited
 | 
			
		||||
          failure-percentage: "${TB_QUEUE_RE_MAIN_PROCESSING_STRATEGY_FAILURE_PERCENTAGE:0}" # Skip retry if failures or timeouts are less then X percentage of messages;
 | 
			
		||||
@ -175,10 +175,10 @@ queue:
 | 
			
		||||
      - name: "${TB_QUEUE_RE_HP_QUEUE_NAME:HighPriority}"
 | 
			
		||||
        topic: "${TB_QUEUE_RE_HP_TOPIC:tb_rule_engine.hp}"
 | 
			
		||||
        poll-interval: "${TB_QUEUE_RE_HP_POLL_INTERVAL_MS:25}"
 | 
			
		||||
        partitions: "${TB_QUEUE_RE_HP_PARTITIONS:3}"
 | 
			
		||||
        partitions: "${TB_QUEUE_RE_HP_PARTITIONS:10}"
 | 
			
		||||
        pack-processing-timeout: "${TB_QUEUE_RE_HP_PACK_PROCESSING_TIMEOUT_MS:60000}"
 | 
			
		||||
        submit-strategy:
 | 
			
		||||
          type: "${TB_QUEUE_RE_HP_SUBMIT_STRATEGY_TYPE:SEQUENTIAL_WITHIN_ORIGINATOR}" # BURST, BATCH, SEQUENTIAL_WITHIN_ORIGINATOR, SEQUENTIAL_WITHIN_TENANT, SEQUENTIAL
 | 
			
		||||
          type: "${TB_QUEUE_RE_HP_SUBMIT_STRATEGY_TYPE:BURST}" # BURST, BATCH, SEQUENTIAL_BY_ORIGINATOR, SEQUENTIAL_BY_TENANT, SEQUENTIAL
 | 
			
		||||
          # For BATCH only
 | 
			
		||||
          batch-size: "${TB_QUEUE_RE_HP_SUBMIT_STRATEGY_BATCH_SIZE:100}" # Maximum number of messages in batch
 | 
			
		||||
        processing-strategy:
 | 
			
		||||
@ -187,6 +187,21 @@ queue:
 | 
			
		||||
          retries: "${TB_QUEUE_RE_HP_PROCESSING_STRATEGY_RETRIES:0}" # Number of retries, 0 is unlimited
 | 
			
		||||
          failure-percentage: "${TB_QUEUE_RE_HP_PROCESSING_STRATEGY_FAILURE_PERCENTAGE:0}" # Skip retry if failures or timeouts are less then X percentage of messages;
 | 
			
		||||
          pause-between-retries: "${TB_QUEUE_RE_HP_PROCESSING_STRATEGY_RETRY_PAUSE:5}"# Time in seconds to wait in consumer thread before retries;
 | 
			
		||||
      - name: "${TB_QUEUE_RE_SQ_QUEUE_NAME:SequentialByOriginator}"
 | 
			
		||||
        topic: "${TB_QUEUE_RE_SQ_TOPIC:tb_rule_engine.sq}"
 | 
			
		||||
        poll-interval: "${TB_QUEUE_RE_SQ_POLL_INTERVAL_MS:25}"
 | 
			
		||||
        partitions: "${TB_QUEUE_RE_SQ_PARTITIONS:10}"
 | 
			
		||||
        pack-processing-timeout: "${TB_QUEUE_RE_SQ_PACK_PROCESSING_TIMEOUT_MS:60000}"
 | 
			
		||||
        submit-strategy:
 | 
			
		||||
          type: "${TB_QUEUE_RE_SQ_SUBMIT_STRATEGY_TYPE:SEQUENTIAL_BY_ORIGINATOR}" # BURST, BATCH, SEQUENTIAL_BY_ORIGINATOR, SEQUENTIAL_BY_TENANT, SEQUENTIAL
 | 
			
		||||
          # For BATCH only
 | 
			
		||||
          batch-size: "${TB_QUEUE_RE_SQ_SUBMIT_STRATEGY_BATCH_SIZE:100}" # Maximum number of messages in batch
 | 
			
		||||
        processing-strategy:
 | 
			
		||||
          type: "${TB_QUEUE_RE_SQ_PROCESSING_STRATEGY_TYPE:RETRY_FAILED_AND_TIMED_OUT}" # SKIP_ALL_FAILURES, RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT
 | 
			
		||||
          # For RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT
 | 
			
		||||
          retries: "${TB_QUEUE_RE_SQ_PROCESSING_STRATEGY_RETRIES:3}" # Number of retries, 0 is unlimited
 | 
			
		||||
          failure-percentage: "${TB_QUEUE_RE_SQ_PROCESSING_STRATEGY_FAILURE_PERCENTAGE:0}" # Skip retry if failures or timeouts are less then X percentage of messages;
 | 
			
		||||
          pause-between-retries: "${TB_QUEUE_RE_SQ_PROCESSING_STRATEGY_RETRY_PAUSE:5}"# Time in seconds to wait in consumer thread before retries;
 | 
			
		||||
  transport:
 | 
			
		||||
    # For high priority notifications that require minimum latency and processing time
 | 
			
		||||
    notifications_topic: "${TB_QUEUE_TRANSPORT_NOTIFICATIONS_TOPIC:tb_transport.notifications}"
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>transport</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.transport</groupId>
 | 
			
		||||
 | 
			
		||||
@ -156,19 +156,19 @@ queue:
 | 
			
		||||
    pack-processing-timeout: "${TB_QUEUE_RULE_ENGINE_PACK_PROCESSING_TIMEOUT_MS:60000}"
 | 
			
		||||
    stats:
 | 
			
		||||
      enabled: "${TB_QUEUE_RULE_ENGINE_STATS_ENABLED:true}"
 | 
			
		||||
      print-interval-ms: "${TB_QUEUE_RULE_ENGINE_STATS_PRINT_INTERVAL_MS:10000}"
 | 
			
		||||
      print-interval-ms: "${TB_QUEUE_RULE_ENGINE_STATS_PRINT_INTERVAL_MS:60000}"
 | 
			
		||||
    queues:
 | 
			
		||||
      - name: "Main"
 | 
			
		||||
      - name: "${TB_QUEUE_RE_MAIN_QUEUE_NAME:Main}"
 | 
			
		||||
        topic: "${TB_QUEUE_RE_MAIN_TOPIC:tb_rule_engine.main}"
 | 
			
		||||
        poll-interval: "${TB_QUEUE_RE_MAIN_POLL_INTERVAL_MS:25}"
 | 
			
		||||
        partitions: "${TB_QUEUE_RE_MAIN_PARTITIONS:10}"
 | 
			
		||||
        pack-processing-timeout: "${TB_QUEUE_RE_MAIN_PACK_PROCESSING_TIMEOUT_MS:60000}"
 | 
			
		||||
        submit-strategy:
 | 
			
		||||
          type: "${TB_QUEUE_RE_MAIN_SUBMIT_STRATEGY_TYPE:BURST}" # BURST, BATCH, SEQUENTIAL_WITHIN_ORIGINATOR, SEQUENTIAL_WITHIN_TENANT, SEQUENTIAL
 | 
			
		||||
          type: "${TB_QUEUE_RE_MAIN_SUBMIT_STRATEGY_TYPE:BURST}" # BURST, BATCH, SEQUENTIAL_BY_ORIGINATOR, SEQUENTIAL_BY_TENANT, SEQUENTIAL
 | 
			
		||||
          # For BATCH only
 | 
			
		||||
          batch-size: "${TB_QUEUE_RE_MAIN_SUBMIT_STRATEGY_BATCH_SIZE:1000}" # Maximum number of messages in batch
 | 
			
		||||
        processing-strategy:
 | 
			
		||||
          type: "${TB_QUEUE_RE_MAIN_PROCESSING_STRATEGY_TYPE:RETRY_FAILED_AND_TIMED_OUT}" # SKIP_ALL_FAILURES, RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT
 | 
			
		||||
          type: "${TB_QUEUE_RE_MAIN_PROCESSING_STRATEGY_TYPE:SKIP_ALL_FAILURES}" # SKIP_ALL_FAILURES, RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT
 | 
			
		||||
          # For RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT
 | 
			
		||||
          retries: "${TB_QUEUE_RE_MAIN_PROCESSING_STRATEGY_RETRIES:3}" # Number of retries, 0 is unlimited
 | 
			
		||||
          failure-percentage: "${TB_QUEUE_RE_MAIN_PROCESSING_STRATEGY_FAILURE_PERCENTAGE:0}" # Skip retry if failures or timeouts are less then X percentage of messages;
 | 
			
		||||
@ -176,10 +176,10 @@ queue:
 | 
			
		||||
      - name: "${TB_QUEUE_RE_HP_QUEUE_NAME:HighPriority}"
 | 
			
		||||
        topic: "${TB_QUEUE_RE_HP_TOPIC:tb_rule_engine.hp}"
 | 
			
		||||
        poll-interval: "${TB_QUEUE_RE_HP_POLL_INTERVAL_MS:25}"
 | 
			
		||||
        partitions: "${TB_QUEUE_RE_HP_PARTITIONS:3}"
 | 
			
		||||
        partitions: "${TB_QUEUE_RE_HP_PARTITIONS:10}"
 | 
			
		||||
        pack-processing-timeout: "${TB_QUEUE_RE_HP_PACK_PROCESSING_TIMEOUT_MS:60000}"
 | 
			
		||||
        submit-strategy:
 | 
			
		||||
          type: "${TB_QUEUE_RE_HP_SUBMIT_STRATEGY_TYPE:SEQUENTIAL_WITHIN_ORIGINATOR}" # BURST, BATCH, SEQUENTIAL_WITHIN_ORIGINATOR, SEQUENTIAL_WITHIN_TENANT, SEQUENTIAL
 | 
			
		||||
          type: "${TB_QUEUE_RE_HP_SUBMIT_STRATEGY_TYPE:BURST}" # BURST, BATCH, SEQUENTIAL_BY_ORIGINATOR, SEQUENTIAL_BY_TENANT, SEQUENTIAL
 | 
			
		||||
          # For BATCH only
 | 
			
		||||
          batch-size: "${TB_QUEUE_RE_HP_SUBMIT_STRATEGY_BATCH_SIZE:100}" # Maximum number of messages in batch
 | 
			
		||||
        processing-strategy:
 | 
			
		||||
@ -188,6 +188,21 @@ queue:
 | 
			
		||||
          retries: "${TB_QUEUE_RE_HP_PROCESSING_STRATEGY_RETRIES:0}" # Number of retries, 0 is unlimited
 | 
			
		||||
          failure-percentage: "${TB_QUEUE_RE_HP_PROCESSING_STRATEGY_FAILURE_PERCENTAGE:0}" # Skip retry if failures or timeouts are less then X percentage of messages;
 | 
			
		||||
          pause-between-retries: "${TB_QUEUE_RE_HP_PROCESSING_STRATEGY_RETRY_PAUSE:5}"# Time in seconds to wait in consumer thread before retries;
 | 
			
		||||
      - name: "${TB_QUEUE_RE_SQ_QUEUE_NAME:SequentialByOriginator}"
 | 
			
		||||
        topic: "${TB_QUEUE_RE_SQ_TOPIC:tb_rule_engine.sq}"
 | 
			
		||||
        poll-interval: "${TB_QUEUE_RE_SQ_POLL_INTERVAL_MS:25}"
 | 
			
		||||
        partitions: "${TB_QUEUE_RE_SQ_PARTITIONS:10}"
 | 
			
		||||
        pack-processing-timeout: "${TB_QUEUE_RE_SQ_PACK_PROCESSING_TIMEOUT_MS:60000}"
 | 
			
		||||
        submit-strategy:
 | 
			
		||||
          type: "${TB_QUEUE_RE_SQ_SUBMIT_STRATEGY_TYPE:SEQUENTIAL_BY_ORIGINATOR}" # BURST, BATCH, SEQUENTIAL_BY_ORIGINATOR, SEQUENTIAL_BY_TENANT, SEQUENTIAL
 | 
			
		||||
          # For BATCH only
 | 
			
		||||
          batch-size: "${TB_QUEUE_RE_SQ_SUBMIT_STRATEGY_BATCH_SIZE:100}" # Maximum number of messages in batch
 | 
			
		||||
        processing-strategy:
 | 
			
		||||
          type: "${TB_QUEUE_RE_SQ_PROCESSING_STRATEGY_TYPE:RETRY_FAILED_AND_TIMED_OUT}" # SKIP_ALL_FAILURES, RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT
 | 
			
		||||
          # For RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT
 | 
			
		||||
          retries: "${TB_QUEUE_RE_SQ_PROCESSING_STRATEGY_RETRIES:3}" # Number of retries, 0 is unlimited
 | 
			
		||||
          failure-percentage: "${TB_QUEUE_RE_SQ_PROCESSING_STRATEGY_FAILURE_PERCENTAGE:0}" # Skip retry if failures or timeouts are less then X percentage of messages;
 | 
			
		||||
          pause-between-retries: "${TB_QUEUE_RE_SQ_PROCESSING_STRATEGY_RETRY_PAUSE:5}"# Time in seconds to wait in consumer thread before retries;
 | 
			
		||||
  transport:
 | 
			
		||||
    # For high priority notifications that require minimum latency and processing time
 | 
			
		||||
    notifications_topic: "${TB_QUEUE_TRANSPORT_NOTIFICATIONS_TOPIC:tb_transport.notifications}"
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>transport</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard.transport</groupId>
 | 
			
		||||
 | 
			
		||||
@ -176,19 +176,19 @@ queue:
 | 
			
		||||
    pack-processing-timeout: "${TB_QUEUE_RULE_ENGINE_PACK_PROCESSING_TIMEOUT_MS:60000}"
 | 
			
		||||
    stats:
 | 
			
		||||
      enabled: "${TB_QUEUE_RULE_ENGINE_STATS_ENABLED:true}"
 | 
			
		||||
      print-interval-ms: "${TB_QUEUE_RULE_ENGINE_STATS_PRINT_INTERVAL_MS:10000}"
 | 
			
		||||
      print-interval-ms: "${TB_QUEUE_RULE_ENGINE_STATS_PRINT_INTERVAL_MS:60000}"
 | 
			
		||||
    queues:
 | 
			
		||||
      - name: "Main"
 | 
			
		||||
      - name: "${TB_QUEUE_RE_MAIN_QUEUE_NAME:Main}"
 | 
			
		||||
        topic: "${TB_QUEUE_RE_MAIN_TOPIC:tb_rule_engine.main}"
 | 
			
		||||
        poll-interval: "${TB_QUEUE_RE_MAIN_POLL_INTERVAL_MS:25}"
 | 
			
		||||
        partitions: "${TB_QUEUE_RE_MAIN_PARTITIONS:10}"
 | 
			
		||||
        pack-processing-timeout: "${TB_QUEUE_RE_MAIN_PACK_PROCESSING_TIMEOUT_MS:60000}"
 | 
			
		||||
        submit-strategy:
 | 
			
		||||
          type: "${TB_QUEUE_RE_MAIN_SUBMIT_STRATEGY_TYPE:BURST}" # BURST, BATCH, SEQUENTIAL_WITHIN_ORIGINATOR, SEQUENTIAL_WITHIN_TENANT, SEQUENTIAL
 | 
			
		||||
          type: "${TB_QUEUE_RE_MAIN_SUBMIT_STRATEGY_TYPE:BURST}" # BURST, BATCH, SEQUENTIAL_BY_ORIGINATOR, SEQUENTIAL_BY_TENANT, SEQUENTIAL
 | 
			
		||||
          # For BATCH only
 | 
			
		||||
          batch-size: "${TB_QUEUE_RE_MAIN_SUBMIT_STRATEGY_BATCH_SIZE:1000}" # Maximum number of messages in batch
 | 
			
		||||
        processing-strategy:
 | 
			
		||||
          type: "${TB_QUEUE_RE_MAIN_PROCESSING_STRATEGY_TYPE:RETRY_FAILED_AND_TIMED_OUT}" # SKIP_ALL_FAILURES, RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT
 | 
			
		||||
          type: "${TB_QUEUE_RE_MAIN_PROCESSING_STRATEGY_TYPE:SKIP_ALL_FAILURES}" # SKIP_ALL_FAILURES, RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT
 | 
			
		||||
          # For RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT
 | 
			
		||||
          retries: "${TB_QUEUE_RE_MAIN_PROCESSING_STRATEGY_RETRIES:3}" # Number of retries, 0 is unlimited
 | 
			
		||||
          failure-percentage: "${TB_QUEUE_RE_MAIN_PROCESSING_STRATEGY_FAILURE_PERCENTAGE:0}" # Skip retry if failures or timeouts are less then X percentage of messages;
 | 
			
		||||
@ -196,10 +196,10 @@ queue:
 | 
			
		||||
      - name: "${TB_QUEUE_RE_HP_QUEUE_NAME:HighPriority}"
 | 
			
		||||
        topic: "${TB_QUEUE_RE_HP_TOPIC:tb_rule_engine.hp}"
 | 
			
		||||
        poll-interval: "${TB_QUEUE_RE_HP_POLL_INTERVAL_MS:25}"
 | 
			
		||||
        partitions: "${TB_QUEUE_RE_HP_PARTITIONS:3}"
 | 
			
		||||
        partitions: "${TB_QUEUE_RE_HP_PARTITIONS:10}"
 | 
			
		||||
        pack-processing-timeout: "${TB_QUEUE_RE_HP_PACK_PROCESSING_TIMEOUT_MS:60000}"
 | 
			
		||||
        submit-strategy:
 | 
			
		||||
          type: "${TB_QUEUE_RE_HP_SUBMIT_STRATEGY_TYPE:SEQUENTIAL_WITHIN_ORIGINATOR}" # BURST, BATCH, SEQUENTIAL_WITHIN_ORIGINATOR, SEQUENTIAL_WITHIN_TENANT, SEQUENTIAL
 | 
			
		||||
          type: "${TB_QUEUE_RE_HP_SUBMIT_STRATEGY_TYPE:BURST}" # BURST, BATCH, SEQUENTIAL_BY_ORIGINATOR, SEQUENTIAL_BY_TENANT, SEQUENTIAL
 | 
			
		||||
          # For BATCH only
 | 
			
		||||
          batch-size: "${TB_QUEUE_RE_HP_SUBMIT_STRATEGY_BATCH_SIZE:100}" # Maximum number of messages in batch
 | 
			
		||||
        processing-strategy:
 | 
			
		||||
@ -208,6 +208,21 @@ queue:
 | 
			
		||||
          retries: "${TB_QUEUE_RE_HP_PROCESSING_STRATEGY_RETRIES:0}" # Number of retries, 0 is unlimited
 | 
			
		||||
          failure-percentage: "${TB_QUEUE_RE_HP_PROCESSING_STRATEGY_FAILURE_PERCENTAGE:0}" # Skip retry if failures or timeouts are less then X percentage of messages;
 | 
			
		||||
          pause-between-retries: "${TB_QUEUE_RE_HP_PROCESSING_STRATEGY_RETRY_PAUSE:5}"# Time in seconds to wait in consumer thread before retries;
 | 
			
		||||
      - name: "${TB_QUEUE_RE_SQ_QUEUE_NAME:SequentialByOriginator}"
 | 
			
		||||
        topic: "${TB_QUEUE_RE_SQ_TOPIC:tb_rule_engine.sq}"
 | 
			
		||||
        poll-interval: "${TB_QUEUE_RE_SQ_POLL_INTERVAL_MS:25}"
 | 
			
		||||
        partitions: "${TB_QUEUE_RE_SQ_PARTITIONS:10}"
 | 
			
		||||
        pack-processing-timeout: "${TB_QUEUE_RE_SQ_PACK_PROCESSING_TIMEOUT_MS:60000}"
 | 
			
		||||
        submit-strategy:
 | 
			
		||||
          type: "${TB_QUEUE_RE_SQ_SUBMIT_STRATEGY_TYPE:SEQUENTIAL_BY_ORIGINATOR}" # BURST, BATCH, SEQUENTIAL_BY_ORIGINATOR, SEQUENTIAL_BY_TENANT, SEQUENTIAL
 | 
			
		||||
          # For BATCH only
 | 
			
		||||
          batch-size: "${TB_QUEUE_RE_SQ_SUBMIT_STRATEGY_BATCH_SIZE:100}" # Maximum number of messages in batch
 | 
			
		||||
        processing-strategy:
 | 
			
		||||
          type: "${TB_QUEUE_RE_SQ_PROCESSING_STRATEGY_TYPE:RETRY_FAILED_AND_TIMED_OUT}" # SKIP_ALL_FAILURES, RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT
 | 
			
		||||
          # For RETRY_ALL, RETRY_FAILED, RETRY_TIMED_OUT, RETRY_FAILED_AND_TIMED_OUT
 | 
			
		||||
          retries: "${TB_QUEUE_RE_SQ_PROCESSING_STRATEGY_RETRIES:3}" # Number of retries, 0 is unlimited
 | 
			
		||||
          failure-percentage: "${TB_QUEUE_RE_SQ_PROCESSING_STRATEGY_FAILURE_PERCENTAGE:0}" # Skip retry if failures or timeouts are less then X percentage of messages;
 | 
			
		||||
          pause-between-retries: "${TB_QUEUE_RE_SQ_PROCESSING_STRATEGY_RETRY_PAUSE:5}"# Time in seconds to wait in consumer thread before retries;
 | 
			
		||||
  transport:
 | 
			
		||||
    # For high priority notifications that require minimum latency and processing time
 | 
			
		||||
    notifications_topic: "${TB_QUEUE_TRANSPORT_NOTIFICATIONS_TOPIC:tb_transport.notifications}"
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <artifactId>transport</artifactId>
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										2
									
								
								ui/package-lock.json
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										2
									
								
								ui/package-lock.json
									
									
									
										generated
									
									
									
								
							@ -1,6 +1,6 @@
 | 
			
		||||
{
 | 
			
		||||
  "name": "thingsboard",
 | 
			
		||||
  "version": "2.4.3",
 | 
			
		||||
  "version": "2.5.0",
 | 
			
		||||
  "lockfileVersion": 1,
 | 
			
		||||
  "requires": true,
 | 
			
		||||
  "dependencies": {
 | 
			
		||||
 | 
			
		||||
@ -20,7 +20,7 @@
 | 
			
		||||
    <modelVersion>4.0.0</modelVersion>
 | 
			
		||||
    <parent>
 | 
			
		||||
        <groupId>org.thingsboard</groupId>
 | 
			
		||||
        <version>2.5.0-SNAPSHOT</version>
 | 
			
		||||
        <version>2.5.1-SNAPSHOT</version>
 | 
			
		||||
        <artifactId>thingsboard</artifactId>
 | 
			
		||||
    </parent>
 | 
			
		||||
    <groupId>org.thingsboard</groupId>
 | 
			
		||||
 | 
			
		||||
@ -88,6 +88,37 @@
 | 
			
		||||
							</md-option>
 | 
			
		||||
						</md-select>
 | 
			
		||||
					</md-input-container>
 | 
			
		||||
					<md-checkbox class="md-block" flex="100" flex-gt-sm="60" ng-disabled="$root.loading" aria-label="{{ 'admin.enable-proxy' | translate }}" ng-model="vm.settings.jsonValue.enableProxy">
 | 
			
		||||
						{{ 'admin.enable-proxy' | translate }}
 | 
			
		||||
					</md-checkbox>
 | 
			
		||||
					<div layout-gt-sm="row">
 | 
			
		||||
					<md-input-container class="md-block" flex="100" flex-gt-sm="60" ng-if="vm.settings.jsonValue.enableProxy">
 | 
			
		||||
						<label translate>admin.proxy-host</label>
 | 
			
		||||
						<input required name="proxyHost" ng-model="vm.settings.jsonValue.proxyHost">
 | 
			
		||||
						<div ng-messages="vm.settingsForm.proxyHost.$error">
 | 
			
		||||
							<div translate ng-message="required">admin.proxy-host-required</div>
 | 
			
		||||
						</div>
 | 
			
		||||
					</md-input-container>
 | 
			
		||||
					<md-input-container ng-if="vm.settings.jsonValue.enableProxy" class="md-block" flex="100" flex-gt-sm="40">
 | 
			
		||||
						<label translate>admin.proxy-port</label>
 | 
			
		||||
						<input required name="proxyPort" ng-model="vm.settings.jsonValue.proxyPort"
 | 
			
		||||
							   ng-pattern="/^([0-9]{1,4}|[1-5][0-9]{4}|6[0-4][0-9]{3}|65[0-4][0-9]{2}|655[0-2][0-9]|6553[0-5])$/"
 | 
			
		||||
							   md-maxlength="5">
 | 
			
		||||
						<div ng-messages="vm.settingsForm.proxyPort.$error" role="alert" multiple>
 | 
			
		||||
							<div translate ng-message="required">admin.proxy-port-required</div>
 | 
			
		||||
							<div translate ng-message="pattern">admin.proxy-port-invalid</div>
 | 
			
		||||
							<div translate ng-message="md-maxlength">admin.proxy-port-invalid</div>
 | 
			
		||||
						</div>
 | 
			
		||||
					</md-input-container>
 | 
			
		||||
					</div>
 | 
			
		||||
					<md-input-container class="md-block" ng-if="vm.settings.jsonValue.enableProxy">
 | 
			
		||||
						<label translate>admin.proxy-user</label>
 | 
			
		||||
						<input name="proxyUser" ng-model="vm.settings.jsonValue.proxyUser">
 | 
			
		||||
					</md-input-container>
 | 
			
		||||
					<md-input-container class="md-block" ng-if="vm.settings.jsonValue.enableProxy">
 | 
			
		||||
						<label translate>admin.proxy-password</label>
 | 
			
		||||
						<input name="proxyPassword" ng-model="vm.settings.jsonValue.proxyPassword">
 | 
			
		||||
					</md-input-container>
 | 
			
		||||
					<md-input-container class="md-block">
 | 
			
		||||
						<label translate>common.username</label>
 | 
			
		||||
						<input name="username" placeholder="{{ 'common.enter-username' | translate }}" ng-model="vm.settings.jsonValue.username">
 | 
			
		||||
 | 
			
		||||
@ -87,6 +87,14 @@
 | 
			
		||||
        "timeout-invalid": "That doesn't look like a valid timeout.",
 | 
			
		||||
        "enable-tls": "Enable TLS",
 | 
			
		||||
        "tls-version": "TLS version",
 | 
			
		||||
        "enable-proxy": "Enable proxy",
 | 
			
		||||
        "proxy-host": "Proxy host",
 | 
			
		||||
        "proxy-host-required": "Proxy host is required.",
 | 
			
		||||
        "proxy-port": "Proxy port",
 | 
			
		||||
        "proxy-port-required": "You must supply a proxy port.",
 | 
			
		||||
        "proxy-port-invalid": "That doesn't look like a valid proxy port.",
 | 
			
		||||
        "proxy-user": "Proxy user",
 | 
			
		||||
        "proxy-password": "Proxy password",
 | 
			
		||||
        "send-test-mail": "Send test mail",
 | 
			
		||||
        "security-settings": "Security settings",
 | 
			
		||||
        "password-policy": "Password policy",
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user