samiulsami commented on PR #2587:
URL: https://github.com/apache/james-project/pull/2587#issuecomment-2647214064

   Hello,
   The postgres app halts with the following fatal error IFF I run with JMAP 
enabled:
   ```
   05:26:19.694 [ERROR] o.a.j.GuiceJamesServer - Fatal error while starting 
James
   org.apache.commons.configuration2.ex.ConfigurationException: Missing 
org.apache.james.jmap.mailet.filter.JMAPFiltering in mailets configuration 
(mailetcontainer -> processors -> transport).
           at 
org.apache.james.modules.server.MailetContainerModule$ProcessorsCheck$Impl.lambda$check$3(MailetContainerModule.java:311)
           at java.base/java.util.Optional.orElseThrow(Unknown Source)
           at 
org.apache.james.modules.server.MailetContainerModule$ProcessorsCheck$Impl.check(MailetContainerModule.java:310)
           at 
org.apache.james.modules.server.MailetContainerModule$ProcessorsCheck$Or.lambda$check$0(MailetContainerModule.java:262)
           at java.base/java.util.stream.ReferencePipeline$7$1.accept(Unknown 
Source)
           at 
java.base/java.util.Spliterators$ArraySpliterator.forEachRemaining(Unknown 
Source)
           at java.base/java.util.stream.AbstractPipeline.copyInto(Unknown 
Source)
           at 
java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(Unknown Source)
           at 
java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(Unknown Source)
           at java.base/java.util.stream.AbstractPipeline.evaluate(Unknown 
Source)
           at java.base/java.util.stream.ReferencePipeline.collect(Unknown 
Source)
           at 
org.apache.james.modules.server.MailetContainerModule$ProcessorsCheck$Or.check(MailetContainerModule.java:267)
           at 
org.apache.james.modules.server.MailetContainerModule$MailetModuleInitializationOperation.checkProcessors(MailetContainerModule.java:223)
           at 
org.apache.james.modules.server.MailetContainerModule$MailetModuleInitializationOperation.initModule(MailetContainerModule.java:184)
           at 
com.github.fge.lambdas.consumers.ConsumerChainer.lambda$sneakyThrow$9(ConsumerChainer.java:73)
           at java.base/java.util.stream.ReferencePipeline$15$1.accept(Unknown 
Source)
           at java.base/java.util.ArrayList.forEach(Unknown Source)
           at java.base/java.util.stream.SortedOps$RefSortingSink.end(Unknown 
Source)
           at java.base/java.util.stream.DistinctOps$1$2.end(Unknown Source)
           at java.base/java.util.stream.Sink$ChainedReference.end(Unknown 
Source)
           at java.base/java.util.stream.AbstractPipeline.copyInto(Unknown 
Source)
           at 
java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(Unknown Source)
           at 
java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(Unknown Source)
           at java.base/java.util.stream.AbstractPipeline.evaluate(Unknown 
Source)
           at java.base/java.util.stream.ReferencePipeline.collect(Unknown 
Source)
           at 
org.apache.james.utils.InitializationOperations.processStartables(InitializationOperations.java:52)
           at 
org.apache.james.utils.InitializationOperations.initModules(InitializationOperations.java:41)
           at org.apache.james.GuiceJamesServer.start(GuiceJamesServer.java:95)
           at org.apache.james.JamesServerMain.main(JamesServerMain.java:30)
           at 
org.apache.james.PostgresJamesServerMain.main(PostgresJamesServerMain.java:181)
   ```
   ----
   
   ### Fix
   Tweak the [<b>postgres-app/sample-configuration/mailetcontainer.xml</b> 
](https://github.com/Arsnael/james-project/blob/postgresql-merge/server/apps/postgres-app/sample-configuration/mailetcontainer.xml)
 file:
   - Add these mailets under the *"transport"* processor.
   ```xml
               <mailet match="RecipientIsLocal" 
class="org.apache.james.jmap.mailet.filter.JMAPFiltering">
                   <onMailetException>ignore</onMailetException>
               </mailet>
               <mailet match="RecipientIsLocal" class="VacationMailet">
                   <onMailetException>ignore</onMailetException>
               </mailet>
   ```
   -   (Is this required?) Add this matcher under the 
*"transport.relay-allowed"* matcher
   ```xml
               <matcher match="org.apache.james.jmap.mailet.SentByJmap"/>
   ```
   The JMAP backend has been functioning smoothly after these additions, but is 
there anything else that needs changing?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@james.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscr...@james.apache.org
For additional commands, e-mail: notifications-h...@james.apache.org

Reply via email to