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 bt...@apache.org on 2017/06/14 08:06:16 UTC

[01/21] james-project git commit: JAMES-1789 Webadmin now supports quota

Repository: james-project
Updated Branches:
  refs/heads/master 28cfa6d6f -> 6f2af02ba


JAMES-1789 Webadmin now supports quota


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/e3ed1ec5
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/e3ed1ec5
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/e3ed1ec5

Branch: refs/heads/master
Commit: e3ed1ec52aa1ff18bcfbf12f99d53733144fe2bb
Parents: 689ec5c
Author: benwa <bt...@linagora.com>
Authored: Thu Jun 8 20:17:02 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 14:55:17 2017 +0700

----------------------------------------------------------------------
 server/protocols/webadmin/README.adoc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/e3ed1ec5/server/protocols/webadmin/README.adoc
----------------------------------------------------------------------
diff --git a/server/protocols/webadmin/README.adoc b/server/protocols/webadmin/README.adoc
index 56d0032..34f69e3 100644
--- a/server/protocols/webadmin/README.adoc
+++ b/server/protocols/webadmin/README.adoc
@@ -1,6 +1,6 @@
 = Web administration for JAMES
 
-The web administration supports for now the CRUD operations on the domains, the users and the users mailboxes, as described in the following sections.
+The web administration supports for now the CRUD operations on the domains, the users and the users mailboxes, and quotas, as described in the following sections.
 
 **WARNING**: This API allow authentication only via the use of JWT. It means that, otherwise, an administrator should ensure an attacker can not use this API.
 


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


[07/21] james-project git commit: JAMES-1789 Improve CLI message readability with better case

Posted by bt...@apache.org.
JAMES-1789 Improve CLI message readability with better case


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/e7271034
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/e7271034
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/e7271034

Branch: refs/heads/master
Commit: e7271034b3bf0af767d6aab2c8bd0e296b0f6a0a
Parents: 6d57db0
Author: benwa <bt...@linagora.com>
Authored: Thu Jun 8 22:41:33 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:30 2017 +0700

----------------------------------------------------------------------
 .../java/org/apache/james/cli/type/CmdType.java | 76 ++++++++++----------
 .../org/apache/james/cli/type/CmdTypeTest.java  |  2 +-
 2 files changed, 39 insertions(+), 39 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/e7271034/server/container/cli/src/main/java/org/apache/james/cli/type/CmdType.java
