You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-dev@james.apache.org by rc...@apache.org on 2020/05/18 03:03:27 UTC

[james-project] branch master updated (f67aeee -> 4edb31b)

This is an automated email from the ASF dual-hosted git repository.

rcordier pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/james-project.git.


    from f67aeee  JAMES-3183 adds X-Originating-IP in network mailet matcher
     new 24fd2c4  JAMES-3140 Relocate Cassandra backend cassandra.properties file
     new 009c2b4  JAMES-3140 Fix ModSeq::toString
     new 5bfbea1  JAMES-3168: Add integration test for EchoMethod
     new dccd616  JAMES-3168: Guice binding for JMAP-RFC8621, use jmap project everywhere to support both -draft and -rfc8621 implementations
     new 8b87d45  JAMES-3168: Use assertJ for json assertion in EchoMethod test
     new 4edb31b  JAMES-3168: remove unused property 'message_limit' for integration testing jmap rfc after rebase

The 6 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../init/CassandraConfigurationReadingTest.java    |   2 +-
 .../cassandra.properties                           |   0
 .../main/java/org/apache/james/mailbox/ModSeq.java |   5 +-
 .../smtp/cassandra-rabbitmq-object-storage/pom.xml |   2 +-
 mpt/impl/smtp/cassandra/pom.xml                    |   2 +-
 pom.xml                                            |   4 +-
 server/container/cli-integration/pom.xml           |   2 +-
 server/container/guice/cassandra-guice/pom.xml     |   4 +-
 .../org/apache/james/CassandraJamesServerMain.java |   4 +-
 .../container/guice/cassandra-ldap-guice/pom.xml   |   2 +-
 .../guice/cassandra-rabbitmq-guice/pom.xml         |   2 +-
 .../guice/cassandra-rabbitmq-ldap-guice/pom.xml    |   2 +-
 server/container/guice/memory-guice/pom.xml        |   4 +-
 .../org/apache/james/MemoryJamesServerMain.java    |   4 +-
 server/container/guice/pom.xml                     |  13 +-
 .../guice/protocols/{jmap-draft => jmap}/pom.xml   |  10 +-
 .../james/jmap/draft/DraftMethodsModule.java}      |   2 +-
 .../apache/james/jmap/draft/JMAPCommonModule.java  |   0
 .../jmap/draft/JMAPConfigurationStartUpCheck.java  |   0
 .../org/apache/james/jmap/draft/JMAPModule.java    |   5 +-
 .../apache/james/jmap/draft/JmapGuiceProbe.java    |   0
 .../apache/james/jmap/draft/MessageIdProbe.java    |   0
 .../james/jmap/rfc8621/RFC8621MethodsModule.java}  |  29 ++--
 .../james/modules/protocols/JMAPServerModule.java} |   2 +-
 .../main/resources/defaultJmapMailetContainer.xml  |   0
 .../apache/james/jmap/draft/JMAPModuleTest.java    |   0
 .../james/jmap/draft/JmapJamesServerContract.java  |   1 -
 .../james/jmap/draft/MailetPreconditionTest.java   |   1 -
 .../apache/james/modules/TestJMAPServerModule.java |   0
 server/mailet/integration-testing/pom.xml          |   2 +-
 server/pom.xml                                     |   3 +-
 .../pom.xml                                        |   2 +-
 .../jmap-draft-integration-testing-common/pom.xml  |   2 +-
 .../memory-jmap-draft-integration-testing/pom.xml  |   2 +-
 .../pom.xml                                        |   2 +-
 .../pom.xml                                        |  47 +++---
 .../jmap/rfc8621/contract/EchoMethodContract.scala | 167 +++++++++++++++++++++
 .../pom.xml                                        |  44 +++---
 .../jmap/rfc8621/memory/MemoryEchoMethodTest.java} |  20 +--
 .../src/test/resources/dnsservice.xml              |   0
 .../src/test/resources/domainlist.xml              |   0
 .../src/test/resources/imapserver.xml              |  19 +--
 .../src/test/resources/keystore                    | Bin
 .../src/test/resources/listeners.xml               |   0
 .../src/test/resources/lmtpserver.xml              |   0
 .../src/test/resources/mailetcontainer.xml         |   0
 .../src/test/resources/mailrepositorystore.xml     |   0
 .../src/test/resources/managesieveserver.xml       |   0
 .../src/test/resources/pop3server.xml              |   0
 .../src/test/resources/smtpserver.xml              |   0
 .../jmap-rfc-8621-integration-tests}/pom.xml       |  39 ++---
 server/protocols/jmap-rfc-8621/pom.xml             |   8 +-
 .../james/jmap/routes/JMAPApiRoutesTest.scala      | 157 +++++++++++++------
 .../webadmin-integration-test-common/pom.xml       |   4 +-
 54 files changed, 430 insertions(+), 190 deletions(-)
 rename backends-common/cassandra/src/test/resources/{ => configuration-reader-test}/cassandra.properties (100%)
 rename server/container/guice/protocols/{jmap-draft => jmap}/pom.xml (89%)
 rename server/container/guice/protocols/{jmap-draft/src/main/java/org/apache/james/jmap/draft/MethodsModule.java => jmap/src/main/java/org/apache/james/jmap/draft/DraftMethodsModule.java} (98%)
 rename server/container/guice/protocols/{jmap-draft => jmap}/src/main/java/org/apache/james/jmap/draft/JMAPCommonModule.java (100%)
 rename server/container/guice/protocols/{jmap-draft => jmap}/src/main/java/org/apache/james/jmap/draft/JMAPConfigurationStartUpCheck.java (100%)
 rename server/container/guice/protocols/{jmap-draft => jmap}/src/main/java/org/apache/james/jmap/draft/JMAPModule.java (98%)
 rename server/container/guice/protocols/{jmap-draft => jmap}/src/main/java/org/apache/james/jmap/draft/JmapGuiceProbe.java (100%)
 rename server/container/guice/protocols/{jmap-draft => jmap}/src/main/java/org/apache/james/jmap/draft/MessageIdProbe.java (100%)
 copy server/container/guice/{guice-common/src/main/java/org/apache/james/modules/IsStartedProbeModule.java => protocols/jmap/src/main/java/org/apache/james/jmap/rfc8621/RFC8621MethodsModule.java} (66%)
 rename server/container/guice/protocols/{jmap-draft/src/main/java/org/apache/james/modules/protocols/JMAPDraftServerModule.java => jmap/src/main/java/org/apache/james/modules/protocols/JMAPServerModule.java} (98%)
 rename server/container/guice/protocols/{jmap-draft => jmap}/src/main/resources/defaultJmapMailetContainer.xml (100%)
 rename server/container/guice/protocols/{jmap-draft => jmap}/src/test/java/org/apache/james/jmap/draft/JMAPModuleTest.java (100%)
 rename server/container/guice/protocols/{jmap-draft => jmap}/src/test/java/org/apache/james/jmap/draft/JmapJamesServerContract.java (98%)
 rename server/container/guice/protocols/{jmap-draft => jmap}/src/test/java/org/apache/james/jmap/draft/MailetPreconditionTest.java (99%)
 rename server/container/guice/protocols/{jmap-draft => jmap}/src/test/java/org/apache/james/modules/TestJMAPServerModule.java (100%)
 copy {mailbox/tools/quota-recompute => server/protocols/jmap-rfc-8621-integration-tests/jmap-rfc-8621-integration-tests-common}/pom.xml (59%)
 create mode 100644 server/protocols/jmap-rfc-8621-integration-tests/jmap-rfc-8621-integration-tests-common/src/main/scala/org/apache/james/jmap/rfc8621/contract/EchoMethodContract.scala
 copy server/{container/guice/jpa-common-guice => protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests}/pom.xml (59%)
 copy server/protocols/{webadmin-integration-test/memory-webadmin-integration-test/src/test/java/org/apache/james/webadmin/integration/memory/MemoryWebAdminServerIntegrationTest.java => jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/java/org/apache/james/jmap/rfc8621/memory/MemoryEchoMethodTest.java} (72%)
 copy server/protocols/{webadmin-integration-test/memory-webadmin-integration-test => jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests}/src/test/resources/dnsservice.xml (100%)
 copy server/protocols/{webadmin-integration-test/memory-webadmin-integration-test => jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests}/src/test/resources/domainlist.xml (100%)
 copy mpt/mavenplugin/src/site/fml/faq.fml => server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/imapserver.xml (69%)
 copy server/protocols/{webadmin-integration-test/memory-webadmin-integration-test => jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests}/src/test/resources/keystore (100%)
 copy server/protocols/{webadmin-integration-test/memory-webadmin-integration-test => jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests}/src/test/resources/listeners.xml (100%)
 copy server/protocols/{jmap-draft-integration-testing/memory-jmap-draft-integration-testing => jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests}/src/test/resources/lmtpserver.xml (100%)
 copy server/protocols/{jmap-draft-integration-testing/memory-jmap-draft-integration-testing => jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests}/src/test/resources/mailetcontainer.xml (100%)
 copy server/protocols/{webadmin-integration-test/memory-webadmin-integration-test => jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests}/src/test/resources/mailrepositorystore.xml (100%)
 copy server/protocols/{jmap-draft-integration-testing/memory-jmap-draft-integration-testing => jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests}/src/test/resources/managesieveserver.xml (100%)
 copy server/protocols/{jmap-draft-integration-testing/memory-jmap-draft-integration-testing => jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests}/src/test/resources/pop3server.xml (100%)
 copy server/protocols/{jmap-draft-integration-testing/memory-jmap-draft-integration-testing => jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests}/src/test/resources/smtpserver.xml (100%)
 copy {mpt/impl/managesieve => server/protocols/jmap-rfc-8621-integration-tests}/pom.xml (58%)


---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org


[james-project] 03/06: JAMES-3168: Add integration test for EchoMethod

Posted by rc...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rcordier pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/james-project.git

commit 5bfbea1ca99bb62ee2a89978c933bff85d22f773
Author: duc91 <du...@gmail.com>
AuthorDate: Mon May 11 17:06:07 2020 +0700

    JAMES-3168: Add integration test for EchoMethod
---
 server/container/guice/pom.xml                     |   5 +
 server/pom.xml                                     |   3 +-
 .../jmap-rfc-8621-integration-tests-common/pom.xml |  69 +++++++++
 .../jmap/rfc8621/contract/EchoMethodContract.scala | 167 +++++++++++++++++++++
 .../memory-jmap-rfc-8621-integration-tests/pom.xml |  58 +++++++
 .../jmap/rfc8621/memory/MemoryEchoMethodTest.java  |  39 +++++
 .../src/test/resources/dnsservice.xml              |  29 ++++
 .../src/test/resources/domainlist.xml              |  24 +++
 .../src/test/resources/imapserver.xml              |  39 +++++
 .../src/test/resources/keystore                    | Bin 0 -> 2245 bytes
 .../src/test/resources/listeners.xml               |  46 ++++++
 .../src/test/resources/lmtpserver.xml              |  23 +++
 .../src/test/resources/mailetcontainer.xml         | 132 ++++++++++++++++
 .../src/test/resources/mailrepositorystore.xml     |  30 ++++
 .../src/test/resources/managesieveserver.xml       |  32 ++++
 .../src/test/resources/pop3server.xml              |  23 +++
 .../src/test/resources/smtpserver.xml              |  48 ++++++
 .../jmap-rfc-8621-integration-tests/pom.xml        |  65 ++++++++
 18 files changed, 831 insertions(+), 1 deletion(-)

