Federico Barbieri wrote:
> It doesn't seems very ugly to me... anyway I agree with you: MimeMessage
> reply() sucks and so I'd like to see a reply() method in the Mail object
> being a bit more juicy.
> +1

Ok, that's low priority for me at the moment, but I'll think about
that.  I guess the working example is at least a good start for others.

> I knew of this limitation but I was thinking to a more generic
> "repository" model.
> you define as many repositoryes as you wish:
> <repositroy name="system"> org.apache.james.servlets</repository>
> <repositroy name="myservlets"> com.mycompany.mypackage</repository>
> ....
> 
> and then access them like:
> <servlet match="All" class="system.ToRepository">
> <servlet match="All" class="myservlets.MyServlet">
> ....
> 
> Right now an ugly turn around is to set rootpath="" and call servlets
> like:
> <servlet match="All" class="com.mycompany.mypackage.MyServlet">
> 
> I agree that's sound really dirt so...

I actually went ahead and put in the suggestion Jon had.  Right before
the servlets tag, I put in servletpackages, and then enumerate a bunch
of servletpackage tags.  Then I removed rootpath in servlets and instead
have it loop through the possible packages, trying to load the class
that way.  While I can see the benefits of the repository approach
above, I don't like the idea of class="<repositoryname>.<classname>" as
the repository name looks like a poorly named package.  If you did want
this approach, I would prefer repository="<repositoryname"
class="<classname>".  Nevertheless, I prefer Jon's method as you can
order the packages to determine which one to find in the rare case there
is a name conflict.  And if that still can't help you, you can also
explicitly put the whole class name.

> There are many and many situations where a loop can be generated:
> let's say I'm going to holydays ans a set my "ImOnVacation" servlet to
> reply any message saying I'll be back next week. Just before leaving I
> send a message to a friend which is going on holydays too and has set up
> the same servlet. The message will continue bouncing from my servlet to
> his...

True... I know there's a way to put in a maximum number of SMTP relay
hoops (doh... that's another servlet I guess I have to write), but I'm
not to prevent these auto-responder redlines.  I'll think about it as
well.

As long as I'm writing, there's a few other things that need to get
fixed in JAMES.  First is it's not explictly putting in Return-Path: and
Received: headers, which proper SMTP mail servers should.  Even if
you're a relaying server, you should put in the Received header, and the
Return-Path is just good practice I've seen most mail servers do to help
prevent spam.  I'm working on this now, tryign to get MailHeaders to
support adding this as well as keeping the mail headers "ordering" that
InternetAddress has if you construct it normally, but loses if you
construct it from an InputStream (strange implementation bug, IMHO, but
I can see the logic of why this is).

The other thing is that JAMES is unfortunately adding extra dots to
emails!!!  Not sure if this is from the latest patch to
CharTerminatedInputStream (?), or maybe the latest avalon just isn't in
the James tree.  In any case, it's somewhat annoying and I can't put it
into beta use until that's fixed.

Glad to see I'm not the only one working late on Sunday night.  Hope
everyone had a Happy Easter!

Serge


------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Archives and Other:  <http://java.apache.org/>
Problems?:           [EMAIL PROTECTED]

Reply via email to