I have 3 different files for env: test, staging and production. Each of those 
has different parameters like: kafka host, endpoint urls, redis connection host…
I read about 
`https://ci.apache.org/projects/flink/flink-docs-stable/dev/best_practices.html#register-the-parameters-globally`
 
<https://ci.apache.org/projects/flink/flink-docs-stable/dev/best_practices.html#register-the-parameters-globally%60>
 but its has a few downside: If I have a model class (for transformation) and 
want to use a env variable, I have to pass it in the constructor (because the 
global paramters can only accessed inside context)

I wonder if are there any better solution for accessing env anywhere in our 
jobs? I can be fine with having a class storing all the env values and if I can 
somehow spec the env as “prod” I can init the ProdEnv Class… I’m looking for 
any ideas here :)

Thank a bunch,

Andy,

Reply via email to