I just want Artemis instead of activemq or even without spooler (or in memory/direct) for fever and more minimal build. I even thinking about use dovecot as imap and connect with proxy/sasl to james as smtp server. I dont sure about how james stable with big data in database while dovecote is rock solid.

С уважением,
Руководитель ИТ
ООО «КПС-Технологии»
Терсков Илья Андреевич
Моб.: +7 (996) 415-16-29
E-mail:[email protected]

УВЕДОМЛЕНИЕ О КОНФИДЕНЦИАЛЬНОСТИ:
Это электронное сообщение и любые документы, приложенные к нему, содержат конфиденциальную информацию. Настоящим уведомляем Вас, что если это сообщение не предназначено Вам, использование, копирование и распространение информации, содержащейся в настоящем сообщении, а также осуществление любых действий на основе этой информации строго запрещено. Если Вы получили это сообщение по
ошибке, пожалуйста, сообщите об этом отправителю по электронной почте и
удалите данное сообщение.

CONFIDENTIALITY NOTICE:
This email and any files attached to it are confidential. If you are not the intended recipient, you are notified that using, copying, distributing, or taking any action in reliance on the contents of this information is strictly prohibited. If you have received this email in error, please notify the sender and delete this
message.


------ Исходное сообщение ------
От "Felix Auringer" <[email protected]>
Кому [email protected]
Дата 17.09.2026 13:47:53
Тема Re: Email Queues in James

Hey,

as far as I understood the data flows as following:

- SMTP between client and James
- As soon as client ends the DATA command, James runs its SMTP hooks, puts the 
email in its incoming queue (spool) and returns success to the client
- At this point, the client has received success but the email is not yet in 
the final persistent storage (e.g. database), only in the (persisted) spool
- James copies the email out of the spool and processes it with the 
mailetcontainer
- If the process is successful, the LocalDelivery Mailet puts the email in the 
final persistent storage (e.g. database) and removes the email from the spool

