configuration-files

Is it possible to use multiple ehcache.xml (in different projects, same war)?

↘锁芯ラ 提交于 2019-11-28 02:34:58
问题 I have a services project and a web project. I need to have eh-cache in both projects. The idea is that if the service project is updated, it's cache-related changes (like keys and invalidation rules) will also be available, while no changes are made to the web project. Being so independent, the service project can also be used with another projects without them even knowing of eh-cache. At this point, my web project also uses eh-cache for its own purposes. I am not much experienced with eh

Boost property_tree: multiple values per key

假如想象 提交于 2019-11-28 01:58:07
问题 Boost property tree seems like an excellent library to use for parsing config files. However, I can't figure out how to handle situations where there are multiple values per key. For example, let's say I was specifying a box like this: box { x -1 1 y -1 1 z -1 1 } where x , y , and z are the bounds of the box on the x , y , and z axes respectively, specified using property_tree's INFO format. I see mention in the manual of using quotes for values that use spaces, but then I don't see that I

Does SQL Server CLR Integration support configuration files?

一曲冷凌霜 提交于 2019-11-28 00:40:38
问题 I use SQL Server CLR Integration to create an ASSEMBLY. Load Command: CREATE ASSEMBLY TcpClr FROM 'G:\TcpClrTest.dll' WITH PERMISSION_SET = UNSAFE Without App.Config The dll code contains : string ip=ConfigurationManager.AppSettings["connection"].ToString(); Also the App.config contains : <appSettings> <add key="connection" value="127.0.0.1"/> </appSettings> But when I execute the PROCEDURE,the SQL Server shows an error System.NullReferenceException Does SQL Server CLR Integration support App

How can I specify an alternate config file for a WCF client?

a 夏天 提交于 2019-11-28 00:23:05
问题 I am working on a large system, for which I have to use WCF to access a web service. My test code works fine, now I need to integrate my WCF client code into the larger system. I cannot add to the existing 'app.config' file, and would like specify a separate .config file for use by my client code. How best can I accomplish this? Thanks! 回答1: There are 2 options. Option 1. Working with channels. If you are working with channels directly, .NET 4.0 and .NET 4.5 has the

Storing connection strings in machine.config vs storing them in web.config

試著忘記壹切 提交于 2019-11-28 00:02:47
For a dedicated server, is it better to store the connection string in web.config or machine.config? what's the advantages and disadvantages of each approach? Thanks Edit: I'm concerned about security here, so, the question is about which approach is more secure. I would always go with web.config on the grounds that that is where everyone would expect it to be. There is no point in giving the person that has to maintain the web site any more difficulty by storing connection strings in an unusual place. ADDITIONAL Based on the additional information that the OP is interested in the security

What is the benefit of using the ConfigParser instead of a regular python.py file when writing configuration files?

為{幸葍}努か 提交于 2019-11-27 23:48:52
问题 I have been using the ConfigParser module to write configuration files for some time. However, a thought recently struck me; why not just use pure Python instead? Take this example configuration file: [parameters] # Host host = stackoverflow.com port = 22 To read these values into my code, I do import ConfigParser config = ConfigParser.SafeConfigParser() config.read('host.cfg') host = config.get('parameters', 'host') port = config.get('parameters', 'port') On the other hand, if I had a config

create your own settings in xml

筅森魡賤 提交于 2019-11-27 23:20:00
I'm in a ASP.NET project where I need to give several parameters to the administrator that is going to install the website, like: AllowUserToChangePanelLayout AllowUserToDeleteCompany etc... My question is, will be a good thing to add this into the web.config file, using my own configSession or add as a profile varibles? or should I create a XML file for this? What do you do and what are the cons and favs? I originally thought about web.config but I then realized that I should mess up with Website configurations and my own web app configuration and that I should create a different file, them I

CloudConfigurationManager does not pick up ApplicationSettings from app.config

无人久伴 提交于 2019-11-27 23:09:45
问题 I have a library containing some Azure helper classes. Inside these helper classes I obtain settings such as the Azure account name and key. When running in Azure these settings are picked up from the cloud configuration file (cscfg). This all works fine. In order to unit test these classes outside of Azure (specifically the RoleEnvironment) I created settings of the same variable names within the unit test project. These actually get saved within an app.config file and are edited via the

Controlling a project with Maven and Spring: How to set Spring config file using Maven profiles?

[亡魂溺海] 提交于 2019-11-27 21:33:26
I am trying to configure a Spring configuration file with database information based on whether a certain Maven profile is active. I've seen pieces of answers to this but I'm having trouble putting it all together. I have a Maven profile like this: <profiles> <profile> <id>production</id> <activation> <property> <name>environment.type</name> <value>prod</value> </property> </activation> </profile> <profile> <id>development</id> <activation> <property> <name>environment.type</name> <value>dev</value> </property> </activation> <!-- Database properties for Spring --> <properties> <db.driver

What is a good place to store configuration in Google AppEngine (python)

十年热恋 提交于 2019-11-27 21:22:09
问题 I am making a Google AppEngine application and am doubting were I should store (sensitive) configuration data like credentials. Should I make a single bigtable entity for configuration, or is there another advised way to store it. 回答1: If you're okay with embedding them in your source, you can do that, but if you need it to be dynamically configurable, the datastore is the way to go. You can avoid fetching the settings on every request by caching them in local memory. Here's a helper class