But this is never reaching into the actual app! On Wed, Feb 4, 2009 at 7:25 PM, Mike Nichols <[email protected]>wrote:
> > Matt- > I think this is due to the bus shutdown message : "Shutdown bus" which > isn't formatted in xml. > > On Feb 2, 7:58 pm, Ayende Rahien <[email protected]> wrote: > > applied > > > > On Mon, Feb 2, 2009 at 2:02 PM, Matt Burton <[email protected]> > wrote: > > > Yep - that's what I wound up doing. Figured out what was going wrong - > > > see the attached patch - the shorthand versions of the command line > > > arguments aren't getting parsed correctly ("asm", "cfg", etc...) - > > > when the ExecutingOptions instance is converted to a string it uses > > > the short versions. I changed the ToString implementation to use the > > > long versions, which do get parsed correctly, and then that's the > > > string that gets written to the registry for the ImagePath. Good to > > > go. My service still wouldn't start at that point but luckily the > > > event log told me what was going on - service didn't have permissions > > > for the queue - d'oh! :) I'm sure you would rather that the root issue > > > with parsing the arguments is solved but unfortunately I need to move > > > on at this point. If you want I could try to dig into that late > > > tonight. > > > > > While I've got you I've noticed an intermittent issue wherein I'll > > > have a problem starting a service, but my subscriptions were stored > > > before the process bombs. When I fix the issue and restart the service > > > I get a deserialization error sometimes when it reads the subscription > > > queue complaining about missing the root element in the document. The > > > remedy is to purge the subscription queue and start over but it would > > > be nice to know what's happening in the interim. Any ideas? > > > > > On Mon, Feb 2, 2009 at 1:19 PM, Ayende Rahien <[email protected]> > wrote: > > > > Put a System.Diagnostics.Debugger.Launch() in it. > > > > > > On Mon, Feb 2, 2009 at 11:16 PM, Matt Burton <[email protected]> > > > wrote: > > > > > >> Ah - gotcha. Okay - I'll take a look - getting the ever helpful > > > >> "Service cannot be started. The service process could not connect to > > > >> the service controller" message in the event log... > > > > > >> On Mon, Feb 2, 2009 at 1:12 PM, Ayende Rahien <[email protected]> > > > wrote: > > > >> > That is an old version of the host. > > > >> > On Mon, Feb 2, 2009 at 11:08 PM, Matt Burton < > [email protected]> > > > >> > wrote: > > > > > >> >> Alright - I'll give it a go and see if I can figure out what's > going > > > >> >> on. I know you said you were using RSB for the NHProf site - how > are > > > >> >> you hosting the services for that? I'm looking to integrate this > into > > > >> >> our current codebase and I'm keen on getting the host to work so > I > > > >> >> don't have to go reinventing the wheel - but if there's a simpler > way > > > >> >> I can use in the interim I'm all ears... > > > > > >> >> On Mon, Feb 2, 2009 at 1:05 PM, Ayende Rahien <[email protected] > > > > > >> >> wrote: > > > >> >> > Not tested yet. > > > > > >> >> > On Mon, Feb 2, 2009 at 11:00 PM, Matt Burton < > > > [email protected]> > > > >> >> > wrote: > > > > > >> >> >> Excellent - thanks! Are you able to host and run services now? > > > > > >> >> >> On Mon, Feb 2, 2009 at 3:27 AM, Ayende Rahien < > [email protected]> > > > >> >> >> wrote: > > > >> >> >> > applied > > > > > >> >> >> > On Fri, Jan 30, 2009 at 6:27 AM, Matt Burton > > > >> >> >> > <[email protected]> > > > >> >> >> > wrote: > > > > > >> >> >> >> Sure thing - there you go. This gets around the install > > > problem, > > > >> >> >> >> but > > > >> >> >> >> like I said, the service won't start - haven't been able to > dig > > > >> >> >> >> into > > > >> >> >> >> that to diagnose yet... > > > > > >> >> >> >> Thanks, > > > >> >> >> >> Matt > > > > > >> >> >> >> On Thu, Jan 29, 2009 at 6:44 PM, Ayende Rahien > > > >> >> >> >> <[email protected]> > > > >> >> >> >> wrote: > > > >> >> >> >> > Can you create a patch? It is hard for me to see what was > > > >> >> >> >> > changed. > > > > > >> >> >> >> > On Thu, Jan 29, 2009 at 6:23 PM, Matt Burton > > > >> >> >> >> > <[email protected]> > > > >> >> >> >> > wrote: > > > > > >> >> >> >> >> No matter what combination I try I wind up with the > > > following > > > >> >> >> >> >> error > > > >> >> >> >> >> when attempting to install a service using the host... > > > > > C:\dev\rsb-spike\Services\bin\Debug>Rhino.ServiceBus.Host.exe > > > >> >> >> >> >> /action:Install /asm:"Services.dll" > > > >> >> >> >> >> /name:"ApplicationServices" > > > >> >> >> >> >> Installing service ApplicationServices... > > > >> >> >> >> >> Creating EventLog source ApplicationServices in log > > > >> >> >> >> >> Application... > > > >> >> >> >> >> System.InvalidOperationException: Cannot get service > file > > > >> >> >> >> >> name. > > > >> >> >> >> >> at > > > >> >> >> >> >> > System.ServiceProcess.ServiceInstaller.Install(IDictionary > > > >> >> >> >> >> stateSaver) > > > >> >> >> >> >> at > > > >> >> >> >> >> > System.Configuration.Install.Installer.Install(IDictionary > > > >> >> >> >> >> stateSaver) > > > >> >> >> >> >> at > > > > > Rhino.ServiceBus.Host.Actions.InstallAction.Execute(ExecutingOptions > > > >> >> >> >> >> options) in C:\dev\open-source\rhino-tools.ti > > > > > > p\trunk\rhino-service.bus\Rhino.ServiceBus.Host\Actions\InstallAction.cs:line > > > >> >> >> >> >> 18 > > > >> >> >> >> >> at Rhino.ServiceBus.Host.Program.Main(String[] args) > in > > > > > C:\dev\open-source\rhino-tools.tip\trunk\rhino-service.bus\Rh > > > >> >> >> >> >> ino.ServiceBus.Host\Program.cs:line 31 > > > > > >> >> >> >> >> I hacked on it for a bit and was able to get the service > to > > > >> >> >> >> >> install > > > >> >> >> >> >> by > > > >> >> >> >> >> changing the InstallAction implementation to the > following: > > > > > >> >> >> >> >> public void Execute(ExecutingOptions options) > > > >> >> >> >> >> { > > > > > >> >> >> >> >> var installer = new ProjectInstaller > > > >> >> >> >> >> { > > > >> >> >> >> >> DisplayName = options.Name, > > > >> >> >> >> >> Description = options.Name, > > > >> >> >> >> >> Context = new InstallContext() > > > >> >> >> >> >> }; > > > >> >> >> >> >> installer.Context.Parameters.Add("assemblypath", > > > >> >> >> >> >> this.GetType().Assembly.Location); > > > >> >> >> >> >> installer.Install(new Hashtable()); > > > >> >> >> >> >> using (var system = > > > >> >> >> >> >> Registry.LocalMachine.OpenSubKey("System")) > > > >> >> >> >> >> using (var currentControlSet = > > > >> >> >> >> >> system.OpenSubKey("CurrentControlSet")) > > > >> >> >> >> >> using (var services = > > > >> >> >> >> >> currentControlSet.OpenSubKey("Services")) > > > >> >> >> >> >> using (var service = > > > >> >> >> >> >> services.OpenSubKey(installer.ServiceName, > > > >> >> >> >> >> true)) > > > >> >> >> >> >> { > > > >> >> >> >> >> var path = (string)service.GetValue("ImagePath"); > > > > > >> >> >> >> >> options.Action = Action.Server; > > > > > >> >> >> >> >> service.SetValue("ImagePath", path + options); > > > >> >> >> >> >> } > > > >> >> >> >> >> } > > > > > >> >> >> >> >> Notice the addition of the "assemblypath" context and > then > > > >> >> >> >> >> changing > > > >> >> >> >> >> the Action to Server. I can now install and uninstall > but > > > the > > > >> >> >> >> >> service > > > >> >> >> >> >> won't start - I'm getting the following message in the > event > > > >> >> >> >> >> viewer: > > > > > >> >> >> >> >> "Service cannot be started. The service process could > not > > > >> >> >> >> >> connect > > > >> >> >> >> >> to > > > >> >> >> >> >> the service controller" > > > > > >> >> >> >> >> Any thoughts? > > > > > >> >> >> >> >> Thanks, > > > >> >> >> >> >> Matt > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Rhino Tools Dev" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/rhino-tools-dev?hl=en -~----------~----~----~----~------~----~------~--~---
