Hi Steve, thanks for your answers. However, I think IBM has built its appserver with some more complexity than appservers like jetty. So here are the complications I can think of with your approaches:
Am 11.11.2008 um 14:59 schrieb Steve Loughran: > Johannes Kleinlercher wrote: >> Hi all, >> I am very impressed of the idea and concept of smartfrog. >> However, after reading lots of documentation I didn't get a clue how >> to extend smartfrog >> to our own needs. >> What if I have a WebSphere Application Server and I want to do the >> configuration management >> with smartfrog? As I understand I have to write my own smartfrog >> component. > > Hello Johannes. > > There's two ways to do things > (1) custom Java components > (2) take and extend the existing components, using them in new > compound objects > > The first of these gives you the most control, but is also the > hardest work. Taking some existing stuff is a lot easier > > for the problem of WSAS, you can probably divide the problem up > > -Starting WebSphere with the right classpath and JVM options > -deploying WAR and EAR files > -checking the health of the web application > > to check the health, the LivenessPage component can be deployed to > issue HTTP GETs on a regular basis > /org/smartfrog/services/www/livenessPage.sf This will work, I think. > > > To deploy WAR/EAR files, the DeployByCopy components do all the > heavy lifting: they copy files to the relevant directory on startup, > delete them when terminated: > /org/smartfrog/services/www/dbc/components.sf In WebSphere you can't deploy by copying files. You have to call a wsadmin script (jacl or jython) with commands like "AdminApp.install(ear,options) > > > This leaves the app server itself. We don't have a custom component > for that, the way we do with Jetty. Instead you have to either use > the Cargo components (assuming Cargo can work with WebSphere), or > just use the Java component to bring up WebSphere. This is how we > bring things like JBoss up; it works very well: > > /org/smartfrog/services/www/servers/jboss4.sf > As I understand these components they just start a java process and you can define some classpaths or systemproperties. However, websphere configuration is much more complex. the appservers and related environment are first configured via wsadmin (or the web console) and saved in XML files. Then the servers get started by the nodeagent which is the parent- process for the appservers. > (these are all in the sf-www component bundle; the smartfrog-www > RPM, and documented in the wiki: > http://wiki.smartfrog.org/wiki/display/sf/sf-www > ) > > >> I also understand that with the smartfrogs declarative language I >> define how a component should be >> configured and then it changes the configuration the way that it >> should be. If a component is already >> configured this way it does nothing. Okay in theory, but somehow I >> have to program this compare and configure >> and I have to provide websphere scripts or a websphere API do >> configure websphere, isn't it? > > You could actually start the native scripts, but then you need to > use the RunShell component to hook everything up, and do some work > to get any component values (such as environment variables) down to > the process. If you can get away with the Java command, that is the > one to go for. I still do not understand how you get to the state-driven-deployment feature. according to http://wiki.smartfrog.org/wiki/display/sf/State-driven+deployment smartfrog supports: The SmartFrog language can be used to describe the states of target systems, and the [SmartFrog Daemon] act as the configuration management agent. One subtlety is that while SmartFrog components can detect when they are not in a specific state, they do not normally automatically apply the changes. Instead they report the failure to their parent component. You need to use the retry component to undeploy then redeploy the component(s). That is really too "wishy-washy" ;) What do I need to implement to support this for websphere? > > >> Did I miss something or how do I implement a extension for WebSphere? > > Start with the Java command to run WebSphere and use the > DeployByCopy component to deploy web applications to the relevant > directory. Send us email if things aren't working or something > doesn't make sense, as that gives me an excuse to improve the > documentation. Writing WebSphere support in a new component is > harder work and something you should hold off doing until you are > sure that you really need it. > > Servuss, > > -steve ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Smartfrog-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/smartfrog-users
