-
Notifications
You must be signed in to change notification settings - Fork 16
Configuration Details
Sea Yo edited this page Mar 29, 2016
·
29 revisions
Eywa looks at /etc/eywa/eywa.yml
for configurations by default. You can pass any file location you want by appending -conf=<your file location>
at the time of starting your service:
eywa serve -conf="my/file/location" &
Here is a table of configs for Eywa:
name | defaults | description |
---|---|---|
service.host | localhost | Host name that Eywa will be binding to. |
service.api_port | 8080 | Port that Eywa will be listening to for API's. |
service.device_port | 8081 | Port that Eywa will be accepting connections from devices. |
service.pid_file | /var/eywa/eywa.pid | File that records the current running Eywa's pid. (Not recommended to change) |
service.assets |
< empty>
|
Eywa will come with an admin panel including data visualization soon. Leave this blank for now. |
security.dashboard.username | root | Dashboard username. Change it for production use. |
security.dashboard.password | waterISwide | Password for the dashboard user. Change it for production use. |
security.dashboard.token_expiry | 24 hours | Settings for token to expire. |
security.dashboard.aes.key | abcdefg123456789 | AES key for encrypting auth tokens. You need to change it to 16 bytes string. |
security.dashboard.aes.iv | 123456789abcdefg | AES iv for pairing with AES key. You need to change it to 16 bytes string. |
security.ssl.cert_file | Location of SSL certificate file. Leave it blank if you don't want to use SSL. | |
security.ssl.key_file | Location of SSL key file. Leave it blank if you don't want to use SSL. | |
connections.http.long_polling | 600 seconds | For http long polling, the server timeouts every 600 seconds. Client needs to establish connection again after that. |
connections.websocket.request_queue_size | 8 | Each websocket connection can queue up some requests. Increasing this size if you have bursts of requests going into one single connection and that connection won't be able to consume quickly. Any request that gets backlogged beyond this size, will be dropped and returned as failure. |
connections.websocket.timeouts.write | 4 seconds | If the request to the client takes more than this value, connection will be considered dead. |
connections.websocket.timeouts.read | 5 minutes | Websocket clients need to regularly Ping Eywa in order to keep the connection alive. Tune this parameter if your client pings less often than per 5 min. |
connections.websocket.timeouts.request | 4 seconds | If the requests are not sent successfully within this value, request will be considered failure. The cause can either be connection slowness or too many requests are queued up. Connection won't be considered dead as oppose to connections.websocket.timeouts.write . |
connections.websocket.timeouts.response | 16 seconds | For some requests that require clients' response, the requester waits for this amount of time. Increase it if you know you local network is slow. |
connections.websocket.buffer_sizes.read | 1024 bytes | The buffer size for reading from the client. |
connections.websocket.buffer_sizes.write | 1024 bytes | The buffer size for writing to the client. |
indices.disable | false | Turn this on if you don't want to index your data. |
indices.host | localhost | The Elasticsearch host. |
indices.port | 9200 | The Elasticsearch port. |
indices.number_of_shards | 8 | The number of shards of time series data. The default value may gave you enough performance already. |
indices.number_of_replicas | 0 | The number of replicas of time series data. If you are running with micro services separately and you need data redundancy, increase this value. But indexing latency will be introduced. |
indices.ttl_enabled | false | Enable the data retention. |
indices.ttl | <none> |
The time series data retention period. |
database.db_type | sqlite3 | The type of database, default: sqlite3. MySql or Postgres will be supported soon. |
database.db_file | /var/eywa/eywa.db | The database file for sqlite3. |
logging.eywa.filename | /var/eywa/eywa.log | The log filename for Eywa's main logger. |
logging.eywa.maxsize | 1 GB | The maxsize of the main logger. If it goes beyond this size, Eywa will try to rotate it. |
logging.eywa.maxage | 7 days | The number of days to retain old log files based on the timestamp encoded in their filename. |
logging.eywa.maxbackups | 5 files | The maximum number of old log files to retain. |
logging.eywa.level | info | Log level of Eywa's main logger. |
logging.eywa.buffer_size | 512 lines | Buffer size of Eywa's main logger. Before it's filled, logs won't be flushed to disk. |
logging.indices.filename | /var/eywa/indices.log | The log filename for Eywa's indexing logger. |
logging.indices.maxsize | 1 GB | The maxsize of the indexing logger. If it goes beyond this size, Eywa will try to rotate it. |
logging.indices.maxage | 7 days | The number of days to retain old log files based on the timestamp encoded in their filename. |
logging.indices.maxbackups | 5 files | The maximum number of old log files to retain. |
logging.indices.level | warn | Log level of Eywa's indexing logger. |
logging.indices.buffer_size | 512 lines | Buffer size of Eywa's indexing logger. Before it's filled, logs won't be flushed to disk. |
logging.database.filename | /var/eywa/db.log | The log filename for Eywa's database logger. |
logging.database.maxsize | 1 GB | The maxsize of the database logger. If it goes beyond this size, Eywa will try to rotate it. |
logging.database.maxage | 7 days | The number of days to retain old log files based on the timestamp encoded in their filename. |
logging.database.maxbackups | 5 files | The maximum number of old log files to retain. |
logging.database.level | warn | Log level of Eywa's database logger. |
logging.database.buffer_size | 512 lines | Buffer size of Eywa's database logger. Before it's filled, logs won't be flushed to disk. |
There are a few settings can be updated via Admin Endpoints. They are:
security.dashboard.username:
security.dashboard.password:
security.dashboard.token_expiry:
security.api_key:
connections.http.timeouts.long_polling:
connections.websocket.request_queue_size:
connections.websocket.timeouts.write:
connections.websocket.timeouts.read:
connections.websocket.timeouts.request:
connections.websocket.timeouts.response:
connections.websocket.buffer_sizes.write:
connections.websocket.buffer_sizes.read:
indices.disable:
Please check the API Doc for how to update them dynamically.