diff --git a/server/container/guice/pom.xml b/server/container/guice/pom.xml
index af004d3..6586449 100644
--- a/server/container/guice/pom.xml
+++ b/server/container/guice/pom.xml
@@ -221,6 +221,11 @@
             </dependency>
             <dependency>
                 <groupId>${james.groupId}</groupId>
+                <artifactId>james-server-jmap-rfc-8621</artifactId>
+                <version>${project.version}</version>
+            </dependency>
+            <dependency>
+                <groupId>${james.groupId}</groupId>
                 <artifactId>james-server-jpa-smtp-common-guice</artifactId>
                 <version>${project.version}</version>
             </dependency>
diff --git a/server/pom.xml b/server/pom.xml
index c5b8efa..a152c6a 100644
--- a/server/pom.xml
+++ b/server/pom.xml
@@ -85,8 +85,9 @@
         <module>protocols/fetchmail</module>
         <module>protocols/jmap</module>
         <module>protocols/jmap-draft</module>
-        <module>protocols/jmap-rfc-8621</module>
         <module>protocols/jmap-draft-integration-testing</module>
+        <module>protocols/jmap-rfc-8621</module>
+        <module>protocols/jmap-rfc-8621-integration-tests</module>
         <module>protocols/jwt</module>
         <module>protocols/protocols-imap4</module>
         <module>protocols/protocols-library</module>