----------------------------------------------------------------------
diff --git a/server/container/cli/src/main/java/org/apache/james/cli/type/CmdType.java b/server/container/cli/src/main/java/org/apache/james/cli/type/CmdType.java
index 3876699..ef192a6 100644
--- a/server/container/cli/src/main/java/org/apache/james/cli/type/CmdType.java
+++ b/server/container/cli/src/main/java/org/apache/james/cli/type/CmdType.java
@@ -22,44 +22,44 @@ package org.apache.james.cli.type;
  * Enumeration of valid command types.
  */
 public enum CmdType {
-    ADDUSER("adduser", "username","password"),
-    REMOVEUSER("removeuser", "username"),
-    LISTUSERS("listusers"),
-    ADDDOMAIN("adddomain", "domainname"),
-    REMOVEDOMAIN("removedomain", "domainname"),
-    CONTAINSDOMAIN("containsdomain", "domainname"),
-    LISTDOMAINS("listdomains"),
-    LISTMAPPINGS("listmappings"),
-    LISTUSERDOMAINMAPPINGS("listuserdomainmappings", "user","domain"),
-    ADDADDRESSMAPPING("addaddressmapping", "user","domain", "fromaddress"),
-    REMOVEADDRESSMAPPING("removeaddressmapping", "user","domain", "fromaddress"),
-    ADDREGEXMAPPING("addregexmapping", "user","domain", "regex"),
-    REMOVEREGEXMAPPING("removeregexmapping", "user","domain", "regex"),
-    SETPASSWORD("setpassword", "username","password"),
-    COPYMAILBOX("copymailbox", "srcbean","dstbean"),
-    DELETEUSERMAILBOXES("deleteusermailboxes", "user"),
-    CREATEMAILBOX("createmailbox", "namespace", "user", "name"),
-    LISTUSERMAILBOXES("listusermailboxes", "user"),
-    DELETEMAILBOX("deletemailbox", "namespace", "user", "name"),
-    GETSTORAGEQUOTA("getstoragequota", "quotaroot"),
-    GETMESSAGECOUNTQUOTA("getmessagecountquota", "quotaroot"),
-    GETQUOTAROOT("getquotaroot", "namespace", "user", "name"),
-    GETMAXSTORAGEQUOTA("getmaxstoragequota", "quotaroot"),
-    GETMAXMESSAGECOUNTQUOTA("getmaxmessagecountquota", "quotaroot"),
-    SETMAXSTORAGEQUOTA("setmaxstoragequota", "quotaroot", "max_message_count"),
-    SETMAXMESSAGECOUNTQUOTA("setmaxmessagecountquota", "quotaroot", "max_storage"),
-    SETDEFAULTMAXSTORAGEQUOTA("setdefaultmaxstoragequota", "max_storage"),
-    SETDEFAULTMAXMESSAGECOUNTQUOTA("setdefaultmaxmessagecountquota", "max_message_count"),
-    GETDEFAULTMAXSTORAGEQUOTA("getdefaultmaxstoragequota"),
-    GETDEFAULTMAXMESSAGECOUNTQUOTA("getdefaultmaxmessagecountquota"),
-    REINDEXMAILBOX("reindexmailbox", "namespace", "user", "name"),
-    REINDEXALL("reindexall"),
-    GETSIEVEQUOTA("getsievequota"),
-    SETSIEVEQUOTA("setsievequota", "quota"),
-    REMOVESIEVEQUOTA("removesievequota"),
-    GETSIEVEUSERQUOTA("getsieveuserquota", "username"),
-    SETSIEVEUSERQUOTA("setsieveuserquota", "username", "quota"),
-    REMOVESIEVEUSERQUOTA("removesieveuserquota", "username");
+    ADDUSER("AddUser", "username","password"),
+    REMOVEUSER("RemoveUser", "username"),
+    LISTUSERS("ListUsers"),
+    ADDDOMAIN("AddDomain", "domainName"),
+    REMOVEDOMAIN("RemoveDomain", "domainName"),
+    CONTAINSDOMAIN("ContainsDomain", "domainName"),
+    LISTDOMAINS("ListDomains"),
+    LISTMAPPINGS("ListMappings"),
+    LISTUSERDOMAINMAPPINGS("ListUserDomainMappings", "user","domain"),
+    ADDADDRESSMAPPING("AddAddressMapping", "user","domain", "fromAddress"),
+    REMOVEADDRESSMAPPING("RemoveAddressMapping", "user","domain", "fromAddress"),
+    ADDREGEXMAPPING("AddRegexMapping", "user","domain", "regex"),
+    REMOVEREGEXMAPPING("RemoveRegexMapping", "user","domain", "regex"),
+    SETPASSWORD("SetPassword", "username","password"),
+    COPYMAILBOX("CopyMailbox", "srcBean","dstBean"),
+    DELETEUSERMAILBOXES("DeleteUserMailboxes", "user"),
+    CREATEMAILBOX("CreateMailbox", "namespace", "user", "name"),
+    LISTUSERMAILBOXES("ListUserMailboxes", "user"),
+    DELETEMAILBOX("DeleteMailbox", "namespace", "user", "name"),
+    GETSTORAGEQUOTA("GetStorageQuota", "quotaroot"),
+    GETMESSAGECOUNTQUOTA("GetMessageCountQuota", "quotaroot"),
+    GETQUOTAROOT("GetQuotaroot", "namespace", "user", "name"),
+    GETMAXSTORAGEQUOTA("GetMaxStorageQuota", "quotaroot"),
+    GETMAXMESSAGECOUNTQUOTA("GetMaxMessageCountQuota", "quotaroot"),
+    SETMAXSTORAGEQUOTA("SetMaxStorageQuota", "quotaroot", "max_message_count"),
+    SETMAXMESSAGECOUNTQUOTA("SetMaxMessageCountQuota", "quotaroot", "max_storage"),
+    SETDEFAULTMAXSTORAGEQUOTA("SetDefaultMaxStorageQuota", "max_storage"),
+    SETDEFAULTMAXMESSAGECOUNTQUOTA("SetDefaultMaxMessageCountQuota", "max_message_count"),
+    GETDEFAULTMAXSTORAGEQUOTA("GetDefaultMaxStorageQuota"),
+    GETDEFAULTMAXMESSAGECOUNTQUOTA("GetDefaultMaxMessageCountQuota"),
+    REINDEXMAILBOX("ReindexMailbox", "namespace", "user", "name"),
+    REINDEXALL("ReindexAll"),
+    GETSIEVEQUOTA("GetSieveQuota"),
+    SETSIEVEQUOTA("SetSieveQuota", "quota"),
+    REMOVESIEVEQUOTA("RemoveSieveQuota"),
+    GETSIEVEUSERQUOTA("GetSieveUserQuota", "username"),
+    SETSIEVEUSERQUOTA("SetSieveUserQuota", "username", "quota"),
+    REMOVESIEVEUSERQUOTA("RemoveSieveUserQuota", "username");
 
     private final String command;
     private final String[] arguments;

http://git-wip-us.apache.org/repos/asf/james-project/blob/e7271034/server/container/cli/src/test/java/org/apache/james/cli/type/CmdTypeTest.java
----------------------------------------------------------------------
diff --git a/server/container/cli/src/test/java/org/apache/james/cli/type/CmdTypeTest.java b/server/container/cli/src/test/java/org/apache/james/cli/type/CmdTypeTest.java
index e38a81f..3d66295 100644
--- a/server/container/cli/src/test/java/org/apache/james/cli/type/CmdTypeTest.java
+++ b/server/container/cli/src/test/java/org/apache/james/cli/type/CmdTypeTest.java
@@ -245,7 +245,7 @@ public class CmdTypeTest {
     
     @Test
     public void usageShouldOutputCommandNamesAndArguments() {
-        assertThat(CmdType.CREATEMAILBOX.getUsage()).isEqualTo("createmailbox <namespace> <user> <name>");
+        assertThat(CmdType.CREATEMAILBOX.getUsage()).isEqualTo("CreateMailbox <namespace> <user> <name>");
     }
     
 }
\ 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


[02/21] james-project git commit: JAMES-1789 Webadmin now supports authentication via JWT

Posted by bt...@apache.org.
JAMES-1789 Webadmin now supports authentication via JWT


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/689ec5ca
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/689ec5ca
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/689ec5ca

Branch: refs/heads/master
Commit: 689ec5ca35afc3da26174d589726fa61a9d187d8
Parents: 28cfa6d
Author: benwa <bt...@linagora.com>
Authored: Thu Jun 8 20:16:28 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 14:55:17 2017 +0700

----------------------------------------------------------------------
 server/protocols/webadmin/README.adoc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/689ec5ca/server/protocols/webadmin/README.adoc
----------------------------------------------------------------------
diff --git a/server/protocols/webadmin/README.adoc b/server/protocols/webadmin/README.adoc
index c4ab9ae..56d0032 100644
--- a/server/protocols/webadmin/README.adoc
+++ b/server/protocols/webadmin/README.adoc
@@ -2,7 +2,7 @@
 
 The web administration supports for now the CRUD operations on the domains, the users and the users mailboxes, as described in the following sections.
 
-**WARNING**: This API do not allow authentication for now. It means that an administrator should ensure an attacker can not use this API.
+**WARNING**: This API allow authentication only via the use of JWT. It means that, otherwise, an administrator should ensure an attacker can not use this API.
 
 == Administrating domains
 


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


[05/21] james-project git commit: JAMES-1789 Remove documentation from the sources for webadmin

Posted by bt...@apache.org.
JAMES-1789 Remove documentation from the sources for webadmin


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/39bd19d0
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/39bd19d0
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/39bd19d0

Branch: refs/heads/master
Commit: 39bd19d010231b6eee2defb65d0bc284025b47f3
Parents: 27118d1
Author: benwa <bt...@linagora.com>
Authored: Thu Jun 8 20:26:00 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:25 2017 +0700

----------------------------------------------------------------------
 server/protocols/webadmin/README.adoc | 358 -----------------------------
 1 file changed, 358 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/39bd19d0/server/protocols/webadmin/README.adoc
----------------------------------------------------------------------
diff --git a/server/protocols/webadmin/README.adoc b/server/protocols/webadmin/README.adoc
deleted file mode 100644
index 34f69e3..0000000
--- a/server/protocols/webadmin/README.adoc
+++ /dev/null
@@ -1,358 +0,0 @@
-= Web administration for JAMES
-
-The web administration supports for now the CRUD operations on the domains, the users and the users mailboxes, and quotas, as described in the following sections.
-
-**WARNING**: This API allow authentication only via the use of JWT. It means that, otherwise, an administrator should ensure an attacker can not use this API.
-
-== Administrating domains
-
-=== Create a domain
-
-.bash
-====
-curl -XPUT http://ip:port/domains/domainToBeCreated
-====
-
-Resource name domainToBeCreated:
-
- - can not be null or empty
- - can not contain '@'
- - can not be more than 255 characters
- - can not contain '/'
-
-Response codes:
-
- - 204: The domain was successfully added
- - 400: The domain name is invalid
- - 500: Internal error while adding the domain
-
-=== Delete a domain
-
-.bash
-====
-curl -XDELETE http://ip:port/domains/domainToBeDeleted
-====
-
-Response codes:
-
- - 204: The domain was successfully removed
- - 500: Internal error while removing the domain
-
-=== Test if a domain exists
-
-.bash
-====
-curl -XGET http://ip:port/domains/domainName
-====
-
-Response codes:
-
- - 204: The domains exists
- - 404: The domain does not exist
- - 500: Internal error while accessing the domains
-
-=== Get the list of domains
-
-.bash
-====
-curl -XGET http://ip:port/domains
-====
-
-Possible response:
-
-.json
-====
-{"domains":["domain1", "domain2"]}
-====
-
-Response codes:
-
- - 200: The domain list was successfully retrieved
- - 500: Internal error while accessing the domains
-
-== Administrating users
-
-=== Create a user
-
-.bash
-====
-curl -XPUT http://ip:port/users/usernameToBeUsed -d '{"password":"passwordToBeUsed"}'
-====
-
-Resource name usernameToBeUsed:
-
- - can not be null or empty
- - can not be more than 255 characters
- - can not contain '/'
-
-Response codes:
-
- - 204: The user was successfully created
- - 400: The user name or the payload is invalid
- - 409: Conflict: A concurrent modification make that query to fail
- - 500: Internal error while adding the user
-
-Note: if the user is already, its password will be updated.
-
-=== Updating a user password
-
-Same than Create, but a user need to exist.
-
-If the user do not exist, then it will be created.
-
-=== Deleting a user
-
-.bash
-====
-curl -XDELETE http://ip:port/users/userToBeDeleted
-====
-
-Response codes:
-
- - 204: The user was successfully deleted
- - 500: Internal error while deleting the user
-
-=== Retrieving the user list
-
-.bash
-====
-curl -XGET http://ip:port/users
-====
-
-The answer looks like:
-
-.json
-====
-[{"username":"username@domain-jmapauthentication.tld"},{"username":"username@domain.tld"}]
-====
-
-Response codes:
-
- - 200: The user name list was successfully retrieved
- - 500: Internal error while retrieving the users
-
-== Administrating user mailboxes
-
-=== Creating a mailbox
-
-.bash
-====
-curl -XPUT http://ip:port/users/usernameToBeUsed/mailboxes/mailboxNameToBeCreated
-====
-
-Resource name usernameToBeUsed should be an existing user
-Resource name mailboxNameToBeCreated should not be empty, nor contain # & % * characters.
-
-Response codes:
-
- - 204: The mailbox now exists on the server
- - 400: Invalid mailbox name
- - 404: The user name does not exist
- - 500: Internal error
-
- To create nested mailboxes, for instance a work mailbox inside the INBOX mailbox, people should use the . separator. The sample query is:
-
- .bash
- ====
- curl -XDELETE http://ip:port/users/usernameToBeUsed/mailboxes/INBOX.work
- ====
-
-=== Deleting a mailbox and its children
-
-.bash
-====
-curl -XDELETE http://ip:port/users/usernameToBeUsed/mailboxes/mailboxNameToBeCreated
-====
-
-Resource name usernameToBeUsed should be an existing user
-Resource name mailboxNameToBeCreated should not be empty
-
-Response codes:
-
- - 204: The mailbox now does not exist on the server
- - 400: Invalid mailbox name
- - 404: The user name does not exist
- - 500: Internal error
-
-=== Testing existence of a mailbox
-
-.bash
-====
-curl -XGET http://ip:port/users/usernameToBeUsed/mailboxes/mailboxNameToBeCreated
-====
-
-Resource name usernameToBeUsed should be an existing user
-Resource name mailboxNameToBeCreated should not be empty
-
-Response codes:
-
- - 204: The mailbox exists
- - 400: Invalid mailbox name
- - 404: The user name does not exist, the mailbox does not exist
- - 500: Internal error
-
-=== Listing user mailboxes
-
-.bash
-====
-curl -XGET http://ip:port/users/usernameToBeUsed/mailboxes
-====
-
-The answer looks like:
-
-.json
-====
-[{"mailboxName":"INBOX"},{"mailboxName":"outbox"}]
-====
-
-Resource name usernameToBeUsed should be an existing user
-
-Response codes:
-
- - 200: The mailboxes list was successfully retrieved
- - 404: The user name does not exist
- - 500: Internal error
-
-=== Deleting user mailboxes
-
-.bash
-====
-curl -XDELETE http://ip:port/users/usernameToBeUsed/mailboxes
-====
-
-Resource name usernameToBeUsed should be an existing user
-
-Response codes:
-
- - 204: The user do not have mailboxes anymore
- - 404: The user name does not exist
- - 500: Internal error
-
-== Administrating quotas
-
-A quota with a value of -1 means unlimited
-
-=== Reading per quotaroot mail count limitation
-
-.bash
-====
-curl -XGET http://ip:port/quota/count
-====
-
-The answer looks like:
-
-.json
-====
-100000
-====
-
-Response codes:
- - 200: Nothing special
- - 500: Internal error
-
-=== Updating per quotaroot mail count limitation
-
-.bash
-====
-curl -XPUT http://ip:port/quota/count -d '1024000000'
-====
-
-Response codes:
-
- - 204: Value updated
- - 400: The body is not a positive integer
- - 500: Internal error
-
-=== Removing per quotaroot mail count limitation
-
-It removes the limitation, and the quota becomes UNILIMITED.
-
-.bash
-====
-curl -XPUT http://ip:port/quota/count -d '1024000000'
-====
-
-Response codes:
-
- - 204: Value updated to UNLIMITED
- - 500: Internal error
-
-=== Reading per quotaroot size limitation
-
-.bash
-====
-curl -XGET http://ip:port/quota/size
-====
-
-The answer looks like:
-
-.json
-====
-100000
-====
-
-It represent the allowed Byte count of the mailboxes belonging to this quotaroot.
-
-Response codes:
-
- - 200: Nothing special
- - 500: Internal error
-
-=== Updating per quotaroot size limitation
-
-.bash
-====
-curl -XPUT http://ip:port/quota/size -d '1024000000'
-====
-
-Response codes:
-
- - 204: Value updated
- - 400: The body is not a positive integer
- - 500: Internal error
-
-=== Removing per quotaroot size limitation
-
-It removes the limitation, and the quota becomes UNILIMITED.
-
-.bash
-====
-curl -XPUT http://ip:port/quota/size -d '1024000000'
-====
-
-Response codes:
-
- - 204: Value updated to UNLIMITED
- - 500: Internal error
-
-=== Managing count and size at the same time
-
-.bash
-====
-curl -XGET http://ip:port/quota/
-====
-
-Will return:
-
-.json
-====
-{"count":52,"size":42}
-====
-
-Response codes:
-
- - 200: Success
- - 500: Internal error
-
-You can also write the value the same way:
-
-.bash
-====
-curl -XPUT http://ip:port/quota/ -d '{"count":52,"size":42}'
-====
-
-Response codes:
-
- - 204: Success
- - 400: Invalid JSON, or numbers are less than -1.
- - 500: Internal error
\ 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


[21/21] james-project git commit: JAMES-1789 Document virtual hosting

Posted by bt...@apache.org.
JAMES-1789 Document virtual hosting


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/671a5eda
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/671a5eda
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/671a5eda

Branch: refs/heads/master
Commit: 671a5eda4bbf7ca1d122eeedf6be5f7dcf8083b0
Parents: dcb7c96
Author: benwa <bt...@linagora.com>
Authored: Mon Jun 12 18:02:04 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:53 2017 +0700

----------------------------------------------------------------------
 src/site/markdown/server/manage-cli.md | 28 +++++++++++++++++++++++++++-
 1 file changed, 27 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/671a5eda/src/site/markdown/server/manage-cli.md
----------------------------------------------------------------------
diff --git a/src/site/markdown/server/manage-cli.md b/src/site/markdown/server/manage-cli.md
index 5003828..51abed8 100644
--- a/src/site/markdown/server/manage-cli.md
+++ b/src/site/markdown/server/manage-cli.md
@@ -51,6 +51,8 @@ And list your domains:
 
 ## Managing users
 
+Note: the following commands are explained with virtual hosting turned on.
+
 Users are accounts on the mail server. James can maintain mailboxes for them.
 
 You can add a user:
@@ -83,6 +85,30 @@ Finally, you can list users:
 {cli} ListUsers
 ```
 
+### Virtual hosting
+
+James supports virtualhosting.
+
+ - If set to true in the configuration, then the username is the full mail address.
+
+The domains then become a part of the user.
+
+*usera@domaina.com and* *usera@domainb.com* on a mail server with *domaina.com* and *domainb.com* configured are mail addresses that belongs to different users.
+
+ - If set to false in the configurations, then the username is the mail address local part.
+
+It means that a user  is automatically created for all the domains configured on your server.
+
+*usera@domaina.com and* *usera@domainb.com* on a mail server with *domaina.com* and *domainb.com* configured are mail addresses that belongs to the same users.
+
+Here are some sample commands for managing users when virtual hosting is turned off:
+
+```
+{cli} AddUser user password
+{cli} RemoveUser user
+{cli} SetPassword user password
+```
+
 ## Managing mailboxes
 
 An administrator can perform some basic operation on user mailboxes.
@@ -90,7 +116,7 @@ An administrator can perform some basic operation on user mailboxes.
 Note on mailbox formatting: mailboxes are composed of three parts.
 
  - The namespace, indicating what kind of mailbox it is. (Shared or not?). The value for users mailboxes is #private . Note that for now no other values are supported as James do not support shared mailboxes.
- - The username.
+ - The username as stated above, depending on the virtual hosting value.
  - And finally mailbox name. Be aware that '.' serves as mailbox hierarchy delimiter.
 
 An administrator can delete all of the mailboxes of a user, which is not done automatically when removing a user (to avoid data loss):


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


[10/21] james-project git commit: JAMES-1789 Update James Guice configuration speech

Posted by bt...@apache.org.
JAMES-1789 Update James Guice configuration speech


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/64c2b06f
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/64c2b06f
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/64c2b06f

Branch: refs/heads/master
Commit: 64c2b06f968619859f38eea1b6842112e4ef5459
Parents: 75bb019
Author: benwa <bt...@linagora.com>
Authored: Sat Jun 10 10:26:54 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:40 2017 +0700

----------------------------------------------------------------------
 src/site/xdoc/server/config-guice.xml | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/64c2b06f/src/site/xdoc/server/config-guice.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/config-guice.xml b/src/site/xdoc/server/config-guice.xml
index 20559e6..d776729 100644
--- a/src/site/xdoc/server/config-guice.xml
+++ b/src/site/xdoc/server/config-guice.xml
@@ -27,13 +27,15 @@
 
   <section name="Guice configure Apache James Server">
 
-    <p>Such configuration is only developed for Cassandra backend.</p>
+    <p>Such configuration only applies to Guice packaging.</p>
+
     <p>You are encouraged to contribute by developing a new backend guice module.
-       Have a look to the <i>james-server-cassandra-guice</i> artifact.
+       Have a look to the <i>james-server-cassandra-guice</i> artifact. This can easily be done
+      as a third party application.
     </p>
 
-    <p>We provide a sample-configuration folder with needed files to run James. 
-      You can start by copying it and modify these files according to your needs.</p>
+    <p>We provide a tested configuration for docker environment, for each Guice artifact, which can be a good base for your own configuration.
+       Have a look on <a href="https://github.com/apache/james-project/tree/master/dockerfiles/run/guice">GitHub</a>. </p>
 
     <p>You can/must configure James for the following:</p>
 


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


[11/21] james-project git commit: JAMES-1789 Update guice config link to point dockerfiles

Posted by bt...@apache.org.
JAMES-1789 Update guice config link to point dockerfiles


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/75bb019f
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/75bb019f
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/75bb019f

Branch: refs/heads/master
Commit: 75bb019f37b71328f74e41ed7cfb9429151961de
Parents: 6782b96
Author: benwa <bt...@linagora.com>
Authored: Sat Jun 10 10:23:17 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:40 2017 +0700

----------------------------------------------------------------------
 src/site/xdoc/server/config-cassandra.xml |  2 +-
 src/site/xdoc/server/config-guice.xml     | 16 ++++++++--------
 2 files changed, 9 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/75bb019f/src/site/xdoc/server/config-cassandra.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/config-cassandra.xml b/src/site/xdoc/server/config-cassandra.xml
index 61ed173..2be8cd8 100644
--- a/src/site/xdoc/server/config-cassandra.xml
+++ b/src/site/xdoc/server/config-cassandra.xml
@@ -29,7 +29,7 @@
 
     Note: Cassandra is only available with Guice distributions (cassandra-guice and cassandra-guice-ldap).
 
-    <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/cassandra-template.properties">cassandra-template.properties</a> to get some examples and hints.</p>
+    <p>Consult <a href="https://github.com/apache/james-project/blob/master/dockerfiles/run/guice/cassandra/destination/conf/cassandra.properties">cassandra-template.properties</a> to get some examples and hints.</p>
 
       <dl>
         <dt><strong>cassandra.nodes</strong></dt>

http://git-wip-us.apache.org/repos/asf/james-project/blob/75bb019f/src/site/xdoc/server/config-guice.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/config-guice.xml b/src/site/xdoc/server/config-guice.xml
index 81dc1b6..20559e6 100644
--- a/src/site/xdoc/server/config-guice.xml
+++ b/src/site/xdoc/server/config-guice.xml
@@ -46,42 +46,42 @@
       </tr>
 
       <tr>
-        <td><a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/cassandra-template.properties">cassandra-template.properties</a></td>
+        <td><a href="https://github.com/apache/james-project/blob/master/dockerfiles/run/guice/cassandra/destination/conf/cassandra.properties">cassandra-template.properties</a></td>
         <td><a href="config-cassandra.html">Cassandra Configuration</a></td>
         <td></td>
       </tr>
       <tr>
-        <td><a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/dnsservice-template.xml">dnsservice.xml</a></td>
+        <td><a href="https://github.com/apache/james-project/blob/master/dockerfiles/run/guice/cassandra/destination/conf/dnsservice.xml">dnsservice.xml</a></td>
         <td><a href="config-dnsservice.html">DNS Service Configuration</a></td>
         <td></td>
       </tr>
       <tr>
-        <td><a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/elasticsearch-template.properties">elasticsearch-template.properties</a></td>
+        <td><a href="https://github.com/apache/james-project/blob/master/dockerfiles/run/guice/cassandra/destination/conf/elasticsearch.properties">elasticsearch-template.properties</a></td>
         <td><a href="config-elasticsearch.html">ElasticSearch Configuration</a></td>
         <td></td>
       </tr>
       <tr>
-        <td><a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/imapserver-template.xml">imapserver.xml</a></td>
+        <td><a href="https://github.com/apache/james-project/blob/master/dockerfiles/run/guice/cassandra/destination/conf/imapserver.xml">imapserver.xml</a></td>
         <td><a href="config-imap4.html">IMAP4 Configuration</a></td>
         <td></td>
       </tr>
       <tr>
-        <td><a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/lmtpserver-template.xml">lmtpserver.xml</a></td>
+        <td><a href="https://github.com/apache/james-project/blob/master/dockerfiles/run/guice/cassandra/destination/conf/lmtpserver.xml">lmtpserver.xml</a></td>
         <td><a href="config-smtp-lmtp.html">LMTP Configuration</a></td>
         <td></td>
       </tr>
       <tr>
-        <td><a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/mailetcontainer-template.xml">mailetcontainer.xml</a></td>
+        <td><a href="https://github.com/apache/james-project/blob/master/dockerfiles/run/guice/cassandra/destination/conf/mailetcontainer.xml">mailetcontainer.xml</a></td>
         <td><a href="config-mailetcontainer.html">Mailet Container Configuration</a></td>
         <td></td>
       </tr>
       <tr>
-        <td><a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/pop3server-template.xml">pop3server.xml</a></td>
+        <td><a href="https://github.com/apache/james-project/blob/master/dockerfiles/run/guice/cassandra/destination/conf/pop3server.xml">pop3server.xml</a></td>
         <td><a href="config-pop3.html">POP3 Configuration</a></td>
         <td></td>
       </tr>
       <tr>
-        <td><a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/smtpserver-template.xml">smtpserver.xml</a></td>
+        <td><a href="https://github.com/apache/james-project/blob/master/dockerfiles/run/guice/cassandra/destination/conf/smtpserver.xml">smtpserver.xml</a></td>
         <td><a href="config-smtp-lmtp.html">SMTP Configuration</a></td>
         <td></td>
       </tr>


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


[18/21] james-project git commit: JAMES-1789 jpa-smtp does not supports CLI

Posted by bt...@apache.org.
JAMES-1789 jpa-smtp does not supports CLI


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/dcb7c968
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/dcb7c968
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/dcb7c968

Branch: refs/heads/master
Commit: dcb7c968d35c7e6a0a5c1071fa8c03a1616854b4
Parents: e1140e4
Author: benwa <bt...@linagora.com>
Authored: Mon Jun 12 17:43:16 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:53 2017 +0700

----------------------------------------------------------------------
 src/site/xdoc/server/packaging.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/dcb7c968/src/site/xdoc/server/packaging.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/packaging.xml b/src/site/xdoc/server/packaging.xml
index 247e8ce..fffa283 100644
--- a/src/site/xdoc/server/packaging.xml
+++ b/src/site/xdoc/server/packaging.xml
@@ -135,7 +135,7 @@
                         <td>Yes</td>
                         <td>Yes</td>
                         <td>Yes</td>
-                        <td>Yes</td>
+                        <td>No</td>
                     </tr>
                     <tr>
                         <td>Supports WebAdmin</td>


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


[16/21] james-project git commit: JAMES-1789 Cassandra is not supported anymore with Spring

Posted by bt...@apache.org.
JAMES-1789 Cassandra is not supported anymore with Spring


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/4cbed35a
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/4cbed35a
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/4cbed35a

Branch: refs/heads/master
Commit: 4cbed35a2ca16235713d162eb688688438fb4325
Parents: fcfb1f7
Author: benwa <bt...@linagora.com>
Authored: Sat Jun 10 11:03:07 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:49 2017 +0700

----------------------------------------------------------------------
 src/site/xdoc/server/config-mailbox.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/4cbed35a/src/site/xdoc/server/config-mailbox.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/config-mailbox.xml b/src/site/xdoc/server/config-mailbox.xml
index d556a64..e575a8a 100644
--- a/src/site/xdoc/server/config-mailbox.xml
+++ b/src/site/xdoc/server/config-mailbox.xml
@@ -37,7 +37,7 @@
 
       <dl>
         <dt><strong>provider</strong></dt>
-        <dd>Supported providers are: jpa (default), jcr, maildir, cassandra, memory. Be aware that maildir will only work on unix like operation systems!
+        <dd>Supported providers are: jpa (default), jcr, maildir, memory. Be aware that maildir will only work on unix like operation systems!
         Cassandra mailbox need to be compiled and run using java 8.</dd>
       </dl>
 


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


[17/21] james-project git commit: JAMES-1789 Add information about packaging

Posted by bt...@apache.org.
JAMES-1789 Add information about packaging


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/b1a812eb
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/b1a812eb
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/b1a812eb

Branch: refs/heads/master
Commit: b1a812eb0893a55dd3a01ffca5296342a637844b
Parents: 4cbed35
Author: benwa <bt...@linagora.com>
Authored: Sat Jun 10 11:32:08 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:49 2017 +0700

----------------------------------------------------------------------
 src/site/site.xml                  |  13 +-
 src/site/xdoc/server/packaging.xml | 202 ++++++++++++++++++++++++++++++++
 2 files changed, 209 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/b1a812eb/src/site/site.xml
----------------------------------------------------------------------
diff --git a/src/site/site.xml b/src/site/site.xml
index aca55d8..e523974 100644
--- a/src/site/site.xml
+++ b/src/site/site.xml
@@ -113,8 +113,9 @@
                         <item name="Performance" href="/server/feature-performance.html" />
                         <item name="Security" href="/server/feature-security.html" />
                     </item>
-                    <item name="2. Install James" href="/server/install.html" />
-                    <item name="3. Configure James" href="/server/config.html" collapse="true" >
+                    <item name="2. Packaging" href="/server/packaging.html" />
+                    <item name="3. Install James" href="/server/install.html" />
+                    <item name="4. Configure James" href="/server/config.html" collapse="true" >
                         <item name="System" href="/server/config-system.html" />
                         <item name="Domain List" href="/server/config-domainlist.html" />
                         <item name="Users" href="/server/config-users.html" />
@@ -136,21 +137,21 @@
                         <item name="Quota" href="/server/config-quota.html" />
                         <item name="Events" href="/server/config-events.html" />
                     </item>
-                    <item name="4. Manage" href="/server/manage.html" collapse="true" >
+                    <item name="5. Manage" href="/server/manage.html" collapse="true" >
                         <item name="WebAdmin" href="/server/manage-webadmin.html" />
                         <item name="Command line" href="/server/manage-cli.html" />
                         <item name="Metrics" href="/server/metrics.html" />
                     </item>
-                    <item name="5. Monitor" href="/server/monitor.html" collapse="true" >
+                    <item name="6. Monitor" href="/server/monitor.html" collapse="true" >
                         <item name="Logging" href="/server/monitor-logging.html" />
                         <item name="JMX" href="/server/monitor-jmx.html" />
                         <item name="Folders" href="/server/monitor-folders.html" />
                     </item>
-                    <item name="6. Upgrade" href="/server/upgrade.html" collapse="true" >
+                    <item name="7. Upgrade" href="/server/upgrade.html" collapse="true" >
                         <item name="Upgrade from 2.3" href="/server/upgrade-2.3.html" />
                         <item name="Upgrade database" href="/server/upgrade-database.html" />
                     </item>
-                    <item name="7. Developers Corner" href="/server/dev.html" collapse="true" >
+                    <item name="8. Developers Corner" href="/server/dev.html" collapse="true" >
                         <item name="Build from source" href="/server/dev-build.html" />
                         <item name="Database Schema" href="/server/dev-database-schema.html" />
                         <item name="Develop Extensions" href="/server/dev-extend.html" collapse="true" >

http://git-wip-us.apache.org/repos/asf/james-project/blob/b1a812eb/src/site/xdoc/server/packaging.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/packaging.xml b/src/site/xdoc/server/packaging.xml
new file mode 100644
index 0000000..247e8ce
--- /dev/null
+++ b/src/site/xdoc/server/packaging.xml
@@ -0,0 +1,202 @@
+<?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.
+-->
+<document>
+
+    <properties>
+        <title>Apache James Server 3 - Packaging</title>
+    </properties>
+
+    <body>
+
+        <section name="Available packaging options">
+            <p>James components are assembled in various way, called packaging.</p>
+
+            <ul>The packaging you choose will influence:
+                <li>Your java requirement</li>
+                <li>The protocol the mail server supports</li>
+                <li>The components you can use</li>
+            </ul>
+
+            <p>Thus, one must carefully choose his packaging.</p>
+
+            <ul>To help you doing this, here is a list of available packages:
+                <li><a href="https://github.com/apache/james-project/tree/master/server/app">Spring</a>: Allows you to
+                    choose across various available implementations for each component. Requires more configuration effort.</li>
+                <li><a href="https://github.com/apache/james-project/tree/master/server/container/guice/cassandra-guice">
+                    Cassandra-guice</a>: Ships a James server storing emails in Cassandra and index them in ElasticSearch.</li>
+                <li><a href="https://github.com/apache/james-project/tree/master/server/container/guice/cassandra-ldap-guice">
+                    Cassandra-guice-ldap</a>: Ships a James server storing emails in Cassandra and index them in ElasticSearch. User are authenticated against a LDAP server.</li>
+                <li><a href="https://github.com/apache/james-project/tree/master/server/container/guice/jpa-guice">
+                    Jpa-Guice</a>: Ships a James server storing emails in a SQL database (derby by default) accessed with JPA and Lucene to index emails.</li>
+                <li><a href="https://github.com/apache/james-project/tree/master/server/container/guice/jpa-smtp">
+                    Jpa-Smtp</a>: A tiny SMTP server shiped without mailbox, using SQL database to store data, accessed by JPA.</li>
+            </ul>
+
+            <p>Note: Especially using Guice, one can easily define new modules for existing James components, as well as
+            for third party code. Note that building your own combination of components will lead to an untested and unsupported server.
+            </p>
+        </section>
+
+        <section name="Support matrix">
+            <p>
+                <table>
+                    <tr>
+                        <th>Packaging</th>
+                        <th>Spring</th>
+                        <th>Cassandra-guice</th>
+                        <th>Cassandra-ldap-guice</th>
+                        <th>Jpa-guice</th>
+                        <th>Jpa-smtp</th>
+                    </tr>
+                    <tr>
+                        <td>IoC framework</td>
+                        <td>Spring</td>
+                        <td>Guice</td>
+                        <td>Guice</td>
+                        <td>Guice</td>
+                        <td>Guice</td>
+                    </tr>
+                    <tr>
+                        <td>Java version</td>
+                        <td>Java 6</td>
+                        <td>Java 8</td>
+                        <td>Java 8</td>
+                        <td>Java 8</td>
+                        <td>Java 8</td>
+                    </tr>
+                    <tr>
+                        <td>Docker image</td>
+                        <td><a href="https://github.com/apache/james-project/tree/master/dockerfiles/run/spring">Available</a></td>
+                        <td><a href="https://github.com/apache/james-project/tree/master/dockerfiles/run/guice/cassandra">Available</a></td>
+                        <td><a href="https://github.com/apache/james-project/tree/master/dockerfilehttps://github.com/apache/james-project/tree/master/dockerfiles/run/guice/jpas/run/guice/cassandra-ldap">Available</a></td>
+                        <td><a href="https://github.com/apache/james-project/tree/master/dockerfiles/run/guice/jpa">Available</a></td>
+                        <td>None</td>
+                    </tr>
+                    <tr>
+                        <td>Supports SMTP</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                    </tr>
+                    <tr>
+                        <td>Supports IMAP</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                        <td>No</td>
+                    </tr>
+                    <tr>
+                        <td>Supports JMAP</td>
+                        <td>No</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                        <td>No</td>
+                        <td>No</td>
+                    </tr>
+                    <tr>
+                        <td>Supports POP3</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                        <td>No</td>
+                    </tr>
+                    <tr>
+                        <td>Supports FetchMail</td>
+                        <td>Yes</td>
+                        <td>No</td>
+                        <td>No</td>
+                        <td>No</td>
+                        <td>No</td>
+                    </tr>
+                    <tr>
+                        <td>Supports CLI</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                    </tr>
+                    <tr>
+                        <td>Supports WebAdmin</td>
+                        <td>No</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                    </tr>
+                    <tr>
+                        <td>Supports Grafana metrics</td>
+                        <td>No</td>
+                        <td>Yes</td>
+                        <td>Yes</td>
+                        <td>No</td>
+                        <td>No</td>
+                    </tr>
+                    <tr>
+                        <td>Mailbox implementation</td>
+                        <td>JPA/MailDir/JCR/Memory</td>
+                        <td>Cassandra</td>
+                        <td>Cassandra</td>
+                        <td>JPA</td>
+                        <td>JPA</td>
+                    </tr>
+                    <tr>
+                        <td>Indexer implementation</td>
+                        <td>Lucene/None</td>
+                        <td>ElasticSearch</td>
+                        <td>ElasticSearch</td>
+                        <td>Lucene</td>
+                        <td>None</td>
+                    </tr>
+                    <tr>
+                        <td>Server data implementation</td>
+                        <td>JPA/File/HBase/JCR</td>
+                        <td>Cassandra</td>
+                        <td>Cassandra</td>
+                        <td>JPA</td>
+                        <td>JPA</td>
+                    </tr>
+                    <tr>
+                        <td>Mail queue implementation</td>
+                        <td>ActiveMQ</td>
+                        <td>ActiveMQ</td>
+                        <td>ActiveMQ</td>
+                        <td>ActiveMQ</td>
+                        <td>ActiveMQ</td>
+                    </tr>
+                    <tr>
+                        <td>Sieve</td>
+                        <td>Experimental</td>
+                        <td>Experimental</td>
+                        <td>Experimental</td>
+                        <td>Experimental</td>
+                        <td>No</td>
+                    </tr>
+                </table>
+            </p>
+        </section>
+
+    </body>
+
+</document>


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


[12/21] james-project git commit: JAMES-1789 Note about Guice Java8 requirement

Posted by bt...@apache.org.
JAMES-1789 Note about Guice Java8 requirement


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/884072a5
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/884072a5
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/884072a5

Branch: refs/heads/master
Commit: 884072a5a0fb09496c06a137fe28bfedb2586f36
Parents: 64c2b06
Author: benwa <bt...@linagora.com>
Authored: Sat Jun 10 10:30:17 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:45 2017 +0700

----------------------------------------------------------------------
 src/site/xdoc/server/index.xml | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/884072a5/src/site/xdoc/server/index.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/index.xml b/src/site/xdoc/server/index.xml
index f160d38..4d2064c 100644
--- a/src/site/xdoc/server/index.xml
+++ b/src/site/xdoc/server/index.xml
@@ -58,7 +58,8 @@
           configuration compatibility has been retained with 2.3.2.</p>
           
         <p>Apache James Server 3.0 requires Java 1.6. A migration guide for
-           users willing to upgrade from 2.3 to 3.0 is <a href="upgrade-2.3.html">available</a>.</p>
+           users willing to upgrade from 2.3 to 3.0 is <a href="upgrade-2.3.html">available</a>. If relying on Guice
+           packaging, you can use some additional components (Cassandra, ElasticSearch, ...). Guice packaging requires java-8.</p>
     
 
 


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


[20/21] james-project git commit: JAMES-1789 Normalize snake case in CLI parameters

Posted by bt...@apache.org.
JAMES-1789 Normalize snake case in CLI parameters


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/e1140e47
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/e1140e47
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/e1140e47

Branch: refs/heads/master
Commit: e1140e4709d998e63f87ab54c566a52c842ff885
Parents: b1a812e
Author: benwa <bt...@linagora.com>
Authored: Mon Jun 12 17:40:14 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:53 2017 +0700

----------------------------------------------------------------------
 .../cli/src/main/java/org/apache/james/cli/type/CmdType.java | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/e1140e47/server/container/cli/src/main/java/org/apache/james/cli/type/CmdType.java
----------------------------------------------------------------------
diff --git a/server/container/cli/src/main/java/org/apache/james/cli/type/CmdType.java b/server/container/cli/src/main/java/org/apache/james/cli/type/CmdType.java
index ef192a6..1858666 100644
--- a/server/container/cli/src/main/java/org/apache/james/cli/type/CmdType.java
+++ b/server/container/cli/src/main/java/org/apache/james/cli/type/CmdType.java
@@ -46,10 +46,10 @@ public enum CmdType {
     GETQUOTAROOT("GetQuotaroot", "namespace", "user", "name"),
     GETMAXSTORAGEQUOTA("GetMaxStorageQuota", "quotaroot"),
     GETMAXMESSAGECOUNTQUOTA("GetMaxMessageCountQuota", "quotaroot"),
-    SETMAXSTORAGEQUOTA("SetMaxStorageQuota", "quotaroot", "max_message_count"),
-    SETMAXMESSAGECOUNTQUOTA("SetMaxMessageCountQuota", "quotaroot", "max_storage"),
-    SETDEFAULTMAXSTORAGEQUOTA("SetDefaultMaxStorageQuota", "max_storage"),
-    SETDEFAULTMAXMESSAGECOUNTQUOTA("SetDefaultMaxMessageCountQuota", "max_message_count"),
+    SETMAXSTORAGEQUOTA("SetMaxStorageQuota", "quotaroot", "maxMessageCount"),
+    SETMAXMESSAGECOUNTQUOTA("SetMaxMessageCountQuota", "quotaroot", "maxStorage"),
+    SETDEFAULTMAXSTORAGEQUOTA("SetDefaultMaxStorageQuota", "maxStorage"),
+    SETDEFAULTMAXMESSAGECOUNTQUOTA("SetDefaultMaxMessageCountQuota", "maxMessageCount"),
     GETDEFAULTMAXSTORAGEQUOTA("GetDefaultMaxStorageQuota"),
     GETDEFAULTMAXMESSAGECOUNTQUOTA("GetDefaultMaxMessageCountQuota"),
     REINDEXMAILBOX("ReindexMailbox", "namespace", "user", "name"),


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


[06/21] james-project git commit: JAMES-1789 Consolidate management instructions

Posted by bt...@apache.org.
JAMES-1789 Consolidate management instructions


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/7c69293d
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/7c69293d
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/7c69293d

Branch: refs/heads/master
Commit: 7c69293d14354fcd0b6b547ae5d5f8b7988e9941
Parents: e727103
Author: benwa <bt...@linagora.com>
Authored: Thu Jun 8 22:53:07 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:30 2017 +0700

----------------------------------------------------------------------
 src/site/site.xml                               |   3 -
 src/site/xdoc/server/manage-domains.xml         |  67 ------
 src/site/xdoc/server/manage-jmx.xml             |  99 +++++++++
 .../xdoc/server/manage-recipientrewrite.xml     | 203 -------------------
 src/site/xdoc/server/manage-users.xml           |  66 ------
 src/site/xdoc/server/manage.xml                 |  86 +-------
 6 files changed, 106 insertions(+), 418 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/7c69293d/src/site/site.xml
----------------------------------------------------------------------
diff --git a/src/site/site.xml b/src/site/site.xml
index e511b1a..aca55d8 100644
--- a/src/site/site.xml
+++ b/src/site/site.xml
@@ -137,9 +137,6 @@
                         <item name="Events" href="/server/config-events.html" />
                     </item>
                     <item name="4. Manage" href="/server/manage.html" collapse="true" >
-                        <item name="Domains" href="/server/manage-domains.html" />
-                        <item name="Users" href="/server/manage-users.html" />
-                        <item name="Recipient Rewrite" href="/server/manage-recipientrewrite.html" />
                         <item name="WebAdmin" href="/server/manage-webadmin.html" />
                         <item name="Command line" href="/server/manage-cli.html" />
                         <item name="Metrics" href="/server/metrics.html" />

http://git-wip-us.apache.org/repos/asf/james-project/blob/7c69293d/src/site/xdoc/server/manage-domains.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/manage-domains.xml b/src/site/xdoc/server/manage-domains.xml
deleted file mode 100644
index 22a1dc5..0000000
--- a/src/site/xdoc/server/manage-domains.xml
+++ /dev/null
@@ -1,67 +0,0 @@
-<?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.    
--->
-<document>
-
- <properties>
-  <title>Apache James Server 3 - Manage Domains</title>
- </properties>
-
-<body>
-
-  <section name="Manage Domains">
-  
-    <p>Domain accounts are shared across services.  A common Domain repository is shared across James 
-       services.  That is, once you've created a POP3 mail and set a password, that same 
-       is available for authenticated SMTP and NNTP.</p>
-    
-    <p>If you have JPADomainList (default setup), you can add, delete and list the domains.</p>
-    
-    <p>If you have XMLDomainList for example, you can only list the available domains. To add a domain,
-       you must add it in the domainlist.xml file.</p>
-
-  </section>
-
-  <section name="Manage Domains via Cli">
-  
-    <p>Invoke "james-cli.sh adddomain &lt;mydomain.tls&gt; &lt;mydomain.tls&gt; is the domain name 
-      of the domain you wish to create.</p>
-      
-    <p>That's it.  Your domains are now created and can be used by all James services.</p>
-    
-  </section>
-
-  <section name="Manage Domains via JMX">
-  
-    <p>Use and JMX client to access the DomainList management function.</p>
-  
-    <p>The managed objects are exposed from localhost only (for security reasons) on the following URL:</p>
-      
-    <p><code>service:jmx:rmi:///jndi/rmi://localhost:9999/jmxrmi</code></p>
-      
-    <p>If you want a remote access, you can install a web application management tool such as jmanage. 
-       You will get screens such as the following one.</p>
-         
-    <p><img src="images/jmx-management/jmx-domainlist.png"/></p>
-
-  </section>
-  
-</body>
-
-</document>

http://git-wip-us.apache.org/repos/asf/james-project/blob/7c69293d/src/site/xdoc/server/manage-jmx.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/manage-jmx.xml b/src/site/xdoc/server/manage-jmx.xml
new file mode 100644
index 0000000..65aab55
--- /dev/null
+++ b/src/site/xdoc/server/manage-jmx.xml
@@ -0,0 +1,99 @@
+<?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.
+-->
+<document>
+
+    <properties>
+        <title>Apache James Server 3 - Manage Domains</title>
+    </properties>
+
+    <body>
+
+        <section name="Manage via JMX">
+
+            <p>James can be managed via JMX.</p>
+
+            <p>The managed objects are exposed from localhost only (for security reasons) on the following URL:</p>
+
+            <p><code>service:jmx:rmi://localhost/jndi/rmi://localhost:999/jmxrmi </code></p>
+
+            <p>Simply launch jconsole to access the exposed attributes and methods.</p>
+
+            <p>If you want a remote access, change 'localhost' to your server hostname in the previous URL:</p>
+
+            <p><code>service:jmx:rmi://localhost/jndi/rmi://localhost:999/jmxrmi </code></p>
+
+            <p>To manage through a firewall, you will have to take care to random ports creation (read
+                <a href="http://docs.oracle.com/javase/6/docs/technotes/guides/management/agent.html">JMX agent</a>
+                ,
+                <a href="http://olegz.wordpress.com/2009/03/23/jmx-connectivity-through-the-firewall">JMX through firewall</a>
+                and
+                <a href="http://blogs.law.harvard.edu/hoanga/2006/07/07/getting-java-jmx-to-work-through-firewalls-properly">Getting Java JMX to work through firewalls properly</a>.
+            </p>
+
+            <p>You can install a web application management tool such as jmanage.
+                You will get screens such as the following one.</p>
+
+            <p><img src="images/jmx-management/jmx-domainlist.png"/></p>
+
+        </section>
+
+        <section name="Manage Domains via JMX">
+
+            <p>Use a JMX client to access the DomainList management function.</p>
+
+            <p>The managed objects are exposed from localhost only (for security reasons) on the following URL:</p>
+
+            <p><code>service:jmx:rmi:///jndi/rmi://localhost:9999/jmxrmi</code></p>
+
+            <p>If you want a remote access, you can install a web application management tool such as jmanage.
+                You will get screens such as the following one.</p>
+
+            <p><img src="images/jmx-management/jmx-domainlist.png"/></p>
+
+        </section>
+
+        <section name="Manage Users via JMX">
+
+            <p>Use and JMX client to access the Users management function.</p>
+
+            <p>The managed objects are exposed from localhost only (for security reasons) on the following URL:</p>
+
+            <p><code>service:jmx:rmi:///jndi/rmi://localhost:9999/jmxrmi</code></p>
+
+            <p>If you want a remote access, you can install a web application management tool such as jmanage.
+                You will get screens such as the following one.</p>
+
+            <p><img src="images/jmx-management/jmx-user.png"/></p>
+
+        </section>
+
+        <section name="Manage Virtual Users via JMX">
+
+            <p>Use and JMX client to access the Virtual User management function.</p>
+
+            <p>The managed objects are exposed from localhost only (for security reasons) on the following URL:</p>
+
+            <p><code>service:jmx:rmi:///jndi/rmi://localhost:9999/jmxrmi</code></p>
+
+        </section>
+
+    </body>
+
+</document>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/james-project/blob/7c69293d/src/site/xdoc/server/manage-recipientrewrite.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/manage-recipientrewrite.xml b/src/site/xdoc/server/manage-recipientrewrite.xml
deleted file mode 100644
index 08abc4d..0000000
--- a/src/site/xdoc/server/manage-recipientrewrite.xml
+++ /dev/null
@@ -1,203 +0,0 @@
-<?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.    
--->
-<document>
-
- <properties>
-  <title>Apache James Server 3 - Manage Recipient Rewrite Table</title>
- </properties>
-
-<body>
-
-  <section name="Manage Recipient Rewrite">
-  
-    <p>To rewrite recipients, you need to create some "mappings".</p>
-
-    <p>You will rewrite any recipient to an existing or a non-existing server account.</p>
-    
-    <p>So read "mapping allows to rewrite a 'fromAny(Existing/NotExisting) user and/or domain' to a 'toAny(Existing/NotExisting)Account'".</p>
-
-    <p>'An existing account' means an account defined in the Apache James Server.</p>
-    
-    <p>You can also use regular expressions and wildcards (*) for the 'fromAny'.</p>
-    
-    <p>The available methods exposed in the management interface are the following:</p>
-    
-    <source>
-    /**
-     * Add regex mapping
-     * 
-     * @param user
-     *            the username. Null if no username should be used
-     * @param domain
-     *            the domain. Null if no domain should be used
-     * @param regex
-     *            the regex.
-     */
-    void addRegexMapping(String user, String domain, String regex) throws Exception;
-
-    /**
-     * Remove regex mapping
-     * 
-     * @param user
-     *            the username. Null if no username should be used
-     * @param domain
-     *            the domain. Null if no domain should be used
-     * @param regex
-     *            the regex.
-     */
-    void removeRegexMapping(String user, String domain, String regex) throws Exception;
-
-    /***
-     * Add address mapping
-     * 
-     * @param user
-     *            the username. Null if no username should be used
-     * @param domain
-     *            the domain. Null if no domain should be used
-     * @param address
-     *            the address.
-     */
-    void addAddressMapping(String user, String domain, String address) throws Exception;
-
-    /**
-     * Remove address mapping
-     * 
-     * @param user
-     *            the username. Null if no username should be used
-     * @param domain
-     *            the domain. Null if no domain should be used
-     * @param address
-     */
-    void removeAddressMapping(String user, String domain, String address) throws Exception;
-
-    /**
-     * Add error mapping
-     * 
-     * @param user
-     *            the username. Null if no username should be used
-     * @param domain
-     *            the domain. Null if no domain should be used
-     * @param error
-     */
-    void addErrorMapping(String user, String domain, String error) throws Exception;
-
-    /**
-     * Remove error mapping
-     * 
-     * @param user
-     *            the username. Null if no username should be used
-     * @param domain
-     *            the domain. Null if no domain should be used
-     * @param error
-     * @return true if successfully
-     */
-    void removeErrorMapping(String user, String domain, String error) throws Exception;
-
-    /**
-     * Add domain mapping
-     * 
-     * @param domain
-     *            the domain. Null if no domain should be used
-     * @param targetDomain
-     *            the target domain for the mapping
-     * @return true if successfully
-     */
-    void addDomainMapping(String domain, String targetDomain) throws Exception;
-
-    /**
-     * Remove domain mapping
-     * 
-     * @param domain
-     *            the domain. Null if no domain should be used
-     * @param targetDomain
-     *            the target domain for the mapping
-     * 
-     * @return true if successfully
-     */
-    void removeDomainMapping(String domain, String targetDomain) throws Exception;
-
-    /**
-     * Return the explicit mapping stored for the given user and domain. Return
-     * null if no mapping was found
-     * 
-     * @param user
-     *            the username
-     * @param domain
-     *            the domain
-     * @return the collection which holds the mappings.
-     */
-    Collection&lt;String&gt; getUserDomainMappings(String user, String domain) throws Exception;
-
-    /**
-     * Try to identify the right method based on the prefix of the mapping and
-     * add it.
-     * 
-     * @param user
-     *            the username. Null if no username should be used
-     * @param domain
-     *            the domain. Null if no domain should be used
-     * @param mapping
-     *            the mapping.
-     */
-    void addMapping(String user, String domain, String mapping) throws Exception;
-
-    /**
-     * Try to identify the right method based on the prefix of the mapping and
-     * remove it.
-     * 
-     * @param user
-     *            the username. Null if no username should be used
-     * @param domain
-     *            the domain. Null if no domain should be used
-     * @param mapping
-     *            the mapping.
-     */
-    void removeMapping(String user, String domain, String mapping) throws Exception;
-
-    /**
-     * Return a Map which holds all mappings. The key is the user@domain and the
-     * value is a Collection which holds all mappings
-     * 
-     * @return Map which holds all mappings
-     */
-    Map&lt;String, Collection&lt;String&gt;&gt; getAllMappings() throws Exception;
-    </source>
-
-  </section>
-
-  <section name="Manage Recipient Rewrite Table via Cli">
-  
-    <p>Not available in this release.</p>
-    
-  </section>
-
-  <section name="Manage Virtual Users via JMX">
-  
-    <p>Use and JMX client to access the Virtual User management function.</p>
-  
-    <p>The managed objects are exposed from localhost only (for security reasons) on the following URL:</p>
-      
-    <p><code>service:jmx:rmi:///jndi/rmi://localhost:9999/jmxrmi</code></p>
-      
-  </section>
-
-</body>
-
-</document>

http://git-wip-us.apache.org/repos/asf/james-project/blob/7c69293d/src/site/xdoc/server/manage-users.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/manage-users.xml b/src/site/xdoc/server/manage-users.xml
deleted file mode 100644
index 85b6d1f..0000000
--- a/src/site/xdoc/server/manage-users.xml
+++ /dev/null
@@ -1,66 +0,0 @@
-<?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.    
--->
-<document>
-
- <properties>
-  <title>Apache James Server 3 - Manage Users</title>
- </properties>
-
-<body>
-
-  <section name="Manage Users">
-  
-    <p>User accounts are shared across services.  A common user repository is shared across James 
-      services.  That is, once you've created a POP3 mail account and set a password, that same 
-      account is available for authenticated SMTP and NNTP.</p>
-      
-  </section>
-    
-  <section name="Manage Users via Cli">
-  
-    <p>Invoke "james-cli.sh adduser &lt;user&gt; &lt;password&gt;" where &lt;user&gt; is the user name 
-      and &lt;password&gt; is the password of the account you wish to create.</p>
-      
-    <p>Please note that the user name MUST be a complete email address of the form &lt;user&gt;@&lt;domain&gt; 
-      (where &lt;domain&gt; is any of the values specified in the &lt;servernames&gt; block of XMLDomainList or
-      a domain defined via the <a href="manage-domains.html">domain management</a>).</p>
-      
-    <p>That's it.  Your users are now created and can be used by all James services.</p>
-    
-  </section>
-
-  <section name="Manage Users via JMX">
-  
-    <p>Use and JMX client to access the Users management function.</p>
-  
-    <p>The managed objects are exposed from localhost only (for security reasons) on the following URL:</p>
-      
-    <p><code>service:jmx:rmi:///jndi/rmi://localhost:9999/jmxrmi</code></p>
-     
-    <p>If you want a remote access, you can install a web application management tool such as jmanage. 
-       You will get screens such as the following one.</p>
-         
-    <p><img src="images/jmx-management/jmx-user.png"/></p>
-
-  </section>
-  
-</body>
-
-</document>

http://git-wip-us.apache.org/repos/asf/james-project/blob/7c69293d/src/site/xdoc/server/manage.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/manage.xml b/src/site/xdoc/server/manage.xml
index 8d5025c..5904174 100644
--- a/src/site/xdoc/server/manage.xml
+++ b/src/site/xdoc/server/manage.xml
@@ -26,8 +26,7 @@
 <body>
 
   <section name="Manage James Server">
-<!-- 
--->  
+
     <p>You need to make sure that your user/domain/mail repository configuration is correct before managing.  If 
     you change your user/domain/mail repository type (i.e. file to database) or the configuration of your user repository 
     (i.e. the file or database URL) after you have added user/domain/mail, you may lose your user/domain/mail data.  Please change these 
@@ -36,85 +35,14 @@
     <p>After you've done this, restart James to ensure that any changes you've made in 
        the configuration are incorporated into the running system.</p>
        
-     <p>You are now ready to manage <a href="manage-domains.html">Domains</a>, 
-       <a href="manage-users.html">Users</a> and <a href="manage-recipientrewrite.html">Recipient Rewrite Table</a>.</p>
-
-    <p>You can manage James via:</p>
-    
-    <ol>
-      <li><a href="#Manage_via_CLI">CLI (Client Line Interface)</a></li>
-      <li><a href="#Manage_via_JMX">JMX (Java Management Extension)</a></li>
-    </ol>
-    
-    <subsection name="Manage via CLI">
-  
-      <p>Once James is up and listening, managing via the command line interface is simple.</p>
-      
-      <p>cd bin</p>
-      
-      <p>./james-cli.sh (or james-cli.bat on windows) ./james-cli.sh -h localhost -p 9999</p>
-
-      <p>You will be shown with a list of commands.</p>
+     <p>You are now ready to manage Some internal James data-structure.</p>
 
-      <source>
-  usage: java org.apache.james.cli.ServerCmd --host &lt;arg&gt; &lt;command&gt;
-    -h,--host &lt;/arg&gt;   node hostname or ip address
-    -p,--port &lt;/arg&gt;   remote jmx agent port number
-  Available commands:
-    adduser &lt;/username&gt; &lt;/password&gt;
-    removeuser &lt;/username&gt;
-    listusers
-    adddomain &lt;/domainname&gt;
-    removedomain &lt;/domainname&gt;
-    listdomains
-    containsdomain
-      </source>
-  
-      <p>Note the address and port defined in conf/jmx.properties (default is jmx.address=127.0.0.1 and jmx.port=9999)</p>
-
-    </subsection>
-    
-    <subsection name="Manage via JMX">
-    
-      <p>James can be managed via JMX.</p>
-      
-      <p>The managed objects are exposed from localhost only (for security reasons) on the following URL:</p>
-      
-      <p><code>service:jmx:rmi://localhost/jndi/rmi://localhost:999/jmxrmi </code></p>
-      
-      <p>Simply launch jconsole to access the exposed attributes and methods.</p>
-<!-- 
-      <div class="ui-widget">
-        <div class="ui-state-error ui-corner-all" style="padding: 0 .7em;"> 
-          <p><span class="ui-icon ui-icon-alert" style="float: left; margin-right: .3em;"></span> 
-          <strong>JMX on Windows:</strong>
-          to let windows start with jmx username/password enabled, 
-          you need to modify the security settings for the jmx files like descripted here:
-          <a href="http://download.oracle.com/javase/1.5.0/docs/guide/management/security-windows.html">
-          http://download.oracle.com/javase/1.5.0/docs/guide/management/security-windows.html</a>
-        </p>
-        </div>
-      </div>
--->
-      <p>If you want a remote access, change 'localhost' to your server hostname in the previous URL:</p>
-      
-      <p><code>service:jmx:rmi://localhost/jndi/rmi://localhost:999/jmxrmi </code></p>
-      
-      <p>To manage through a firewall, you will have to take care to random ports creation (read
-         <a href="http://docs.oracle.com/javase/6/docs/technotes/guides/management/agent.html">JMX agent</a>
-         , 
-         <a href="http://olegz.wordpress.com/2009/03/23/jmx-connectivity-through-the-firewall">JMX through firewall</a>
-         and
-         <a href="http://blogs.law.harvard.edu/hoanga/2006/07/07/getting-java-jmx-to-work-through-firewalls-properly">Getting Java JMX to work through firewalls properly</a>.
-      </p>
-      
-      <p>You can install a web application management tool such as jmanage. 
-         You will get screens such as the following one.</p>
-      
-       <p><img src="images/jmx-management/jmx-domainlist.png"/></p>
+      <ul>You can do this:
+          <li>Using <a href="manage-cli.html">The command line client</a></li>
+          <li>Using <a href="manage-webadmin.html">The web REST interface</a> (Guice only)</li>
+          <li>Using <a href="manage-jmx.html">The JMX interface</a> (Experimental)</li>
+      </ul>
 
-    </subsection>
-  
   </section>
 
 </body>


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


[03/21] james-project git commit: JAMES-1789 Webadmin documentation should be exposed on the website

Posted by bt...@apache.org.
JAMES-1789 Webadmin documentation should be exposed on the website


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/27118d17
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/27118d17
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/27118d17

Branch: refs/heads/master
Commit: 27118d171fd11b1a44f3f9ef529db58ab41f5522
Parents: e3ed1ec
Author: benwa <bt...@linagora.com>
Authored: Thu Jun 8 20:25:04 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:19 2017 +0700

----------------------------------------------------------------------
 src/site/markdown/server/manage-webadmin.md | 334 +++++++++++++++++++++++
 src/site/site.xml                           |   1 +
 2 files changed, 335 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/27118d17/src/site/markdown/server/manage-webadmin.md
----------------------------------------------------------------------
diff --git a/src/site/markdown/server/manage-webadmin.md b/src/site/markdown/server/manage-webadmin.md
new file mode 100644
index 0000000..04d8d07
--- /dev/null
+++ b/src/site/markdown/server/manage-webadmin.md
@@ -0,0 +1,334 @@
+Web administration for JAMES
+============================
+
+The web administration supports for now the CRUD operations on the domains,the users, their mailboxes and their quotas, as described in the following sections.
+
+**WARNING**: This API allow authentication only via the use of JWT. If not configured with JWT, an administrator should ensure an attacker can not use this API.
+
+Please also note **webadmin** is only enabled with **Guice**. You can not use it when using James with **Spring**, as the required injections are not implemented.
+
+## Administrating domains
+
+### Create a domain
+
+```
+curl -XPUT http://ip:port/domains/domainToBeCreated
+```
+
+Resource name domainToBeCreated:
+
+ - can not be null or empty
+ - can not contain '@'
+ - can not be more than 255 characters
+ - can not contain '/'
+
+Response codes:
+
+ - 204: The domain was successfully added
+ - 400: The domain name is invalid
+ - 500: Internal error while adding the domain
+
+### Delete a domain
+
+```
+curl -XDELETE http://ip:port/domains/domainToBeDeleted
+```
+
+Response codes:
+
+ - 204: The domain was successfully removed
+ - 500: Internal error while removing the domain
+
+### Test if a domain exists
+
+```
+curl -XGET http://ip:port/domains/domainName
+```
+
+Response codes:
+
+ - 204: The domain exists
+ - 404: The domain does not exist
+ - 500: Internal error while accessing the domains
+
+### Get the list of domains
+
+```
+curl -XGET http://ip:port/domains
+```
+
+Possible response:
+
+```
+{"domains":["domain1", "domain2"]}
+```
+
+Response codes:
+
+ - 200: The domain list was successfully retrieved
+ - 500: Internal error while accessing the domains
+
+## Administrating users
+
+### Create a user
+
+```
+curl -XPUT http://ip:port/users/usernameToBeUsed -d '{"password":"passwordToBeUsed"}'
+```
+
+Resource name usernameToBeUsed:
+
+ - can not be null or empty
+ - can not be more than 255 characters
+ - can not contain '/'
+
+Response codes:
+
+ - 204: The user was successfully created
+ - 400: The user name or the payload is invalid
+ - 409: Conflict: A concurrent modification make that query to fail
+ - 500: Internal error while adding the user
+
+Note: if the user is already, its password will be updated.
+
+### Updating a user password
+
+Same than Create, but a user need to exist.
+
+If the user do not exist, then it will be created.
+
+### Deleting a user
+
+```
+curl -XDELETE http://ip:port/users/userToBeDeleted
+```
+
+Response codes:
+
+ - 204: The user was successfully deleted
+ - 500: Internal error while deleting the user
+
+### Retrieving the user list
+
+```
+curl -XGET http://ip:port/users
+```
+
+The answer looks like:
+
+```
+[{"username":"username@domain-jmapauthentication.tld"},{"username":"username@domain.tld"}]
+```
+
+Response codes:
+
+ - 200: The user name list was successfully retrieved
+ - 500: Internal error while retrieving the users
+
+## Administrating user mailboxes
+
+### Creating a mailbox
+
+```
+curl -XPUT http://ip:port/users/usernameToBeUsed/mailboxes/mailboxNameToBeCreated
+```
+
+Resource name usernameToBeUsed should be an existing user
+Resource name mailboxNameToBeCreated should not be empty, nor contain # & % * characters.
+
+Response codes:
+
+ - 204: The mailbox now exists on the server
+ - 400: Invalid mailbox name
+ - 404: The user name does not exist
+ - 500: Internal error
+
+ To create nested mailboxes, for instance a work mailbox inside the INBOX mailbox, people should use the . separator. The sample query is:
+
+```
+curl -XDELETE http://ip:port/users/usernameToBeUsed/mailboxes/INBOX.work
+```
+
+### Deleting a mailbox and its children
+
+```
+curl -XDELETE http://ip:port/users/usernameToBeUsed/mailboxes/mailboxNameToBeCreated
+```
+
+Resource name usernameToBeUsed should be an existing user
+Resource name mailboxNameToBeCreated should not be empty
+
+Response codes:
+
+ - 204: The mailbox now does not exist on the server
+ - 400: Invalid mailbox name
+ - 404: The user name does not exist
+ - 500: Internal error
+
+### Testing existence of a mailbox
+
+```
+curl -XGET http://ip:port/users/usernameToBeUsed/mailboxes/mailboxNameToBeCreated
+```
+
+Resource name usernameToBeUsed should be an existing user
+Resource name mailboxNameToBeCreated should not be empty
+
+Response codes:
+
+ - 204: The mailbox exists
+ - 400: Invalid mailbox name
+ - 404: The user name does not exist, the mailbox does not exist
+ - 500: Internal error
+
+### Listing user mailboxes
+
+```
+curl -XGET http://ip:port/users/usernameToBeUsed/mailboxes
+```
+
+The answer looks like:
+
+```
+[{"mailboxName":"INBOX"},{"mailboxName":"outbox"}]
+```
+
+Resource name usernameToBeUsed should be an existing user
+
+Response codes:
+
+ - 200: The mailboxes list was successfully retrieved
+ - 404: The user name does not exist
+ - 500: Internal error
+
+### Deleting user mailboxes
+
+```
+curl -XDELETE http://ip:port/users/usernameToBeUsed/mailboxes
+```
+
+Resource name usernameToBeUsed should be an existing user
+
+Response codes:
+
+ - 204: The user do not have mailboxes anymore
+ - 404: The user name does not exist
+ - 500: Internal error
+
+## Administrating quotas
+
+A quota with a value of -1 means unlimited
+
+### Reading per quotaroot mail count limitation
+
+```
+curl -XGET http://ip:port/quota/count
+```
+
+The answer looks like:
+
+```
+100000
+```
+
+Response codes:
+ - 200: Nothing special
+ - 500: Internal error
+
+### Updating per quotaroot mail count limitation
+
+```
+curl -XPUT http://ip:port/quota/count -d '1024000000'
+```
+
+Response codes:
+
+ - 204: Value updated
+ - 400: The body is not a positive integer
+ - 500: Internal error
+
+### Removing per quotaroot mail count limitation
+
+It removes the limitation, and the quota becomes UNILIMITED.
+
+```
+curl -XDELETE http://ip:port/quota/count
+```
+
+Response codes:
+
+ - 204: Value updated to UNLIMITED
+ - 500: Internal error
+
+### Reading per quotaroot size limitation
+
+```
+curl -XGET http://ip:port/quota/size
+```
+
+The answer looks like:
+
+```
+100000
+```
+
+It represent the allowed Byte count of the mailboxes belonging to this quotaroot.
+
+Response codes:
+
+ - 200: Nothing special
+ - 500: Internal error
+
+### Updating per quotaroot size limitation
+
+```
+curl -XPUT http://ip:port/quota/size -d '1024000000'
+```
+
+Response codes:
+
+ - 204: Value updated
+ - 400: The body is not a positive integer
+ - 500: Internal error
+
+### Removing per quotaroot size limitation
+
+It removes the limitation, and the quota becomes UNILIMITED.
+
+```
+curl -XDELETE http://ip:port/quota/size
+```
+
+Response codes:
+
+ - 204: Value updated to UNLIMITED
+ - 500: Internal error
+
+### Managing count and size at the same time
+
+```
+curl -XGET http://ip:port/quota/
+```
+
+Will return:
+
+```
+{"count":52,"size":42}
+```
+
+Response codes:
+
+ - 200: Success
+ - 500: Internal error
+
+You can also write the value the same way:
+
+```
+curl -XPUT http://ip:port/quota/ -d '{"count":52,"size":42}'
+```
+
+Response codes:
+
+ - 204: Success
+ - 400: Invalid JSON, or numbers are less than -1.
+ - 500: Internal error
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/james-project/blob/27118d17/src/site/site.xml
----------------------------------------------------------------------
diff --git a/src/site/site.xml b/src/site/site.xml
index 2d823ca..ba4d2bb 100644
--- a/src/site/site.xml
+++ b/src/site/site.xml
@@ -141,6 +141,7 @@
                         <item name="Users" href="/server/manage-users.html" />
                         <item name="Recipient Rewrite" href="/server/manage-recipientrewrite.html" />
                         <item name="Metrics" href="/server/metrics.html" />
+                        <item name="Metrics" href="/server/manage-webadmin.html" />
                     </item>
                     <item name="5. Monitor" href="/server/monitor.html" collapse="true" >
                         <item name="Logging" href="/server/monitor-logging.html" />


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


[08/21] james-project git commit: JAMES-1789 Specify which configuration to use with which packaging

Posted by bt...@apache.org.
JAMES-1789 Specify which configuration to use with which packaging


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/6782b966
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/6782b966
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/6782b966

Branch: refs/heads/master
Commit: 6782b9661fa64439c02f378406cada48538c2708
Parents: 907d717
Author: benwa <bt...@linagora.com>
Authored: Sat Jun 10 10:18:43 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:35 2017 +0700

----------------------------------------------------------------------
 src/site/xdoc/server/config-cassandra.xml          |  2 ++
 src/site/xdoc/server/config-domainlist.xml         |  2 +-
 src/site/xdoc/server/config-events.xml             |  2 ++
 src/site/xdoc/server/config-fetchmail.xml          |  2 ++
 src/site/xdoc/server/config-mailbox.xml            |  2 ++
 src/site/xdoc/server/config-quota.xml              |  2 ++
 .../xdoc/server/config-recipientrewritetable.xml   |  2 +-
 src/site/xdoc/server/config-system.xml             |  4 +++-
 src/site/xdoc/server/config-users.xml              |  4 +++-
 src/site/xdoc/server/config.xml                    | 17 ++++++++++++-----
 10 files changed, 30 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/6782b966/src/site/xdoc/server/config-cassandra.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/config-cassandra.xml b/src/site/xdoc/server/config-cassandra.xml
index 6def65d..61ed173 100644
--- a/src/site/xdoc/server/config-cassandra.xml
+++ b/src/site/xdoc/server/config-cassandra.xml
@@ -27,6 +27,8 @@
 
   <section name="Cassandra Configuration">
 
+    Note: Cassandra is only available with Guice distributions (cassandra-guice and cassandra-guice-ldap).
+
     <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/cassandra-template.properties">cassandra-template.properties</a> to get some examples and hints.</p>
 
       <dl>

http://git-wip-us.apache.org/repos/asf/james-project/blob/6782b966/src/site/xdoc/server/config-domainlist.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/config-domainlist.xml b/src/site/xdoc/server/config-domainlist.xml
index ef7a33d..2c46dbe 100644
--- a/src/site/xdoc/server/config-domainlist.xml
+++ b/src/site/xdoc/server/config-domainlist.xml
@@ -31,7 +31,7 @@
     
       <p>This configuration block is defined by the <strong>domainlist</strong> tag.</p>
       
-      <p>You must specify the DomainList class as attribute of the domainlist tag (org.apache.james.domainlist.jpa.JPADomainList, or org.apache.james.domainlist.xml.XMLDomainList, or...)</p> 
+      <p>Using Spring, you must specify the DomainList class as attribute of the domainlist tag (org.apache.james.domainlist.jpa.JPADomainList, or org.apache.james.domainlist.xml.XMLDomainList, or...). This have no effect when using Guice.</p>
 
       <dl>
         <dt><strong>domainnames</strong></dt>

http://git-wip-us.apache.org/repos/asf/james-project/blob/6782b966/src/site/xdoc/server/config-events.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/config-events.xml b/src/site/xdoc/server/config-events.xml
index 62dfa51..4a5d887 100644
--- a/src/site/xdoc/server/config-events.xml
+++ b/src/site/xdoc/server/config-events.xml
@@ -27,6 +27,8 @@
 
         <section name="Events System Configuration">
 
+            This configuration applies only to Spring packaging.
+
             <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/events-template.xml">events-template.xml</a> in GIT to get some examples and hints.</p>
 
             <p>Use this configuration to define the type of Event System you want.</p>

http://git-wip-us.apache.org/repos/asf/james-project/blob/6782b966/src/site/xdoc/server/config-fetchmail.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/config-fetchmail.xml b/src/site/xdoc/server/config-fetchmail.xml
index f7afcfe..73d882e 100755
--- a/src/site/xdoc/server/config-fetchmail.xml
+++ b/src/site/xdoc/server/config-fetchmail.xml
@@ -27,6 +27,8 @@
 
   <section name="Fetchmail Configuration">
 
+    This configuration file requires Spring packaging.
+
     <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/fetchmail-template.xml">fetchmail-template.xml</a> in GIT to get some examples and hints.</p>
 
     <p>Fetchmail acts as a gateway between an external message store such as an IMAP

http://git-wip-us.apache.org/repos/asf/james-project/blob/6782b966/src/site/xdoc/server/config-mailbox.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/config-mailbox.xml b/src/site/xdoc/server/config-mailbox.xml
index bfa149c..d556a64 100644
--- a/src/site/xdoc/server/config-mailbox.xml
+++ b/src/site/xdoc/server/config-mailbox.xml
@@ -27,6 +27,8 @@
 
   <section name="Mailbox Configuration">
 
+      This configuration applies only to Spring packaging.
+
     <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/mailbox-template.xml">mailbox-template.xml</a> in GIT to get some examples and hints.</p>
     
     <p>Use this configuration to define the type of mailbox storage used to persist the user's mails.</p>

http://git-wip-us.apache.org/repos/asf/james-project/blob/6782b966/src/site/xdoc/server/config-quota.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/config-quota.xml b/src/site/xdoc/server/config-quota.xml
index 74e6d34..17a494f 100644
--- a/src/site/xdoc/server/config-quota.xml
+++ b/src/site/xdoc/server/config-quota.xml
@@ -27,6 +27,8 @@
 
   <section name="Quota Configuration">
 
+    This configuration applies only to Spring packaging.
+
     <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/quota-template.xml">quota-template.xml</a> in GIT to get some examples and hints.</p>
     
     <p>Use this configuration to define the type of quota storage used to persist the quotas.</p>

http://git-wip-us.apache.org/repos/asf/james-project/blob/6782b966/src/site/xdoc/server/config-recipientrewritetable.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/config-recipientrewritetable.xml b/src/site/xdoc/server/config-recipientrewritetable.xml
index d217a28..7de3248 100644
--- a/src/site/xdoc/server/config-recipientrewritetable.xml
+++ b/src/site/xdoc/server/config-recipientrewritetable.xml
@@ -33,7 +33,7 @@
     
      <p>The default table for storing James' Recipient Rewrite mappings.</p>
 
-     <p>Add a class attribute to recipientrewritetable tag (class="org.apache.james.rrt.jpa.JPARecipientRewriteTable).</p>
+     <p>Using Spring, you should add a class attribute to recipientrewritetable tag (class="org.apache.james.rrt.jpa.JPARecipientRewriteTable). It has no effect with Guice packaging.</p>
 
      <dl>
         <dt><strong>recursiveMapping</strong></dt>

http://git-wip-us.apache.org/repos/asf/james-project/blob/6782b966/src/site/xdoc/server/config-system.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/config-system.xml b/src/site/xdoc/server/config-system.xml
index bb71839..e7c66c1 100644
--- a/src/site/xdoc/server/config-system.xml
+++ b/src/site/xdoc/server/config-system.xml
@@ -53,7 +53,9 @@
     </subsection>
 
     <subsection name="james-database.properties">
-    
+
+        <p>This configuration file is only relevant when using JPA, with Spring or Guice.</p>
+
       <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/james-database-template.properties">james-database.properties</a> in GIT to get some examples and hints.</p>
 
       <p>The database connection in database.properties</p>

http://git-wip-us.apache.org/repos/asf/james-project/blob/6782b966/src/site/xdoc/server/config-users.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/config-users.xml b/src/site/xdoc/server/config-users.xml
index b3ef344..d259725 100644
--- a/src/site/xdoc/server/config-users.xml
+++ b/src/site/xdoc/server/config-users.xml
@@ -39,7 +39,9 @@
   
      <p>JPA (database via OpenJPA) based user repository. This is the default implementation.</p>
      
-     <p>The usersrepository tag as 2 attributes: name="LocalUsers" and class="org.apache.james.user.file.UsersFileRepository"></p>
+     <p>The usersrepository tag as 2 attributes: name="LocalUsers" and class="org.apache.james.user.file.UsersFileRepository">
+     The class tag should be specified for Spring, but is not taken into acount by Guice.</p>
+
 
       <dl>
         <dt><strong>algorithm</strong></dt>

http://git-wip-us.apache.org/repos/asf/james-project/blob/6782b966/src/site/xdoc/server/config.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/config.xml b/src/site/xdoc/server/config.xml
index e5af722..613043c 100644
--- a/src/site/xdoc/server/config.xml
+++ b/src/site/xdoc/server/config.xml
@@ -29,10 +29,17 @@
   
     <p>All configuration files resides in the ./conf and ./conf/META-INF folder.</p>
     
-    <p>We ship with default configuration (embedded in jars) and -template files
+    <p>With default Spring packaging, we ship with default configuration (embedded in jars) and -template files
        you can use to override the default configuration. Simply copy in conf folder *-template.xml
        to *.xml (example: smtpserver-template.xml to smtpserver.xml), and change
        in *.xml the settings to map your needs.</p>
+
+    <p> For Guice based packaging, you are encouraged to take a look at default configuration of the
+      <a href="https://github.com/apache/james-project/tree/master/dockerfiles/run/guice">James docker images</a>.</p>
+
+    <p>Please note that the configuration is dependent of the packaging you have chosen. Some configuration files are specific to
+    some back-ends, to some protocols. Please also note that some configuration files are not required for Guice. In this
+    case, it will be specified.</p>
        
     <p>You can/must configure James for the following:</p>
     
@@ -61,17 +68,17 @@
       </tr>
       <tr>
         <td><a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/mailbox-template.xml">mailbox.xml</a></td>
-        <td><a href="config-mailbox.html">Mailbox Configuration</a></td>
+        <td><a href="config-mailbox.html">Mailbox Configuration (Spring only)</a></td>
         <td></td>
       </tr>
       <tr>
         <td><a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/quota-template.xml">mailbox.xml</a></td>
-        <td><a href="config-quota.html">Quota Configuration</a></td>
+        <td><a href="config-quota.html">Quota Configuration (Spring only)</a></td>
         <td></td>
       </tr>
       <tr>
         <td><a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/events-template.xml">events.xml</a></td>
-        <td><a href="config-events.html">Event system Configuration</a></td>
+        <td><a href="config-events.html">Event system Configuration (Spring only)</a></td>
         <td></td>
       </tr>
       <tr>
@@ -111,7 +118,7 @@
       </tr>
       <tr>
         <td><a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/fetchmail-template.xml">fetchmail.xml</a></td>
-        <td><a href="config-fetchmail.html">FetchMail Configuration</a></td>
+        <td><a href="config-fetchmail.html">FetchMail Configuration (Spring only)</a></td>
         <td></td>
       </tr>
 


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


[15/21] james-project git commit: JAMES-1789 Update download instructions to latest released version

Posted by bt...@apache.org.
JAMES-1789 Update download instructions to latest released version


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/426b7300
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/426b7300
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/426b7300

Branch: refs/heads/master
Commit: 426b730079b531dc23a6e40daea36a6355c2f6d7
Parents: 884072a
Author: benwa <bt...@linagora.com>
Authored: Sat Jun 10 10:31:50 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:45 2017 +0700

----------------------------------------------------------------------
 src/site/xdoc/server/index.xml | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/426b7300/src/site/xdoc/server/index.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/index.xml b/src/site/xdoc/server/index.xml
index 4d2064c..18af545 100644
--- a/src/site/xdoc/server/index.xml
+++ b/src/site/xdoc/server/index.xml
@@ -40,11 +40,11 @@
 	      <a href="manage.html">manage</a>, <a href="monitor.html">monitor</a> 
 	      and <a href="dev.html">develop</a> Apache James Server.</p>
 
-        <p>Download Apache James Mail Server 3.0-beta4 and <a href="quick-start.html">quick-start</a> it!</p>
+        <p>Download Apache James Mail Server 3.0-RC1 and <a href="quick-start.html">quick-start</a> it!</p>
         <p>
           <span class="minibutton btn-download">
             <a href="http://james.apache.org/download.cgi#Apache_James_Server">
-              <span><span class="icon"></span>Early Apache James Server 3.0-beta4</span>
+              <span><span class="icon"></span>Early Apache James Server 3.0-RC1</span>
             </a>
           </span>
         </p>


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


[14/21] james-project git commit: JAMES-1789 Mailet news should be part of James news

Posted by bt...@apache.org.
JAMES-1789 Mailet news should be part of James news


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/fcfb1f7c
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/fcfb1f7c
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/fcfb1f7c

Branch: refs/heads/master
Commit: fcfb1f7cea072626aeaacb818d12accbfac3427d
Parents: 4eb95d6
Author: benwa <bt...@linagora.com>
Authored: Sat Jun 10 10:39:47 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:45 2017 +0700

----------------------------------------------------------------------
 .../_posts/2012-12-08-mailet-2.5.0.markdown     | 12 ++++++
 src/site/xdoc/mailet/index.xml                  | 39 --------------------
 2 files changed, 12 insertions(+), 39 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/fcfb1f7c/src/homepage/_posts/2012-12-08-mailet-2.5.0.markdown
----------------------------------------------------------------------
diff --git a/src/homepage/_posts/2012-12-08-mailet-2.5.0.markdown b/src/homepage/_posts/2012-12-08-mailet-2.5.0.markdown
new file mode 100644
index 0000000..9c5d907
--- /dev/null
+++ b/src/homepage/_posts/2012-12-08-mailet-2.5.0.markdown
@@ -0,0 +1,12 @@
+---
+layout: post
+title:  "Apache James Mailet 2.5.0 Released"
+date:   2012-12-08 16:13:22 +0200
+categories: james update
+---
+
+Apache Mailet 2.5.0 released.
+
+This release brings all components under the same project so future releases will be made with
+all of them. All Mailet artifact have the same version, names that start with apache-mailet-*
+and are OSGi bundles.
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/james-project/blob/fcfb1f7c/src/site/xdoc/mailet/index.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/mailet/index.xml b/src/site/xdoc/mailet/index.xml
index 9e501fa..1321f2a 100644
--- a/src/site/xdoc/mailet/index.xml
+++ b/src/site/xdoc/mailet/index.xml
@@ -44,45 +44,6 @@
                     <a href='http://james.apache.org/download.cgi'>here</a>.
                 </p>
             </subsection>
-            <subsection name='News'>
-                <ul>
-                    <li>2012 December -
-                        <a href="http://james.apache.org/mailet/">Apache Mailet</a>
-                        2.5.0 released.
-                        This release brings all components under the same project so future releases will be made with
-                        all of them. All Mailet artifact have the same version, names that start with apache-mailet-*
-                        and are OSGi bundles.
-                    </li>
-                    <li>2009 May -
-                        <a href='http://james.apache.org/mailet/crypto' rel='tag'>Apache Crypto Mailets</a>
-                        1.0 released. This package contains mailets which encode, decode, sign and verify mail
-                        plus cryptology utilities. This code has previously been bundled with
-                        <a href='http://james.apache.org/server'>Apache James Server</a>.
-                        For more information, see the
-                        <a href='http://james.apache.org/mailet/crypto/release-notes.html'>release notes</a>.
-                    </li>
-                    <li>2009 Apr -
-                        <a href='http://james.apache.org/mailet/base/' rel='tag'>Apache Mailet Base</a>
-                        1.0 released. Mailbox base is a basic mailet toolkit. This code has previously been bundled with
-                        <a href='http://james.apache.org/server'>Apache James Server</a>.
-                        For more information, see the
-                        <a href='http://james.apache.org/mailet/base/release-notes.html'>release notes</a>.
-                    </li>
-                    <li>2009 Feb -
-                        <a href='http://james.apache.org/mailet/mailetdocs-maven-plugin/' rel='tag'>MailetDocs</a>
-                        <a href='http://maven.apache.org' rel='tag'>Maven</a>
-                        Plugin 0.1 released. This is the first
-                        release of this catalog generator.
-                        For more information, see the
-                        <a href='http://james.apache.org/mailet/mailetdocs-maven-plugin/release-notes.html'>release
-                            notes</a>.
-                    </li>
-                    <li>2009 Jan -
-                        <a href='http://james.apache.org/mailet/api/index.html' rel='tag'>Apache Mailet 2.4</a>
-                        released. Available<a href='http://james.apache.org/download.cgi'>here</a>.
-                    </li>
-                </ul>
-            </subsection>
         </section>
         <section name='Further Information'>
             <ul>


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


[13/21] james-project git commit: JAMES-1789 Remove all references to nightly builds

Posted by bt...@apache.org.
JAMES-1789 Remove all references to nightly builds


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/4eb95d63
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/4eb95d63
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/4eb95d63

Branch: refs/heads/master
Commit: 4eb95d63252a90142be8e73fb836a5b950757da8
Parents: 426b730
Author: benwa <bt...@linagora.com>
Authored: Sat Jun 10 10:33:25 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:45 2017 +0700

----------------------------------------------------------------------
 src/site/xdoc/download.xml | 22 ----------------------
 1 file changed, 22 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/4eb95d63/src/site/xdoc/download.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/download.xml b/src/site/xdoc/download.xml
index 2ca6fb4..40374d1 100644
--- a/src/site/xdoc/download.xml
+++ b/src/site/xdoc/download.xml
@@ -136,28 +136,6 @@ is found <a href='http://www.apache.org/licenses/exports/'>here</a>.
       </code></p>
     
     </subsection>
-  
-    <subsection name="Nightly Builds">
-   
-      <p>The software listed above represents the latest Release Build
-         available from the Apache James Project.</p>
-<!-- 
-Do not promote snapshots, See JAMES-1558
-
-      <p>The James project also provides 
-         <a href="http://people.apache.org/builds/james/nightly/">Nighly Builds</a>:
-        <u>periodic snapshots during development</u>. Generally, these are considered
-        stable snapshots, but they have not undergone as much testing as a
-        Release Build, nor have they been voted upon for release by the
-        developer community. These are simply convenient test builds.
-        Sometimes the purpose for a Nightly Build could be soliciting feedback on
-        a specific change.</p>
-    
-      <p>James continous integration can be found on 
-      <a href="https://hudson.apache.org/hudson/view/G-L/view/James/">Hudson</a>.</p>
--->    
-  
-    </subsection>
 
   </section>
 


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


[09/21] james-project git commit: JAMES-1789 consolidate advantage "Manageable"

Posted by bt...@apache.org.
JAMES-1789 consolidate advantage "Manageable"


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/907d7178
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/907d7178
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/907d7178

Branch: refs/heads/master
Commit: 907d71789587b1cadec0d8f722d67c58474645a9
Parents: 7c69293
Author: benwa <bt...@linagora.com>
Authored: Sat Jun 10 10:04:46 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:35 2017 +0700

----------------------------------------------------------------------
 src/site/xdoc/server/advantages.xml | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/907d7178/src/site/xdoc/server/advantages.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/advantages.xml b/src/site/xdoc/server/advantages.xml
index ed3238c..62ff569 100644
--- a/src/site/xdoc/server/advantages.xml
+++ b/src/site/xdoc/server/advantages.xml
@@ -63,7 +63,9 @@
 
         <subsection name="Manageable">
 
-          <p>Manage domains, users,... via well-known JMX tools - <a href="manage.html">read more</a>.</p>
+          <p>Manage domains, users,... via a <a href="manage-cli.html">command line client</a>, a <a href="manage-webadmin.html">
+            REST interface</a> or a well-known JMX tools - <a href="manage.html">read more</a>.See also <a href="metrics.html">
+            metrics</a> in live with Grafana.</p>
 
           <p><img src="images/jmx-management/jmx-user-part.png" /></p>
 


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


[19/21] james-project git commit: JAMES-1789 Reindent config-system

Posted by bt...@apache.org.
JAMES-1789 Reindent config-system


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/6f2af02b
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/6f2af02b
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/6f2af02b

Branch: refs/heads/master
Commit: 6f2af02bacf1b301b3c6fe1514c0a968e63281c0
Parents: 671a5ed
Author: benwa <bt...@linagora.com>
Authored: Wed Jun 14 13:34:05 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:53 2017 +0700

----------------------------------------------------------------------
 src/site/xdoc/server/config-system.xml | 282 ++++++++++++++--------------
 1 file changed, 141 insertions(+), 141 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/6f2af02b/src/site/xdoc/server/config-system.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/server/config-system.xml b/src/site/xdoc/server/config-system.xml
index e7c66c1..08098b7 100644
--- a/src/site/xdoc/server/config-system.xml
+++ b/src/site/xdoc/server/config-system.xml
@@ -19,147 +19,147 @@
 -->
 <document>
 
- <properties>
-  <title>Apache James Server 3 - Server Wide Configuration</title>
- </properties>
-
-<body>
-
-  <section name="Server Wide Configuration">
-  
-    <subsection name="Introduction">
-    
-      <p>There are a number of global configuration files that do not fall into any one 
-        component. They have effects that are global in scope across the server.</p>
-      
-      <p>Some of these files are crucial, while others can be ignored by any but the most sophisticated 
-        server administrators.</p>
-        
-    </subsection>
-    
-    <subsection name="spring-server.xml">
-    
-      <p>In James distribution, the spring files are located under conf/context folder and splitted into a main 
-         file (james-server-context.xml) which imports 4 other files (1 per mailbox type): james-mailbox-jcr-context.xml, james-mailbox-jpa-context.xml, 
-         james-mailbox-maildir-context.xml, james-mailbox-memory-context.xml.</p>
-    
-      <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/container/spring/src/main/resources/META-INF/org/apache/james/spring-server.xml">spring-server.xml</a> in GIT to
-         get some examples and hints.</p>
-      
-      <p>spring beans files are the place where the Apache James Server wiring is done. It should be modified only by expert-users.</p>
-      
-      <p>In combination with james-database.properties and META-INF/persistence.xml, the datasource to access the database is defined in spring-server.xml</p>
-      
-    </subsection>
-
-    <subsection name="james-database.properties">
-
-        <p>This configuration file is only relevant when using JPA, with Spring or Guice.</p>
-
-      <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/james-database-template.properties">james-database.properties</a> in GIT to get some examples and hints.</p>
-
-      <p>The database connection in database.properties</p>
-
-      <p>James has the capacity to use a JDBC-compatible database for storage of both message and user 
-         data. This section explains how to configure James to utilize a database for storage.</p>
-    
-      <p>To avoid vendor-specific issues, the JPA (Java Persistence Architecture) is used (using the Apache OpenJPA implementation).</p>
-      
-      <p>There must be a database instance accessible from the James server.  An account with appropriate
-         privileges (select, insert, delete into tables, and on initial startup creation of tables) and
-         with sufficient quota for the data to be inserted into the database must be available.</p>
-      
-      <p>Also, since James will use JDBC to access the database, an appropriate JDBC driver must be 
-         available for installation. You can place the JDBC driver jar in the conf/lib folder, it will
-         be automatically loaded.</p>
-      
-      <dl>
-        <dt><strong>database.driverClassName</strong></dt>
-        <dd>he class name of the database driver to be used.</dd>
-        <dt><strong>database.url</strong></dt>
-        <dd>The JDBC connection URL for your database/driver.</dd>
-        <dt><strong>database.username</strong></dt>
-        <dd>The user id of the database account to be used by this connection.</dd>
-        <dt><strong>database.password</strong></dt>
-        <dd>The password of the database account to be used by this connection.</dd>
-        <dt><strong>vendorAdapter.database</strong></dt>
-        <dd>Supported adapters are: DB2, DERBY, H2, HSQL, INFORMIX, MYSQL, ORACLE, POSTGRESQL, SQL_SERVER, SYBASE .</dd>
-        <dt><strong>openjpa.streaming</strong></dt>
-        <dd>true or false - Use streaming for Blobs. This is only supported on a limited set of databases atm. You
-        should check if its supported by your DB before enable it. See <a href="http://openjpa.apache.org/builds/latest/docs/manual/ref_guide_mapping_jpa.html">http://openjpa.apache.org/builds/latest/docs/manual/ref_guide_mapping_jpa.html</a> (#7.11. LOB Streaming).</dd>
-      </dl>
-      
-      <p>Note for postgresql databases: Add standard_conforming_strings=off to your postgresql.xml, otherwise you 
-        will get ""Invalid escape string Hint: Escape string must be empty or one character. {prepstmnt 174928937 
-        SELECT t0.mailbox_id, t0.mailbox_highest_modseq, t0.mailbox_last_uid, t0.mailbox_name, t0.mailbox_namespace,
-         t0.mailbox_uid_validity, t0.user_name FROM public.james_mailbox t0 WHERE (t0.mailbox_name LIKE ? 
-         ESCAPE '\\' AND t0.user_name = ? AND t0.mailbox_namespace = ?) [params=?, ?, ?]} [code=0, state=22025]"</p>
-         
-    </subsection>
-    
-    <subsection name="META-INF/persistence.xml">
-    
-      <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/META-INF/persistence.xml">META-INF/persistence.xml</a> in GIT to get some examples and hints.</p>
-      
-      <p>The JPA mapping and properties are defined in the in META-INF/persistence.xml.</p>
-      
-      <p>You can override the definition in external file and importing the external file in the persistence.xml (see jpa-mappings.xml provided example in GIT)</p>
-
-            <source>
-&lt;mapping-file&gt;META-INF/jpa-mappings.xml&lt;/mapping-file&gt;</source>
-    
-      </subsection>
-
-    <subsection name="jmx.properties">
-    
-      <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/jmx-template.properties">jmx.properties</a> in GIT to get some examples and hints.</p>
-      
-      <p>This is used to configure the JMX MBean server via which all management is achieved (also used by via the james-cli).</p>
-      
-      <dl>
-        <dt><strong>jmx.address</strong></dt>
-        <dd>The IP address (host name) the MBean Server will bind/listen to.</dd>
-        <dt><strong>jmx.port</strong></dt>
-        <dd>The port number the MBean Server will bind/listen to.</dd>
-      </dl>
-      
-      <p>To access from a remote location, it has been reported that -Dcom.sun.management.jmxremote.ssl=false is 
-         needed in the startup script.</p>
-
-    </subsection>
-
-    <subsection name="sqlResources.xml">
-    
-      <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/sqlResources.xml">sqlResources.xml</a> in GIT to get some examples and hints.</p>
-      
-      <p>This file is deprecated but some mailets... still need it. The standard way to access database
-         is JPA, but some functionalities are not yet migrated and still need the sqlResources.xml resources.</p>
-    
-      <p>The precise SQL statements used by Apache James Server to modify and view data stored in the database 
-         are specified in sqlResources.xml file.</p>
-      
-      <p>If you are using a SQL database with unusual SQL commands or data types, you may
-         need to add special entries to this file.  The James team
-         does try to keep sqlResources.xml updated, so if you do run into a
-         special case, please let us know.</p>
-      
-      <p>Also, if the database tables are not created a priori, but rather are to be created by James
-         upon startup, special attention should be paid to the "create table" statements in this file.  Such
-         statements tend to be both very database and very database instance specific.</p>
-
-    </subsection>
-
-    <subsection name="JCR Repository Configuration">
-
-      <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/jcr-repository-template.xml">jcr-repository.xml</a> in GIT to get some examples and hints.</p>
-      
-      <p>Used to configure the JCR mailbox (if configure in mailbox.xml).</p>
-
-    </subsection>
-
-  </section>
-
-</body>
+    <properties>
+        <title>Apache James Server 3 - Server Wide Configuration</title>
+    </properties>
+
+    <body>
+
+        <section name="Server Wide Configuration">
+
+            <subsection name="Introduction">
+
+                <p>There are a number of global configuration files that do not fall into any one
+                    component. They have effects that are global in scope across the server.</p>
+
+                <p>Some of these files are crucial, while others can be ignored by any but the most sophisticated
+                    server administrators.</p>
+
+            </subsection>
+
+            <subsection name="spring-server.xml">
+
+                <p>In James distribution, the spring files are located under conf/context folder and splitted into a main
+                    file (james-server-context.xml) which imports 4 other files (1 per mailbox type): james-mailbox-jcr-context.xml, james-mailbox-jpa-context.xml,
+                    james-mailbox-maildir-context.xml, james-mailbox-memory-context.xml.</p>
+
+                <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/container/spring/src/main/resources/META-INF/org/apache/james/spring-server.xml">spring-server.xml</a> in GIT to
+                    get some examples and hints.</p>
+
+                <p>spring beans files are the place where the Apache James Server wiring is done. It should be modified only by expert-users.</p>
+
+                <p>In combination with james-database.properties and META-INF/persistence.xml, the datasource to access the database is defined in spring-server.xml</p>
+
+            </subsection>
+
+            <subsection name="james-database.properties">
+
+                <p>This configuration file is only relevant when using JPA, with Spring or Guice.</p>
+
+                <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/james-database-template.properties">james-database.properties</a> in GIT to get some examples and hints.</p>
+
+                <p>The database connection in database.properties</p>
+
+                <p>James has the capacity to use a JDBC-compatible database for storage of both message and user
+                    data. This section explains how to configure James to utilize a database for storage.</p>
+
+                <p>To avoid vendor-specific issues, the JPA (Java Persistence Architecture) is used (using the Apache OpenJPA implementation).</p>
+
+                <p>There must be a database instance accessible from the James server.  An account with appropriate
+                    privileges (select, insert, delete into tables, and on initial startup creation of tables) and
+                    with sufficient quota for the data to be inserted into the database must be available.</p>
+
+                <p>Also, since James will use JDBC to access the database, an appropriate JDBC driver must be
+                    available for installation. You can place the JDBC driver jar in the conf/lib folder, it will
+                    be automatically loaded.</p>
+
+                <dl>
+                    <dt><strong>database.driverClassName</strong></dt>
+                    <dd>he class name of the database driver to be used.</dd>
+                    <dt><strong>database.url</strong></dt>
+                    <dd>The JDBC connection URL for your database/driver.</dd>
+                    <dt><strong>database.username</strong></dt>
+                    <dd>The user id of the database account to be used by this connection.</dd>
+                    <dt><strong>database.password</strong></dt>
+                    <dd>The password of the database account to be used by this connection.</dd>
+                    <dt><strong>vendorAdapter.database</strong></dt>
+                    <dd>Supported adapters are: DB2, DERBY, H2, HSQL, INFORMIX, MYSQL, ORACLE, POSTGRESQL, SQL_SERVER, SYBASE .</dd>
+                    <dt><strong>openjpa.streaming</strong></dt>
+                    <dd>true or false - Use streaming for Blobs. This is only supported on a limited set of databases atm. You
+                        should check if its supported by your DB before enable it. See <a href="http://openjpa.apache.org/builds/latest/docs/manual/ref_guide_mapping_jpa.html">http://openjpa.apache.org/builds/latest/docs/manual/ref_guide_mapping_jpa.html</a> (#7.11. LOB Streaming).</dd>
+                </dl>
+
+                <p>Note for postgresql databases: Add standard_conforming_strings=off to your postgresql.xml, otherwise you
+                    will get ""Invalid escape string Hint: Escape string must be empty or one character. {prepstmnt 174928937
+                    SELECT t0.mailbox_id, t0.mailbox_highest_modseq, t0.mailbox_last_uid, t0.mailbox_name, t0.mailbox_namespace,
+                    t0.mailbox_uid_validity, t0.user_name FROM public.james_mailbox t0 WHERE (t0.mailbox_name LIKE ?
+                    ESCAPE '\\' AND t0.user_name = ? AND t0.mailbox_namespace = ?) [params=?, ?, ?]} [code=0, state=22025]"</p>
+
+            </subsection>
+
+            <subsection name="META-INF/persistence.xml">
+
+                <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/META-INF/persistence.xml">META-INF/persistence.xml</a> in GIT to get some examples and hints.</p>
+
+                <p>The JPA mapping and properties are defined in the in META-INF/persistence.xml.</p>
+
+                <p>You can override the definition in external file and importing the external file in the persistence.xml (see jpa-mappings.xml provided example in GIT)</p>
+
+                <source>
+                    &lt;mapping-file&gt;META-INF/jpa-mappings.xml&lt;/mapping-file&gt;</source>
+
+            </subsection>
+
+            <subsection name="jmx.properties">
+
+                <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/jmx-template.properties">jmx.properties</a> in GIT to get some examples and hints.</p>
+
+                <p>This is used to configure the JMX MBean server via which all management is achieved (also used by via the james-cli).</p>
+
+                <dl>
+                    <dt><strong>jmx.address</strong></dt>
+                    <dd>The IP address (host name) the MBean Server will bind/listen to.</dd>
+                    <dt><strong>jmx.port</strong></dt>
+                    <dd>The port number the MBean Server will bind/listen to.</dd>
+                </dl>
+
+                <p>To access from a remote location, it has been reported that -Dcom.sun.management.jmxremote.ssl=false is
+                    needed in the startup script.</p>
+
+            </subsection>
+
+            <subsection name="sqlResources.xml">
+
+                <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/sqlResources.xml">sqlResources.xml</a> in GIT to get some examples and hints.</p>
+
+                <p>This file is deprecated but some mailets... still need it. The standard way to access database
+                    is JPA, but some functionalities are not yet migrated and still need the sqlResources.xml resources.</p>
+
+                <p>The precise SQL statements used by Apache James Server to modify and view data stored in the database
+                    are specified in sqlResources.xml file.</p>
+
+                <p>If you are using a SQL database with unusual SQL commands or data types, you may
+                    need to add special entries to this file.  The James team
+                    does try to keep sqlResources.xml updated, so if you do run into a
+                    special case, please let us know.</p>
+
+                <p>Also, if the database tables are not created a priori, but rather are to be created by James
+                    upon startup, special attention should be paid to the "create table" statements in this file.  Such
+                    statements tend to be both very database and very database instance specific.</p>
+
+            </subsection>
+
+            <subsection name="JCR Repository Configuration">
+
+                <p>Consult <a href="https://github.com/apache/james-project/tree/master/server/app/src/main/resources/jcr-repository-template.xml">jcr-repository.xml</a> in GIT to get some examples and hints.</p>
+
+                <p>Used to configure the JCR mailbox (if configure in mailbox.xml).</p>
+
+            </subsection>
+
+        </section>
+
+    </body>
 
 </document>
 


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


[04/21] james-project git commit: JAMES-1789 Add a complete documentation page for cli

Posted by bt...@apache.org.
JAMES-1789 Add a complete documentation page for cli


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/6d57db02
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/6d57db02
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/6d57db02

Branch: refs/heads/master
Commit: 6d57db0220d5c07df57e3af3759769fd06e94533
Parents: 39bd19d
Author: benwa <bt...@linagora.com>
Authored: Thu Jun 8 21:24:44 2017 +0700
Committer: benwa <bt...@linagora.com>
Committed: Wed Jun 14 15:01:25 2017 +0700

----------------------------------------------------------------------
 src/site/markdown/server/manage-cli.md | 276 ++++++++++++++++++++++++++++
 src/site/site.xml                      |   3 +-
 2 files changed, 278 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/6d57db02/src/site/markdown/server/manage-cli.md
----------------------------------------------------------------------
diff --git a/src/site/markdown/server/manage-cli.md b/src/site/markdown/server/manage-cli.md
new file mode 100644
index 0000000..5003828
--- /dev/null
+++ b/src/site/markdown/server/manage-cli.md
@@ -0,0 +1,276 @@
+Manage James via the Command Line
+=================================
+
+With any packaging, James is packed with a command line client.
+
+To use it enter, for Spring distrubution:
+
+```
+./bin/james-cli.sh -h 127.0.0.1 -p 9999 COMMAND
+```
+
+And for Guice distributions:
+
+```
+java -jar /root/james-cli.jar -h 127.0.0.1 -p 9999 COMMAND
+```
+
+The following document will explain you which are the available options for **COMMAND**.
+
+Note: the command line before **COMMAND** will be documente as *{cli}*.
+
+## Manage Domains
+
+Domains represent the domain names handled by your server.
+
+You can add a domain:
+
+```
+{cli} AddDomain domain.tld
+```
+
+You can remove a domain:
+
+```
+{cli} RemoveDomain domain.tld
+```
+
+(Note: associated users are not removed automatically)
+
+Check if a domain is handled:
+
+```
+{cli} ContainsDomain domain.tld
+```
+
+And list your domains:
+
+```
+{cli} ListDomains
+```
+
+## Managing users
+
+Users are accounts on the mail server. James can maintain mailboxes for them.
+
+You can add a user:
+
+```
+{cli} AddUser user@domain.tld password
+```
+
+Note: the domain used should have been previously created.
+
+You can delete a user:
+
+```
+{cli} RemoveUser user@domain.tld
+```
+
+(Note: associated mailboxes are not removed automatically)
+
+And change a user password:
+
+```
+{cli} SetPassword user@domain.tld password
+```
+
+Note: All these write operations can not be performed on LDAP backend, as the implementation is read-only.
+
+Finally, you can list users:
+
+```
+{cli} ListUsers
+```
+
+## Managing mailboxes
+
+An administrator can perform some basic operation on user mailboxes.
+
+Note on mailbox formatting: mailboxes are composed of three parts.
+
+ - The namespace, indicating what kind of mailbox it is. (Shared or not?). The value for users mailboxes is #private . Note that for now no other values are supported as James do not support shared mailboxes.
+ - The username.
+ - And finally mailbox name. Be aware that '.' serves as mailbox hierarchy delimiter.
+
+An administrator can delete all of the mailboxes of a user, which is not done automatically when removing a user (to avoid data loss):
+
+```
+{cli} DeleteUserMailboxes user@domain.tld
+```
+
+He can delete a specific mailbox:
+
+```
+{cli} DeleteMailbox #private user@domain.tld INBOX.toBeDeleted
+```
+
+He can list the mailboxes of a specific user:
+
+```
+{cli} ListUserMailboxes user@domain.tld
+```
+
+And finally can create a specific mailbox:
+
+```
+{cli} CreateMailbox #private user@domain.tld INBO.newFolder
+```
+
+## Managing mappings
+
+A mapping is a recipient rewritting rule. There is several kind of rewritting rules:
+
+ - address mapping: rewrite a given mail address into an other one.
+ - regex mapping.
+
+You can manage address mapping like (redirects email from user@domain.tld to redirected@domain.new, then deletes the mapping):
+
+```
+{cli} AddAddressMapping redirected domain.new user@domain.tld
+{cli} RemoveAddressMapping redirected domain.new user@domain.tld
+```
+
+You can manage regex mapping like this:
+
+```
+{cli} AddRegexMapping redirected domain.new .*@domain.tld
+{cli} RemoveRegexMapping redirected domain.new .*@domain.tld
+```
+
+You can view mapping for a mail address:
+
+```
+{cli} ListUserDomainMappings user domain.tld
+```
+
+And all mappings defined on the server:
+
+```
+{cli} ListMappings
+```
+
+## Manage quotas
+
+Quotas are limitations on a group of mailboxes. They can limit the **size** or the **messages count** in a group of mailboxes.
+
+James groups by defaults mailboxes by user (but it can be overridden), and labels each group with a quotaroot.
+
+To get the quotaroot a given mailbox belongs to:
+
+```
+{cli} GetQuotaroot #private user@domain.tld INBOX
+```
+
+Then you can get the specific quotaroot limitations.
+
+For the number of messages:
+
+```
+{cli} GetMessageCountQuota quotaroot
+```
+
+And for the storage space available:
+
+```
+{cli} GetStorageQuota quotaroot
+```
+
+You see the maximum allowed for these values:
+
+For the number of messages:
+
+```
+{cli} GetMaxMessageCountQuota quotaroot
+```
+
+And for the storage space available:
+
+```
+{cli} GetMaxStorageQuota quotaroot
+```
+
+You can also specify maximum for these values.
+
+
+For the number of messages:
+
+```
+{cli} SetMaxMessageCountQuota quotaroot value
+```
+
+And for the storage space available:
+
+```
+{cli} SetMaxStorageQuota quotaroot value
+```
+
+With value being an integer. Please note the use of units for storage (K, M, G). For instance:
+
+
+```
+{cli} SetMaxStorageQuota someone@apache.org 4G
+```
+
+Moreover, James allows to specify defaults maximum values, at the server level. Note: syntax is similar to what was exposed previously.
+
+```
+{cli} SetDefaultMaxMessageCountQuota value
+{cli} GetDefaultMaxMessageCountQuota
+{cli} SetDefaultMaxStorageQuota value
+{cli} GetDefaultMaxStorageQuota
+```
+
+## Re-indexing
+
+James allow you to index your emails in a search engine, for making search faster. Both ElasticSearch and Lucene are supported.
+
+For some reasons, you might want to re-index your mails (inconsistencies across datastore, migrations).
+
+To re-index all mails of all mailboxes of all users, type:
+
+```
+{cli} ReindexAll
+```
+
+And for a precise mailbox:
+
+```
+{cli} Reindex #private user@domain.tld INBOX
+```
+
+## Sieve scripts quota
+
+James implements Sieve (RFC-5228). Your users can then writte scripts and upload them to the server. Thus they can
+define the desired behavior upon email reception. James defines a Sieve mailet for this, and stores Sieve scripts. You
+can update them via the ManageSieve protocol, or via the ManageSieveMailet.
+
+You can define quota for the total size of Sieve scripts, per user.
+
+Syntax is similar to what was exposed for quotas. For defaults values:
+
+```
+{cli} GetSieveQuota
+{cli} SetSieveQuota value
+{cli} RemoveSieveQuota
+```
+
+And for specific user quotas:
+
+```
+{cli} GetSieveUserQuota user@domain.tld
+{cli} SetSieveQuota user@domain.tld value
+{cli} RemoveSieveUserQuota user@domain.tld
+```
+
+## Switching of mailbox implementation
+
+Migration is experimental for now. You would need to customize **Spring** configuration to add a new mailbox manager with a different bean name.
+
+You can then copy data accross mailbox managers using:
+
+```
+{cli} CopyMailbox srcBean dstBean
+```
+
+You will then need to reconfigure James to use the new mailbox manager.

http://git-wip-us.apache.org/repos/asf/james-project/blob/6d57db02/src/site/site.xml
----------------------------------------------------------------------
diff --git a/src/site/site.xml b/src/site/site.xml
index ba4d2bb..e511b1a 100644
--- a/src/site/site.xml
+++ b/src/site/site.xml
@@ -140,8 +140,9 @@
                         <item name="Domains" href="/server/manage-domains.html" />
                         <item name="Users" href="/server/manage-users.html" />
                         <item name="Recipient Rewrite" href="/server/manage-recipientrewrite.html" />
+                        <item name="WebAdmin" href="/server/manage-webadmin.html" />
+                        <item name="Command line" href="/server/manage-cli.html" />
                         <item name="Metrics" href="/server/metrics.html" />
-                        <item name="Metrics" href="/server/manage-webadmin.html" />
                     </item>
                     <item name="5. Monitor" href="/server/monitor.html" collapse="true" >
                         <item name="Logging" href="/server/monitor-logging.html" />


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