svn commit: r1005763 - in /james/server/trunk: spring-common/src/main/java/org/apache/james/container/spring/ spring-deployment/src/main/config/james/ spring-deployment/src/main/java/org/apache/james/
Author: norman Date: Fri Oct 8 10:19:44 2010 New Revision: 1005763 URL: http://svn.apache.org/viewvc?rev=1005763&view=rev Log: Use a BeanFactoryPostProcessor implementation to resolve filesystem urls in spring-beans.xml. This allows us to be sure that all the directories in spring-beans.xml use the same "parent". Added: james/server/trunk/spring-common/src/main/java/org/apache/james/container/spring/FileSystemResolver.java Removed: james/server/trunk/spring-deployment/src/main/java/org/apache/james/container/spring/FileSystemUtils.java Modified: james/server/trunk/spring-deployment/src/main/config/james/spring-beans.xml Added: james/server/trunk/spring-common/src/main/java/org/apache/james/container/spring/FileSystemResolver.java URL: http://svn.apache.org/viewvc/james/server/trunk/spring-common/src/main/java/org/apache/james/container/spring/FileSystemResolver.java?rev=1005763&view=auto == --- james/server/trunk/spring-common/src/main/java/org/apache/james/container/spring/FileSystemResolver.java (added) +++ james/server/trunk/spring-common/src/main/java/org/apache/james/container/spring/FileSystemResolver.java Fri Oct 8 10:19:44 2010 @@ -0,0 +1,80 @@ +/ + * Licensed to the Apache Software Foundation (ASF) under one * + * or more contributor license agreements. See the NOTICE file * + * distributed with this work for additional information* + * regarding copyright ownership. The ASF licenses this file * + * to you under the Apache License, Version 2.0 (the* + * "License"); you may not use this file except in compliance * + * with the License. You may obtain a copy of the License at * + * * + * http://www.apache.org/licenses/LICENSE-2.0 * + * * + * Unless required by applicable law or agreed to in writing, * + * software distributed under the License is distributed on an * + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * + * KIND, either express or implied. See the License for the* + * specific language governing permissions and limitations * + * under the License. * + / +package org.apache.james.container.spring; + +import java.io.FileNotFoundException; + +import org.apache.james.services.FileSystem; +import org.springframework.beans.BeansException; +import org.springframework.beans.FatalBeanException; +import org.springframework.beans.factory.config.BeanDefinition; +import org.springframework.beans.factory.config.BeanDefinitionVisitor; +import org.springframework.beans.factory.config.BeanFactoryPostProcessor; +import org.springframework.beans.factory.config.ConfigurableListableBeanFactory; + +/** + * + * {...@link BeanFactoryPostProcessor} implementation which parse the spring configuration and search for property values which are + * prefixed with {...@link #FS_PREFIX}. If such a property is found it will try to resolve the given path via the {...@link FileSystem} service + * and replace it. + */ +public class FileSystemResolver implements BeanFactoryPostProcessor{ + +private static final String FS_PREFIX ="filesystem="; + +private final FileSystemVisitor visitor = new FileSystemVisitor(); + +private FileSystem fs; + +public void setFileSystem(FileSystem fs) { +this.fs = fs; +} + + +/* + * (non-Javadoc) + * @see org.springframework.beans.factory.config.BeanFactoryPostProcessor#postProcessBeanFactory(org.springframework.beans.factory.config.ConfigurableListableBeanFactory) + */ +public void postProcessBeanFactory(ConfigurableListableBeanFactory factory) throws BeansException { +String names[] = factory.getBeanDefinitionNames(); +for (int i = 0; i < names.length; i++) { +BeanDefinition def = factory.getBeanDefinition(names[i]); +visitor.visitBeanDefinition(def); + +} +} + + +private final class FileSystemVisitor extends BeanDefinitionVisitor { + +@Override +protected String resolveStringValue(String strVal) throws BeansException { +if (strVal.startsWith(FS_PREFIX)) { +try { +return fs.getFile(strVal.substring(FS_PREFIX.length())).toString(); +} catch (FileNotFoundException e) { +throw new FatalBeanException("Unable to convert value with filesystem service", e); +} +} +return strVal; +} + +} + +} Modified: james/server/trunk/spring-deployment/src/main/config/james/spring-beans.xml URL: http://svn.apache.org/viewvc/james/server/trunk/spr
Exception-Handling
Hi List, i want to notify the Postmaster if a message causes an exception and go to the error processor. So i altered the ToRepository and added a Function. Does anyone got an eMail (eml-file) that causes an exception in the spoolmanager? Or - is there an other safe way to throw an exception in a Mailet or a Matcher ? cu es gl Frank Frank Fitzke Entwickler Fon: +49 234 388 77 217 - Fax: +49 234 388 77 210 - mobil: - - E-Mail: frank.fit...@globolog.com Globolog GmbH - Lise-Meitner-Allee 4 - 44801 Bochum Fon: +49 234 - 388 77 200 - Fax: +49 234 - 388 77 210 - E-Mail: i...@globolog.com - Web: www.globolog.com Geschäftsführer: Rainer Schulz, Rainer Stecken - Handelsregister: Bochum HRB 10560 - USt.IdNr.: DE244850223 Der Inhalt dieser Email, inklusive seiner Anhänge, ist vertraulich und ausschließlich für den bezeichneten Empfänger bestimmt. Wenn Sie nicht der vorgesehene Empfänger dieser Email oder dessen Vertreter sind, so beachten Sie bitte, dass jede Form der Kenntnisnahme, Nutzung, Veröffentlichung, Vervielfältigung oder Weitergabe unzulässig ist. Wir bitten Sie in diesem Fall, sich mit dem Absender dieser Email in Verbindung zu setzen. This e-mail is intended exclusively for the individual or entity to which it is addressed and may contain confidential or legally privileged information, which may not be disclosed under current legislation. Any form of disclosure, copying or distribution of this e-mail is strictly prohibited. If you have received this message in error, please notify the sender immediately by e-mail and delete all copies of the message. Powered by TEAM UP!® 3 Besuchen Sie uns auf der DMS Expo vom 26. - 28. Oktober 2010 auf der Messe Stuttgart, Halle 7, Stand D11 - To unsubscribe, e-mail: server-dev-unsubscr...@james.apache.org For additional commands, e-mail: server-dev-h...@james.apache.org
Re: Exception-Handling
Hi Frank, I wonder why you "hacked" the ToRepository mailet. You could just have insert the "NotifyPostmaster" mailet in the error processor. Did it not work for you ? Bye, Norman Am 08.10.2010 13:19, schrieb Frank Fitzke: Hi List, i want to notify the Postmaster if a message causes an exception and go to the error processor. So i altered the ToRepository and added a Function. Does anyone got an eMail (eml-file) that causes an exception in the spoolmanager? Or - is there an other safe way to throw an exception in a Mailet or a Matcher ? cu es gl Frank Frank Fitzke Entwickler Fon: +49 234 388 77 217 - Fax: +49 234 388 77 210 - mobil: - - E-Mail: frank.fit...@globolog.com Globolog GmbH - Lise-Meitner-Allee 4 - 44801 Bochum Fon: +49 234 - 388 77 200 - Fax: +49 234 - 388 77 210 - E-Mail: i...@globolog.com - Web: www.globolog.com Geschäftsführer: Rainer Schulz, Rainer Stecken - Handelsregister: Bochum HRB 10560 - USt.IdNr.: DE244850223 Der Inhalt dieser Email, inklusive seiner Anhänge, ist vertraulich und ausschließlich für den bezeichneten Empfänger bestimmt. Wenn Sie nicht der vorgesehene Empfänger dieser Email oder dessen Vertreter sind, so beachten Sie bitte, dass jede Form der Kenntnisnahme, Nutzung, Veröffentlichung, Vervielfältigung oder Weitergabe unzulässig ist. Wir bitten Sie in diesem Fall, sich mit dem Absender dieser Email in Verbindung zu setzen. This e-mail is intended exclusively for the individual or entity to which it is addressed and may contain confidential or legally privileged information, which may not be disclosed under current legislation. Any form of disclosure, copying or distribution of this e-mail is strictly prohibited. If you have received this message in error, please notify the sender immediately by e-mail and delete all copies of the message. Powered by TEAM UP!® 3 Besuchen Sie uns auf der DMS Expo vom 26. - 28. Oktober 2010 auf der Messe Stuttgart, Halle 7, Stand D11 - To unsubscribe, e-mail: server-dev-unsubscr...@james.apache.org For additional commands, e-mail: server-dev-h...@james.apache.org - To unsubscribe, e-mail: server-dev-unsubscr...@james.apache.org For additional commands, e-mail: server-dev-h...@james.apache.org
AW: Exception-Handling
Hi Norman, some mails i encountered can't be processed by the NotifyPostmaster-Mailet which throwed Exceptions itself. Some eMails were "very" malformed. :-( So i have to handle the exception in the very last position in the spoolmanager. cu es gl Frank > Hi Frank, > > I wonder why you "hacked" the ToRepository mailet. You could just have > insert the "NotifyPostmaster" mailet in the error processor. Did it not > work for you ? > > Bye, > Norman > > > Hi List, > > > > i want to notify the Postmaster if a message causes an exception and go to > the error processor. > > > > So i altered the ToRepository and added a Function. > > > > Does anyone got an eMail (eml-file) that causes an exception in the > spoolmanager? > > Or - is there an other safe way to throw an exception in a Mailet or a > Matcher ? > > > > cu es gl > > Frank > > Frank Fitzke Entwickler Fon: +49 234 388 77 217 - Fax: +49 234 388 77 210 - mobil: - - E-Mail: frank.fit...@globolog.com Globolog GmbH - Lise-Meitner-Allee 4 - 44801 Bochum Fon: +49 234 - 388 77 200 - Fax: +49 234 - 388 77 210 - E-Mail: i...@globolog.com - Web: www.globolog.com Geschäftsführer: Rainer Schulz, Rainer Stecken - Handelsregister: Bochum HRB 10560 - USt.IdNr.: DE244850223 Der Inhalt dieser Email, inklusive seiner Anhänge, ist vertraulich und ausschließlich für den bezeichneten Empfänger bestimmt. Wenn Sie nicht der vorgesehene Empfänger dieser Email oder dessen Vertreter sind, so beachten Sie bitte, dass jede Form der Kenntnisnahme, Nutzung, Veröffentlichung, Vervielfältigung oder Weitergabe unzulässig ist. Wir bitten Sie in diesem Fall, sich mit dem Absender dieser Email in Verbindung zu setzen. This e-mail is intended exclusively for the individual or entity to which it is addressed and may contain confidential or legally privileged information, which may not be disclosed under current legislation. Any form of disclosure, copying or distribution of this e-mail is strictly prohibited. If you have received this message in error, please notify the sender immediately by e-mail and delete all copies of the message. Powered by TEAM UP!® 3 Besuchen Sie uns auf der DMS Expo vom 26. - 28. Oktober 2010 auf der Messe Stuttgart, Halle 7, Stand D11 - To unsubscribe, e-mail: server-dev-unsubscr...@james.apache.org For additional commands, e-mail: server-dev-h...@james.apache.org
Re: Exception-Handling
Hi Frank, could you give me some more details about your enviroment. * What version of JAMES are you using ? * Could you show me a stracktrace for the NotifyPostMaster mailet ? I wonder if the exception only accours when the NotifyPostMaster Mailet tries to alter the original MimeMessage or while reading it. Unfortunaly javamail is very strict... I wonder if setting some of the "strict" properties to false would help you: http://java.sun.com/products/javamail/javadocs/javax/mail/internet/package-summary.html Bye, Norman Am 08.10.2010 13:57, schrieb Frank Fitzke: Hi Norman, some mails i encountered can't be processed by the NotifyPostmaster-Mailet which throwed Exceptions itself. Some eMails were "very" malformed. :-( So i have to handle the exception in the very last position in the spoolmanager. cu es gl Frank Hi Frank, I wonder why you "hacked" the ToRepository mailet. You could just have insert the "NotifyPostmaster" mailet in the error processor. Did it not work for you ? Bye, Norman Hi List, i want to notify the Postmaster if a message causes an exception and go to the error processor. So i altered the ToRepository and added a Function. Does anyone got an eMail (eml-file) that causes an exception in the spoolmanager? Or - is there an other safe way to throw an exception in a Mailet or a Matcher ? cu es gl Frank Frank Fitzke Entwickler Fon: +49 234 388 77 217 - Fax: +49 234 388 77 210 - mobil: - - E-Mail: frank.fit...@globolog.com Globolog GmbH - Lise-Meitner-Allee 4 - 44801 Bochum Fon: +49 234 - 388 77 200 - Fax: +49 234 - 388 77 210 - E-Mail: i...@globolog.com - Web: www.globolog.com Geschäftsführer: Rainer Schulz, Rainer Stecken - Handelsregister: Bochum HRB 10560 - USt.IdNr.: DE244850223 Der Inhalt dieser Email, inklusive seiner Anhänge, ist vertraulich und ausschließlich für den bezeichneten Empfänger bestimmt. Wenn Sie nicht der vorgesehene Empfänger dieser Email oder dessen Vertreter sind, so beachten Sie bitte, dass jede Form der Kenntnisnahme, Nutzung, Veröffentlichung, Vervielfältigung oder Weitergabe unzulässig ist. Wir bitten Sie in diesem Fall, sich mit dem Absender dieser Email in Verbindung zu setzen. This e-mail is intended exclusively for the individual or entity to which it is addressed and may contain confidential or legally privileged information, which may not be disclosed under current legislation. Any form of disclosure, copying or distribution of this e-mail is strictly prohibited. If you have received this message in error, please notify the sender immediately by e-mail and delete all copies of the message. Powered by TEAM UP!® 3 Besuchen Sie uns auf der DMS Expo vom 26. - 28. Oktober 2010 auf der Messe Stuttgart, Halle 7, Stand D11 - To unsubscribe, e-mail: server-dev-unsubscr...@james.apache.org For additional commands, e-mail: server-dev-h...@james.apache.org - To unsubscribe, e-mail: server-dev-unsubscr...@james.apache.org For additional commands, e-mail: server-dev-h...@james.apache.org
svn commit: r1005830 - /james/server/trunk/spring-deployment/src/main/config/james/smtpserver.xml
Author: eric Date: Fri Oct 8 13:56:07 2010 New Revision: 1005830 URL: http://svn.apache.org/viewvc?rev=1005830&view=rev Log: Enable ValidRcptHandler by default + document verifyIdentity is true by default Modified: james/server/trunk/spring-deployment/src/main/config/james/smtpserver.xml Modified: james/server/trunk/spring-deployment/src/main/config/james/smtpserver.xml URL: http://svn.apache.org/viewvc/james/server/trunk/spring-deployment/src/main/config/james/smtpserver.xml?rev=1005830&r1=1005829&r2=1005830&view=diff == --- james/server/trunk/spring-deployment/src/main/config/james/smtpserver.xml (original) +++ james/server/trunk/spring-deployment/src/main/config/james/smtpserver.xml Fri Oct 8 13:56:07 2010 @@ -103,6 +103,7 @@ + @@ -208,14 +209,13 @@ - - + - + - -->
svn commit: r1005906 - in /james/server/trunk/src/site: ./ apt/ xdoc/ xdoc/stylesheets/
Author: eric Date: Fri Oct 8 17:08:02 2010 New Revision: 1005906 URL: http://svn.apache.org/viewvc?rev=1005906&view=rev Log: One more safety commit for 3.0 web site (JAMES-887) Added: james/server/trunk/src/site/apt/release_notes.apt - copied, changed from r1005434, james/server/trunk/src/site/apt/release-notes.apt james/server/trunk/src/site/xdoc/adding_domains.xml - copied, changed from r1005819, james/server/trunk/src/site/xdoc/adding_domains_users.xml james/server/trunk/src/site/xdoc/adding_users.xml james/server/trunk/src/site/xdoc/adding_virtualusers.xml james/server/trunk/src/site/xdoc/domains_configuration.xml james/server/trunk/src/site/xdoc/mailetcontainer.xml - copied, changed from r1005819, james/server/trunk/src/site/xdoc/mailet_api.xml james/server/trunk/src/site/xdoc/mailetcontainer_configuration.xml - copied, changed from r1005434, james/server/trunk/src/site/xdoc/spoolmanager_configuration.xml james/server/trunk/src/site/xdoc/monitoring_instructions.xml james/server/trunk/src/site/xdoc/perfomance.xml james/server/trunk/src/site/xdoc/queue_priority.xml james/server/trunk/src/site/xdoc/queues_monitoring.xml james/server/trunk/src/site/xdoc/security.xml james/server/trunk/src/site/xdoc/stylesheets/stylesheet.css - copied unchanged from r1005819, james/server/trunk/src/site/xdoc/stylesheet.css james/server/trunk/src/site/xdoc/users_configuration.xml - copied, changed from r1005434, james/server/trunk/src/site/xdoc/userstores_configuration.xml Removed: james/server/trunk/src/site/apt/release-notes.apt james/server/trunk/src/site/xdoc/adding_domains_users.xml james/server/trunk/src/site/xdoc/mailet_api.xml james/server/trunk/src/site/xdoc/protocols.xml james/server/trunk/src/site/xdoc/spoolmanager.xml james/server/trunk/src/site/xdoc/spoolmanager_configuration.xml james/server/trunk/src/site/xdoc/stylesheet.css james/server/trunk/src/site/xdoc/userstores_configuration.xml Modified: james/server/trunk/src/site/site.xml james/server/trunk/src/site/xdoc/extend_james.xml james/server/trunk/src/site/xdoc/index.xml james/server/trunk/src/site/xdoc/summary.xml Copied: james/server/trunk/src/site/apt/release_notes.apt (from r1005434, james/server/trunk/src/site/apt/release-notes.apt) URL: http://svn.apache.org/viewvc/james/server/trunk/src/site/apt/release_notes.apt?p2=james/server/trunk/src/site/apt/release_notes.apt&p1=james/server/trunk/src/site/apt/release-notes.apt&r1=1005434&r2=1005906&rev=1005906&view=diff == --- james/server/trunk/src/site/apt/release-notes.apt (original) +++ james/server/trunk/src/site/apt/release_notes.apt Fri Oct 8 17:08:02 2010 @@ -28,15 +28,15 @@ Release Notes *3.0-M1 Release Notes The Java Apache Mail Enterprise Server (a.k.a. Apache James) Project is happy to announce the release - of version 3.0 of the Apache James server. + of version 3.0-M1 of the Apache James server. The Apache James Server is a 100% pure Java enterprise mail server based on open protocols. Currently supported are SMTP/LMTP, POP3, IMAP4 - protocols together with several different storage solutions (relational database, - maildir, jcr). + protocols together with several different storage solutions (relational database via JPA and JDBC, + maildir, JCR). - The James server also serves as a mail application platform. The James - project hosts the Apache Mailet API, and the James server has a Mailet + The James server also serves as a mail application platform. It + hosts the Apache Mailet API, and acts has a Mailet container. This feature makes it easy to design, write, and deploy custom applications for mail processing. This modularity and ease of customization is one of James' strengths, and can allow administrators @@ -50,10 +50,10 @@ Release Notes We are still actively looking for eager, capable developers to contribute to James. If you're interesting in contributing to the James project, please subscribe to the James developer mailing list. - Information about James can be found at the http://james.apache.org/";>James web site + Information about James can be found at the {{{http://james.apache.org/}James web site}} at http://james.apache.org/. Users interested in subscribing to the James - mailto:server-user-subscr...@james.apache.org";>user and - mailto:server-dev-subscr...@james.apache.org";>developer mailings lists should send emails + {{{mailto:server-user-subscr...@james.apache.org}user}} and + {{{mailto:server-dev-subscr...@james.apache.org}developer}} mailings lists should send emails to server-user-subscr...@james.apache.org and server-dev-subscr...@james.apache.org, respectively *2.3.1 Release Notes Modified: james/server/trunk/src/site/site.xml URL: http://svn.apache.or
Spring migration
Hello All, I would like to contribute to the Spring port of JAMES. It will be very good if some one tells me the steps. I do not see any bug tracker for the Spring port yet on JIRA. Kind Regards... Dhrubo
Re: Spring migration
Hi, James 3 will be soon release and runs on Spring. You can check it out from http://svn.apache.org/repos/asf/james/server/trunk/. Just compile it with mvn package and use it (dist zip is in spring-deployement/target). There some open JIRA for 3.0-M1 on https://issues.apache.org/jira/secure/BrowseVersion.jspa?id=10411&versionId=12314294&showOpenIssuesOnly=true, but come back on mailing list to talk about. Tks, Eric On 9/10/2010 06:10, Dhrubo wrote: Hello All, I would like to contribute to the Spring port of JAMES. It will be very good if some one tells me the steps. I do not see any bug tracker for the Spring port yet on JIRA. Kind Regards... Dhrubo - To unsubscribe, e-mail: server-dev-unsubscr...@james.apache.org For additional commands, e-mail: server-dev-h...@james.apache.org