Rodney Rindels wrote:
Hello Fellow POE Lovers.

I had a project dropped on my desk, after extensively reading the requirements and reading the POE discussion groups and documentation, I'm convinced I finally have a POE worthy project.

But. Since I Noticed Rocco mentions more than once the fact that some things are better left to cron.. I Thought I would get the more experience POE users opinion on this one.


Sounds like a project for POE to me, certainly beyond cron's abilities, sure you could do it that way but it would be a nightmare.


Basically I need to build an Event Based, Web Attached (for Management), FTP, SFTP,WWW::Mechanize, Expect, and Serial Device Controlled framework.


wowzers, you forgot the kitchen sink. Make sure to use CPAN to its fullest with the above list, pretty sure everything is covered.


A few features of the requirements are ability to start, stop, and restart from web console, as well as pull statistics and dynamic reconfiguration.

Centralized logging to x,y, or z (Ie. Could be syslog, could be flat , could be database).


Definitely check out Log4perl, http://log4perl.sf.net , it should help you accomplish the above in a very very nice way with minimal coding by you. I have used POE with Log4perl before and it was a dream.


Persistant Database Connections

And the ability to connect and transfer files to x number of system types based off either custom scripts or Centralized with Configuration files driving the changing pieces.


I hate to say it but with all your various systems, protocols, etc. I would start from scratch with an XML based config system. I don't throw out XML lightly as I think it is overkill for a lot of things, but with all the different setups you are talking about it can be very effective. XML::Simple should do nicely.


I started down the road of building at least (what I think) could be a core to keep the daemon running properly where I build _start event which kicks off kernel delay to call _start again every so often.

Thoughts, Suggestions, Therapy?


The only thing I would say specifically about POE, and I have said it before, is use the object wrapped sessions. The regular subroutine based sessions are nice for simple and small projects, or examples like those in the cookbook. But using the object based ones have made life so much easier for me in the past. No need to meddle in the HEAP and passing a bunch of values around. It allows you to restrict the events to things that should normally be firing events, and lets everything else that would normally just be a method call to an object remain as such, don't use a bunch of event calls just to pass values/objects around, etc. Just my $.02.


Rodney



Good luck.

http://danconia.org

Reply via email to