james-project.git
18 months ago[maven-release-plugin] prepare for next development iteration
Benoit Tellier [Mon, 22 Mar 2021 04:47:07 +0000 (11:47 +0700)] 
[maven-release-plugin] prepare for next development iteration

18 months ago[maven-release-plugin] prepare release james-project-3.6.0
Benoit Tellier [Mon, 22 Mar 2021 04:27:45 +0000 (11:27 +0700)] 
[maven-release-plugin] prepare release james-project-3.6.0

18 months agoRevert "[maven-release-plugin] prepare release james-project-3.6.0"
Benoit Tellier [Fri, 19 Mar 2021 11:21:48 +0000 (18:21 +0700)] 
Revert "[maven-release-plugin] prepare release james-project-3.6.0"

This reverts commit 7ceb0d527b250c6740eb30983b312a7be6266eb6.

18 months agoRevert "[maven-release-plugin] prepare for next development iteration"
Benoit Tellier [Fri, 19 Mar 2021 11:21:45 +0000 (18:21 +0700)] 
Revert "[maven-release-plugin] prepare for next development iteration"

This reverts commit b3ea0e9e29cc19e53ca25780b245fcc613f8572d.

18 months ago[maven-release-plugin] prepare for next development iteration
Benoit Tellier [Fri, 19 Mar 2021 08:41:44 +0000 (15:41 +0700)] 
[maven-release-plugin] prepare for next development iteration

18 months ago[maven-release-plugin] prepare release james-project-3.6.0
Benoit Tellier [Fri, 19 Mar 2021 08:39:42 +0000 (15:39 +0700)] 
[maven-release-plugin] prepare release james-project-3.6.0

18 months ago[RELEASE] Documentation should mention 3.6.0
Benoit Tellier [Tue, 16 Mar 2021 09:05:52 +0000 (16:05 +0700)] 
[RELEASE] Documentation should mention 3.6.0

18 months ago[RELEASE] Homepage post for 3.6.0
Benoit Tellier [Tue, 16 Mar 2021 07:46:30 +0000 (14:46 +0700)] 
[RELEASE] Homepage post for 3.6.0

18 months ago[RELEASE] Freeze 3.6.0 CHANGELOG.md and upgrade-instructions.md
Benoit Tellier [Tue, 16 Mar 2021 07:36:47 +0000 (14:36 +0700)] 
[RELEASE] Freeze 3.6.0 CHANGELOG.md and upgrade-instructions.md

18 months ago[RELEASE] Add missing changelog entries
Benoit Tellier [Tue, 16 Mar 2021 07:34:28 +0000 (14:34 +0700)] 
[RELEASE] Add missing changelog entries

18 months agoJAMES-3316 Modularize JMAP routes and authentication mechanism 334/head
Benoit Tellier [Wed, 17 Mar 2021 07:26:01 +0000 (14:26 +0700)] 
JAMES-3316 Modularize JMAP routes and authentication mechanism

This allow third party to reuse the existing Guice modules while adding
their own extra routes and authentication mechanism.

18 months agoJAMES-3506 Avoid a full body read within VacationMailet
Benoit Tellier [Thu, 11 Mar 2021 02:12:17 +0000 (09:12 +0700)] 
JAMES-3506 Avoid a full body read within VacationMailet

In order to see if a part have the message/disposition-notification content type
a full parsing of the message is required.

MDNs falls in the category of automatically
generated reports described in RFC-1892

The Multipart/Report Content Type for the Reporting of Mail System Administrative Messages

The Multipart/Report MIME content-type is a general "family" or
   "container" type for electronic mail reports of any kind.

So:

 - Not only we are more generic
 - But also we save a full message read and parsing

18 months agoJAMES-3499 Fix LDAP related dockerfiles
Benoit Tellier [Fri, 12 Mar 2021 10:42:28 +0000 (17:42 +0700)] 
JAMES-3499 Fix LDAP related dockerfiles

