Hi Eric , Thanks for your reply, I just want to run a system command upon getting New mail , Upon reading a mail , Upon Deleting a mail for a perticuler mailbox ID (IMAP mailbox) with details like destination user , UID or some custom headers information that is coming in that mail.
Basically I have a voicemail system. Upon getting any voicemail for User A system is sending that to A's mailbox account (Running at James). Now I need to send a SMS with UID to A's Mobile Number so that IMAP client at Mobile device can fetch that particular mail with UID from IMAP mail server (James). Rajesh Bansal, Project Manager Telemune Software Solutions Pvt. Ltd. M. No. +91-9871791327 www.telemune.net -----Original Message----- From: Eric Charles [mailto:e...@apache.org] Sent: Friday, November 23, 2012 5:15 PM To: James Users List Subject: Re: How to retrieve UID of a message during send message Hi Rajesh, Not sure to understant your requirements. I you want an imap client to be automatically notified that he has a mail, this is done by default with the IDLE IMAP extension. If you want to put in the inbox of a particular user a mail, this is possible with the ToRecipientFolder mailet (only in trunk source, not yet released). If you want to take custome action based on a mail, you can do it on 2 levels: - custom mailet (the easiest and recommended way) - MailboxListener - intrusive way in the source code - for examples, start from [1] Maybe you can tell us more on your goal so we can bring a better answer. Thx, Eric [1] https://svn.apache.org/repos/asf/james/mailbox/trunk/store/src/main/java/org/apache/james/mailbox/store/MailboxEventDispatcher.java MailboxEventDispatcher On 23/11/2012 10:38, Rajesh Bansal wrote: > Thanks Ioan, > > Can you provide me any code for adding MailboxListener in James. Its very > much urgent for me. Kindly help me. > > Rajesh Bansal, > Project Manager > Telemune Software Solutions Pvt. Ltd. > M. No. +91-9871791327 > www.telemune.net > > > -----Original Message----- > From: Ioan Eugen Stan [mailto:stan.ieu...@gmail.com] > Sent: Friday, November 23, 2012 4:02 PM > To: James Users List > Subject: Re: How to retrieve UID of a message during send message > > Hello Rajesh, > > I think the short answer is you can't. Bellow you can find my arguments. > > On Wikipedia [1] you can find a summary of what an UID is supposed to > be and do. > > In James, UID's are unique and unique per mailbox and are generated as > an increasing sequence. You can see the code that generates them in > [2],[3],[4]. > > They are generated whenever an operation is attempted on a mailbox > (new message, copy, etc) so you can't control the value that get's > assigned to it. If the operation fails the UID will be skipped so you > can have missing UIDs. > > Hope this helps, > > [1] http://en.wikipedia.org/wiki/Message-ID > [2] > https://github.com/apache/james-mailbox/blob/trunk/jpa/src/main/java/org/apache/james/mailbox/jpa/mail/JPAUidProvider.java > [3] > https://github.com/apache/james-mailbox/blob/trunk/memory/src/main/java/org/apache/james/mailbox/inmemory/mail/InMemoryUidProvider.java > [4] > https://github.com/apache/james-mailbox/blob/trunk/jcr/src/main/java/org/apache/james/mailbox/jcr/mail/JCRUidProvider.java > > On Thu, Nov 22, 2012 at 4:55 PM, Rajesh Bansal > <rajesh.ban...@telemune.net> wrote: >> Hi Eric, >> >> >> >> Is it possible thru any type of mailet configuration to send same message >> with same UID to another user. From which I can retrieve with POP access. >> >> >> >> Rajesh Bansal, >> >> Project Manager >> >> Telemune Software Solutions Pvt. Ltd. >> >> M. No. +91-9871791327 >> >> www.telemune.net >> >> >> >> From: Rajesh Bansal [mailto:rajesh.ban...@telemune.net] >> Sent: Thursday, November 22, 2012 8:20 PM >> To: 'Eric Charles'; 'server-user@james.apache.org' >> Subject: How to retrieve UID of a message during send message >> >> >> >> Hi Friends, >> >> >> >> I am sending a mail to a user (JAMES Server) by using SMTP. I want to >> retrieve UID of this mail from james so that I can provide to my IMAP client >> for fetching this particular UID message. >> >> >> >> Its very much urgent for me. Can you guys please help me in this regard. >> How I can make this happen. >> >> >> >> I am new to James and Java . So kindly help me with little more detail. I >> will really appreciate your help. >> >> >> >> Thanks in advance. >> >> >> >> Rajesh Bansal, >> >> Project Manager >> >> Telemune Software Solutions Pvt. Ltd. >> >> M. No. +91-9871791327 >> >> www.telemune.net >> >> >> > > > --------------------------------------------------------------------- To unsubscribe, e-mail: server-user-unsubscr...@james.apache.org For additional commands, e-mail: server-user-h...@james.apache.org