Re: Configuring instances/app directly in SiteConfig.xml
Dev WO <[email protected]> Tue, 20 Jul 2004 19:53:28 +0200
| Newsgroups | gmane.comp.web.webobjects.admin |
|---|---|
| Message-ID | <[email protected]> |
>>>> I think we can get some information about instances with wotask, >>>> but I couldn't find how to do it, for exemple: >>> >>> I assume that you mean directly from the SiteConfig.xml? >> Not really, SiteConfig.xml doesn't know about on/off instances, >> memory usage, etc I think. > > In that case, you want to use Monitor, rather than talking to wotaskd > directly. > > >>>> -getting the list of running instances >>> >>> If wotaskd is set to generate the WOConfig.xml, this should have a >>> list of running instances. >> Is there anyway to see if an instance is on or off (or crashed) >> inside SiteConfig.xml? > > No. WOConfig.xml (if generated) will have some of that information, > but SiteConfig is the site configuration, not the site status. OK, I have to check a the documentation to learn about WOConfig if it can help. > > >>>> -getting the list of dead/crashed instances >>> >>> This would be the list of instances minus the list of running >>> instances :) >> of course;) but in SiteConfig.xml I may be able to get only the >> configured instances, without knowing if it's on or off no? > > Correct. > > >>>> -getting the memory usage of an instance >>>> -getting the CPU usage of an instance >>> >>> Sorry. >> At least for the memory, I think the instance itself got some >> informations (WOStats), but I though I could get these information in >> a terminal window, but maybe it's more "system" than WO... > > This information is more system (the information provided by the > instance is only approximate, I believe). It's easy enough to create a > direct action to return the WOStats information, then use wget or curl > to retrieve it. I understand your point, I was just wondering about a direct way to get to the information, I'd like to make the app as "simple" as possible to reduce the maintenance process/complexity. > > > >>> You can use Monitor... >> I'm trying to make a WebApplication to "monitor" the Applications / >> Instances on a per user basis, so I don't want to use Monitor. > > I see. Unfortunately the protocol between Monitor/wotaskd isn't open > (though practically, it's just XML passed through direct actions). > > >>>> We've also got some problems when we use Monitor after modifying >>>> directly the xml file (we stop Monitor before modifying): >>> >>> Unless you stop wotaskd, this won't work at all. Monitor never >>> writes at all. >> But when I have several instances running, if I change something in >> Monitor, the .xml file is updated, the instance I modified is updated >> and all the other instances didn't stop. So there's a wotaskd process >> for each instance? > > No, there's a wotaskd process per host. > > wotaskd starts and reads the SiteConfig.xml to configure itself. > Monitor starts and reads the SiteConfig.xml to configure itself. > You make a change to <something> in Monitor. > Monitor sends some information about the change directly to wotaskd. > wotaskd directly changes the state of the <something>, and writes a > new copy of the SiteConfig.xml reflecting that change. > > wotaskd and Monitor never read the SiteConfig.xml after startup. > Monitor never writes the SiteConfig.xml. wotaskd writes the > SiteConfig.xml as appropriate to save a new configuration. OK. thanks for the clarification, I understand a lot more what's going on. I think I'll try to go back to WO documentation, I think I've red a mention about maintaining the SiteConfig.xml file by hand... > > Karl > > -- > > Due to budgetary constraints, the light at the end of the tunnel has > been temporarily turned off. > > Homepage: > http://homepage.mac.com/khsu/index.html > >