18 months agoJAMES-3499 Clean dependencies: webadmin-mailbox
Benoit Tellier [Fri, 12 Mar 2021 04:48:51 +0000 (11:48 +0700)] 
JAMES-3499 Clean dependencies: webadmin-mailbox

18 months agoJAMES-3499 Distributed guice module should not depend on activemq
Benoit Tellier [Fri, 12 Mar 2021 03:40:12 +0000 (10:40 +0700)] 
JAMES-3499 Distributed guice module should not depend on activemq

18 months agoJAMES-3492, add note about need of separate Elasticsearch 6 instance for reporting...
andreasvaldma [Fri, 12 Mar 2021 08:30:39 +0000 (10:30 +0200)] 
JAMES-3492, add note about need of separate Elasticsearch 6 instance for reporting metrics to Elasticsearch

18 months agoJAMES-3492, upgrade documentation
andreasvaldma [Fri, 12 Mar 2021 08:19:27 +0000 (10:19 +0200)] 
JAMES-3492, upgrade documentation

18 months agoJAMES-3492, add upgrade instructions
andreasvaldma [Fri, 12 Mar 2021 06:41:39 +0000 (08:41 +0200)] 
JAMES-3492, add upgrade instructions

18 months agoJAMES-3492, add upgrade instructions
andreasvaldma [Thu, 11 Mar 2021 13:33:30 +0000 (15:33 +0200)] 
JAMES-3492, add upgrade instructions

18 months agoJAMES-3492, pass JamesWithNonCompatibleElasticSearchServerTest
andreasvaldma [Thu, 11 Mar 2021 11:17:33 +0000 (13:17 +0200)] 
JAMES-3492, pass JamesWithNonCompatibleElasticSearchServerTest

18 months agoJAMES-3502, fix indent in tests
andreasvaldma [Thu, 11 Mar 2021 08:53:46 +0000 (10:53 +0200)] 
JAMES-3502, fix indent in tests

18 months agoJAMES-3502, remove elastic six modules
andreasvaldma [Thu, 11 Mar 2021 08:25:18 +0000 (10:25 +0200)] 
JAMES-3502, remove elastic six modules

18 months agoJAMES-3502, was using old elastic module
andreasvaldma [Thu, 11 Mar 2021 08:24:49 +0000 (10:24 +0200)] 
JAMES-3502, was using old elastic module

18 months agoJAMES-3492, remove mistakingly added dependency
andreasvaldma [Thu, 11 Mar 2021 06:52:59 +0000 (08:52 +0200)] 
JAMES-3492, remove mistakingly added dependency

18 months agoJAMES-3492, applied sortpom:sort
andreasvaldma [Wed, 10 Mar 2021 18:40:14 +0000 (20:40 +0200)] 
JAMES-3492, applied sortpom:sort

18 months agoJAMES-3492, fix tests, wait for elasticsearch flushes to complete for test assertions
andreasvaldma [Wed, 10 Mar 2021 18:03:55 +0000 (20:03 +0200)] 
JAMES-3492, fix tests, wait for elasticsearch flushes to complete for test assertions

18 months agoJAMES-3492, change ElasticSearchStartUpCheck.java to use v7
andreasvaldma [Wed, 10 Mar 2021 18:02:22 +0000 (20:02 +0200)] 
JAMES-3492, change ElasticSearchStartUpCheck.java to use v7

18 months agoJAMES-3492, disable failing tests
andreasvaldma [Wed, 10 Mar 2021 18:00:31 +0000 (20:00 +0200)] 
JAMES-3492, disable failing tests

18 months agoJAMES-3492, switch to elasticsearch 7 in poms
andreasvaldma [Wed, 10 Mar 2021 17:58:09 +0000 (19:58 +0200)] 
JAMES-3492, switch to elasticsearch 7 in poms