diff --git a/server/protocols/jmap-rfc-8621-integration-tests/jmap-rfc-8621-integration-tests-common/pom.xml b/server/protocols/jmap-rfc-8621-integration-tests/jmap-rfc-8621-integration-tests-common/pom.xml
new file mode 100644
index 0000000..3cedba7
--- /dev/null
+++ b/server/protocols/jmap-rfc-8621-integration-tests/jmap-rfc-8621-integration-tests-common/pom.xml
@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements. See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership. The ASF licenses this file
+    to you under the Apache License, Version 2.0 (the
+    "License"); you may not use this file except in compliance
+    with the License. You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing,
+    software distributed under the License is distributed on an
+    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    KIND, either express or implied. See the License for the
+    specific language governing permissions and limitations
+    under the License.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+    <parent>
+        <artifactId>jmap-rfc-8621-integration-tests</artifactId>
+        <groupId>org.apache.james</groupId>
+        <version>3.6.0-SNAPSHOT</version>
+    </parent>
+
+    <modelVersion>4.0.0</modelVersion>
+    <artifactId>jmap-rfc-8621-integration-tests-common</artifactId>
+    <description>JMAP RFC-8621 integration test suite common to all products</description>
+    <name>Apache James :: Server :: JMAP RFC-8621 :: Contract for Integration Testing</name>
+
+    <dependencies>
+        <dependency>
+            <groupId>${james.groupId}</groupId>
+            <artifactId>james-server-guice-common</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>${james.groupId}</groupId>
+            <artifactId>james-server-guice-jmap</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>${james.groupId}</groupId>
+            <artifactId>testing-base</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>com.typesafe.play</groupId>
+            <artifactId>play-json_${scala.base}</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>io.rest-assured</groupId>
+            <artifactId>rest-assured</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>net.javacrumbs.json-unit</groupId>
+            <artifactId>json-unit-assertj</artifactId>
+        </dependency>
+    </dependencies>
+
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>net.alchim31.maven</groupId>
+                <artifactId>scala-maven-plugin</artifactId>
+            </plugin>
+        </plugins>
+    </build>
+</project>
\ No newline at end of file
diff --git a/server/protocols/jmap-rfc-8621-integration-tests/jmap-rfc-8621-integration-tests-common/src/main/scala/org/apache/james/jmap/rfc8621/contract/EchoMethodContract.scala b/server/protocols/jmap-rfc-8621-integration-tests/jmap-rfc-8621-integration-tests-common/src/main/scala/org/apache/james/jmap/rfc8621/contract/EchoMethodContract.scala
new file mode 100644
index 0000000..4c960ee
--- /dev/null
+++ b/server/protocols/jmap-rfc-8621-integration-tests/jmap-rfc-8621-integration-tests-common/src/main/scala/org/apache/james/jmap/rfc8621/contract/EchoMethodContract.scala
@@ -0,0 +1,167 @@
+/****************************************************************
+ * Licensed to the Apache Software Foundation (ASF) under one   *
+ * or more contributor license agreements.  See the NOTICE file *
+ * distributed with this work for additional information        *
+ * regarding copyright ownership.  The ASF licenses this file   *
+ * to you under the Apache License, Version 2.0 (the            *
+ * "License"); you may not use this file except in compliance   *
+ * with the License.  You may obtain a copy of the License at   *
+ *                                                              *
+ *   http://www.apache.org/licenses/LICENSE-2.0                 *
+ *                                                              *
+ * Unless required by applicable law or agreed to in writing,   *
+ * software distributed under the License is distributed on an  *
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       *
+ * KIND, either express or implied.  See the License for the    *
+ * specific language governing permissions and limitations      *
+ * under the License.                                           *
+ ****************************************************************/
+package org.apache.james.jmap.rfc8621.contract
+
+import java.nio.charset.StandardCharsets
+import io.netty.handler.codec.http.HttpHeaderNames.ACCEPT
+import io.restassured.RestAssured
+import io.restassured.builder.RequestSpecBuilder
+import io.restassured.config.EncoderConfig.encoderConfig
+import io.restassured.config.RestAssuredConfig.newConfig
+import io.restassured.http.ContentType
+import net.javacrumbs.jsonunit.assertj.JsonAssertions.assertThatJson
+import org.apache.http.HttpStatus
+import org.apache.james.GuiceJamesServer
+import org.apache.james.jmap.JMAPUrls.JMAP
+import org.apache.james.jmap.draft.JmapGuiceProbe
+import org.apache.james.jmap.rfc8621.contract.EchoMethodContract._
+import org.junit.jupiter.api.{BeforeEach, Test}
+
+object EchoMethodContract {
+
+  private val REQUEST_OBJECT: String =
+    """{
+      |  "using": [
+      |    "urn:ietf:params:jmap:core"
+      |  ],
+      |  "methodCalls": [
+      |    [
+      |      "Core/echo",
+      |      {
+      |        "arg1": "arg1data",
+      |        "arg2": "arg2data"
+      |      },
+      |      "c1"
+      |    ]
+      |  ]
+      |}""".stripMargin
+  private val REQUEST_OBJECT_WITH_UNSUPPORTED_METHOD: String =
+    """{
+      |  "using": [
+      |    "urn:ietf:params:jmap:core"
+      |  ],
+      |  "methodCalls": [
+      |    [
+      |      "Core/echo",
+      |      {
+      |        "arg1": "arg1data",
+      |        "arg2": "arg2data"
+      |      },
+      |      "c1"
+      |    ],
+      |    [
+      |      "error",
+      |      {
+      |        "type": "Not implemented"
+      |      },
+      |      "notsupport"
+      |    ]
+      |  ]
+      |}""".stripMargin
+
+  private val RESPONSE_OBJECT: String =
+    """{
+      |  "sessionState": "75128aab4b1b",
+      |  "methodResponses": [
+      |    [
+      |      "Core/echo",
+      |      {
+      |        "arg1": "arg1data",
+      |        "arg2": "arg2data"
+      |      },
+      |      "c1"
+      |    ]
+      |  ]
+      |}""".stripMargin
+  private val RESPONSE_OBJECT_WITH_UNSUPPORTED_METHOD: String =
+    """{
+      |  "sessionState": "75128aab4b1b",
+      |  "methodResponses": [
+      |    [
+      |      "Core/echo",
+      |      {
+      |        "arg1": "arg1data",
+      |        "arg2": "arg2data"
+      |      },
+      |      "c1"
+      |    ],
+      |    [
+      |      "error",
+      |      {
+      |        "type": "Not implemented"
+      |      },
+      |      "notsupport"
+      |    ]
+      |  ]
+      |}""".stripMargin
+
+  private val ACCEPT_RFC8621_VERSION_HEADER: String = """application/json; jmapVersion=rfc-8621"""
+}
+
+trait EchoMethodContract {
+
+  @BeforeEach
+  def setUp(server: GuiceJamesServer): Unit = {
+    RestAssured.requestSpecification = new RequestSpecBuilder()
+      .setContentType(ContentType.JSON)
+      .setAccept(ContentType.JSON)
+      .setConfig(newConfig.encoderConfig(encoderConfig.defaultContentCharset(StandardCharsets.UTF_8)))
+      .setPort(server.getProbe(classOf[JmapGuiceProbe])
+        .getJmapPort
+        .getValue)
+      .setBasePath(JMAP)
+      .build
+  }
+
+  @Test
+  def echoMethodShouldRespondOKWithRFC8621VersionAndSupportedMethod(): Unit = {
+    val response: String = RestAssured
+      .`given`()
+        .header(ACCEPT.toString, ACCEPT_RFC8621_VERSION_HEADER)
+        .body(REQUEST_OBJECT)
+      .when()
+        .post()
+      .then
+        .statusCode(HttpStatus.SC_OK)
+        .contentType(ContentType.JSON)
+      .extract()
+        .body()
+        .asString()
+
+    assertThatJson(response).isEqualTo(RESPONSE_OBJECT)
+  }
+
+  @Test
+  def echoMethodShouldRespondWithRFC8621VersionAndUnsupportedMethod(): Unit = {
+    val response: String = RestAssured
+      .`given`()
+        .header(ACCEPT.toString, ACCEPT_RFC8621_VERSION_HEADER)
+        .body(REQUEST_OBJECT_WITH_UNSUPPORTED_METHOD)
+      .when()
+        .post()
+      .then
+        .statusCode(HttpStatus.SC_OK)
+        .contentType(ContentType.JSON)
+      .extract()
+        .body()
+        .asString()
+
+    assertThatJson(response).isEqualTo(RESPONSE_OBJECT_WITH_UNSUPPORTED_METHOD)
+  }
+}
diff --git a/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/pom.xml b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/pom.xml
new file mode 100644
index 0000000..97bc022
--- /dev/null
+++ b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/pom.xml
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements. See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership. The ASF licenses this file
+    to you under the Apache License, Version 2.0 (the
+    "License"); you may not use this file except in compliance
+    with the License. You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing,
+    software distributed under the License is distributed on an
+    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    KIND, either express or implied. See the License for the
+    specific language governing permissions and limitations
+    under the License.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+    <parent>
+        <artifactId>jmap-rfc-8621-integration-tests</artifactId>
+        <groupId>org.apache.james</groupId>
+        <version>3.6.0-SNAPSHOT</version>
+    </parent>
+
+    <modelVersion>4.0.0</modelVersion>
+    <artifactId>memory-jmap-rfc-8621-integration-tests</artifactId>
+    <description>JMAP RFC-8621 integration test for memory product</description>
+    <name>Apache James :: Server :: JMAP RFC-8621 :: Memory Integration Testing</name>
+
+    <dependencies>
+        <dependency>
+            <groupId>${james.groupId}</groupId>
+            <artifactId>james-server-guice-common</artifactId>
+            <type>test-jar</type>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>${james.groupId}</groupId>
+            <artifactId>james-server-guice-jmap</artifactId>
+            <type>test-jar</type>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>james-server-memory-guice</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>jmap-rfc-8621-integration-tests-common</artifactId>
+            <scope>test</scope>
+        </dependency>
+    </dependencies>
+</project>
\ No newline at end of file
diff --git a/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/java/org/apache/james/jmap/rfc8621/memory/MemoryEchoMethodTest.java b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/java/org/apache/james/jmap/rfc8621/memory/MemoryEchoMethodTest.java
new file mode 100644
index 0000000..7108a6b
--- /dev/null
+++ b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/java/org/apache/james/jmap/rfc8621/memory/MemoryEchoMethodTest.java
@@ -0,0 +1,39 @@
+/****************************************************************
+ * Licensed to the Apache Software Foundation (ASF) under one   *
+ * or more contributor license agreements.  See the NOTICE file *
+ * distributed with this work for additional information        *
+ * regarding copyright ownership.  The ASF licenses this file   *
+ * to you under the Apache License, Version 2.0 (the            *
+ * "License"); you may not use this file except in compliance   *
+ * with the License.  You may obtain a copy of the License at   *
+ *                                                              *
+ *   http://www.apache.org/licenses/LICENSE-2.0                 *
+ *                                                              *
+ * Unless required by applicable law or agreed to in writing,   *
+ * software distributed under the License is distributed on an  *
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       *
+ * KIND, either express or implied.  See the License for the    *
+ * specific language governing permissions and limitations      *
+ * under the License.                                           *
+ ****************************************************************/
+
+package org.apache.james.jmap.rfc8621.memory;
+
+import static org.apache.james.MemoryJamesServerMain.IN_MEMORY_SERVER_AGGREGATE_MODULE;
+import static org.apache.james.modules.TestJMAPServerModule.LIMIT_TO_20_MESSAGES;
+
+import org.apache.james.GuiceJamesServer;
+import org.apache.james.JamesServerBuilder;
+import org.apache.james.JamesServerExtension;
+import org.apache.james.jmap.rfc8621.contract.EchoMethodContract;
+import org.apache.james.modules.TestJMAPServerModule;
+import org.junit.jupiter.api.extension.RegisterExtension;
+
+public class MemoryEchoMethodTest implements EchoMethodContract {
+    @RegisterExtension
+    static JamesServerExtension testExtension = new JamesServerBuilder()
+        .server(configuration -> GuiceJamesServer.forConfiguration(configuration)
+            .combineWith(IN_MEMORY_SERVER_AGGREGATE_MODULE)
+            .overrideWith(TestJMAPServerModule.maximumMessages(LIMIT_TO_20_MESSAGES)))
+        .build();
+}
diff --git a/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/dnsservice.xml b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/dnsservice.xml
new file mode 100644
index 0000000..0978a00
--- /dev/null
+++ b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/dnsservice.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one   
+  or more contributor license agreements.  See the NOTICE file 
+  distributed with this work for additional information        
+  regarding copyright ownership.  The ASF licenses this file   
+  to you under the Apache License, Version 2.0 (the            
+  "License"); you may not use this file except in compliance   
+  with the License.  You may obtain a copy of the License at   
+                                                               
+    http://www.apache.org/licenses/LICENSE-2.0                 
+                                                               
+  Unless required by applicable law or agreed to in writing,   
+  software distributed under the License is distributed on an  
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       
+  KIND, either express or implied.  See the License for the    
+  specific language governing permissions and limitations      
+  under the License.                                           
+ -->
+
+<dnsservice>
+  <servers>
+    <server>8.8.8.8</server>
+    <server>62.210.16.6</server>
+  </servers>
+  <autodiscover>false</autodiscover>
+  <authoritative>false</authoritative>
+  <maxcachesize>50000</maxcachesize>
+</dnsservice>
diff --git a/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/domainlist.xml b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/domainlist.xml
new file mode 100644
index 0000000..fe17431
--- /dev/null
+++ b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/domainlist.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one   
+  or more contributor license agreements.  See the NOTICE file 
+  distributed with this work for additional information        
+  regarding copyright ownership.  The ASF licenses this file   
+  to you under the Apache License, Version 2.0 (the            
+  "License"); you may not use this file except in compliance   
+  with the License.  You may obtain a copy of the License at   
+                                                               
+    http://www.apache.org/licenses/LICENSE-2.0                 
+                                                               
+  Unless required by applicable law or agreed to in writing,   
+  software distributed under the License is distributed on an  
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       
+  KIND, either express or implied.  See the License for the    
+  specific language governing permissions and limitations      
+  under the License.                                           
+ -->
+
+<domainlist>
+    <autodetect>false</autodetect>
+    <autodetectIP>false</autodetectIP>
+</domainlist>
diff --git a/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/imapserver.xml b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/imapserver.xml
new file mode 100644
index 0000000..aa7c2fb
--- /dev/null
+++ b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/imapserver.xml
@@ -0,0 +1,39 @@
+<?xml version="1.0"?>
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+
+<imapservers>
+    <imapserver enabled="true">
+        <jmxName>imapserver</jmxName>
+        <bind>0.0.0.0:0</bind>
+        <connectionBacklog>200</connectionBacklog>
+        <tls socketTLS="false" startTLS="false">
+            <!-- To create a new keystore execute:
+            keytool -genkey -alias james -keyalg RSA -keystore /path/to/james/conf/keystore
+              -->
+            <keystore>file://conf/keystore</keystore>
+            <secret>james72laBalle</secret>
+            <provider>org.bouncycastle.jce.provider.BouncyCastleProvider</provider>
+        </tls>
+        <connectionLimit>0</connectionLimit>
+        <connectionLimitPerIP>0</connectionLimitPerIP>
+    </imapserver>
+</imapservers>
diff --git a/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/keystore b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/keystore
new file mode 100644
index 0000000..536a6c7
Binary files /dev/null and b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/keystore differ
diff --git a/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/listeners.xml b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/listeners.xml
new file mode 100644
index 0000000..59e3fec
--- /dev/null
+++ b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/listeners.xml
@@ -0,0 +1,46 @@
+<?xml version="1.0"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one   
+  or more contributor license agreements.  See the NOTICE file 
+  distributed with this work for additional information        
+  regarding copyright ownership.  The ASF licenses this file   
+  to you under the Apache License, Version 2.0 (the            
+  "License"); you may not use this file except in compliance   
+  with the License.  You may obtain a copy of the License at   
+                                                               
+    http://www.apache.org/licenses/LICENSE-2.0                 
+                                                               
+  Unless required by applicable law or agreed to in writing,   
+  software distributed under the License is distributed on an  
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       
+  KIND, either express or implied.  See the License for the    
+  specific language governing permissions and limitations      
+  under the License.                                           
+ -->
+
+<listeners>
+  <listener>
+    <class>org.apache.james.mailbox.quota.mailing.listeners.QuotaThresholdCrossingListener</class>
+    <group>QuotaThresholdCrossingListener-lower-threshold</group>
+    <configuration>
+      <thresholds>
+        <threshold>
+          <value>0.1</value>
+        </threshold>
+      </thresholds>
+      <name>first</name>
+    </configuration>
+  </listener>
+  <listener>
+    <class>org.apache.james.mailbox.quota.mailing.listeners.QuotaThresholdCrossingListener</class>
+    <group>QuotaThresholdCrossingListener-upper-threshold</group>
+    <configuration>
+      <thresholds>
+        <threshold>
+          <value>0.2</value>
+        </threshold>
+      </thresholds>
+      <name>second</name>
+    </configuration>
+  </listener>
+</listeners>
\ No newline at end of file
diff --git a/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/lmtpserver.xml b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/lmtpserver.xml
new file mode 100644
index 0000000..f838adb
--- /dev/null
+++ b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/lmtpserver.xml
@@ -0,0 +1,23 @@
+<?xml version="1.0"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one   
+  or more contributor license agreements.  See the NOTICE file 
+  distributed with this work for additional information        
+  regarding copyright ownership.  The ASF licenses this file   
+  to you under the Apache License, Version 2.0 (the            
+  "License"); you may not use this file except in compliance   
+  with the License.  You may obtain a copy of the License at   
+                                                               
+    http://www.apache.org/licenses/LICENSE-2.0                 
+                                                               
+  Unless required by applicable law or agreed to in writing,   
+  software distributed under the License is distributed on an  
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       
+  KIND, either express or implied.  See the License for the    
+  specific language governing permissions and limitations      
+  under the License.                                           
+ -->
+
+<lmtpservers>
+
+</lmtpservers>
diff --git a/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/mailetcontainer.xml b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/mailetcontainer.xml
new file mode 100644
index 0000000..8672b93
--- /dev/null
+++ b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/mailetcontainer.xml
@@ -0,0 +1,132 @@
+<?xml version="1.0"?>
+
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements.  See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership.  The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied.  See the License for the
+  specific language governing permissions and limitations
+  under the License.
+ -->
+
+<mailetcontainer enableJmx="false">
+
+    <context>
+        <postmaster>postmaster@james.minet.net</postmaster>
+    </context>
+
+    <spooler>
+        <threads>2</threads>
+    </spooler>
+
+    <processors>
+
+        <processor state="root" enableJmx="false">
+            <mailet match="All" class="PostmasterAlias"/>
+            <mailet match="RelayLimit=30" class="Null"/>
+            <mailet match="All" class="ToProcessor">
+                <processor>transport</processor>
+            </mailet>
+        </processor>
+
+        <processor state="error" enableJmx="false">
+            <mailet match="All" class="Bounce"/>
+        </processor>
+
+        <processor state="transport" enableJmx="false">
+            <matcher name="mdn-matcher" match="org.apache.james.mailetcontainer.impl.matchers.And">
+                <matcher match="HasMimeType=multipart/report"/>
+                <matcher match="HasMimeTypeParameter=report-type=disposition-notification"/>
+            </matcher>
+            <matcher name="relay-allowed" match="org.apache.james.mailetcontainer.impl.matchers.Or">
+                <matcher match="SMTPAuthSuccessful"/>
+                <matcher match="SMTPIsAuthNetwork"/>
+                <matcher match="SentByMailet"/>
+                <matcher match="org.apache.james.jmap.mailet.SentByJmap"/>
+            </matcher>
+
+            <mailet match="All" class="RemoveMimeHeader">
+                <name>bcc</name>
+            </mailet>
+            <mailet match="All" class="ICSSanitizer"/>
+            <mailet match="All" class="org.apache.james.jmap.mailet.TextCalendarBodyToAttachment"/>
+            <mailet match="All" class="RecipientRewriteTable">
+                <errorProcessor>rrt-error</errorProcessor>
+            </mailet>
+            <mailet match="RecipientIsLocal" class="org.apache.james.jmap.mailet.VacationMailet"/>
+            <mailet match="mdn-matcher" class="org.apache.james.jmap.mailet.ExtractMDNOriginalJMAPMessageId" >
+                <onMailetException>ignore</onMailetException>
+            </mailet>
+            <mailet match="RecipientIsLocal" class="Sieve"/>
+            <mailet match="RecipientIsLocal" class="SpamAssassin">
+                <onMailetException>ignore</onMailetException>
+                <spamdHost>localhost</spamdHost>
+                <spamdPort>783</spamdPort>
+            </mailet>
+            <mailet match="IsMarkedAsSpam" class="WithStorageDirective">
+                <targetFolderName>Spam</targetFolderName>
+            </mailet>
+            <mailet match="RecipientIsLocal" class="org.apache.james.jmap.mailet.filter.JMAPFiltering"/>
+            <mailet match="RecipientIsLocal" class="LocalDelivery"/>
+            <mailet match="HostIsLocal" class="ToProcessor">
+                <processor>local-address-error</processor>
+                <notice>550 - Requested action not taken: no such user here</notice>
+            </mailet>
+
+            <mailet match="relay-allowed" class="RemoteDelivery">
+                <outgoingQueue>outgoing</outgoingQueue>
+                <delayTime>5000, 100000, 500000</delayTime>
+                <maxRetries>25</maxRetries>
+                <maxDnsProblemRetries>0</maxDnsProblemRetries>
+                <deliveryThreads>10</deliveryThreads>
+                <sendpartial>true</sendpartial>
+                <bounceProcessor>bounces</bounceProcessor>
+            </mailet>
+
+            <mailet match="All" class="ToProcessor">
+                <processor>relay-denied</processor>
+            </mailet>
+        </processor>
+
+        <processor state="local-address-error" enableJmx="false">
+            <mailet match="All" class="Bounce">
+                <attachment>none</attachment>
+            </mailet>
+        </processor>
+
+        <processor state="relay-denied" enableJmx="false">
+            <mailet match="All" class="Bounce">
+                <attachment>none</attachment>
+            </mailet>
+        </processor>
+
+        <processor state="bounces" enableJmx="false">
+            <mailet match="All" class="DSNBounce">
+                <passThrough>false</passThrough>
+            </mailet>
+        </processor>
+
+        <processor state="rrt-error" enableJmx="false">
+            <mailet match="All" class="ToRepository">
+                <repositoryPath>memory://var/mail/rrt-error/</repositoryPath>
+                <passThrough>true</passThrough>
+            </mailet>
+            <mailet match="IsSenderInRRTLoop" class="Null"/>
+            <mailet match="All" class="Bounce"/>
+        </processor>
+
+    </processors>
+
+</mailetcontainer>
+
+
diff --git a/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/mailrepositorystore.xml b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/mailrepositorystore.xml
new file mode 100644
index 0000000..ed3e003
--- /dev/null
+++ b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/mailrepositorystore.xml
@@ -0,0 +1,30 @@
+<?xml version="1.0"?>
+
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements.  See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership.  The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied.  See the License for the
+  specific language governing permissions and limitations
+  under the License.
+ -->
+
+<mailrepositorystore>
+    <mailrepositories>
+        <mailrepository class="org.apache.james.mailrepository.memory.MemoryMailRepository">
+            <protocols>
+                <protocol>memory</protocol>
+            </protocols>
+        </mailrepository>
+    </mailrepositories>
+</mailrepositorystore>
diff --git a/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/managesieveserver.xml b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/managesieveserver.xml
new file mode 100644
index 0000000..f136a43
--- /dev/null
+++ b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/managesieveserver.xml
@@ -0,0 +1,32 @@
+<?xml version="1.0"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one   
+  or more contributor license agreements.  See the NOTICE file 
+  distributed with this work for additional information        
+  regarding copyright ownership.  The ASF licenses this file   
+  to you under the Apache License, Version 2.0 (the            
+  "License"); you may not use this file except in compliance   
+  with the License.  You may obtain a copy of the License at   
+                                                               
+    http://www.apache.org/licenses/LICENSE-2.0                 
+                                                               
+  Unless required by applicable law or agreed to in writing,   
+  software distributed under the License is distributed on an  
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       
+  KIND, either express or implied.  See the License for the    
+  specific language governing permissions and limitations      
+  under the License.                                           
+ -->
+ 
+<!--
+   This template file can be used as example for James Server configuration
+   DO NOT USE IT AS SUCH AND ADAPT IT TO YOUR NEEDS
+-->
+ 
+<!-- See http://james.apache.org/server/3/config.html for usage -->
+
+<managesieveservers>
+
+</managesieveservers>
+
+
diff --git a/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/pop3server.xml b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/pop3server.xml
new file mode 100644
index 0000000..bec385a
--- /dev/null
+++ b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/pop3server.xml
@@ -0,0 +1,23 @@
+<?xml version="1.0"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one   
+  or more contributor license agreements.  See the NOTICE file 
+  distributed with this work for additional information        
+  regarding copyright ownership.  The ASF licenses this file   
+  to you under the Apache License, Version 2.0 (the            
+  "License"); you may not use this file except in compliance   
+  with the License.  You may obtain a copy of the License at   
+                                                               
+    http://www.apache.org/licenses/LICENSE-2.0                 
+                                                               
+  Unless required by applicable law or agreed to in writing,   
+  software distributed under the License is distributed on an  
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       
+  KIND, either express or implied.  See the License for the    
+  specific language governing permissions and limitations      
+  under the License.                                           
+ -->
+
+
+<pop3servers>
+</pop3servers>
diff --git a/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/smtpserver.xml b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/smtpserver.xml
new file mode 100644
index 0000000..0211d77
--- /dev/null
+++ b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/smtpserver.xml
@@ -0,0 +1,48 @@
+<?xml version="1.0"?>
+
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements.  See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership.  The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied.  See the License for the
+  specific language governing permissions and limitations
+  under the License.
+ -->
+
+<smtpservers>
+    <smtpserver enabled="true">
+        <jmxName>smtpserver-global</jmxName>
+        <bind>0.0.0.0:0</bind>
+        <connectionBacklog>200</connectionBacklog>
+        <tls socketTLS="false" startTLS="false">
+            <keystore>file://conf/keystore</keystore>
+            <secret>james72laBalle</secret>
+            <provider>org.bouncycastle.jce.provider.BouncyCastleProvider</provider>
+            <algorithm>SunX509</algorithm>
+        </tls>
+        <connectiontimeout>360</connectiontimeout>
+        <connectionLimit>0</connectionLimit>
+        <connectionLimitPerIP>0</connectionLimitPerIP>
+        <authRequired>false</authRequired>
+        <verifyIdentity>true</verifyIdentity>
+        <maxmessagesize>0</maxmessagesize>
+        <addressBracketsEnforcement>true</addressBracketsEnforcement>
+        <smtpGreeting>JAMES Linagora's SMTP awesome Server</smtpGreeting>
+        <handlerchain>
+            <handler class="org.apache.james.smtpserver.fastfail.ValidRcptHandler"/>
+            <handler class="org.apache.james.smtpserver.CoreCmdHandlerLoader"/>
+        </handlerchain>
+    </smtpserver>
+</smtpservers>
+
+
diff --git a/server/protocols/jmap-rfc-8621-integration-tests/pom.xml b/server/protocols/jmap-rfc-8621-integration-tests/pom.xml
new file mode 100644
index 0000000..997ceac
--- /dev/null
+++ b/server/protocols/jmap-rfc-8621-integration-tests/pom.xml
@@ -0,0 +1,65 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements. See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership. The ASF licenses this file
+    to you under the Apache License, Version 2.0 (the
+    "License"); you may not use this file except in compliance
+    with the License. You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing,
+    software distributed under the License is distributed on an
+    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    KIND, either express or implied. See the License for the
+    specific language governing permissions and limitations
+    under the License.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+    <parent>
+        <artifactId>james-server</artifactId>
+        <groupId>org.apache.james</groupId>
+        <version>3.6.0-SNAPSHOT</version>
+        <relativePath>../../pom.xml</relativePath>
+    </parent>
+
+    <modelVersion>4.0.0</modelVersion>
+    <artifactId>jmap-rfc-8621-integration-tests</artifactId>
+    <packaging>pom</packaging>
+    <name>Apache James :: Server :: JMAP RFC-8621 :: Integration Testing</name>
+
+    <modules>
+        <module>jmap-rfc-8621-integration-tests-common</module>
+        <module>memory-jmap-rfc-8621-integration-tests</module>
+    </modules>
+
+    <dependencyManagement>
+        <dependencies>
+            <dependency>
+                <groupId>${james.groupId}</groupId>
+                <artifactId>james-server-guice-common</artifactId>
+                <version>${project.version}</version>
+            </dependency>
+            <dependency>
+                <groupId>${project.groupId}</groupId>
+                <artifactId>james-server-guice-jmap</artifactId>
+                <version>${project.version}</version>
+            </dependency>
+            <dependency>
+                <groupId>${project.groupId}</groupId>
+                <artifactId>james-server-guice-jmap</artifactId>
+                <version>${project.version}</version>
+                <type>test-jar</type>
+            </dependency>
+            <dependency>
+                <groupId>${project.groupId}</groupId>
+                <artifactId>jmap-rfc-8621-integration-tests-common</artifactId>
+                <version>${project.version}</version>
+            </dependency>
+        </dependencies>
+    </dependencyManagement>
+</project>
\ No newline at end of file


