Search Results

Search found 15209 results on 609 pages for 'configuration'.

Page 9/609 | < Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >

  • Module configuration and layout configuration in zend framework.

    - by Prasanth P
    Hi all, I got some codes from other articles for configuring module and layout in zend framework. I tried with in my local. i didn't get different layout for default and admin module. Here is my code for configuring module and layout for zend framework. configs/application.ini [production] # Debug output phpSettings.display_startup_errors = 0 phpSettings.display_errors = 0 # Include path includePaths.library = APPLICATION_PATH "/../library" # Bootstrap bootstrap.path = APPLICATION_PATH "/Bootstrap.php" bootstrap.class = "Bootstrap" admin.bootstrap.path = APPLICATION_PATH "/modules/admin/Bootstrap.php" admin.bootstrap.class = "admin_Bootstrap" # Front Controller resources.frontController.controllerDirectory = APPLICATION_PATH "/controllers" resources.frontController.env = APPLICATION_ENV # Session resources.session.name = "ZendSession" resources.session.save_path = APPLICATION_PATH "/../data/session" resources.session.remember_me_seconds = 86400 # Layout resources.layout.layout = "layout" resources.layout.layoutPath = APPLICATION_PATH "/layouts" admin.resources.layout.layout = "admin" admin.resources.layout.layoutPath = APPLICATION_PATH "/modules/admin/layouts" # Views resources.view.encoding = "UTF-8" resources.view.basePath = APPLICATION_PATH "/views/" resources.view[] = resources.frontController.moduleDirectory = APPLICATION_PATH "/modules" resources.modules[] = resources.view[] = admin.resources.view[] = [staging : production] [testing : production] phpSettings.display_startup_errors = 1 phpSettings.display_errors = 1 [development : production] phpSettings.display_startup_errors = 1 phpSettings.display_errors = 1 application/Bootstrap.php <?php /** * Ensure all communications are managed by sessions. */ require_once ('Zend/Session.php'); Zend_Session::start(); class Bootstrap extends Zend_Application_Bootstrap_Bootstrap { protected function _initDoctype() { $this->bootstrap( 'view' ); $view = $this->getResource( 'view' ); $view->navigation = array(); $view->subnavigation = array(); $view->headTitle( 'Module One' ); $view->headLink()->appendStylesheet('/css/clear.css'); $view->headLink()->appendStylesheet('/css/main.css'); $view->headScript()->appendFile('/js/jquery.js'); $view->doctype( 'XHTML1_STRICT' ); //$view->navigation = $this->buildMenu(); } /*protected function _initAppAutoLoad() { $autoloader = new Zend_Application_Module_Autoloader(array( 'namespace' => 'default', 'basePath' => APPLICATION_PATH )); return $autoloader; }*/ protected function _initLayoutHelper() { $this->bootstrap('frontController'); $layout = Zend_Controller_Action_HelperBroker::addHelper( new ModuleLayoutLoader()); } public function _initControllers() { $front = Zend_Controller_Front::getInstance(); $front->addModuleDirectory(APPLICATION_PATH . '/modules/admin/', 'admin'); } protected function _initAutoLoadModuleAdmin() { $autoloader = new Zend_Application_module_Autoloader(array( 'namespace' => 'Admin', 'basePath' => APPLICATION_PATH . '/modules/admin' )); return $autoloader; } protected function _initModuleutoload() { $autoloader = new Zend_Application_Module_Autoloader ( array ('namespace' => '', 'basePath' => APPLICATION_PATH ) ); return $autoloader; } } class ModuleLayoutLoader extends Zend_Controller_Action_Helper_Abstract // looks up layout by module in application.ini { public function preDispatch() { $bootstrap = $this->getActionController() ->getInvokeArg('bootstrap'); $config = $bootstrap->getOptions(); echo $module = $this->getRequest()->getModuleName(); /*echo "Configs : <pre>"; print_r($config[$module]);*/ if (isset($config[$module]['resources']['layout']['layout'])) { $layoutScript = $config[$module]['resources']['layout']['layout']; $this->getActionController() ->getHelper('layout') ->setLayout($layoutScript); } } } application/modules/admin/Bootstrap.php <?php class Admin_Bootstrap extends Zend_Application_Module_Bootstrap { /*protected function _initAppAutoload() { $autoloader = new Zend_Application_Module_Autoloader(array( 'namespace' => 'admin', 'basePath' => APPLICATION_PATH . '/modules/admin/' )); return $autoloader; }*/ protected function _initDoctype() { $this->bootstrap( 'view' ); $view = $this->getResource( 'view' ); $view->navigation = array(); $view->subnavigation = array(); $view->headTitle( 'Module One' ); $view->headLink()->appendStylesheet('/css/clear.css'); $view->headLink()->appendStylesheet('/css/main.css'); $view->headScript()->appendFile('/js/jquery.js'); $view->doctype( 'XHTML1_STRICT' ); //$view->navigation = $this->buildMenu(); } } Please go through it and let me know any knows how do configure module and layout in right way.. Thanks and regards, Prasanth P

    Read the article

  • SQL Server 2005 Disk Configuration: Single RAID 1+0 or multiple RAID 1+0s?

    - by mfredrickson
    Assuming that the workload for the SQL Server is just a normal OLTP database, and that there are a total of 20 disks available, which configuration would make more sense? A single RAID 1+0, containing all 20 disks. This physical volume would contain both the data files and the transaction log files, but two logical drives would be created from this RAID: one for the data files and one for the log files. Or... Two RAID 1+0s, each containing 10 disks. One physical volume would contain the data files, and the other would contain the log files. The reason for this question is due to a disagreement between me (SQL Developer) and a co-worker (DBA). For every configuration that I've done, or seen others do, the data files and transaction log files were separated at the physical level, and were placed on separate RAIDs. However, my co-workers argument is that by placing all the disks into a single RAID 1+0, then any IO that is done by the server is potentially shared between all 20 disks, instead of just 10 disks in my suggested configuration. Conceptually, his argument makes sense to me. Also, I've found some information from Microsoft that seems to supports his position. http://technet.microsoft.com/en-us/library/cc966414.aspx In the section titled "3. RAID10 Configuration", showing a configuration in which all 20 disks are allocated to a single RAID 1+0, it states: In this scenario, the I/O parallelism can be used to its fullest by all partitions. Therefore, distribution of I/O workload is among 20 physical spindles instead of four at the partition level. But... every other configuration I've seen suggests physically separating the data and log files onto separate RAIDs. Everything I've found here on Server Fault suggests the same. I understand that a log files will be write heavy, and that data files will be a combination of reads and writes, but does this require that the files be placed onto separate RAIDs instead of a single RAID?

    Read the article

  • Installing a configuration profile on iPhone - programmatically

    - by Seva Alekseyev
    Hi all, I would like to ship a configuration profile with my iPhone application, and install it if needed. Mind you, we're talking about a configuration profile, not a provisioning profile. First off, such a task is possible. If you place a config profile on a Web page and click on it from Safari, it will get installed. If you e-mail a profile and click the attachment, it will install as well. "Installed" in this case means "The installation UI is invoked" - but I could not even get that far. So I was working under the theory that initiating a profile installation involves navigating to it as a URL. I added the profile to my app bundle. A) First, I tried [sharedApp openURL] with the file:// URL into my bundle. No such luck - nothing happens. B) I then added an HTML page to my bundle that has a link to the profile, and loaded it into a UIWebView. Clicking on the link does nothing. Loading an identical page from a Web server in Safari, however, works fine - the link is clickable, the profile installs. I provided a UIWebViewDelegate, answering YES to every navigation request - no difference. C) Then I tried to load the same Web page from my bundle in Safari (using [sharedApp openURL] - nothing happens. I guess, Safari cannot see files inside my app bundle. D) Uploading the page and the profile on a Web server is doable, but a pain on the organizational level, not to mention an extra source of failures (what if no 3G coverage? etc.). So my big question is: how do I install a profile programmatically? And the little questions are: what can make a link non-clickable within a UIWebView? Is it possible to load a file:// URL from my bundle in Safari? If not, is there a local location on iPhone where I can place files and Safari can find them? EDIT on B): the problem is somehow in the fact that we're linking to a profile. I renamed it from .mobileconfig to .xml ('cause it's really XML), altered the link. And the link worked in my UIWebView. Renamed it back - same stuff. It looks as if UIWebView is reluctant to do application-wide stuff - since installation of the profile closes the app. I tried telling it that it's OK - by means of UIWebViewDelegate - but that did not convince. Same behavior for mailto: URLs within UIWebView. For mailto: URLs the common technique is to translate them into [openURL] calls, but that doesn't quite work for my case, see scenario A. For itms: URLs, however, UIWebView works as expected... EDIT2: tried feeding a data URL to Safari via [openURL] - does not work, see here: http://stackoverflow.com/questions/641461/iphone-open-data-url-in-safari EDIT3: found a lot of info on how Safari does not support file:// URLs. UIWebView, however, very much does. Also, Safari on the simulator open them just fine. The latter bit is the most frustrating.

    Read the article

  • What CI server and Configuration Management tools I should use

    - by Bera
    Hi ! What CI server and Configuration Management tools I should use together for a truly development and deploy maintenance. There isn't the de facto rails sustainable environment, is there? Some assumptions: • code control version ok - git (de facto tool) • test framework ok - whatever (rspec is my choice) • code coverage and analysis ok - whatever (metric-fu, for example) • server stack ok - (Passenger for example) • issue tracker (RedMine) • etc, ... I'm want to play if integrity and moonshine projects, for me it's a good for beginning, isn't it? What do you think about this? Thanks, Bruno

    Read the article

  • java: Preferences API vs. Apache Commons Configuration

    - by Jason S
    I need to allow the user to store/load an arbitrary number of lists of objects (assume they are Serializable). Conceptually I want a data model like class FooBean { /* bean stuff here */ } class FooList { final private Set<FooBean> items = new HashSet<FooBean>(); public boolean add(FooBean item) { return items.add(item); } public boolean remove(FooBean item) { return items.remove(item); } public Collection<FooBean> getItems() { return Collections.unmodifiableSet(items); } } class FooStore { public FooStore() { /* something... uses Preferences or Commons Configuration */ } public FooList load(String key) { /* something... retrieves a FooList associated with the key */ } public void store(String key, FooList items) { /* something... saves a FooList under the given key */ } } Should I use the Preferences API or Commons Config? What's the advantages of each?

    Read the article

  • Hibernate MySQL transaction configuration issue

    - by James
    I'm having trouble starting a transaction with Hibernate and MySQL while running in JUnit. I'm getting a HibernateException which states: "No TransactionManagerLookup specified". I believe this error is because I don't have a proper configuration setting for hibernate.transaction.manager_lookup_class. I see that under the namespace of org.hibernate.transaction there are quite a few different lookup classes that I could use. All of the documentation that I could find on these was very vague. My question is what is the appropriate one for MySQL?

    Read the article

  • Are IoC containers about configuration files?

    - by Jader Dias
    Recently I developed a performance tester console application, with no UI, with the help of a IoC containter (Castle-Windsor-Microkernel). This library enabled me to let the user choose which test(s) to run, simply by changing the configuration file. Have I realized what IoC containers are about? I'm not sure. Even Joel said here on SO that IoC are difficult to understand. From my example, what do you conclude? Am I using IoC container for exactly what they were designed for? Or I am just using one of its secondary features?

    Read the article

  • enterprise library configuration 4.0

    - by prince23
    hi, i am using enterprise libaray confiuration 4.0. and here i have set the file size as rollSizeKB="20" but once my file size reaches 9kb. a new file is created. what is te issue. why is it creating new file once it reaches 9KB. <add fileName="c:\Exception.log" footer="----------------------------------------" formatter="Text Formatter" header="----------------------------------------" rollFileExistsBehavior="Increment" rollInterval="None" rollSizeKB="20" timeStampPattern="yyyy-MM-dd" listenerDataType="Microsoft.Practices.EnterpriseLibrary.Logging.Configuration.RollingFlatFileTraceListenerData, Microsoft.Practices.EnterpriseLibrary.Logging, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" traceOutputOptions="Timestamp" filter="All" type="Microsoft.Practices.EnterpriseLibrary.Logging.TraceListeners.RollingFlatFileTraceListener, Microsoft.Practices.EnterpriseLibrary.Logging, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" name="Exception Policy" /> any help would be great thank you

    Read the article

  • Mscorcfg.msc .net Configuration Tools problem

    - by vijay shiyani
    I'm trying to run Microsoft's .NET Framework Configuration Tool (Mscorcfg.msc). I have Visual Studio 2008 installed. I also have the following installed on my PC: Microsoft .Net Framework v1.0.3705 Microsoft .Net Framework 2.0 Service Pack 2 Microsoft .Net Framework 3.0 Service Pack 2 Microsoft .Net Framework 3.5 SP1 Microsoft .Net Framework v4.0.30319 I'm not sure why, but I can't start "Mscorcfg.msc" the usual way (as suggested in the http://msdn.microsoft.com/en-us/library/2bc0cxhc(VS.80).aspx and http://msdn.microsoft.com/en-us/library/2bc0cxhc.aspx URL). I looked for "Mscorcfg.msc" on my PC and found only 1 occurence (in the C:\WINDOWS\ServicePackFiles\i386 folder). When I double-click on the .msc file in Windows Explorer, I get the "MMC could not create the snap-in." message. What should I do ? Thanks

    Read the article

  • Common, reusable iPhone-App configuration screen

    - by Janey
    I'm writing code that will allow my iphone-app to have a "configuration page". A grouped, scrolling, UITableView... with cells that contain the needed textFields, switches, sliders, etc. It is an ENOURMOUS amount of code. Is there an easier way? Is there a way I could create a simple text-file, contain all my desired design choices and have my (reusable) code build the TableView for me? Or... can I just do the whole thing quicker/easier in Interface Builder instead of code?

    Read the article

  • ClearCase UCM Mainline Configuration Management Pattern Question

    - by cogmios
    A configuration management pattern question (using Rational ClearCase UCM) When I use the mainline approach I create new releases by: - create release 1 from mainline - on a certain moment baseline release 1, deliver release 1 to mainline - create release 2 from mainline - on a certain moment baseline release 2, deliver release 2 to mainline - create release 3 from mainline - etc... Works very nice because the pathname is /main/release 3/latest instead of /main/release 1/release 2/release 3/latest etc... However... when in release 1 are new elements that have to be propagated to later releases I can not use the mainline since the mainline is already on e.g. release 4. The only thing I can do is deliver/merge from release 1 directly to release 2. The bad thing is that the pathname then becomes /main/release 1/release 2/latest for that files (and possibly later releases). That is I think not in line with the mainline approach. What am I doing wrong?

    Read the article

  • iphone configuration profile installed via webkit.

    - by mamel
    Good day! I am using Xcode 3.1.4 and iPhone SDK 2.2.1. I am creating an iphone application and i would need the user to download a custom configuration profile (created by me) from a URL loaded via webkit. I have tested the URL in safari and it downloads and installs the profile just fine. however, the url opened via webkit could NOT download it. Why is this happening? Is this really possible? any help would be much appreciated. thanks.

    Read the article

  • Automating Firefox configuration settings

    - by Richard100
    Hi All, During web development work, I need to be able to quickly switch various config settings in Firefox. In particular I need to be able to: 1) Switch off cookies 2) Switch off javascript 3) Switch my user agent (I have the user-agent switcher add-on installed) and then back again. Instead of doing this manually, it would be great if i could add a "macro" button to my toolbar that I could simply click to toggle the three settings above. Anyone know if this is possible? Btw - Firefox Profiles doesn't really cut it. You can't dynamically switch profiles within a specific Firefox instance, which I need to be able to do. Btw2 - I got excited when i saw Greasemonkey, Chicken Foot, but it looks like these can only automate browsing/DOM tasks, and not with firefox configuration settings. Thanks Richard.

    Read the article

  • GIt Deployment + Configuration Files + Heroku

    - by Andrew
    I'm using Heroku to host a Rails app, which means using Git to deploy to Heroku. Because of the "pure Git workflow" on Heroku, anything that needs to go upstream to the server has to be configured identically on my local box. However I need to have certain configuration files be different depending on whether I'm in the local setup or deployed on Heroku. Again, because of the deployment method Heroku uses I can't use .gitignore and a template (as I have seen suggested many times, and have used in other projects). What I need is for git to somehow track changes on a file, but selectively tell git not to override certain files when pulling from a particular repo -- basically to make certain changes one-way only. Can this be done? I'd appreciate any suggestions!

    Read the article

  • Leveraging .Net 4.0 Framework Tools For Encrypting Web Configuration Sections

    - by Sam Abraham
    I would like to share a few points with regards to encrypting web configuration sections in .Net 4.0. This information is also applicable to .Net 3.5 and 2.0. Two methods can work perfectly for encrypting connection strings in a Web project configuration file:   1-Do It All Yourself! In this approach, helper functions for encrypting/decrypting configuration file content are implemented. Program would explicitly retrieve appropriate content from configuration file then decrypt it appropriately.  Disadvantages of this implementation would be the added overhead for maintaining the encryption/decryption code as well the burden of always ensuring sections are appropriately decrypted before use and encrypted appropriately whenever edited.   2- Leverage the .Net 4.0 Framework (The Way to go!) Fortunately, all needed tools for protecting configuration files are built-in to the .Net 2.0/3.5/4.0 versions with very little setup needed. To encrypt connection strings, one can use the ASP.Net IIS Registration Tool (Aspnet_regiis.exe). Note that a 64-bit version of the tool also exists under the Framework64 folder for 64-bit systems. The command we need to encrypt our web.config file connection strings is simply the following:   Aspnet_regiis –pe “connectionstrings” –app “/sampleApplication” –prov “RsaProtectedConfigurationProvider”   To later decrypt this configuration section:   Aspnet_regiis –pd “connectionstrings” –app “/SampleApplication”   The following is a brief description of the command line options used in the example above. Aspnet_regiis supports many more options which you can read about in the links provided for reference below.   Option Description -pe  Section name to encrypt -pd  Section name to decrypt -app  Web application name -prov  Encryption/Decryption provider   ASP.Net automatically decrypts the content of the Web.Config file at runtime so no programming changes are needed.   Another tool, aspnet_setreg.exe is to be used if certain configuration file sections pertinent to the .Net runtime are to be encrypted. For more information on when and how to use aspnet_setreg, please refer to the references below.   Hope this helps!   Some great references concerning the topic:   http://msdn.microsoft.com/en-us/library/ff650037.aspx http://msdn.microsoft.com/en-us/library/zhhddkxy.aspx http://msdn.microsoft.com/en-us/library/dtkwfdky.aspx http://msdn.microsoft.com/en-us/library/68ze1hb2.aspx

    Read the article

  • Custom Configuration Section Handlers

    Most .NET developers who need to store something in configuration tend to use appSettings for this purpose, in my experience.  More recently, the framework itself has helped things by adding the <connectionStrings /> section so at least these are in their own section and not adding to the appSettings clutter that pollutes most apps.  I recommend avoiding appSettings for several reasons.  In addition to those listed there, I would add that strong typing and validation are additional reasons to go the custom configuration section route. For my ASP.NET Tips and Tricks talk, I use the following example, which is a simple DemoSettings class that includes two fields.  The first is an integer representing how many attendees there are present for the talk, and the second is the title of the talk.  The setup in web.config is as follows: <configSections> <section name="DemoSettings" type="ASPNETTipsAndTricks.Code.DemoSettings" /> </configSections>   <DemoSettings sessionAttendees="100" title="ASP.NET Tips and Tricks DevConnections Spring 2010" /> Referencing the values in code is strongly typed and straightforward.  Here I have a page that exposes two properties which internally get their values from the configuration section handler: public partial class CustomConfig1 : System.Web.UI.Page { public string SessionTitle { get { return DemoSettings.Settings.Title; } } public int SessionAttendees { get { return DemoSettings.Settings.SessionAttendees; } } } Note that the settings are only read from the config file once after that they are cached so there is no need to be concerned about excessive file access. Now weve seen how to set it up on the config file and how to refer to the settings in code.  All that remains is to see the file itself: public class DemoSettings : ConfigurationSection { private static DemoSettings settings = ConfigurationManager.GetSection("DemoSettings") as DemoSettings; public static DemoSettings Settings{ get { return settings;} }   [ConfigurationProperty("sessionAttendees" , DefaultValue = 200 , IsRequired = false)] [IntegerValidator(MinValue = 1 , MaxValue = 10000)] public int SessionAttendees { get { return (int)this["sessionAttendees"]; } set { this["sessionAttendees"] = value; } }   [ConfigurationProperty("title" , IsRequired = true)] [StringValidator(InvalidCharacters = "~!@#$%^&*()[]{}/;\"|\\")] public string Title { get { return (string)this["title"]; } set { this["title"] = value; }   } } The class is pretty straightforward, but there are some important components to note.  First, it must inherit from System.Configuration.ConfigurationSection.  Next, as a convention I like to have a static settings member that is responsible for pulling out the section when the class is first referenced, and further to expose this collection via a static readonly property, Settings.  Note that the types of both of these are the type of my class, DemoSettings. The properties of the class, SessionAttendees and Title, should map to the attributes of the config element in the XML file.  The [ConfigurationProperty] attribute allows you to map the attribute name to the property name (thus using both XML standard naming conventions and C# naming conventions).  In addition, you can specify a default value to use if nothing is specified in the config file, and whether or not the setting must be provided (IsRequired).  If it is required, then it doesnt make sense to include a default value. Beyond defaults and required, you can specify more advanced validation rules for the configuration values using additional C# attributes, such as [IntegerValidator] and [StringValidator].  Using these, you can declaratively specify that your configuration values be in a given range, or omit certain forbidden characters, for instance.  Of course you can write your own custom validation attributes, and there are others specified in System.Configuration. Individual sections can also be loaded from separate files, using syntax like this: <DemoSettings configSource="demosettings.config" /> Summary Using a custom configuration section handler is not hard.  If your application or component requires configuration, I recommend creating a custom configuration handler dedicated to your app or component.  Doing so will reduce the clutter in appSettings, will provide you with strong typing and validation, and will make it much easier for other developers or system administrators to locate and understand the various configuration values that are necessary for a given application. Did you know that DotNetSlackers also publishes .net articles written by top known .net Authors? We already have over 80 articles in several categories including Silverlight. Take a look: here.

    Read the article

  • wcf configuration for this code

    - by user208081
    I have the following code and would like to convert a lot of code into configuration settings for WCF. As you can see, the code is using wshttpbinding. I appreciate any help on this. try { // Provides a unique network address that a client uses to communicate with a service endpoint. EndpointAddress endpointAddress = new EndpointAddress(new Uri(FAXServiceSettings.Default.FAXReceiveServiceURL)); // Specify the protocols, transports, and message encoders used for communication between the client and the service. // WSHttpBinding represents an interoperable binding that supports distributed transactions and secure, reliable sessions. // Spefically, SOAP message security is enabled for secure transmission of the message content. WSHttpBinding clientBinding = new WSHttpBinding(SecurityMode.Message); clientBinding.OpenTimeout = TimeSpan.FromSeconds(FAXServiceSettings.Default.FAXReceiveServiceOpenTimeoutInSeconds); clientBinding.SendTimeout = TimeSpan.FromSeconds(FAXServiceSettings.Default.FAXReceiveServiceOpenTimeoutInSeconds); // Use the ChannelFactory to enable the creation of channels to the binding and endpoint. using (ChannelFactory<IReceiveFAX> channelFactory = new ChannelFactory<IReceiveFAX>(clientBinding, endpointAddress)) { // Creates a channel of a specified type to a specified endpoint address. IReceiveFAX channel = channelFactory.CreateChannel(); if (channel != null) { try { // Submit the FaxSchedule instance for routing. channel.SubmitFAXForRouting(CreateNewFaxScheduleContainerInstance()); // Explicitly close the channel using the IClientChannel interface. CloseChannel((channel as IClientChannel)); } finally { // Explicitly dispose of the channel using IDisposable interface. DisposeOfChannel((channel as IDisposable)); channel = null; } } // This method causes a CommunicationObject to gracefully transition from any state, other than the Closed state, into the Closed state. The Close method allows any // unfinished work to be completed before returning. For example, finish sending any buffered messages. channelFactory.Close(); } } catch { throw; } Pratik

    Read the article

  • Java - encrypt / decrypt user name and password from a configuration file

    - by nzpcmad
    We are busy developing a Java web service for a client. There are two possible choices: Store the encrypted user name / password on the web service client. Read from a config. file on the client side, decrypt and send. Store the encrypted user name / password on the web server. Read from a config. file on the web server, decrypt and use in the web service. The user name / password is used by the web service to access a third-party application. The client already has classes that provide this functionality but this approach involves sending the user name / password in the clear (albeit within the intranet). They would prefer storing the info. within the web service but don't really want to pay for something they already have. (Security is not a big consideration because it's only within their intranet). So we need something quick and easy in Java. Any recommendations? The server is Tomkat 5.5. The web service is Axis2. What encrypt / decrypt package should we use? What about a key store? What configuration mechanism should we use? Will this be easy to deploy?

    Read the article

  • how to read in a list of custom configuration objects

    - by Johnny
    hi, I want to implement Craig Andera's custom XML configuration handler in a slightly different scenario. What I want to be able to do is to read in a list of arbitrary length of custom objects defined as: public class TextFileInfo { public string Name { get; set; } public string TextFilePath { get; set; } public string XmlFilePath { get; set; } } I managed to replicate Craig's solution for one custom object but what if I want several? Craig's deserialization code is: public class XmlSerializerSectionHandler : IConfigurationSectionHandler { public object Create(object parent, object configContext, XmlNode section) { XPathNavigator nav = section.CreateNavigator(); string typename = (string)nav.Evaluate("string(@type)"); Type t = Type.GetType(typename); XmlSerializer ser = new XmlSerializer(t); return ser.Deserialize(new XmlNodeReader(section)); } } I think I could do this if I could get Type t = Type.GetType("System.Collections.Generic.List<TextFileInfo>") to work but it throws Could not load type 'System.Collections.Generic.List<Test1.TextFileInfo>' from assembly 'Test1, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'.

    Read the article

  • getting an exception when refreshing the configuration in memory on change to external config file

    - by RKP
    Hi, I have a windows service which reads the config settings from an external file which is located at a different path than the path to the executable for the windows service. the windows service uses a FileSystemWatcher to monitor the changes to the external config file and when it the config file is changed, it should refresh the settings in memory by reading the updated settings from the config file. but this is where I am getting an exception "ConfigurationErrorsException" and the message is "An error occurred creating the configuration section handler for appSettings: The process cannot access the file 'M:\somefolder\WindowsService1.Config' because it is being used by another process." and the inner exception is actually "IOException" with same message. here is the code. I am not sure what is wrong with the code. Please help. protected void watcher_Changed(object sender, FileSystemEventArgs e) { ConfigurationManager.RefreshSection(ConfigSectionName); WriteToEventLog(ConfigKeyCheck); if (FileChanged != null) FileChanged(this, EventArgs.Empty); } private void WriteToEventLog(string key) { if (EventLog.SourceExists(ServiceEventSource)) { EventLog.WriteEntry(ServiceEventSource, string.Format("key:{0}, value:{1}", key, ConfigurationManager.AppSettings[key])); } }

    Read the article

  • WCF doesn't find client configuration

    - by ultraman69
    Hi ! I have a WCF service on server B. Then on the machine A is the client, which is a Windows service. In a separate dll stands all the business logic for this service. So my proxy for the WCF is on that side. I have 2 app.config (client side only) : 1 for the service and another one in the dll. So I tried (for test purpose) puting the servicemodel config section in both. Both still, it doesn't work, it says that it can't find the endpoint with that name and for that contract... What I'm trying to do here is modify the configuration programatically. Here' the code in the business layer dll : Dim ep As New EndpointAddress(New Uri(ConfigurationManager.AppSettings(nomServeurCible)), _ EndpointIdentity.CreateDnsIdentity(ConfigurationManager.AppSettings("Identity_" & nomServeurCible))) serviceCible = New ServiceProxy.ExecOperClient("wsHttp", ep) And here is a sample of the config file : <add key="TEST1" value="http://TEST1:8000/MySpacePerso/ExecOperService"/> <add key="TEST1_CertificateSerialNumber" value="10 hj 6y 7b 00 01 32 12 01 21"/> <add key="Identity_TEST1" value="TEST1"/> <system.serviceModel> <client> <endpoint address="http://SERV_NAME:8000/CSSTQDA/ExecOperService" binding="wsHttpBinding" behaviorConfiguration="myClientBehavior" bindingConfiguration="MybindingCon" contract="ExecOper.Service.IExecOper" name="wsHttp"> <identity> <dns value="SERV_CERT_NAME"/> </identity> </endpoint> </client> <bindings> <wsHttpBinding> <binding name="MybindingCon"> <security mode="Message"> <message clientCredentialType="UserName" /> </security> </binding> </wsHttpBinding> </bindings> <behaviors> <serviceBehaviors> <behavior name="ServiceTraitementBehavior"> <serviceMetadata httpGetEnabled="True"/> <serviceDebug includeExceptionDetailInFaults="True" /> </behavior> </serviceBehaviors> <endpointBehaviors> <behavior name="myClientBehavior"> <clientCredentials> <serviceCertificate> <authentication certificateValidationMode="ChainTrust" revocationMode="NoCheck"/> </serviceCertificate> </clientCredentials> </behavior> </endpointBehaviors> </behaviors>

    Read the article

  • Multiple WCF windows services on the same box - endpoint configuration

    - by David Belanger
    Hi, I have 2 windows services installed on a machine with different service names, they install and start fine. What's happening is that they're both listening to the same endpoints and thus competing for messages. I've tried to change the baseAddress to be different for both services without success. Here's my service host config: <configuration> <appSettings> <add key="ServiceName" value="Service - Service Host 1"/> </appSettings> <system.serviceModel> <bindings> <wsHttpBinding> <binding name="NoSecurityBinding"> <security mode="None"> <message establishSecurityContext="false"/> <transport clientCredentialType="None"/> </security> </binding> </wsHttpBinding> <basicHttpBinding> <binding name="NoSecurityBinding"> <security mode="None"> <transport clientCredentialType="None"/> </security> </binding> </basicHttpBinding> </bindings> <services> <service name="Lib.Interface.Service" behaviorConfiguration="Lib.Interface.ServiceBehavior"> <host> <baseAddresses> <add baseAddress="http://localhost:8000/Service"/> </baseAddresses> </host> <endpoint address="" binding="basicHttpBinding" bindingConfiguration="NoSecurityBinding" contract="Lib.Interface.IService"/> <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange"/> </service> </services> <behaviors> <serviceBehaviors> <behavior name="Lib.Interface.ServiceBehavior"> <serviceMetadata httpGetEnabled="True" policyVersion="Policy12"/> <serviceDebug includeExceptionDetailInFaults="False"/> </behavior> </serviceBehaviors> </behaviors> Any idea how I could set up the services (other than unique service names) so they're not conflicting with one another? Thanks.

    Read the article

< Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >