[InterMine Dev] About the ObjectStoreQueryDurationException

Chen Yian chenyian at nibio.go.jp
Wed Mar 13 01:54:19 GMT 2013


Hi Fengyuan,

Thanks for your reply.
I'm sorry I forgot to attach the query, it is as follow:

<query model="genomic" view="Gene.goAnnotation.subject.primaryIdentifier 
Gene.goAnnotation.subject.name Gene.goAnnotation.subject.symbol
Gene.goAnnotation.ontologyTerm.identifier 
Gene.goAnnotation.ontologyTerm.name Gene.pathways.identifier 
Gene.pathways.name
Gene.proteins.primaryIdentifier Gene.proteins.primaryAccession 
Gene.proteins.name Gene.proteins.organism.name
Gene.proteins.proteinDomainRegions.proteinDomain.primaryIdentifier 
Gene.proteins.proteinDomainRegions.proteinDomain.name
Gene.proteins.proteinDomainRegions.proteinDomain.shortName 
Gene.proteins.proteinDomainRegions.proteinDomain.type
Gene.proteins.structuralDomains.cathClassification.level 
Gene.proteins.structuralDomains.cathClassification.cathCode
Gene.proteins.structuralDomains.cathClassification.description" 
sortOrder="Gene.goAnnotation.subject.primaryIdentifier ASC" ></query>

Though some classes or attributes are TargetMine specific, but I think 
it may not be difficult to image how the query was.

I understand most of  the case Postgres may take care the thread, and 
close it,
I just wonder if it is possible to execute something like 
pg_cancel_backend when we throw an exception and decide to quit?

By the way, I also think we should catch the exception, log the query 
and response to the user with some warning.
What do you think?

All the best,

Chen

(2013/03/13 1:34), Fengyuan Hu wrote:
> Hi Chen,
>
> Sorry you had the problem. Postgres will normally take some time to 
> close the threads, for a large query, it's suppose to take longer, and 
> it's bad at estimating running time of a query.
> It's a bit hard for us to investigate further without accessing your 
> mine from outside world. Could send us an example of the query?
>
> Cheers
> Fengyuan
>
> On 12/03/13 09:22, Chen Yian wrote:
>> Hi all,
>>
>> Someone constructed an improper query which associated with many 
>> classes and without any constraint.
>> Since the query could be expected to return several million results,
>> when it was executed I got the ObjectStoreQueryDurationException 
>> finally.
>> Though the system threw the Exception and stopped working for the 
>> query, PostgreSQL was still running.
>> These threads occupied all resources for a while and some of them 
>> even hang.
>> Probably the problem itself is related to PostgreSQL,
>> but is there any suggestion for preventing this kind of 'accident'?
>>
>> Best,
>>
>> Chen
>>
>>
>>
>>
>> _______________________________________________
>> dev mailing list
>> dev at intermine.org
>> http://mail.intermine.org/cgi-bin/mailman/listinfo/dev
>
>




More information about the dev mailing list