1 Star 0 Fork 159

AFLF/smart-mqtt

forked from smartboot/smart-mqtt 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
docker-compose.yml 3.10 KB
一键复制 编辑 原始数据 按行查看 历史
三刀 提交于 2023-08-12 19:37 . 代码优化
networks:
mqtt-network:
driver: bridge
services:
mqtt-broker:
container_name: smart-mqtt
hostname: mqtt-broker
image: smartboot/smart-mqtt:latest
networks:
mqtt-network: null
# environment:
# BROKER_LOWMEMORY: true
# BROKER_MAXINFLIGHT: 4
restart: always
privileged: true
security_opt:
- no-new-privileges:true
user: root:root
ports:
- 18083:18083
- 1883:1883
logging:
driver: "json-file"
options:
max-size: "100m"
max-file: "1"
# entrypoint: java -Xmx10G -Xmn8G -XX:PretenureSizeThreshold=0 -DbrokerConfig=smart-mqtt.yaml -jar smart-mqtt.jar
# mqtt-broker:
# container_name: bifromq
# hostname: mqtt-broker
# image: bifromq/bifromq:latest
# networks:
# mqtt-network: null
# restart: always
# security_opt:
# - no-new-privileges:true
# user: root:root
# logging:
# driver: "json-file"
# options:
# max-size: "100m"
# max-file: "1"
# mqtt-broker:
# container_name: emqx
# hostname: mqtt-broker
# image: emqx/emqx:5.0.24
# networks:
# mqtt-network: null
# restart: always
# security_opt:
# - no-new-privileges:true
# user: root:root
# logging:
# driver: "json-file"
# options:
# max-size: "100m"
# max-file: "1"
smart-mqtt-bench:
depends_on:
- mqtt-broker
image: smartboot/smart-mqtt-bench:latest
restart: always
privileged: true
security_opt:
- no-new-privileges:true
user: root:root
# environment:
# BROKER_LOWMEMORY: true
networks:
mqtt-network: null
logging:
driver: "json-file"
options:
max-size: "100m"
max-file: "1"
# command: java -cp smart-mqtt-bench.jar -Dhost=mqtt-broker -Dconnect=2000 -Dqos=0 -Dpublisher=1 -Dcount=10 -Dpayload=128 org.smartboot.bench.mqtt.Subscribe
command: java -cp smart-mqtt-bench.jar -Dhost=mqtt-broker -Dconnect=2000 -Dqos=1 -Dpublisher=1 -Dcount=10 -Dpayload=128 org.smartboot.bench.mqtt.Subscribe
# command: java -cp smart-mqtt-bench.jar -Dhost=mqtt-broker -Dconnect=2000 -Dqos=2 -Dpublisher=1 -Dcount=10 -Dpayload=128 org.smartboot.bench.mqtt.Subscribe
# command: java -cp smart-mqtt-bench.jar -Dhost=mqtt-broker -Dconnect=2000 -Dqos=0 -Dcount=10 -Dpayload=128 org.smartboot.bench.mqtt.Publish
# command: java -cp smart-mqtt-bench.jar -Dhost=mqtt-broker -Dconnect=2000 -Dqos=1 -Dcount=10 -Dpayload=128 org.smartboot.bench.mqtt.Publish
# command: java -cp smart-mqtt-bench.jar -Dhost=mqtt-broker -Dconnect=2000 -Dqos=2 -Dcount=10 -Dpayload=128 org.smartboot.bench.mqtt.Publish
# command: java -cp smart-mqtt-bench.jar -Dhost=mqtt-broker -Dconnect=10000 -Dqos=0 -Dpublisher=1 -Dcount=1 -Dtopic=10 -Dpayload=4096 -Dperiod=10000 org.smartboot.bench.mqtt.Subscribe
## 百万连接
# command: java -Xmx300M -Xmn250M -XX:PretenureSizeThreshold=0 -cp smart-mqtt-bench.jar -Dhost=mqtt-broker -Dconnect=25000 -Dqos=0 -Dpublisher=0 -Dtopic=2 -Dperiod=10000 org.smartboot.bench.mqtt.Subscribe
version: '3.7'
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Java
1
https://gitee.com/aflf/smart-mqtt.git
git@gitee.com:aflf/smart-mqtt.git
aflf
smart-mqtt
smart-mqtt
master

搜索帮助

23e8dbc6 1850385 7e0993f3 1850385