---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org


[james-project] 05/06: JAMES-3168: Use assertJ for json assertion in EchoMethod test

Posted by rc...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rcordier pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/james-project.git

commit 8b87d4505de2325ced264177d238b929dfd37f34
Author: duc91 <du...@gmail.com>
AuthorDate: Mon May 11 17:12:41 2020 +0700

    JAMES-3168: Use assertJ for json assertion in EchoMethod test
---
 server/protocols/jmap-rfc-8621/pom.xml             |   8 +-
 .../james/jmap/routes/JMAPApiRoutesTest.scala      | 157 +++++++++++++++------
 2 files changed, 118 insertions(+), 47 deletions(-)

diff --git a/server/protocols/jmap-rfc-8621/pom.xml b/server/protocols/jmap-rfc-8621/pom.xml
index 9f2d220..ba30cd2 100644
--- a/server/protocols/jmap-rfc-8621/pom.xml
+++ b/server/protocols/jmap-rfc-8621/pom.xml
@@ -17,7 +17,8 @@
     specific language governing permissions and limitations
     under the License.
 -->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
     <modelVersion>4.0.0</modelVersion>
 
     <parent>
@@ -83,6 +84,11 @@
             <scope>test</scope>
         </dependency>
         <dependency>
+            <groupId>net.javacrumbs.json-unit</groupId>
+            <artifactId>json-unit-assertj</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
             <groupId>org.mockito</groupId>
             <artifactId>mockito-core</artifactId>
             <scope>test</scope>
diff --git a/server/protocols/jmap-rfc-8621/src/test/scala/org/apache/james/jmap/routes/JMAPApiRoutesTest.scala b/server/protocols/jmap-rfc-8621/src/test/scala/org/apache/james/jmap/routes/JMAPApiRoutesTest.scala
index 4301319..004529b 100644
--- a/server/protocols/jmap-rfc-8621/src/test/scala/org/apache/james/jmap/routes/JMAPApiRoutesTest.scala
+++ b/server/protocols/jmap-rfc-8621/src/test/scala/org/apache/james/jmap/routes/JMAPApiRoutesTest.scala
@@ -1,4 +1,4 @@
-/** **************************************************************
+/****************************************************************
  * Licensed to the Apache Software Foundation (ASF) under one   *
  * or more contributor license agreements.  See the NOTICE file *
  * distributed with this work for additional information        *
@@ -6,16 +6,16 @@
  * to you under the Apache License, Version 2.0 (the            *
  * "License"); you may not use this file except in compliance   *
  * with the License.  You may obtain a copy of the License at   *
- * *
- * http://www.apache.org/licenses/LICENSE-2.0                 *
- * *
+ *                                                              *
+ *   http://www.apache.org/licenses/LICENSE-2.0                 *
+ *                                                              *
  * Unless required by applicable law or agreed to in writing,   *
  * software distributed under the License is distributed on an  *
  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       *
  * KIND, either express or implied.  See the License for the    *
  * specific language governing permissions and limitations      *
  * under the License.                                           *
- * ***************************************************************/
+ ****************************************************************/
 package org.apache.james.jmap.routes
 
 import java.nio.charset.StandardCharsets
@@ -27,11 +27,9 @@ import io.restassured.builder.RequestSpecBuilder
 import io.restassured.config.EncoderConfig.encoderConfig
 import io.restassured.config.RestAssuredConfig.newConfig
 import io.restassured.http.ContentType
+import net.javacrumbs.jsonunit.assertj.JsonAssertions.assertThatJson
 import org.apache.http.HttpStatus
 import org.apache.james.jmap.JMAPUrls.JMAP
-import org.apache.james.jmap.json.Fixture._
-import org.apache.james.jmap.json.Serializer
-import org.apache.james.jmap.model.RequestObject
 import org.apache.james.jmap.{JMAPConfiguration, JMAPRoutesHandler, JMAPServer, Version, VersionParser}
 import org.scalatest.BeforeAndAfter
 import org.scalatest.flatspec.AnyFlatSpec
@@ -48,13 +46,80 @@ class JMAPApiRoutesTest extends AnyFlatSpec with BeforeAndAfter with Matchers {
   private val ROUTES_HANDLER: ImmutableSet[JMAPRoutesHandler] = ImmutableSet.of(new JMAPRoutesHandler(Version.RFC8621, JMAP_API_ROUTE))
 
   private val REQUEST_OBJECT: String =
-    new Serializer().serialize(RequestObject(Seq(coreIdentifier), Seq(invocation1))).toString()
-
+    """{
+      |  "using": [
+      |    "urn:ietf:params:jmap:core"
+      |  ],
+      |  "methodCalls": [
+      |    [
+      |      "Core/echo",
+      |      {
+      |        "arg1": "arg1data",
+      |        "arg2": "arg2data"
+      |      },
+      |      "c1"
+      |    ]
+      |  ]
+      |}""".stripMargin
   private val REQUEST_OBJECT_WITH_UNSUPPORTED_METHOD: String =
-    new Serializer().serialize(RequestObject(Seq(coreIdentifier), Seq(invocation1, unsupportedInvocation))).toString()
-
-  private val RESPONSE_OBJECT: String = new Serializer().serialize(responseObject1).toString()
-  private val RESPONSE_OBJECT_WITH_UNSUPPORTED_METHOD: String = new Serializer().serialize(responseObjectWithUnsupportedMethod).toString()
+    """{
+      |  "using": [
+      |    "urn:ietf:params:jmap:core"
+      |  ],
+      |  "methodCalls": [
+      |    [
+      |      "Core/echo",
+      |      {
+      |        "arg1": "arg1data",
+      |        "arg2": "arg2data"
+      |      },
+      |      "c1"
+      |    ],
+      |    [
+      |      "error",
+      |      {
+      |        "type": "Not implemented"
+      |      },
+      |      "notsupport"
+      |    ]
+      |  ]
+      |}""".stripMargin
+
+  private val RESPONSE_OBJECT: String =
+    """{
+      |  "sessionState": "75128aab4b1b",
+      |  "methodResponses": [
+      |    [
+      |      "Core/echo",
+      |      {
+      |        "arg1": "arg1data",
+      |        "arg2": "arg2data"
+      |      },
+      |      "c1"
+      |    ]
+      |  ]
+      |}""".stripMargin
+  private val RESPONSE_OBJECT_WITH_UNSUPPORTED_METHOD: String =
+    """{
+      |  "sessionState": "75128aab4b1b",
+      |  "methodResponses": [
+      |    [
+      |      "Core/echo",
+      |      {
+      |        "arg1": "arg1data",
+      |        "arg2": "arg2data"
+      |      },
+      |      "c1"
+      |    ],
+      |    [
+      |      "error",
+      |      {
+      |        "type": "Not implemented"
+      |      },
+      |      "notsupport"
+      |    ]
+      |  ]
+      |}""".stripMargin
 
   private val SUPPORTED_VERSIONS = ImmutableSet.of(Version.DRAFT, Version.RFC8621)
 
@@ -92,86 +157,86 @@ class JMAPApiRoutesTest extends AnyFlatSpec with BeforeAndAfter with Matchers {
   "RFC-8621 version, GET" should "not supported and return 404 status" in {
     RestAssured
       .`given`()
-        .header(ACCEPT.toString, ACCEPT_RFC8621_VERSION_HEADER)
+      .header(ACCEPT.toString, ACCEPT_RFC8621_VERSION_HEADER)
       .when()
-        .get
+      .get
       .then
-        .statusCode(HttpStatus.SC_NOT_FOUND)
+      .statusCode(HttpStatus.SC_NOT_FOUND)
   }
 
   "RFC-8621 version, POST, without body" should "return 200 status" in {
     RestAssured
       .`given`()
-        .header(ACCEPT.toString, ACCEPT_RFC8621_VERSION_HEADER)
+      .header(ACCEPT.toString, ACCEPT_RFC8621_VERSION_HEADER)
       .when()
-        .post
+      .post
       .then
-        .statusCode(HttpStatus.SC_OK)
+      .statusCode(HttpStatus.SC_OK)
   }
 
   "RFC-8621 version, POST, methods include supported" should "return OK status" in {
     val response = RestAssured
       .`given`()
-        .header(ACCEPT.toString, ACCEPT_RFC8621_VERSION_HEADER)
-        .body(REQUEST_OBJECT)
+      .header(ACCEPT.toString, ACCEPT_RFC8621_VERSION_HEADER)
+      .body(REQUEST_OBJECT)
       .when()
-        .post()
+      .post()
       .then
-        .statusCode(HttpStatus.SC_OK)
-        .contentType(ContentType.JSON)
+      .statusCode(HttpStatus.SC_OK)
+      .contentType(ContentType.JSON)
       .extract()
-        .body()
-        .asString()
+      .body()
+      .asString()
 
-    response shouldBe (RESPONSE_OBJECT)
+    assertThatJson(response).isEqualTo(RESPONSE_OBJECT)
   }
 
   "RFC-8621 version, POST, with methods" should "return OK status, ResponseObject depend on method" in {
 
     val response = RestAssured
       .`given`()
-        .header(ACCEPT.toString, ACCEPT_RFC8621_VERSION_HEADER)
-        .body(REQUEST_OBJECT_WITH_UNSUPPORTED_METHOD)
+      .header(ACCEPT.toString, ACCEPT_RFC8621_VERSION_HEADER)
+      .body(REQUEST_OBJECT_WITH_UNSUPPORTED_METHOD)
       .when()
-        .post()
+      .post()
       .then
-        .statusCode(HttpStatus.SC_OK)
-        .contentType(ContentType.JSON)
+      .statusCode(HttpStatus.SC_OK)
+      .contentType(ContentType.JSON)
       .extract()
-        .body()
-        .asString()
+      .body()
+      .asString()
 
-    response shouldBe (RESPONSE_OBJECT_WITH_UNSUPPORTED_METHOD)
+    assertThatJson(response).isEqualTo(RESPONSE_OBJECT_WITH_UNSUPPORTED_METHOD)
   }
 
   "Draft version, GET" should "return 404 status" in {
     RestAssured
       .`given`()
-        .header(ACCEPT.toString, ACCEPT_DRAFT_VERSION_HEADER)
+      .header(ACCEPT.toString, ACCEPT_DRAFT_VERSION_HEADER)
       .when()
-        .get
+      .get
       .then
-        .statusCode(HttpStatus.SC_NOT_FOUND)
+      .statusCode(HttpStatus.SC_NOT_FOUND)
   }
 
   "Draft version, POST, without body" should "return 400 status" in {
     RestAssured
       .`given`()
-        .header(ACCEPT.toString, ACCEPT_DRAFT_VERSION_HEADER)
+      .header(ACCEPT.toString, ACCEPT_DRAFT_VERSION_HEADER)
       .when()
-        .post
+      .post
       .then
-        .statusCode(HttpStatus.SC_NOT_FOUND)
+      .statusCode(HttpStatus.SC_NOT_FOUND)
   }
 
   "RFC-8621 version, POST, with wrong requestObject body" should "return 400 status" in {
     RestAssured
       .`given`()
-        .header(ACCEPT.toString, ACCEPT_RFC8621_VERSION_HEADER)
-        .body(WRONG_OBJECT_REQUEST)
+      .header(ACCEPT.toString, ACCEPT_RFC8621_VERSION_HEADER)
+      .body(WRONG_OBJECT_REQUEST)
       .when()
-        .post
+      .post
       .then
-        .statusCode(HttpStatus.SC_BAD_REQUEST)
+      .statusCode(HttpStatus.SC_BAD_REQUEST)
   }
 }


---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org


[james-project] 01/06: JAMES-3140 Relocate Cassandra backend cassandra.properties file

Posted by rc...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rcordier pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/james-project.git

commit 24fd2c4a40e19b8447e556a29a5fe021abcbe272
Author: Benoit Tellier <bt...@linagora.com>
AuthorDate: Tue May 12 11:13:41 2020 +0700

    JAMES-3140 Relocate Cassandra backend cassandra.properties file
    
    This file was used for testing parsing and was fed with meaningless
    values.
    
    However integration tests were relying on it instead of Cassandra
    configuration defaults, leading to '2' retries only being performed
    upon concurrent modseq generation.
    
    Note that this is actually the cause of random failure within
    MailsShouldBeWellReceived::oneHundredMailsShouldBeWellReceived
---
 .../backends/cassandra/init/CassandraConfigurationReadingTest.java      | 2 +-
 .../test/resources/{ => configuration-reader-test}/cassandra.properties | 0
 2 files changed, 1 insertion(+), 1 deletion(-)

diff --git a/backends-common/cassandra/src/test/java/org/apache/james/backends/cassandra/init/CassandraConfigurationReadingTest.java b/backends-common/cassandra/src/test/java/org/apache/james/backends/cassandra/init/CassandraConfigurationReadingTest.java
index da60e9b..a6f5995 100644
--- a/backends-common/cassandra/src/test/java/org/apache/james/backends/cassandra/init/CassandraConfigurationReadingTest.java
+++ b/backends-common/cassandra/src/test/java/org/apache/james/backends/cassandra/init/CassandraConfigurationReadingTest.java
@@ -43,7 +43,7 @@ class CassandraConfigurationReadingTest {
         FileBasedConfigurationBuilder<FileBasedConfiguration> builder = new FileBasedConfigurationBuilder<FileBasedConfiguration>(PropertiesConfiguration.class)
             .configure(new Parameters()
                 .fileBased()
-                .setURL(ClassLoader.getSystemResource("cassandra.properties")));
+                .setURL(ClassLoader.getSystemResource("configuration-reader-test/cassandra.properties")));
 
         CassandraConfiguration configuration = CassandraConfiguration.from(builder.getConfiguration());
 
diff --git a/backends-common/cassandra/src/test/resources/cassandra.properties b/backends-common/cassandra/src/test/resources/configuration-reader-test/cassandra.properties
similarity index 100%
rename from backends-common/cassandra/src/test/resources/cassandra.properties
rename to backends-common/cassandra/src/test/resources/configuration-reader-test/cassandra.properties


---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org


[james-project] 02/06: JAMES-3140 Fix ModSeq::toString

Posted by rc...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rcordier pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/james-project.git

commit 009c2b49a6233c2073743b08e3a0f49c6f0af115
Author: Benoit Tellier <bt...@linagora.com>
AuthorDate: Tue May 12 11:15:05 2020 +0700

    JAMES-3140 Fix ModSeq::toString
---
 mailbox/api/src/main/java/org/apache/james/mailbox/ModSeq.java | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/mailbox/api/src/main/java/org/apache/james/mailbox/ModSeq.java b/mailbox/api/src/main/java/org/apache/james/mailbox/ModSeq.java
index 22cfb62..62640c5 100644
--- a/mailbox/api/src/main/java/org/apache/james/mailbox/ModSeq.java
+++ b/mailbox/api/src/main/java/org/apache/james/mailbox/ModSeq.java
@@ -19,6 +19,7 @@
 
 package org.apache.james.mailbox;
 
+import com.google.common.base.MoreObjects;
 import com.google.common.base.Objects;
 import com.google.common.base.Preconditions;
 
@@ -74,6 +75,8 @@ public class ModSeq implements Comparable<ModSeq> {
     
     @Override
     public String toString() {
-        return "ModSeq{uid=" + modSeq + "}";
+        return MoreObjects.toStringHelper(this)
+            .add("value", modSeq)
+            .toString();
     }
 }


---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org


[james-project] 04/06: JAMES-3168: Guice binding for JMAP-RFC8621, use jmap project everywhere to support both -draft and -rfc8621 implementations

Posted by rc...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rcordier pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/james-project.git

commit dccd616fe4f3b1e8f0d169936d1f493fff4ad8ef
Author: duc91 <du...@gmail.com>
AuthorDate: Mon May 11 17:08:44 2020 +0700

    JAMES-3168: Guice binding for JMAP-RFC8621, use jmap project everywhere to support both -draft and -rfc8621 implementations
---
 .../smtp/cassandra-rabbitmq-object-storage/pom.xml |  2 +-
 mpt/impl/smtp/cassandra/pom.xml                    |  2 +-
 pom.xml                                            |  4 +-
 server/container/cli-integration/pom.xml           |  2 +-
 server/container/guice/cassandra-guice/pom.xml     |  4 +-
 .../org/apache/james/CassandraJamesServerMain.java |  4 +-
 .../container/guice/cassandra-ldap-guice/pom.xml   |  2 +-
 .../guice/cassandra-rabbitmq-guice/pom.xml         |  2 +-
 .../guice/cassandra-rabbitmq-ldap-guice/pom.xml    |  2 +-
 server/container/guice/memory-guice/pom.xml        |  4 +-
 .../org/apache/james/MemoryJamesServerMain.java    |  4 +-
 server/container/guice/pom.xml                     |  8 ++--
 .../guice/protocols/{jmap-draft => jmap}/pom.xml   | 10 +++--
 .../james/jmap/draft/DraftMethodsModule.java}      |  2 +-
 .../apache/james/jmap/draft/JMAPCommonModule.java  |  0
 .../jmap/draft/JMAPConfigurationStartUpCheck.java  |  0
 .../org/apache/james/jmap/draft/JMAPModule.java    |  5 ++-
 .../apache/james/jmap/draft/JmapGuiceProbe.java    |  0
 .../apache/james/jmap/draft/MessageIdProbe.java    |  0
 .../james/jmap/rfc8621/RFC8621MethodsModule.java   | 45 ++++++++++++++++++++++
 .../james/modules/protocols/JMAPServerModule.java} |  2 +-
 .../main/resources/defaultJmapMailetContainer.xml  |  0
 .../apache/james/jmap/draft/JMAPModuleTest.java    |  0
 .../james/jmap/draft/JmapJamesServerContract.java  |  1 -
 .../james/jmap/draft/MailetPreconditionTest.java   |  1 -
 .../apache/james/modules/TestJMAPServerModule.java |  0
 server/mailet/integration-testing/pom.xml          |  2 +-
 .../pom.xml                                        |  2 +-
 .../jmap-draft-integration-testing-common/pom.xml  |  2 +-
 .../memory-jmap-draft-integration-testing/pom.xml  |  2 +-
 .../pom.xml                                        |  2 +-
 .../webadmin-integration-test-common/pom.xml       |  4 +-
 32 files changed, 85 insertions(+), 35 deletions(-)

