Dear all,
I have build a WPF application which is connected to a local SQL server database.
The database request are send from the application through a WCF services.
The WCF services endpoint configuration as well as other application setting are actually store in App.config file. Issue we met today is that if a customer have 4 installation of our application it means we need to setup 4 configuration files.
To overcome this, we were thinking on having a configuration SQL table hosted in the cloud where those settings will be. Then when each application start they will fetch configuration from remote configuration.
In such scenario, the app.config files will contains only the connection string to the configuration table BUT the parameters for the WCF Endpoint are much more complicated to handle and usually what is changing is either the port number or server IP which host the WCF service.
If I store the Port number and remote server in config DB, how can I then update configuration in app. config file ? or may be then endpoint needs to be updated dynamically ?
Here is a sample endpoint configuration in my case :
<client><endpoint address="net.tcp://localhost:4000/SubscriberService" binding="netTcpBinding" contract="ISubscriptionService" name="SubscriptionService" /><endpoint address="net.tcp://localhost:5000/DataSyncService" binding="netTcpBinding" bindingConfiguration="DataSyncService" contract="ServiceDataSync.IDataSync" name="DataSyncService"></endpoint></client>Thanks for advise
Your knowledge is enhanced by that of others.