james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Luc Saulière <luc.sauli...@gmail.com>
Subject Re: DB Access with james3
Date Wed, 02 Feb 2011 01:27:38 GMT
Hello,
I've just read this message and I think it's pretty much that want to do
with my application.
To use a James instance of MailboxManager in my custom app...
Could-you tell me more about this solution? How could I inject an instance
of a class in another app?
threw the jvm?

thx
Luc.

2011/1/19 Norman Maurer <norman@apache.org>

> Sure there is.. But to be honest I would not do this as you will
> always need to look out for db changes etc. So I think the prefered
> way would be to inject an instance of MailboxManager in your custom
> app and store the mails via it. Or is this not possible ?
>
> Bye,
> Norman
>
>
> 2011/1/19 Luc Saulière <luc.sauliere@gmail.com>:
> > Hello,
> > I'm developing with Math on the same mail app. We didn't succeed in
> storing
> > mail as james3 does. In fact the SieveMailet class does not have a
> > setUsersRepo method, I think you're dealing with a newer version of
> > James3...
> > We are developing with the M2 one and SieveMailet have a setMailserver
> > method instead.
> > So, is there any way to store a mail (from another IMAP connection for
> > instance) in the James3 mySQL db, as James3 does (i.e. filling correctly
> all
> > the appropriate tables...)?
> >
> > Thx for helping.
> > Luc.
> >
> > 2011/1/17 Eric Charles <eric@apache.org>
> >
> >> Hi,
> >> The mails store magic occurs in LocalDelivery where the MailboxManager
> is
> >> injected.
> >> (more precise, LocalDelivery uses the SieveMailet initialized with the
> >> MailboxManager)
> >>        sieveMailet.setUsersRepository(usersRepository);
> >>        sieveMailet.setMailboxManager(mailboxManager);
> >>        sieveMailet.init(m);
> >>        sieveMailet.setQuiet(true);
> >> ...
> >>        if (mail.getState() != Mail.GHOST) {
> >>            sieveMailet.service(mail);
> >>        }
> >>
> >> You only need to know that *MailRepository is not for users' mail
> storage
> >> http://james.apache.org/server/3/feature-persistence.html
> >>
> >> Both topics (mailet usage for delivery + separate mail stores) are
> subject
> >> to discussion will certainly change.
> >>
> >> Tks,
> >>
> >> Eric
> >>
> >>
> >>
> >> On 17/01/2011 11:43, math math wrote:
> >>
> >>> Hello everybody,
> >>>
> >>> I am developping a web mail project using james 3M2. I'm trying to
> store
> >>> mails in a "james3" way with an external application using MySql DB.
> I've
> >>> tried to store mails using mysq database repositories for a few days
> now
> >>> but
> >>> i didn't succeed to do so... I 've traced the store method of
> >>> JDBCMailRepository class and also the ToRepository one. But still don't
> >>> know
> >>> how James 3 is storing mails in the DB.
> >>>
> >>> I would be very glad if someone could help me in this task.
> >>>
> >>> Thanks,
> >>> Mat
> >>>
> >>>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
> >> For additional commands, e-mail: server-dev-help@james.apache.org
> >>
> >>
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
> For additional commands, e-mail: server-dev-help@james.apache.org
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message