linagora/james-project

AmqpForwardAttribute mailet support declare exchange type

vttranlina opened this issue · 12 comments

Right now it using direct by default
We can provide the configurable for it by init parameter exchange_type

exchangeType to match syntax

We should make it optional default to direct to prevent bracking change

All places in LNG environment should BTW specify it as fanout for OpenPaaS exchanges:

  • imap.linagora.com
  • CNB prod + preprod
  • MU

@chibenwa How about if we check if the exchange exists (created manually before); if it does, we won't need to recreate it, even if the exchange type doesn't match?

@chibenwa How about if we check if the exchange exists (created manually before); if it does, we won't need to recreate it, even if the exchange type doesn't match?

What's the driver API for this?

Problem is we can only declare.

In case of type mismatch the whole connection shutdowns...

At least from what I remember...

reactor.rabbitmq have not api for it,
I'm thinking to com.rabbitmq.client or handle exception
But it looks complex
hmm, ignore it, let's keep it simple.

When trying upgrade to MU
I got an another error:

(reply-code=406, reply-text=PRECONDITION_FAILED - inequivalent arg 'durable' for exchange 'james:events' in vhost '/': received 'false' but current is 'true'

If now we have a one more mailet parameter, It may cause another error related to another argument.

Can we close this then now?

Can we close this then now?

With commit ignore errors when creating an exchange that already exists with a different configuration, then we don't need change anything in mailetcontainer.xml in prod env.

+1, close