https://github.com/rtler/broadcast-server
golang broadcast server
https://github.com/rtler/broadcast-server
Last synced: over 1 year ago
JSON representation
golang broadcast server
- Host: GitHub
- URL: https://github.com/rtler/broadcast-server
- Owner: RTLer
- Created: 2018-09-10T15:49:25.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2020-02-22T09:58:22.000Z (over 6 years ago)
- Last Synced: 2024-03-27T14:30:46.880Z (over 2 years ago)
- Language: Go
- Size: 60.5 KB
- Stars: 1
- Watchers: 4
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Broadcast Server
run with docker
this service run on redis for publish messages
# How it`s run?
```
go run *.go -BroadcastStats=true -authUrl=http://localhost:8090/api/broadcast/auth -webhookUrl=http://localhost:8090/api/broadcast/webhook -redisAddress=:6389 -serverAddress=:8081 -debug=true -queues=success,failed
```
# flags describe:
* **BroadcastStats**: this flag as default is false, if you set this on true tick online users every 10 seconds.
* **serverAddress**: server port. default is on :8081
* **redisAddress**: set redist connection port, default is on :6379
* **authUrl**: url of your client server for auth users
* **webhookUrl**: webhook url that broadcast server call that on any action
* **debug**: show logs for debuging
* **queues**: RabbitMQ queues. like: transactions,tickets. split with comma. the default queue name is **default**
# data structure for input/output
```json
{
"id": "51fc8126-221e-43fc-abee-91a66fce4fa9",//uuid string
"command": "auth",
"content": "a message title",//string
"data": {}//object
}
```