18 months agoJAMES-3492 Remove NodeMappingFactory & tests
LanKhuat [Mon, 8 Mar 2021 04:17:54 +0000 (11:17 +0700)] 
JAMES-3492 Remove NodeMappingFactory & tests

18 months agoJAMES-3492 Use assertion with Awaitility in QuotaSearcherContract
LanKhuat [Thu, 4 Mar 2021 07:40:59 +0000 (14:40 +0700)] 
JAMES-3492 Use assertion with Awaitility in QuotaSearcherContract

18 months agoJAMES-3492 Adapt ElasticSearchQuotaMailboxListenerTest
LanKhuat [Thu, 4 Mar 2021 07:30:53 +0000 (14:30 +0700)] 
JAMES-3492 Adapt ElasticSearchQuotaMailboxListenerTest

18 months agoJAMES-3492 Add missing dependency
LanKhuat [Thu, 4 Mar 2021 07:29:36 +0000 (14:29 +0700)] 
JAMES-3492 Add missing dependency

18 months agoJAMES-3492 Check Mapping existence by GetMappingsAPI
LanKhuat [Wed, 3 Mar 2021 09:27:55 +0000 (16:27 +0700)] 
JAMES-3492 Check Mapping existence by GetMappingsAPI

18 months agoJAMES-3492 Mapping should be created at the same time as index
LanKhuat [Wed, 3 Mar 2021 08:47:38 +0000 (15:47 +0700)] 
JAMES-3492 Mapping should be created at the same time as index

18 months agoJAMES-3492 Adapt ElasticSearchSearcherTest
LanKhuat [Wed, 3 Mar 2021 08:07:38 +0000 (15:07 +0700)] 
JAMES-3492 Adapt ElasticSearchSearcherTest

18 months agoJAMES-3492 Adapt other implementations of AbstractMessageSearchIndexTest
LanKhuat [Wed, 3 Mar 2021 07:58:20 +0000 (14:58 +0700)] 
JAMES-3492 Adapt other implementations of AbstractMessageSearchIndexTest

18 months agoJAMES-3492 Search no longer need to fetch individual fields
LanKhuat [Wed, 3 Mar 2021 07:53:59 +0000 (14:53 +0700)] 
JAMES-3492 Search no longer need to fetch individual fields

The fields are stored within the document and can be fetched with storedFields option.

18 months agoJAMES-3492 Migrate to Java time date format
LanKhuat [Thu, 4 Mar 2021 08:19:30 +0000 (15:19 +0700)] 
JAMES-3492 Migrate to Java time date format

18 months agoJAMES-3492 Remove mapping check
Lan Khuat [Tue, 2 Mar 2021 15:19:03 +0000 (22:19 +0700)] 
JAMES-3492 Remove mapping check

The check returns status 200 in ElasticSearch 7, preventing the usage of James custom mapping when creating index.

18 months agoJAMES-3492 Replace deprecated CreateIndexRequest
Lan Khuat [Tue, 2 Mar 2021 15:12:27 +0000 (22:12 +0700)] 
JAMES-3492 Replace deprecated CreateIndexRequest

18 months agoJAMES-3492 Adapt ElasticSearchIntegrationTest
Lan Khuat [Tue, 2 Mar 2021 09:28:58 +0000 (16:28 +0700)] 
JAMES-3492 Adapt ElasticSearchIntegrationTest

18 months agoJAMES-3492, switch to elasticsearch 7 in guice modules
andreasvaldma [Tue, 9 Mar 2021 06:37:11 +0000 (08:37 +0200)] 
JAMES-3492, switch to elasticsearch 7 in guice modules

18 months agoMAILBOX-405 Document SubscribeAll task
Benoit Tellier [Mon, 8 Mar 2021 08:22:39 +0000 (15:22 +0700)] 
MAILBOX-405 Document SubscribeAll task

18 months agoMAILBOX-405 Expose SubscribeAll task over webAdmin
Benoit Tellier [Mon, 8 Mar 2021 08:18:06 +0000 (15:18 +0700)] 
MAILBOX-405 Expose SubscribeAll task over webAdmin

