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 "Stefano Bagnara (JIRA)" <se...@james.apache.org> on 2006/02/22 23:22:58 UTC
[jira] Assigned: (JAMES-446) NPE while fetching mail (FetchMail)
[ http://issues.apache.org/jira/browse/JAMES-446?page=all ]
Stefano Bagnara reassigned JAMES-446:
-------------------------------------
Assign To: Stefano Bagnara
> NPE while fetching mail (FetchMail)
> -----------------------------------
>
> Key: JAMES-446
> URL: http://issues.apache.org/jira/browse/JAMES-446
> Project: James
> Type: Bug
> Components: Matchers/Mailets (bundled)
> Versions: 2.3.0a1
> Reporter: Stefano Bagnara
> Assignee: Stefano Bagnara
> Priority: Minor
> Fix For: 2.3.0a2
>
> Hi,
> i am working on an crm-import mailet vor opencustomer.org. On James 2.2.0 i have problems when i try to read hibernate config files from a jar file.
> So i tryed James 2.3.0a1 and it works fine. :-)
> But now i have another problem.
> Fetchmail throws a NullPointer Exception when fetching mails.
> I try Windows XP and Linux with Java 1.5.0_06.
> I found a mail on the mailinglist with the same exception (November, 2 , 2005, Topic:"Fetchmail and IMAP"). But there was no solution.
> Is it a James problem, or a problem with my configuration?
> Thanks, Felix
> fetchmail log file:
> 13/02/06 09:21:43 INFO fetchmail: FetchMail Started
> 13/02/06 09:21:43 INFO fetchmail.flix-noc.com: Fetcher starting fetches
> 13/02/06 09:21:43 ERROR fetchmail.flix-noc.com: An Exception has terminated this fetch.
> java.lang.NullPointerException
> at org.apache.james.fetchmail.FetchMail.computeDynamicAccounts(FetchMail.java:747)
> at org.apache.james.fetchmail.FetchMail.updateDynamicAccounts(FetchMail.java:723)
> at org.apache.james.fetchmail.FetchMail.targetTriggered(FetchMail.java:525)
> at org.apache.avalon.cornerstone.blocks.scheduler.DefaultTimeScheduler.doRunEntry(DefaultTimeScheduler.java:449)
> at org.apache.avalon.cornerstone.blocks.scheduler.DefaultTimeScheduler$1.run(DefaultTimeScheduler.java:412)
> at org.apache.excalibur.thread.impl.ExecutableRunnable.execute(ExecutableRunnable.java:55)
> at org.apache.excalibur.thread.impl.WorkerThread.run(WorkerThread.java:116)
> 13/02/06 09:21:43 INFO fetchmail.flix-noc.com: Fetcher completed fetches
> james-fetchmail.xml:
> <fetchmail enabled="true"> <fetch name="flix-noc.com">
> <accounts>
> <account customrcpt-header="X-Envelope-To"
> user="XXXX"
> password="XXXX"
> recipient="test@flix-noc.com"
> ignorercpt-header="true"/>
> </accounts>
> <host>pop.flix-noc.com</host>
> <interval>60000</interval>
> <javaMailProviderName>pop3</javaMailProviderName>
> <javaMailFolderName>INBOX</javaMailFolderName>
> <javaMailProperties>
> <property name="mail.pop3.connectiontimeout" value="180000"/>
> <property name="mail.pop3.timeout" value="180000"/> </javaMailProperties>
> <fetchall>false</fetchall>
> <recursesubfolders>false</recursesubfolders>
> <fetched leaveonserver="false" markseen="true"/>
> <remotereceivedheader index="1" reject="true" leaveonserver="true" markseen="false"/>
> <maxmessagesize limit="0" reject="false" leaveonserver="true" markseen="false"/>
> <undeliverable leaveonserver="true" markseen="false"/>
> <recipientnotfound defer="true" reject="true" leaveonserver="true" markseen="false"/> <userundefined reject="true" leaveonserver="true" markseen="false" />
> <remoterecipient reject="true" leaveonserver="true" markseen="false" />
> </fetch>
> </fetchmail>
> -------------------
> Let's see:
> FecthMail@747:
> Map newAccounts = new HashMap(
> getLocalUsers().countUsers() * getParsedDynamicAccountParameters().size());
> so the problem should be with getLocalUsers returning null or getParsedDynamicAccountParameters() returning null.
> the localUserRepository is filled in the service method.
> If you have the corret configuration in the assembly.xml you should have no problems.
> So, first thing, check that you updated your assembly.xml (this is a lot different that 2.2.0 assembly.xml)
> <!-- FetchMail Service -->
> <block name="fetchmail" class="org.apache.james.fetchmail.FetchScheduler" >
> <provide name="scheduler"
> role="org.apache.avalon.cornerstone.services.scheduler.TimeScheduler"/>
> <provide name="James" role="org.apache.james.services.MailServer"/>
> <provide name="localusersrepository" role="org.apache.james.services.UsersRepository"/>
> </block>
> <!-- This is needed to link the smtpserver to the local user repository -->
> <block name="localusersrepository" class="org.apache.james.core.LocalUsersRepository">
> <provide name="users-store"
> role="org.apache.james.services.UsersStore"/>
> </block>
> The parsedDynamicAccountParameters shouldn't be null, ever, so please check you assembly and return your feedback.
> Stefano
> ------
> Ok, the assembly.xml looks good.
> It's getLocalUsers that return null.
> It's the same problem with the latest trunk version.
> Any other ideas?
> Felix
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org