|
From: Leif M. <le...@ta...> - 2003-11-06 03:01:23
|
Sal,
From your examples, I think you may be able to see how complicated a
task this could
quickly become. For now, I would like you think about how this kind of
thing can be
done from within the JVM within user code. If problems that can not be
solved from
within the JVM are encountered, it may be necessary for something to be
implemented
in the Wrapper. But so far, I don't see any such problems.
Cheers,
Leif
Sal Ingrilli wrote:
>thanks for the clarification.
>
>i believe leif already pushes all the service hooks through wrapper
>org.tanukisoftware.wrapper.WrapperListener, meaning you can do this without
>waiting for the wrapper to support it.
>
>
>however i can totally see a future version of the wrapper that would execute
>java code/scripts in function of events.
>so now i'd like to reverse my initial position!
>
>i think it would be great for the wrapper to be able to execute something in
>function of a the service events.
>for example:
>wrapper.on-event.start.execute.1=com.mycompany.NotifyStart
>wrapper.on-event.start.execute.2=notifyStart.pl
>wrapper.on-event.restart.execute.1=com.mycompany.NotifyReStart
>wrapper.on-event.restart.execute.2=notifyReStart.pl
>wrapper.on-event.stop.execute.1=com.mycompany.NotifyStop
>wrapper.on-event.stop.execute.2=notifyStop.pl
>
>in the first case, the wrapper would execute the given class inline with the
>same classpath setup in wrapper.conf.
>in the second case, it would execute "start notifyStart.pl"
>and similarly for all other events.
>
>there is an additional problem with this:
>wrapper.on-event.start.execute.1=com.mycompany.NotifyStart
>
>once you start developing, you'll end up with one class for each event
>because the wrapper would just invoke main () on these classes.
>it would be preferable to support only 1 class that implements a
>WrapperListener type interface which the wrapper could then call for all
>events.
>then to avoid jvm/jdk incompatibilities, the wrapper would have to use
>reflection to invoke the methods.
>this would make it a little tougher on the wrapper, but a lot easier on java
>programmers using the wrapper.
>
>so the above now becomes
>wrapper.on-event.*.execute.1=com.mycompany.WrapperListener
>wrapper.on-event.start.execute.2=notifyStart.pl
>wrapper.on-event.restart.execute.1=notifyReStart.pl
>wrapper.on-event.stop.execute.2=notifyStop.pl
>
>which is the same as what the wrapper already supports through
>org.tanukisoftware.wrapper.WrapperListener.
>so all it needs to some on-event way of executing specific shellable
>programs.
>
>i'll shut up now & see what others have to say...
>
>btw, can the pl programs be fully executed with the Win32 ShellExecute () as
>in ShellExecute ("notifyStart.pl") or do you also need to pass the perl
>interpreter's path?
>
>-----Original Message-----
>From: wra...@li...
>[mailto:wra...@li...]On Behalf Of Luis
>Guzman
>Sent: Wednesday, November 05, 2003 2:40 PM
>To: wra...@li...
>Subject: RE: [Wrapper-user] Wrapper notification...
>
>
>Sal,
>
>Yes I am aware of the windows option as in stated in my original
>message. I just needed confirmation that when the wrapper shutdown that
>it isn't a clean service shutdown and will invoke the recovery on the
>services.
>
>How I see it is that the wrapper current features and functionality
>aren't just aiming at running java as a service. It has evolved to be a
>very strong tool for service availability with the ping timeouts, cpu
>timeout, and filter action. Those are all monitoring ability of the
>wrapper.
>
>Now the question about sending email can be rephrased. Instead of an
>email, the ability to execute something on shutdown would leave the door
>open for everyone to create their own custom tools around the event.
>
>Again, my reason for asking is mainly because on some machines we are
>running 5 different services. Now multiply that 60 machines, that's 300
>services that I would need to modify. And our dynamics could change 3
>of those services to different configuration for different databases.
>So, I hope you can understand where I'm heading with these figures.
>
>Regards,
>Luis
>
>
>-----Original Message-----
>From: Sal Ingrilli [mailto:sal...@sy...]
>Sent: Wednesday, November 05, 2003 5:03 PM
>To: wra...@li...
>Subject: RE: [Wrapper-user] Wrapper notification...
>
>
>i think your request is useful.
>however i am against it because your adding non-wrapper functionality to
>the wrapper. additionally you're adding complexity to the development of
>the wrapper.
>
>here are same alternatives
>1. use log4j notifications (email and windows event log are supported)
>2. use windows service recovery options to run a script if a service
>fails...
>
>windows service recovery: go to administrative tools | services |
>right-click on your service | recovery
>
>-----Original Message-----
>From: wra...@li...
>[mailto:wra...@li...]On Behalf Of Luis
>Guzman
>Sent: Wednesday, November 05, 2003 10:41 AM
>To: wra...@li...
>Subject: [Wrapper-user] Wrapper notification...
>
>
>Hi leif,
>
>I was looking into the wrapper.filter.action and was wondering how
>difficult it would be to implement an email notification option? My
>reason for asking, is that it would be easier to manage the set of
>wrapper configuration files than it is to manage each service properties
>to run a script. Which on a second note, does the wrapper.filter.action
>shutdown and restart options report to windows as a failure so then I
>could write a perl script that can send out this email notification
>using the service recovery option to run a file.
>
>Thanks.
>
>Luis
>
>_______________________________________________________
>This message is for the named recipient's use only. It may contain
>sensitive and private proprietary information. No confidentiality is
>waived or lost by any incorrect transmission. If you are not the
>intended recipient, please immediately delete it and all copies of it
>from your system, destroy any hard copies of it and notify the sender.
>You must not, directly or indirectly, use, disclose, distribute, print,
>or copy any part of this message if you are not the intended recipient.
>Sakonnet Technology, LLC and its subsidiaries reserve the right to
>monitor all e-mail communications through their networks. Any views
>expressed in this message are those of the individual sender, except
>where the message states otherwise and the sender is authorized to state
>them to be the views of any such entity. Unless otherwise stated, any
>pricing information given in this message is indicative only, is subject
>to change and does not constitute an offer to deal at any price quoted.
>Any reference to the terms of executed transactions should be treated as
>preliminary only and subject to our formal written confirmation.
>
>
>
>-------------------------------------------------------
>This SF.net email is sponsored by: SF.net Giveback Program. Does
>SourceForge.net help you be more productive? Does it
>help you create better code? SHARE THE LOVE, and help us help
>YOU! Click Here: http://sourceforge.net/donate/
>_______________________________________________
>Wrapper-user mailing list
>Wra...@li...
>https://lists.sourceforge.net/lists/listinfo/wrapper-user
>
>
>
>
>-------------------------------------------------------
>This SF.net email is sponsored by: SF.net Giveback Program. Does
>SourceForge.net help you be more productive? Does it
>help you create better code? SHARE THE LOVE, and help us help
>YOU! Click Here: http://sourceforge.net/donate/
>_______________________________________________
>Wrapper-user mailing list
>Wra...@li...
>https://lists.sourceforge.net/lists/listinfo/wrapper-user
>
>
>-------------------------------------------------------
>This SF.net email is sponsored by: SF.net Giveback Program.
>Does SourceForge.net help you be more productive? Does it
>help you create better code? SHARE THE LOVE, and help us help
>YOU! Click Here: http://sourceforge.net/donate/
>_______________________________________________
>Wrapper-user mailing list
>Wra...@li...
>https://lists.sourceforge.net/lists/listinfo/wrapper-user
>
>
>
>
>-------------------------------------------------------
>This SF.net email is sponsored by: SF.net Giveback Program.
>Does SourceForge.net help you be more productive? Does it
>help you create better code? SHARE THE LOVE, and help us help
>YOU! Click Here: http://sourceforge.net/donate/
>_______________________________________________
>Wrapper-user mailing list
>Wra...@li...
>https://lists.sourceforge.net/lists/listinfo/wrapper-user
>
>
>
|