Mail Attributes: Upgrading JDBC Repositories

James v2.2a9 and later support the notion of attributes on mail. These are like X-headers, except that

James v2.2 has been written to be compatible with older versions, but in order to take advantage of attributes with JDBC repositories, several steps need to be taken.

These are preliminary instructions. Please remember to backup the database and test. Please let us know of any problems.

How to to upgrade db based repositories:

  1. Stop the server.
  2. Backup the database!

  3. Alter both the "inbox" and "spool" tables in the live database by adding the message_attributes column (look for the definition in sqlResources.xml in the <sql name="createTable" ...> entry appropriate for your DBMS). Nulls must be allowed for backward and forward compatibility.

  4. Deploy the updated sqlResources.xml. The version in CVS enables attributes by default. Early versions had attributes support disabled by default; look for "attributes support" string in the sqlResources.xml, and comment/uncomment following the instructions.

  5. Block external access to the server.
  6. Restart the server.
  7. Test until satisfied (more detail to come).
  8. Allow external access to the server.

If you see a SQLException after deploying the new sqlResources.xml, it must likely means that you did not complete the table upgrade properly, and should review.

UpgradingToAttributes (last edited 2009-09-20 22:58:12 by localhost)