Ummm...don't you have commit access? :-)
I can commit it off the M2 tag that I built it on (since this is what I needed it for). Unless this was a branch (which would be pretty pointless anyways), it will break the current code.
I am not sure how properly test the listener with the current code base without installing and running a full on mail server, which I am not going to do. If you can direct me to some documentation (or just tell me and I'll doc it when done) on how to run a simple test to exercise the listener, I can do that.
it is a branch. don't think its useful though to commit to m2. I guess we'll have to wait until someone wants to develop it to completetion.
Create a patch against head and submit it. I can have a look at it.
I committed to HEAD. Class is org.jboss.mail.maillistener.ForwarderMailListener and it's interface.
The configuration entry to jboss-service.xml would look something like:
<!-- Custom listener for forwarding e-mails --> <mbean code="org.jboss.mail.maillistener.ForwarderMailListener" name="jboss.mail:type=MailServices,name=ForwarderListener"> <attribute name="Configuration"> <forwarding> <forward originalAddress="firstname.lastname@example.org">email@example.com</forward> <forward originalAddress="abc.org">firstname.lastname@example.org</forward> <forward originalAddress="webadmin">email@example.com</forward> </forwarding> </attribute> </mbean>
The value for the orginalAddress attribute can either be the user name, domain, or a the full e-mail address to match on. The value for the forward element has to be the full e-mail address of where to forward.