[Mulgara-general] RMITimeoutException

Joe Osowski josowski at plos.org
Fri Apr 15 19:06:26 UTC 2011


I'm considering paging my result sets.   If I'm passing limit and offset through to keep my result sets small.  Is `Order by` required to be sure each set of data is unique?

(Assume there are no new writes between each request)


-Joe


On 04/15/2011 11:13 AM, Alex Hall wrote:
On Fri, Apr 15, 2011 at 11:38 AM, Joe Osowski <josowski at plos.org<mailto:josowski at plos.org>> wrote:
I believe I found a bug in the Mulgara RMI client.

The mulgara.rmi.pagetimeout system setting seems to have no affect.
Note the partial stack trace (and the times they were logged).

2011-04-14 22:32:47,290 DEBUG [main] Migrator - Running Topaz Query:
select c.id<http://c.id> from UserProfile c
2011-04-14 22:33:47,384 ERROR [main] Migrate - Error querying for
UserProfile ids
java.lang.RuntimeException: Error querying for UserProfile ids
        at
org.ambraproject.service.Migrator.getObjectIDs(Migrator.java:319)
        at org.am.....
Caused by: org.mulgara.server.rmi.RMITimeoutException: No data returned
within 1200000ms
        at
org.mulgara.server.rmi.RemoteAnswerWrapperAnswer.waitForPrefetchThread(RemoteAnswerWrapperAnswer.java:492)
        at
org.mulgara.server.rmi.RemoteAnswerWrapperAnswer.nextPage(RemoteAnswerWrapperAnswer.java:458)
        at
org.mulgara.server.rmi.RemoteAnswerWrapperAnswer.next(RemoteAnswerWrapperAnswer.java:427)
        ... 7 more

I notice that the method in the Mulgara client which throws this exception silently ignores an InterruptedException while waiting on the current answer page to be fetched from the server and falls through to the timeout case.  Perhaps there is another timeout in Topaz or Ambra which is interrupting the TQL thread if it's taking too long?

It is a bug for Mulgara to silently discard this exception without reporting it, because this hides the true cause of the exception you're seeing.  But I suspect there is another thread interrupting the Mulgara client thread before the RMI timeout occurs.

-Alex



I wonder if there is a way to easily get the total count of records and
then return paged results using ordering, offset and limit.  Would this
be faster?



On 04/12/2011 07:14 PM, Alex Hall wrote:
> On Tuesday, April 12, 2011, Joe Osowski<josowski at plos.org<mailto:josowski at plos.org>>  wrote:
>> Hia!
>>
>> I'm getting a RMITimeoutException.  (for queries with large result sets)
> In general, I would expect this to be a function of the complexity of
> the query and the size of the input dataset. Because results are
> lazily fetched, a simple query that just returns lots of rows should
> start returning results quickly. Lots of joins and unions of large
> datasets can give you problems.
>
> Asking for distinct or sorted results for a large result set will also
> be slow, because the entire result set must be materialized and
> sorted. Avoid these types of queries unless you specifically need that
> behavior.
>
>> org.mulgara.server.rmi.RMITimeoutException: No data returned within 60000ms
>>
>> I would like to change the the time out to say 360000.  I've added
>> "-Dmulgara.rmi.pagetimeout=360000" to the command starting mulgara.  But
>> it appears to have no affect.
> How are you executing the query? If it's over RMI with a Java client
> then that property may need to be set in the client.
>
> -Alex
>
>
>> I'm using Mulgara 2.1.4.1.  Is there a config file I should be checking?
>>
>> -Joe
>>
>> _______________________________________________
>> Mulgara-general mailing list
>> Mulgara-general at mulgara.org<mailto:Mulgara-general at mulgara.org>
>> http://lists.mulgara.org/mailman/listinfo/mulgara-general
>>
> _______________________________________________
> Mulgara-general mailing list
> Mulgara-general at mulgara.org<mailto:Mulgara-general at mulgara.org>
> http://lists.mulgara.org/mailman/listinfo/mulgara-general
_______________________________________________
Mulgara-general mailing list
Mulgara-general at mulgara.org<mailto:Mulgara-general at mulgara.org>
http://lists.mulgara.org/mailman/listinfo/mulgara-general




More information about the Mulgara-general mailing list