diff --git a/mpt/impl/smtp/cassandra-rabbitmq-object-storage/pom.xml b/mpt/impl/smtp/cassandra-rabbitmq-object-storage/pom.xml
index 267cc92..d4ce24f 100644
--- a/mpt/impl/smtp/cassandra-rabbitmq-object-storage/pom.xml
+++ b/mpt/impl/smtp/cassandra-rabbitmq-object-storage/pom.xml
@@ -95,7 +95,7 @@
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
-            <artifactId>james-server-guice-jmap-draft</artifactId>
+            <artifactId>james-server-guice-jmap</artifactId>
             <type>test-jar</type>
             <scope>test</scope>
         </dependency>
diff --git a/mpt/impl/smtp/cassandra/pom.xml b/mpt/impl/smtp/cassandra/pom.xml
index 8414055..0fefef4 100644
--- a/mpt/impl/smtp/cassandra/pom.xml
+++ b/mpt/impl/smtp/cassandra/pom.xml
@@ -59,7 +59,7 @@
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
-            <artifactId>james-server-guice-jmap-draft</artifactId>
+            <artifactId>james-server-guice-jmap</artifactId>
             <type>test-jar</type>
             <scope>test</scope>
         </dependency>
diff --git a/pom.xml b/pom.xml
index 413a1ad..94adf21 100644
--- a/pom.xml
+++ b/pom.xml
@@ -1479,12 +1479,12 @@
             </dependency>
             <dependency>
                 <groupId>${james.groupId}</groupId>
-                <artifactId>james-server-guice-jmap-draft</artifactId>
+                <artifactId>james-server-guice-jmap</artifactId>
                 <version>${project.version}</version>
             </dependency>
             <dependency>
                 <groupId>${james.groupId}</groupId>
-                <artifactId>james-server-guice-jmap-draft</artifactId>
+                <artifactId>james-server-guice-jmap</artifactId>
                 <version>${project.version}</version>
                 <type>test-jar</type>
             </dependency>
diff --git a/server/container/cli-integration/pom.xml b/server/container/cli-integration/pom.xml
index dafe9c2..8084fda 100644
--- a/server/container/cli-integration/pom.xml
+++ b/server/container/cli-integration/pom.xml
@@ -50,7 +50,7 @@
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
-            <artifactId>james-server-guice-jmap-draft</artifactId>
+            <artifactId>james-server-guice-jmap</artifactId>
             <type>test-jar</type>
             <scope>test</scope>
         </dependency>
diff --git a/server/container/guice/cassandra-guice/pom.xml b/server/container/guice/cassandra-guice/pom.xml
index 4c277fa..8526e09 100644
--- a/server/container/guice/cassandra-guice/pom.xml
+++ b/server/container/guice/cassandra-guice/pom.xml
@@ -174,11 +174,11 @@
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
-            <artifactId>james-server-guice-jmap-draft</artifactId>
+            <artifactId>james-server-guice-jmap</artifactId>
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
-            <artifactId>james-server-guice-jmap-draft</artifactId>
+            <artifactId>james-server-guice-jmap</artifactId>
             <type>test-jar</type>
             <scope>test</scope>
         </dependency>
diff --git a/server/container/guice/cassandra-guice/src/main/java/org/apache/james/CassandraJamesServerMain.java b/server/container/guice/cassandra-guice/src/main/java/org/apache/james/CassandraJamesServerMain.java
index a7fcc7d..bc01ba1 100644
--- a/server/container/guice/cassandra-guice/src/main/java/org/apache/james/CassandraJamesServerMain.java
+++ b/server/container/guice/cassandra-guice/src/main/java/org/apache/james/CassandraJamesServerMain.java
@@ -45,7 +45,7 @@ import org.apache.james.modules.mailbox.ElasticSearchMailboxModule;
 import org.apache.james.modules.mailbox.TikaMailboxModule;
 import org.apache.james.modules.metrics.CassandraMetricsModule;
 import org.apache.james.modules.protocols.IMAPServerModule;
-import org.apache.james.modules.protocols.JMAPDraftServerModule;
+import org.apache.james.modules.protocols.JMAPServerModule;
 import org.apache.james.modules.protocols.LMTPServerModule;
 import org.apache.james.modules.protocols.ManageSieveServerModule;
 import org.apache.james.modules.protocols.POP3ServerModule;