This is probably configurable but I think my description above is accurate for the 
"normal" configurations using the NoAuthCmdHandlerLoader or the 
CoreCmdHandlerLoader (see 
https://github.com/apache/james-project/blob/b3a6cae131a2b2cb3813ab2fe6877633caba674b/server/apps/postgres-app/sample-configuration/smtpserver.xml#L58).
Both are using the SendMailHandler which spools the email but does not persist 
it in the database.
I think there is an LMTP handler that directly stores an email to persistent 
storage but I do not think that this is a good idea for emails originating from 
the internet.

Best regards,
Felix

On 17/09/2026 06.02, Терсков Илья Андреевич wrote:
Hi everyone,
Since there is such a lively discussion going on, I wanted to jump in with a 
quick question related to the topic.
Doesn't the database itself handle data persistence? Is it possible to drop 
ActiveMQ, switch to the MemoryMailQueueModule (from memory-app), and rely on 
the database (like H2, for example) to guarantee persistence instead?
Thanks in advance for your insights!

С уважением,
Руководитель ИТ
ООО «КПС-Технологии»
Терсков Илья Андреевич
Моб.: +7 (996) 415-16-29
E-mail:[email protected]

УВЕДОМЛЕНИЕ О КОНФИДЕНЦИАЛЬНОСТИ:
Это электронное сообщение и любые документы, приложенные к нему, содержат
конфиденциальную информацию. Настоящим уведомляем Вас, что если это сообщение
не предназначено Вам, использование, копирование и распространение информации,
содержащейся в настоящем сообщении, а также осуществление любых действий на
основе этой информации строго запрещено. Если Вы получили это сообщение по
ошибке, пожалуйста, сообщите об этом отправителю по электронной почте и
удалите данное сообщение.

CONFIDENTIALITY NOTICE:
This email and any files attached to it are confidential. If you are not the
intended recipient, you are notified that using, copying, distributing, or 
taking
any action in reliance on the contents of this information is strictly 
prohibited.
If you have received this email in error, please notify the sender and delete 
this
message.


------ Исходное сообщение ------
От "Quan tran hong" <[email protected]>
Кому "James Users List" <[email protected]>
Дата 17.09.2026 9:59:35
Тема Re: Email Queues in James

Hi Felix,

 Do you know for which queues ActiveMQ and for which RabbitMQ is used?

Actually, it is weird to mix the use of both. It should usually be either
one of them. Can I know which James app you are using?

 Do I have to configure a dedicated RabbitMQ server for persistence?

I think you can still have persistence with ActiveMQ.

 My deployment currently uses an in-memory RabbitMQ which does not have
persistence, I guess.

The "in-memory RabbitMQ" term seems weird to me.

 Is there documentation anywhere on how to configure the queues for
persistence?

Just make sure your ActiveMQ/RabbitMQ data is persisted is ok.
e.g. for ActiveMQ: `var/store/activemq/` (Relative to James’s working
directory)
e.g. for RabbitMQ: `/var/lib/rabbitmq/`

Quan

On Wed, Sep 16, 2026 at 4:46 PM Felix Auringer <[email protected]>
wrote:

 Hi Quan,

 thanks for your reply!
 Good to know that I misunderstood the dequeuing in the code and it
 actually works like I would like.
 Do you know for which queues ActiveMQ and for which RabbitMQ is used?
 Do I have to configure a dedicated RabbitMQ server for persistence? My
 deployment currently uses an in-memory RabbitMQ which does not have
 persistence, I guess.
 Is there documentation anywhere on how to configure the queues for
 persistence?

 Best regards,
 Felix

 On 16/09/2026 11.30, Quan tran hong wrote:
 > Hi Felix,
 >
 >> If I understand the James code correctly (please correct me if I'm
 > wrong), the processors completely take emails out of the queue (meaning
 > they only exist in memory?) and reinsert them later if necessary.
 > This would mean that a crash / server restart while an email is processed
 > would mean that the email is lost with no possibility of informing the
 > client. Can I do something about that?
 >
 > Dequeueing does not permanently remove a mail from the mail queue (yet).
 > James keeps it unacknowledged while processing it and
 commits/acknowledges
 > it; failures cause rollback/nack and redelivery by RabbitMQ. A James
 > restart during processing, therefore, would not cause message loss.
 >
 >> Can I configure persistence for the email queues? I would like to have a
 > system which I can restart while emails are queued without them getting
 > lost.
 >
 > I think for RabbitMQ, James set those mail queues to be *durable*
 already.
 > You just need to make sure your RabbitMQ data path is persisted (in case
 > you use Docker).
 >
 > I hope it helps.
 >
 > Regards,
 > Quan
 >
 > On Wed, Sep 16, 2026 at 1:54 PM Felix Auringer <[email protected]
 >
 > wrote:
 >
 >> Hello together,
 >>
 >> I have some questions regarding the email queues in James.
 >>
 >> As far as I understand, there are two processes where an email queue is
 >> necessary, receiving email and sending email.
 >> In my head, the ideal process for these processes looks like this:
 >>
 >> - After the client has sent all commands, the email is put in a queue
 >> (spool / outgoing).
 >> - If and only if the queue operation succeeded, James tells the client
 >> that its email was received successfully.
 >> - The spooler/deliverer takes an email from the queue and processes it
 >> (mailetcontainer / remote delivery).
 >> - If and only if the email processing was successful (persisted in
 >> mailbox/accepted by remote server), the email is removed from the queue.
 >>
 >> If I understand the James code correctly (please correct me if I'm
 wrong),
 >> the processors completely take emails out of the queue (meaning they
 only
 >> exist in memory?) and reinsert them later if necessary.
 >> This would mean that a crash / server restart while an email is
 processed
 >> would mean that the email is lost with no possibility of informing the
 >> client. Can I do something about that?
 >>
 >> According to the docs (and logs during startup), James uses two
 different
 >> message queues:
 >>
 >> - ActiveMQ (https://james.apache.org/server/config-activemq.html):
 >> Manages at least the queues 'spool' and 'outgoing' according to the
 docs.
 >> According to my logs, it uses KahaDB as persistence adapter.
 >> - RabbitMQ (https://james.apache.org/server/config-rabbitmq.html): Used
 >> for distributed MailQueue and distributed event system according to the
 >> docs. It is also running in my single node deployment (as in-memory
 version
 >> because I did not configure anything).
 >>
 >> Which of them is used for the processes described above?
 >> Can I configure persistence for the email queues? I would like to have a
 >> system which I can restart while emails are queued without them getting
 >> lost.
 >>
 >> Best regards,
 >> Felix
 >> ---
 >> Gesellschaft für interkulturelles
 >> Zusammenleben gGmbH (GIZ)
 >> Felix Auringer
 >> IT
 >> Reformationsplatz 2
 >> 13597 Berlin
 >>
 >> Tel: 030/513 0100 00; Fax: 030/513 0100 09
 >> www.giz.berlin;[email protected]
 >>
 >> Amtsgericht Charlottenburg HRB 200872 B
 >> Geschäftsführerin: Dr. Britta Marschke
 >>
 >> ---------------------------------------------------------------------
 >> To unsubscribe, e-mail: [email protected]
 >> For additional commands, e-mail: [email protected]
 >>
 >>
 >

 ---
 Gesellschaft für interkulturelles
 Zusammenleben gGmbH (GIZ)
 Felix Auringer
 IT
 Reformationsplatz 2
 13597 Berlin

 Tel: 030/513 0100 00; Fax: 030/513 0100 09
www.giz.berlin;[email protected]

 Amtsgericht Charlottenburg HRB 200872 B
 Geschäftsführerin: Dr. Britta Marschke

 ---------------------------------------------------------------------
 To unsubscribe, e-mail: [email protected]
 For additional commands, e-mail: [email protected]




---
Gesellschaft für interkulturelles
Zusammenleben gGmbH (GIZ)
Felix Auringer
IT
Reformationsplatz 2
13597 Berlin

Tel: 030/513 0100 00; Fax: 030/513 0100 09 
www.giz.berlin;[email protected]

Amtsgericht Charlottenburg HRB 200872 B
Geschäftsführerin: Dr. Britta Marschke

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to