18 months agoMAILBOX-405 Task to subscribe all mailboxes belonging to a user
Benoit Tellier [Mon, 8 Mar 2021 07:42:18 +0000 (14:42 +0700)] 
MAILBOX-405 Task to subscribe all mailboxes belonging to a user

18 months agoJAMES-3513 Wrong UID dispatched on the EventBus for StoreMessageIdManager::setInMailboxes
Benoit Tellier [Mon, 8 Mar 2021 06:40:51 +0000 (13:40 +0700)] 
JAMES-3513 Wrong UID dispatched on the EventBus for StoreMessageIdManager::setInMailboxes

```
Given msg1 in mbx1 with uid 12 and in mbx2 with uid 58
When I set it in mbx3
Then two deletion events are dispatched, one in mbx1 with uid 12 ok, one in mbx2 and uid 12.
```

18 months agoJAMES-3512 Add a hashingMode option is usersreposiotry.xml
Benoit Tellier [Mon, 8 Mar 2021 04:35:36 +0000 (11:35 +0700)] 
JAMES-3512 Add a hashingMode option is usersreposiotry.xml

18 months agoJAMES-3512 Algorithm::rawValue => Algorithm::asString
Benoit Tellier [Fri, 5 Mar 2021 09:14:36 +0000 (16:14 +0700)] 
JAMES-3512 Algorithm::rawValue => Algorithm::asString

18 months agoJAMES-3512 Document upgrade-instructions.md
Benoit Tellier [Fri, 5 Mar 2021 04:36:57 +0000 (11:36 +0700)] 
JAMES-3512 Document upgrade-instructions.md

18 months agoJAMES-3512 DigestUtil: close base64 encoding stream
Benoit Tellier [Fri, 5 Mar 2021 04:28:44 +0000 (11:28 +0700)] 
JAMES-3512 DigestUtil: close base64 encoding stream

Allow a '-legacy' suffix to the has algorithm to avoid
a breaking change forcing people to reset their password.

18 months agoJAMES-3512 DigestUtil: test existing behaviour
Benoit Tellier [Fri, 5 Mar 2021 04:19:45 +0000 (11:19 +0700)] 
JAMES-3512 DigestUtil: test existing behaviour

18 months agoJAMES-3512 DigestUtil: use standard charset
Benoit Tellier [Fri, 5 Mar 2021 04:03:19 +0000 (11:03 +0700)] 
JAMES-3512 DigestUtil: use standard charset

18 months agoJAMES-3512 Strong typing for algorithm
Benoit Tellier [Fri, 5 Mar 2021 03:59:42 +0000 (10:59 +0700)] 
JAMES-3512 Strong typing for algorithm

18 months agoJAMES-3487 Allow setting on*Exception parameters for Bounce
Benoit Tellier [Tue, 9 Mar 2021 04:57:29 +0000 (11:57 +0700)] 
JAMES-3487 Allow setting on*Exception parameters for Bounce

These were rejected, disabling fine grain error customisation for the end user on those mailets.

18 months agoJAMES-3487 Ignore errors in error processor by default
Benoit Tellier [Tue, 9 Mar 2021 04:54:12 +0000 (11:54 +0700)] 
JAMES-3487 Ignore errors in error processor by default

If (for instance) Bounce throws an exception, we enter an infinite loop as the ERROR processor
itself is handling the error.

(Camel route stopping bug allowed to spot the issue)

18 months agoJAMES-3487 Stop using Exchange.ROUTE_STOP
Benoit Tellier [Tue, 9 Mar 2021 04:44:10 +0000 (11:44 +0700)] 
JAMES-3487 Stop using Exchange.ROUTE_STOP

See https://github.com/apache/camel/commit/7a58163400bf15ba7959f567aa67dc584316dcb6

