That seems like a lot of work.
A simpler thing to do is factor this:
Message msg = mail;
while (mailListeners.hasNext() && msg != null) {
MailListener lsner = (MailListener) mailListeners.next();
jblog.info("sending mail to MailListener: " + lsner);
msg = lsner.send(msg);
}
into its own MBean. You use *that* to pick.
Now for the single mode its obvious that it will be bound to a particular
mailbox. Meaning you'll need to manipulate the mail headers and change the
"to" and make it a local account (whatever the fetchmail is configured to).
For the unbound you'll need a multitude of users->Box configuration. I suggest
a mail listener for that! Then the rules for configuring remote-fetchmail and
local-user can be factored out.
View the original post :
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3870887#3870887
Reply to the post :
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3870887
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
JBoss-Development mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-development