Are you really sure its not logged in the mailet log ? Or is a exception
thrown ? Check spool log.
bye
Am Mittwoch, den 15.03.2006, 16:26 +0100 schrieb Audun V. Nes:
> I am having a bit of problems with the Apache James Mailet API. To
> illustrate the problem I have written a small Hello World mailet:
>
> package org.apache.james.transport.mailets;
>
> import javax.mail.MessagingException;
> import org.apache.mailet.GenericMailet;
> import org.apache.mailet.Mail;
>
> public class HelloWorld extends GenericMailet {
>
> public void service(Mail mail) throws MessagingException {
> log ("HelloWorld's service(Mail)");
> }
>
> public String getMailetInfo() {
> return "HelloWorld Mailet";
> }
> }
>
> This was compiled and put in a jar file called SMSGatewayMailet.jar
> which I put in James's lib directory together with mailet_1_0.jar,
> mail-1.3.1.jar and james.jar (the three libs which was extracted from
> james.sar as suggested by the James documentation).
>
>
> Within the <processor name="root"> context of config.xml I have added
> the following:
>
> <mailet match="All" class="HelloWorld"/>
>
> I disabled POP3 and NNTP and then started James, and started sending
> emails throughit's SMTP interface. When I look at the James' logfiles I
> can see thatthe HelloWorld mailet was successfully instanciated, but the
> line "HelloWorld's service(Mail)" is never written to any of the James'
> logfiles,which must mean that the HelloWorld's service method is never
> executed.
>
> So maybe I have registered is incorrectly in config.xml ? Frankly I
> don't think so as I used the Null mailet as example.
>
> I have spent roughly 6 hours now reading the docs and looking at the
> source samples, but have still not be able to get the service(Mail)
> method to work...
>
> Any good ideas on how I can get my HelloWorld mailet to work ?
>
> best regards
> Audun
>
> !EXCUBATOR:2,441831613272737920526!
> --------------------------------------------------------------------- To
> unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail:
> [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]