18 months agoJAMES-3497 Upgrade camel to latest version
Benoit Tellier [Thu, 4 Mar 2021 08:43:10 +0000 (15:43 +0700)] 
JAMES-3497 Upgrade camel to latest version

18 months agoJAMES-3511 Solve java.util.NoSuchElementException: heartbeatHandler
Benoit Tellier [Thu, 4 Mar 2021 09:49:19 +0000 (16:49 +0700)] 
JAMES-3511 Solve java.util.NoSuchElementException: heartbeatHandler

We encountered the following error:

```
t stacktrace
java.util.NoSuchElementException: heartbeatHandler
at org.jboss.netty.channel.DefaultChannelPipeline.getContextOrDie(DefaultChannelPipeline.java:684)
at org.jboss.netty.channel.DefaultChannelPipeline.remove(DefaultChannelPipeline.java:153)
at org.apache.james.imapserver.netty.ImapChannelUpstreamHandler.messageReceived(ImapChannelUpstreamHandler.java:215)
at org.jboss.netty.channel.SimpleChannelUpstreamHandler.handleUpstream(SimpleChannelUpstreamHandler.java:70)
at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:564)
at org.jboss.netty.channel.DefaultChannelPipeline$DefaultChannelHandlerContext.sendUpstream(DefaultChannelPipeline.java:791)
at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:296)
at org.jboss.netty.handler.codec.frame.FrameDecoder.unfoldAndFireMessageReceived(FrameDecoder.java:462)
at org.jboss.netty.handler.codec.frame.FrameDecoder.callDecode(FrameDecoder.java:443)
at org.jboss.netty.handler.codec.frame.FrameDecoder.messageReceived(FrameDecoder.java:303)
at org.jboss.netty.channel.SimpleChannelUpstreamHandler.handleUpstream(SimpleChannelUpstreamHandler.java:70)
at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:564)
at org.jboss.netty.channel.DefaultChannelPipeline$DefaultChannelHandlerContext.sendUpstream(DefaultChannelPipeline.java:791)
at org.jboss.netty.handler.execution.ChannelUpstreamEventRunnable.doRun(ChannelUpstreamEventRunnable.java:43)
at org.jboss.netty.handler.execution.ChannelEventRunnable.run(ChannelEventRunnable.java:67)
at org.jboss.netty.handler.execution.OrderedMemoryAwareThreadPoolExecutor$ChildExecutor.run(OrderedMemoryAwareThreadPoolExecutor.java:314)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.base/java.lang.Thread.run(Unknown Source)
```

I believe a concurrency issue causes the handler to be removed twice.

We should be idempotent here: the end result is that the heartbeat handler is no longer here, hence we should not fail.

Similarly, if the heartbeat handler is concurrently set, we end up putting it anyway, resulting in an IllegalArgument exception.

The heartbeat handler sends a heartbeat every 30s which is far less than the IMAP command execution timing. If in some corner case we miss it, this is not missin critical to me: it's management should not result in connection closure.

I tried to reproduce, as well as Gauthier Di Folco months ago, without success. I'd like to add defensive try/catchs to handle these failures.

18 months agoJAMES-3511 [Refactoring] ImapChannelUpstreamHandler s/e/event/
Benoit Tellier [Thu, 4 Mar 2021 09:25:56 +0000 (16:25 +0700)] 
JAMES-3511 [Refactoring] ImapChannelUpstreamHandler s/e/event/

18 months agoMAILBOX-405 Ensure renaming many mailboxes works for all product
Benoit Tellier [Thu, 4 Mar 2021 02:13:55 +0000 (09:13 +0700)] 
MAILBOX-405 Ensure renaming many mailboxes works for all product

Add a test at the JMAP level. This was failing before MAILBOX-405
fixes for the distributed server.

18 months agoMAILBOX-405 Dispatch renamed mailboxes once they are all renamed
Benoit Tellier [Wed, 3 Mar 2021 11:54:30 +0000 (18:54 +0700)] 
MAILBOX-405 Dispatch renamed mailboxes once they are all renamed

