-
Notifications
You must be signed in to change notification settings - Fork 18
Remove dependency from environment variables #152
Description
Presently, environment variables are being used for storing and getting following information:
- contract addresses like openst utility contract addresses, etc
- user addresses like utility chain owner, etc
- utility and value chain gas prices
- st prime uuid
- utility and value chain GETH endpoints
- Dynamo DB connection params
- DAX connection params
Environment variables were a hard dependency. The flexibility of creating two different instances of platform was not possible.
For Example: If an application wants to interact with multiple utility chains. With environment variables they could only interact with the platform instance set in the variables. Interacting with multiple chains is not possible.
To achieve this flexibility, we will take configuration as openst platform constructor params and then use the config in place of environment variables, where-ever needed. This will allow platform to connect to a configured set of services. (redis , memcache, DynamoDB, Geth)
After this change the application will create different configurations, instantiate platform for each configuration and then communicate with respective (appropriate) platform instance.