presto-admin
presto-admin copied to clipboard
Make worker configuration be different on each node
There are things in presto configuration which can be set differently on each node.
For example node.id
in node.properties
or node.internal-adress
in config.properites
.
The idea is to support template configuration where user could use some variables which will be resolved on target node. Let say we would have a defined set of variables like:
-
uuid
- generates new uuid -
current_node
- a hostname (or ip address) used topology file for current node -
coordinator
- a hostname of coordinator node defined in topology file
then in configuration files user could have:
- for
config.properties
:
http-server.http.port=28384
query.max-memory=50GB
query.max-memory-per-node=512MB
discovery.uri=http://${coordinator}:28384
coordinator=false
node.internal-address=${current_node}
- for
node.properties
node.id=${uuid}
catalog.config-dir=/etc/presto/catalog
node.data-dir=/var/lib/presto/data
node.environment=presto
node.launcher-log-file=/var/log/presto/launcher.log
node.server-log-file=/var/log/presto/server.log
plugin.dir=/usr/lib/presto/lib/plugin
@cawallin @rschlussel What do you think?
I think this is a duplicate of https://github.com/prestodb/presto-admin/issues/35 It seems like s a valuable addition and the syntax you proposed is good.
Right now we special case the node.id
. Because we generate a uuid on the node side if there's no node.id yet in the config file, but then for future deploys we specifically don't overwrite it so that the node names stay the same.
I closed the old one as this one is more detailed
Hello, I would like to work on this issue. Can you assign it to me? It seems to me that allowing environment variable expansion in configuration files will solve the problem.
Please go ahead. Nobody else is working on this right now.
hai how to set the node.id in node.properties