A child might be created before its parent in complex hierarchy,
causing Propagate lookup right listener to originally fail
(as the parent might not exist yet) until the eventBus retries
eventually catch that up, causing read amplification.

An alternative might be to order the names to be renamed upfront.

18 months agoMAILBOX-405 Decrease rename concurrency
Benoit Tellier [Wed, 3 Mar 2021 04:14:42 +0000 (11:14 +0700)] 
MAILBOX-405 Decrease rename concurrency

18 months agoMAILBOX-405 Add a retry upon rename
Benoit Tellier [Wed, 3 Mar 2021 04:05:11 +0000 (11:05 +0700)] 
MAILBOX-405 Add a retry upon rename

Cassandra do not leverage transactionnality, hence we should try
to minimize half performed operations. Retries is a way to achieve
this and could be seen as a short term mitigation.

18 months agoJAMES-3508 IMAPServerTest: Ensure Appended messages can be read
Benoit Tellier [Wed, 3 Mar 2021 08:59:30 +0000 (15:59 +0700)] 
JAMES-3508 IMAPServerTest: Ensure Appended messages can be read

18 months agoJAMES-3508 Append should not perform an extra data copy
Benoit Tellier [Wed, 3 Mar 2021 07:55:42 +0000 (14:55 +0700)] 
JAMES-3508 Append should not perform an extra data copy

18 months agoJAMES-3508 ImapRequestLineReader should allow to read a literal
Benoit Tellier [Wed, 3 Mar 2021 07:44:57 +0000 (14:44 +0700)] 
JAMES-3508 ImapRequestLineReader should allow to read a literal

18 months agoJAMES-3508 AppendRequest should hold a literal
Benoit Tellier [Wed, 3 Mar 2021 07:29:25 +0000 (14:29 +0700)] 
JAMES-3508 AppendRequest should hold a literal

18 months agoJAMES-3508 IMAP Use literal for requests and responses
Benoit Tellier [Wed, 3 Mar 2021 07:12:35 +0000 (14:12 +0700)] 
JAMES-3508 IMAP Use literal for requests and responses

18 months agoRevert "JAMES-3509 IMAP connection metric was not all the time decreased"
Benoit Tellier [Wed, 3 Mar 2021 08:06:29 +0000 (15:06 +0700)] 
Revert "JAMES-3509 IMAP connection metric was not all the time decreased"

This reverts commit 3bdd6cb361c68d86e682d4e37600d1fc1db359bd.

18 months agoJAMES-2343 Add buffered DeferredFileOutputStream and use it in MimeMessageInputStream...
Benoit Tellier [Wed, 17 Jun 2020 10:03:53 +0000 (17:03 +0700)] 
JAMES-2343 Add buffered DeferredFileOutputStream and use it in MimeMessageInputStreamSource

From the original work of @chikei

18 months agoJAMES-3506 Fix RabbitMQWebAdminServerTaskSerializationIntegrationTest::reprocessingOn...
Benoit Tellier [Tue, 2 Mar 2021 04:57:30 +0000 (11:57 +0700)] 
JAMES-3506 Fix RabbitMQWebAdminServerTaskSerializationIntegrationTest::reprocessingOneMailShouldCreateATask

18 months agoJAMES-3506 JAMES-3506 Fix a typo: soflty -> softly
Benoit Tellier [Mon, 1 Mar 2021 04:51:11 +0000 (11:51 +0700)] 
JAMES-3506 JAMES-3506 Fix a typo: soflty -> softly

18 months agoJAMES-3506 Fix JDBCMailRepository tests
Benoit Tellier [Sun, 28 Feb 2021 12:36:56 +0000 (19:36 +0700)] 
JAMES-3506 Fix JDBCMailRepository tests

 - Tag a not-isolated test as 'unstable'
 - saveChanges was adding a MimeVersion header, breaking equality

