IBMStreams / streamsx.dps

The IBMStreams/streamsx.dps GitHub repository is home to the Streams toolkit named DPS (Distributed Process Store)
http://ibmstreams.github.io/streamsx.dps
Other
4 stars 9 forks source link

Support a parameter to specify the no-sql-kv-store-servers.cfg location #23

Closed m-kotowski closed 7 years ago

m-kotowski commented 8 years ago

Today, the file path of the configuration file is fixed to /etc/no-sql-kv-store-servers.cfg.

I propose to introduce a parameter that can change the file path at submission-time.

Use case 1: I want to use several backends in the same application, for example, Redis and Mongo.

Use case 2: I have an application that is already compiled. I want to run this application on several hosts using dedicated DPS backend instances that are independent from each other.

ddebrunner commented 8 years ago

It would be good if the configuration could come from a Streams 4.2 application configuration.

nysenthil commented 8 years ago

Hi Dan, There is already a flexible solution available for dynamically controlling the config file location from within the Streams applications. We will integrate that fix in the next month or so once our current ongoing customer PoCs conclude.

Alex-Cook4 commented 7 years ago

+1 to having this come from Streams 4.2 application configuration if possible.

Looking forward to having control over the config file location, as I would like to be able to build an application in a dev environment, and submit the .sab file in a production environment. This isn't possible without placing production details on the dev environment (which is not allowed in my case).

Alex-Cook4 commented 7 years ago

Looks like dpsSetConfigFile(rstring dpsConfigFile) was integrated. Should we close this? Asking for application configuration specification could be a separate issue.

brandtol commented 7 years ago

Yes this is in, there is a new function to set the filename http://ibmstreams.github.io/streamsx.dps/com.ibm.streamsx.dps/doc/v3.2.0/en_US/spldoc/html/tk$com.ibm.streamsx.dps/fc$com.ibm.streamsx.store.distributed.html#spldoc_functions__dpsSetConfigFile.rstring

brandtol commented 7 years ago

I agree, for application configuration we should open a new issue. I was thinking about an additional function dpsSetConfigString(rstring conf) that contains the content of the config file as single string (including the carriage returns). The application could construct this string from submission time parameters or from querying an application config object.

Alex-Cook4 commented 7 years ago

+1 to a dpsSetConfigString How do you include carriage returns in SPL? Would it be better to use JSON? Or a properties format? Or even a list\<rstring> where each element is a line?

Alex-Cook4 commented 7 years ago

Regarding the formatting, I think whatever it is should fit well for an appConfig parameter. appConfig specifying a string might be more usable than a config file via appConfig, since the system might be remote.

i.e. in Bluemix, you could change the appConfig and restart the PE to point somewhere new without changing your file (resubmitting).

brandtol commented 7 years ago

Ok, I am closing this one and open a new issue, to discuss. Having CR in SPL strings should be like xxx + "\n" + yyy but a list would be also fine.