@@ -107,7 +107,7 @@ public class CassandraJamesServerMain implements JamesServerMain {
         new POP3ServerModule(),
         new ProtocolHandlerModule(),
         new SMTPServerModule(),
-        new JMAPDraftServerModule(),
+        new JMAPServerModule(),
         WEBADMIN);
 
     public static final Module PLUGINS = Modules.combine(
diff --git a/server/container/guice/cassandra-ldap-guice/pom.xml b/server/container/guice/cassandra-ldap-guice/pom.xml
index f88e0e0..8887655 100644
--- a/server/container/guice/cassandra-ldap-guice/pom.xml
+++ b/server/container/guice/cassandra-ldap-guice/pom.xml
@@ -88,7 +88,7 @@
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
-            <artifactId>james-server-guice-jmap-draft</artifactId>
+            <artifactId>james-server-guice-jmap</artifactId>
             <type>test-jar</type>
             <scope>test</scope>
         </dependency>
diff --git a/server/container/guice/cassandra-rabbitmq-guice/pom.xml b/server/container/guice/cassandra-rabbitmq-guice/pom.xml
index ade5311..1b02418 100644
--- a/server/container/guice/cassandra-rabbitmq-guice/pom.xml
+++ b/server/container/guice/cassandra-rabbitmq-guice/pom.xml
@@ -148,7 +148,7 @@
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
-            <artifactId>james-server-guice-jmap-draft</artifactId>
+            <artifactId>james-server-guice-jmap</artifactId>
             <type>test-jar</type>
             <scope>test</scope>
         </dependency>
diff --git a/server/container/guice/cassandra-rabbitmq-ldap-guice/pom.xml b/server/container/guice/cassandra-rabbitmq-ldap-guice/pom.xml
index c37bc10..9767973 100644
--- a/server/container/guice/cassandra-rabbitmq-ldap-guice/pom.xml
+++ b/server/container/guice/cassandra-rabbitmq-ldap-guice/pom.xml
@@ -116,7 +116,7 @@
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
-            <artifactId>james-server-guice-jmap-draft</artifactId>
+            <artifactId>james-server-guice-jmap</artifactId>
             <type>test-jar</type>
             <scope>test</scope>
         </dependency>
diff --git a/server/container/guice/memory-guice/pom.xml b/server/container/guice/memory-guice/pom.xml
index 59311ee..ebca896 100644
--- a/server/container/guice/memory-guice/pom.xml
+++ b/server/container/guice/memory-guice/pom.xml
@@ -102,11 +102,11 @@
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
-            <artifactId>james-server-guice-jmap-draft</artifactId>
+            <artifactId>james-server-guice-jmap</artifactId>
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
-            <artifactId>james-server-guice-jmap-draft</artifactId>
+            <artifactId>james-server-guice-jmap</artifactId>
             <type>test-jar</type>
             <scope>test</scope>
         </dependency>
diff --git a/server/container/guice/memory-guice/src/main/java/org/apache/james/MemoryJamesServerMain.java b/server/container/guice/memory-guice/src/main/java/org/apache/james/MemoryJamesServerMain.java
index be8595a..9a19fae 100644
--- a/server/container/guice/memory-guice/src/main/java/org/apache/james/MemoryJamesServerMain.java
+++ b/server/container/guice/memory-guice/src/main/java/org/apache/james/MemoryJamesServerMain.java
@@ -31,7 +31,7 @@ import org.apache.james.modules.data.MemoryDataModule;
 import org.apache.james.modules.eventstore.MemoryEventStoreModule;
 import org.apache.james.modules.mailbox.MemoryMailboxModule;
 import org.apache.james.modules.protocols.IMAPServerModule;
-import org.apache.james.modules.protocols.JMAPDraftServerModule;
+import org.apache.james.modules.protocols.JMAPServerModule;
 import org.apache.james.modules.protocols.LMTPServerModule;
 import org.apache.james.modules.protocols.ManageSieveServerModule;
 import org.apache.james.modules.protocols.POP3ServerModule;
@@ -99,7 +99,7 @@ public class MemoryJamesServerMain implements JamesServerMain {
     public static final Module JMAP = Modules.combine(
         new JmapTasksModule(),
         new MemoryDataJmapModule(),
-        new JMAPDraftServerModule());
+        new JMAPServerModule());
 
     public static final Module IN_MEMORY_SERVER_MODULE = Modules.combine(
         new BlobMemoryModule(),
diff --git a/server/container/guice/pom.xml b/server/container/guice/pom.xml
index 6586449..bf8fe7f 100644
--- a/server/container/guice/pom.xml
+++ b/server/container/guice/pom.xml
@@ -59,7 +59,7 @@
         <module>memory-guice</module>
         <module>onami</module>
         <module>protocols/imap</module>
-        <module>protocols/jmap-draft</module>
+        <module>protocols/jmap</module>
         <module>protocols/lmtp</module>
         <module>protocols/managedsieve</module>
         <module>protocols/netty</module>
@@ -99,17 +99,17 @@
             </dependency>
             <dependency>
                 <groupId>${james.groupId}</groupId>
-                <artifactId>james-server-guice-imap</artifactId>
+                <artifactId>james-server-jmap-rfc-8621</artifactId>
                 <version>${project.version}</version>
             </dependency>
             <dependency>
                 <groupId>${james.groupId}</groupId>
-                <artifactId>james-server-guice-jmap-draft</artifactId>
+                <artifactId>james-server-guice-jmap</artifactId>
                 <version>${project.version}</version>
             </dependency>
             <dependency>
                 <groupId>${james.groupId}</groupId>
-                <artifactId>james-server-guice-jmap-draft</artifactId>
+                <artifactId>james-server-guice-jmap</artifactId>
                 <version>${project.version}</version>
                 <type>test-jar</type>
             </dependency>
diff --git a/server/container/guice/protocols/jmap-draft/pom.xml b/server/container/guice/protocols/jmap/pom.xml
similarity index 89%
rename from server/container/guice/protocols/jmap-draft/pom.xml
rename to server/container/guice/protocols/jmap/pom.xml
index 74637a4..c0de05a 100644
--- a/server/container/guice/protocols/jmap-draft/pom.xml
+++ b/server/container/guice/protocols/jmap/pom.xml
@@ -26,10 +26,10 @@
         <relativePath>../../pom.xml</relativePath>
     </parent>
 
-    <artifactId>james-server-guice-jmap-draft</artifactId>
+    <artifactId>james-server-guice-jmap</artifactId>
 
-    <name>Apache James :: Server :: Guice :: JMAP (draft)</name>
-    <description>JMAP (draft) modules for Guice implementation of James server</description>
+    <name>Apache James :: Server :: Guice :: JMAP</name>
+    <description>JMAP (draft and RFC8621) modules for Guice implementation of James server</description>
 
     <dependencies>
         <dependency>
@@ -63,6 +63,10 @@
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
+            <artifactId>james-server-jmap-rfc-8621</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>${james.groupId}</groupId>
             <artifactId>testing-base</artifactId>
             <scope>test</scope>
         </dependency>
diff --git a/server/container/guice/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/MethodsModule.java b/server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/draft/DraftMethodsModule.java
similarity index 98%
rename from server/container/guice/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/MethodsModule.java
rename to server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/draft/DraftMethodsModule.java
index b0fd789..f63684c 100644
--- a/server/container/guice/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/MethodsModule.java
+++ b/server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/draft/DraftMethodsModule.java
@@ -49,7 +49,7 @@ import com.google.inject.Scopes;
 import com.google.inject.multibindings.Multibinder;
 import com.google.inject.name.Names;
 
-public class MethodsModule extends AbstractModule {
+public class DraftMethodsModule extends AbstractModule {
 
     @Override
     protected void configure() {
diff --git a/server/container/guice/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/JMAPCommonModule.java b/server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/draft/JMAPCommonModule.java
similarity index 100%
rename from server/container/guice/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/JMAPCommonModule.java
rename to server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/draft/JMAPCommonModule.java
diff --git a/server/container/guice/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/JMAPConfigurationStartUpCheck.java b/server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/draft/JMAPConfigurationStartUpCheck.java
similarity index 100%
rename from server/container/guice/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/JMAPConfigurationStartUpCheck.java
rename to server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/draft/JMAPConfigurationStartUpCheck.java
diff --git a/server/container/guice/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/JMAPModule.java b/server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/draft/JMAPModule.java
similarity index 98%
rename from server/container/guice/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/JMAPModule.java
rename to server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/draft/JMAPModule.java
index 850f24e..f842c2a 100644
--- a/server/container/guice/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/JMAPModule.java
+++ b/server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/draft/JMAPModule.java
@@ -38,6 +38,7 @@ import org.apache.james.jmap.draft.utils.JsoupHtmlTextExtractor;
 import org.apache.james.jmap.event.PropagateLookupRightListener;
 import org.apache.james.jmap.mailet.VacationMailet;
 import org.apache.james.jmap.mailet.filter.JMAPFiltering;
+import org.apache.james.jmap.rfc8621.RFC8621MethodsModule;
 import org.apache.james.jwt.JwtConfiguration;
 import org.apache.james.lifecycle.api.StartUpCheck;
 import org.apache.james.mailbox.MailboxManager;
@@ -87,7 +88,8 @@ public class JMAPModule extends AbstractModule {
     @Override
     protected void configure() {
         install(new JMAPCommonModule());
-        install(new MethodsModule());
+        install(new DraftMethodsModule());
+        install(new RFC8621MethodsModule());
         install(binder -> binder
             .bind(CamelMailetContainerModule.DefaultProcessorsConfigurationSupplier.class)
             .toInstance(DEFAULT_JMAP_PROCESSORS_CONFIGURATION_SUPPLIER));
@@ -109,6 +111,7 @@ public class JMAPModule extends AbstractModule {
 
         Multibinder<Version> supportedVersions = Multibinder.newSetBinder(binder(), Version.class);
         supportedVersions.addBinding().toInstance(Version.DRAFT);
+        supportedVersions.addBinding().toInstance(Version.RFC8621);
     }
 
     @Provides
diff --git a/server/container/guice/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/JmapGuiceProbe.java b/server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/draft/JmapGuiceProbe.java
similarity index 100%
rename from server/container/guice/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/JmapGuiceProbe.java
rename to server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/draft/JmapGuiceProbe.java
diff --git a/server/container/guice/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/MessageIdProbe.java b/server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/draft/MessageIdProbe.java
similarity index 100%
rename from server/container/guice/protocols/jmap-draft/src/main/java/org/apache/james/jmap/draft/MessageIdProbe.java
rename to server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/draft/MessageIdProbe.java
diff --git a/server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/rfc8621/RFC8621MethodsModule.java b/server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/rfc8621/RFC8621MethodsModule.java
new file mode 100644
index 0000000..19fdbe4
--- /dev/null
+++ b/server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/rfc8621/RFC8621MethodsModule.java
@@ -0,0 +1,45 @@
+/****************************************************************
+ * Licensed to the Apache Software Foundation (ASF) under one   *
+ * or more contributor license agreements.  See the NOTICE file *
+ * distributed with this work for additional information        *
+ * regarding copyright ownership.  The ASF licenses this file   *
+ * to you under the Apache License, Version 2.0 (the            *
+ * "License"); you may not use this file except in compliance   *
+ * with the License.  You may obtain a copy of the License at   *
+ *                                                              *
+ *   http://www.apache.org/licenses/LICENSE-2.0                 *
+ *                                                              *
+ * Unless required by applicable law or agreed to in writing,   *
+ * software distributed under the License is distributed on an  *
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY       *
+ * KIND, either express or implied.  See the License for the    *
+ * specific language governing permissions and limitations      *
+ * under the License.                                           *
+ ****************************************************************/
+
+package org.apache.james.jmap.rfc8621;
+
+
+import org.apache.james.jmap.JMAPRoutesHandler;
+import org.apache.james.jmap.Version;
+import org.apache.james.jmap.method.CoreEcho;
+import org.apache.james.jmap.method.Method;
+import org.apache.james.jmap.routes.JMAPApiRoutes;
+
+import com.google.inject.AbstractModule;
+import com.google.inject.multibindings.Multibinder;
+import com.google.inject.multibindings.ProvidesIntoSet;
+
+public class RFC8621MethodsModule extends AbstractModule {
+
+    @Override
+    protected void configure() {
+        Multibinder<Method> methods = Multibinder.newSetBinder(binder(), Method.class);
+        methods.addBinding().to(CoreEcho.class);
+    }
+
+    @ProvidesIntoSet
+    JMAPRoutesHandler routesHandler(JMAPApiRoutes jmapApiRoutes) {
+        return new JMAPRoutesHandler(Version.RFC8621, jmapApiRoutes);
+    }
+}
diff --git a/server/container/guice/protocols/jmap-draft/src/main/java/org/apache/james/modules/protocols/JMAPDraftServerModule.java b/server/container/guice/protocols/jmap/src/main/java/org/apache/james/modules/protocols/JMAPServerModule.java
similarity index 98%
rename from server/container/guice/protocols/jmap-draft/src/main/java/org/apache/james/modules/protocols/JMAPDraftServerModule.java
rename to server/container/guice/protocols/jmap/src/main/java/org/apache/james/modules/protocols/JMAPServerModule.java
index 2ab7049..afd1357 100644
--- a/server/container/guice/protocols/jmap-draft/src/main/java/org/apache/james/modules/protocols/JMAPDraftServerModule.java
+++ b/server/container/guice/protocols/jmap/src/main/java/org/apache/james/modules/protocols/JMAPServerModule.java
@@ -42,7 +42,7 @@ import com.google.inject.AbstractModule;
 import com.google.inject.multibindings.Multibinder;
 import com.google.inject.multibindings.ProvidesIntoSet;
 
-public class JMAPDraftServerModule extends AbstractModule {
+public class JMAPServerModule extends AbstractModule {
 
     @Override
     protected void configure() {
diff --git a/server/container/guice/protocols/jmap-draft/src/main/resources/defaultJmapMailetContainer.xml b/server/container/guice/protocols/jmap/src/main/resources/defaultJmapMailetContainer.xml
similarity index 100%
rename from server/container/guice/protocols/jmap-draft/src/main/resources/defaultJmapMailetContainer.xml
rename to server/container/guice/protocols/jmap/src/main/resources/defaultJmapMailetContainer.xml
diff --git a/server/container/guice/protocols/jmap-draft/src/test/java/org/apache/james/jmap/draft/JMAPModuleTest.java b/server/container/guice/protocols/jmap/src/test/java/org/apache/james/jmap/draft/JMAPModuleTest.java
similarity index 100%
rename from server/container/guice/protocols/jmap-draft/src/test/java/org/apache/james/jmap/draft/JMAPModuleTest.java
rename to server/container/guice/protocols/jmap/src/test/java/org/apache/james/jmap/draft/JMAPModuleTest.java
diff --git a/server/container/guice/protocols/jmap-draft/src/test/java/org/apache/james/jmap/draft/JmapJamesServerContract.java b/server/container/guice/protocols/jmap/src/test/java/org/apache/james/jmap/draft/JmapJamesServerContract.java
similarity index 98%
rename from server/container/guice/protocols/jmap-draft/src/test/java/org/apache/james/jmap/draft/JmapJamesServerContract.java
rename to server/container/guice/protocols/jmap/src/test/java/org/apache/james/jmap/draft/JmapJamesServerContract.java
index 6f965f7..461b0af 100644
--- a/server/container/guice/protocols/jmap-draft/src/test/java/org/apache/james/jmap/draft/JmapJamesServerContract.java
+++ b/server/container/guice/protocols/jmap/src/test/java/org/apache/james/jmap/draft/JmapJamesServerContract.java
@@ -26,7 +26,6 @@ import java.nio.charset.StandardCharsets;
 
 import org.apache.james.GuiceJamesServer;
 import org.apache.james.domainlist.lib.DomainListConfiguration;
-import org.apache.james.jmap.draft.JmapGuiceProbe;
 import org.junit.jupiter.api.BeforeEach;
 import org.junit.jupiter.api.Test;
 
diff --git a/server/container/guice/protocols/jmap-draft/src/test/java/org/apache/james/jmap/draft/MailetPreconditionTest.java b/server/container/guice/protocols/jmap/src/test/java/org/apache/james/jmap/draft/MailetPreconditionTest.java
similarity index 99%
rename from server/container/guice/protocols/jmap-draft/src/test/java/org/apache/james/jmap/draft/MailetPreconditionTest.java
rename to server/container/guice/protocols/jmap/src/test/java/org/apache/james/jmap/draft/MailetPreconditionTest.java
index 62887bc..228538c 100644
--- a/server/container/guice/protocols/jmap-draft/src/test/java/org/apache/james/jmap/draft/MailetPreconditionTest.java
+++ b/server/container/guice/protocols/jmap/src/test/java/org/apache/james/jmap/draft/MailetPreconditionTest.java
@@ -25,7 +25,6 @@ import static org.assertj.core.api.Assertions.assertThatThrownBy;
 import java.util.List;
 
 import org.apache.commons.configuration2.ex.ConfigurationException;
-import org.apache.james.jmap.draft.JMAPModule;
 import org.apache.james.jmap.mailet.VacationMailet;
 import org.apache.james.jmap.mailet.filter.JMAPFiltering;
 import org.apache.james.mailetcontainer.impl.MatcherMailetPair;
diff --git a/server/container/guice/protocols/jmap-draft/src/test/java/org/apache/james/modules/TestJMAPServerModule.java b/server/container/guice/protocols/jmap/src/test/java/org/apache/james/modules/TestJMAPServerModule.java
similarity index 100%
rename from server/container/guice/protocols/jmap-draft/src/test/java/org/apache/james/modules/TestJMAPServerModule.java
rename to server/container/guice/protocols/jmap/src/test/java/org/apache/james/modules/TestJMAPServerModule.java
diff --git a/server/mailet/integration-testing/pom.xml b/server/mailet/integration-testing/pom.xml
index 5996524..4766cb7 100644
--- a/server/mailet/integration-testing/pom.xml
+++ b/server/mailet/integration-testing/pom.xml
@@ -66,7 +66,7 @@
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
-            <artifactId>james-server-guice-jmap-draft</artifactId>
+            <artifactId>james-server-guice-jmap</artifactId>
             <type>test-jar</type>
             <scope>test</scope>
         </dependency>
diff --git a/server/protocols/jmap-draft-integration-testing/cassandra-jmap-draft-integration-testing/pom.xml b/server/protocols/jmap-draft-integration-testing/cassandra-jmap-draft-integration-testing/pom.xml
index 0767503..ae3d02d 100644
--- a/server/protocols/jmap-draft-integration-testing/cassandra-jmap-draft-integration-testing/pom.xml
+++ b/server/protocols/jmap-draft-integration-testing/cassandra-jmap-draft-integration-testing/pom.xml
@@ -140,7 +140,7 @@
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
-            <artifactId>james-server-guice-jmap-draft</artifactId>
+            <artifactId>james-server-guice-jmap</artifactId>
             <type>test-jar</type>
             <scope>test</scope>
         </dependency>
diff --git a/server/protocols/jmap-draft-integration-testing/jmap-draft-integration-testing-common/pom.xml b/server/protocols/jmap-draft-integration-testing/jmap-draft-integration-testing-common/pom.xml
index 249a54d..46e212e 100644
--- a/server/protocols/jmap-draft-integration-testing/jmap-draft-integration-testing-common/pom.xml
+++ b/server/protocols/jmap-draft-integration-testing/jmap-draft-integration-testing-common/pom.xml
@@ -73,7 +73,7 @@
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
-            <artifactId>james-server-guice-jmap-draft</artifactId>
+            <artifactId>james-server-guice-jmap</artifactId>
             <scope>test</scope>
         </dependency>
         <dependency>
diff --git a/server/protocols/jmap-draft-integration-testing/memory-jmap-draft-integration-testing/pom.xml b/server/protocols/jmap-draft-integration-testing/memory-jmap-draft-integration-testing/pom.xml
index ef9d639..f452e7f 100644
--- a/server/protocols/jmap-draft-integration-testing/memory-jmap-draft-integration-testing/pom.xml
+++ b/server/protocols/jmap-draft-integration-testing/memory-jmap-draft-integration-testing/pom.xml
@@ -74,7 +74,7 @@
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
-            <artifactId>james-server-guice-jmap-draft</artifactId>
+            <artifactId>james-server-guice-jmap</artifactId>
             <type>test-jar</type>
             <scope>test</scope>
         </dependency>
diff --git a/server/protocols/jmap-draft-integration-testing/rabbitmq-jmap-draft-integration-testing/pom.xml b/server/protocols/jmap-draft-integration-testing/rabbitmq-jmap-draft-integration-testing/pom.xml
index e05b983..4260711 100644
--- a/server/protocols/jmap-draft-integration-testing/rabbitmq-jmap-draft-integration-testing/pom.xml
+++ b/server/protocols/jmap-draft-integration-testing/rabbitmq-jmap-draft-integration-testing/pom.xml
@@ -113,7 +113,7 @@
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
-            <artifactId>james-server-guice-jmap-draft</artifactId>
+            <artifactId>james-server-guice-jmap</artifactId>
             <type>test-jar</type>
             <scope>test</scope>
         </dependency>
diff --git a/server/protocols/webadmin-integration-test/webadmin-integration-test-common/pom.xml b/server/protocols/webadmin-integration-test/webadmin-integration-test-common/pom.xml
index 235c24e..43f31ca 100644
--- a/server/protocols/webadmin-integration-test/webadmin-integration-test-common/pom.xml
+++ b/server/protocols/webadmin-integration-test/webadmin-integration-test-common/pom.xml
@@ -74,7 +74,7 @@
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
-            <artifactId>james-server-guice-jmap-draft</artifactId>
+            <artifactId>james-server-guice-jmap</artifactId>
             <type>test-jar</type>
         </dependency>
         <dependency>
@@ -83,7 +83,7 @@
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>
-            <artifactId>james-server-guice-jmap-draft</artifactId>
+            <artifactId>james-server-guice-jmap</artifactId>
         </dependency>
         <dependency>
             <groupId>${james.groupId}</groupId>


---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org


[james-project] 06/06: JAMES-3168: remove unused property 'message_limit' for integration testing jmap rfc after rebase

Posted by rc...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rcordier pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/james-project.git

commit 4edb31b8291341a109e8625676cd41cd6b4793b8
Author: ducnv <du...@gmail.com>
AuthorDate: Sun May 17 16:53:00 2020 +0700

    JAMES-3168: remove unused property 'message_limit' for integration testing jmap rfc after rebase
---
 .../james/jmap/rfc8621/memory/MemoryEchoMethodTest.java   |  3 +--
 .../src/test/resources/imapserver.xml                     | 15 ---------------
 2 files changed, 1 insertion(+), 17 deletions(-)

diff --git a/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/java/org/apache/james/jmap/rfc8621/memory/MemoryEchoMethodTest.java b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/java/org/apache/james/jmap/rfc8621/memory/MemoryEchoMethodTest.java
index 7108a6b..f7aa3c7 100644
--- a/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/java/org/apache/james/jmap/rfc8621/memory/MemoryEchoMethodTest.java
+++ b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/java/org/apache/james/jmap/rfc8621/memory/MemoryEchoMethodTest.java
@@ -20,7 +20,6 @@
 package org.apache.james.jmap.rfc8621.memory;
 
 import static org.apache.james.MemoryJamesServerMain.IN_MEMORY_SERVER_AGGREGATE_MODULE;
-import static org.apache.james.modules.TestJMAPServerModule.LIMIT_TO_20_MESSAGES;
 
 import org.apache.james.GuiceJamesServer;
 import org.apache.james.JamesServerBuilder;
@@ -34,6 +33,6 @@ public class MemoryEchoMethodTest implements EchoMethodContract {
     static JamesServerExtension testExtension = new JamesServerBuilder()
         .server(configuration -> GuiceJamesServer.forConfiguration(configuration)
             .combineWith(IN_MEMORY_SERVER_AGGREGATE_MODULE)
-            .overrideWith(TestJMAPServerModule.maximumMessages(LIMIT_TO_20_MESSAGES)))
+            .overrideWith(new TestJMAPServerModule()))
         .build();
 }
diff --git a/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/imapserver.xml b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/imapserver.xml
index aa7c2fb..ead2b34 100644
--- a/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/imapserver.xml
+++ b/server/protocols/jmap-rfc-8621-integration-tests/memory-jmap-rfc-8621-integration-tests/src/test/resources/imapserver.xml
@@ -21,19 +21,4 @@ under the License.
 
 
 <imapservers>
-    <imapserver enabled="true">
-        <jmxName>imapserver</jmxName>
-        <bind>0.0.0.0:0</bind>
-        <connectionBacklog>200</connectionBacklog>
-        <tls socketTLS="false" startTLS="false">
-            <!-- To create a new keystore execute:
-            keytool -genkey -alias james -keyalg RSA -keystore /path/to/james/conf/keystore
-              -->
-            <keystore>file://conf/keystore</keystore>
-            <secret>james72laBalle</secret>
-            <provider>org.bouncycastle.jce.provider.BouncyCastleProvider</provider>
-        </tls>
-        <connectionLimit>0</connectionLimit>
-        <connectionLimitPerIP>0</connectionLimitPerIP>
-    </imapserver>
 </imapservers>


---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org