18 months agoJAMES-3506 Fix MimeMessageWrapper::getSize
Benoit Tellier [Sun, 28 Feb 2021 04:21:11 +0000 (11:21 +0700)] 
JAMES-3506 Fix MimeMessageWrapper::getSize

Body modifications were not taken into account. When body is
modified we can likely drop buggy smart computations.

Bad size caused bad offsets in FETCH commands.

18 months agoJAMES-3506 MimeMessageWrapper::getMessageSize should avoid a copy when only headers...
Benoit Tellier [Sun, 28 Feb 2021 03:39:31 +0000 (10:39 +0700)] 
JAMES-3506 MimeMessageWrapper::getMessageSize should avoid a copy when only headers are modified

18 months agoJAMES-3506 Back SimpleMailboxMessage with the Content API
Benoit Tellier [Sat, 27 Feb 2021 12:09:32 +0000 (19:09 +0700)] 
JAMES-3506 Back SimpleMailboxMessage with the Content API

This eventually avoids a copy within MessageManager::append

18 months agoJAMES-3506 Rework AppendCommand to enforce Content replay
Benoit Tellier [Sat, 27 Feb 2021 11:40:04 +0000 (18:40 +0700)] 
JAMES-3506 Rework AppendCommand to enforce Content replay

This effectively removes error prone mutable InputStream
from this POJO.

Note that the caller need to pass explicitly a content and manage this resource. InputStream methods, that do not allow the caller to do so, had been dropped.

18 months agoJAMES-3506 Generalize ByteContent
Benoit Tellier [Sat, 27 Feb 2021 10:51:22 +0000 (17:51 +0700)] 
JAMES-3506 Generalize ByteContent

18 months agoJAMES-3506 MessageManager: use content upon Append messages
Benoit Tellier [Sat, 27 Feb 2021 08:13:48 +0000 (15:13 +0700)] 
JAMES-3506 MessageManager: use content upon Append messages

18 months agoJAMES-3506 [Refactoring] Use append command where possible
Benoit Tellier [Sat, 27 Feb 2021 08:03:43 +0000 (15:03 +0700)] 
JAMES-3506 [Refactoring] Use append command where possible

18 months agoJAMES-3506 [Refactoring] MessageManager::append simple method extractions
Benoit Tellier [Sat, 27 Feb 2021 07:57:54 +0000 (14:57 +0700)] 
JAMES-3506 [Refactoring] MessageManager::append simple method extractions

To ease understanding

18 months agoJAMES-3506 Avoid a copy for mail sent with JMAP
Benoit Tellier [Fri, 26 Feb 2021 14:59:25 +0000 (21:59 +0700)] 
JAMES-3506 Avoid a copy for mail sent with JMAP

We achieve this by wrapping (byte array) based structure
using custom MimeMessageSource rather than the input
stream based one (that is forcing a copy).

Implemented both for JMAP draft and JMAP RFC-8621.

18 months agoJAMES-3506 MimeMessageStore: read header twice to avoid a body copy
Benoit Tellier [Fri, 26 Feb 2021 08:37:25 +0000 (15:37 +0700)] 
JAMES-3506 MimeMessageStore: read header twice to avoid a body copy

Large bodies (above 100KB) were copied to a file which is IO heavy,
small bodies were kept in memory, within the S3 blob store.

This avoids a copy when:
 - deduplication is enabled and we need to hash blobs to generate Ids
 - no dedup but size of streams are unknown, a full stream iteration (and
 a copy to a ByteSource for replay) is needed.

18 months agoJAMES-3506 Avoid a memory copy when saving attachments
Benoit Tellier [Fri, 26 Feb 2021 02:27:56 +0000 (09:27 +0700)] 
JAMES-3506 Avoid a memory copy when saving attachments

18 months agoJAMES-3506 Avoid a memory copy when saving the body of a message in the mailbox
Benoit Tellier [Thu, 25 Feb 2021 16:09:52 +0000 (23:09 +0700)] 
JAMES-3506 Avoid a memory copy when saving the body of a message in the mailbox

18 months agoJAMES-3506 Support saving byte source
Benoit Tellier [Thu, 25 Feb 2021 16:07:49 +0000 (23:07 +0700)] 
JAMES-3506 Support saving byte source

18 months agoJAMES-3506 JAMES-3506 Do not copy messages in memory before saving them to the blob...
Benoit Tellier [Thu, 25 Feb 2021 08:33:21 +0000 (15:33 +0700)] 
JAMES-3506 JAMES-3506 Do not copy messages in memory before saving them to the blob store

 - This reduce memory impact for enqueueing emails - SMTP, JMAP message submission
 - This reduce memory impact of dequeuing emails - mailetcontainer processing
 - This reduce overhead of CassandraMailRepository (minor gains)

 The memory gain will be major upon big messages.

 Unefficient memory usage of MailboxMessage is not addressed here.

18 months agoJAMES-3502, use the version in root pom for httpcore library
andreasvaldma [Tue, 2 Mar 2021 07:16:48 +0000 (09:16 +0200)] 
JAMES-3502, use the version in root pom for httpcore library

18 months agoJAMES-3502, use the version in root pom
andreasvaldma [Mon, 1 Mar 2021 12:55:58 +0000 (14:55 +0200)] 
JAMES-3502, use the version in root pom

18 months agoJAMES-3502, remove duplicate line, refactor method name
andreasvaldma [Mon, 1 Mar 2021 12:54:17 +0000 (14:54 +0200)] 
JAMES-3502, remove duplicate line, refactor method name

18 months agoJAMES-3502, update ssl.hostname.verifier and ssl.validation.strategy documentation
andreasvaldma [Thu, 25 Feb 2021 10:04:59 +0000 (12:04 +0200)] 
JAMES-3502, update ssl.hostname.verifier and ssl.validation.strategy documentation

18 months agoJAMES-3502, update ssl.keystore documentation
andreasvaldma [Thu, 25 Feb 2021 09:56:07 +0000 (11:56 +0200)] 
JAMES-3502, update ssl.keystore documentation

18 months agoJAMES-3502, add functional interface annotations
andreasvaldma [Thu, 25 Feb 2021 09:54:34 +0000 (11:54 +0200)] 
JAMES-3502, add functional interface annotations

18 months agoJAMES-3502, add documentation in config-rabbitmq.xml
andreasvaldma [Thu, 25 Feb 2021 09:51:24 +0000 (11:51 +0200)] 
JAMES-3502, add documentation in config-rabbitmq.xml

18 months agoJAMES-3502, fix checkstyle
andreasvaldma [Thu, 25 Feb 2021 09:44:51 +0000 (11:44 +0200)] 
JAMES-3502, fix checkstyle

18 months agoJAMES-3502, update RabbitMQConfiguration documentation
andreasvaldma [Thu, 25 Feb 2021 07:57:37 +0000 (09:57 +0200)] 
JAMES-3502, update RabbitMQConfiguration documentation

18 months agoJAMES-3502, rabbitmqmanagementapi refactor
andreasvaldma [Thu, 25 Feb 2021 07:25:05 +0000 (09:25 +0200)] 
JAMES-3502, rabbitmqmanagementapi refactor

18 months agoJAMES-3502, update documentation for rabbitmq configuration keys.
andreasvaldma [Thu, 25 Feb 2021 07:05:33 +0000 (09:05 +0200)] 
JAMES-3502, update documentation for rabbitmq configuration keys.

18 months agoJAMES-3502, add tls support in RabbitMQManagementAPI.java
andreasvaldma [Thu, 25 Feb 2021 06:17:57 +0000 (08:17 +0200)] 
JAMES-3502, add tls support in RabbitMQManagementAPI.java