Query timeout when running the query


I am using the python library for Stardog to create the database and load the data into the Stardog database. When I run the query, I receive an error regarding exceeding the execution time. The error is:
"QEQOE2: com.complexible.stardog.plan.eval.operator.OperatorException: Execution time exceeded query timeout 300000".

I wonder, how can I change the config for this limitation for the execution time? I want to have no limitation for the execution time. Is there any way to change it through the code below:

db = admin.new_database(database_name, {'edge.properties': True})

Or, I need to change the database configuration in other ways?


Hi Shahrzad,

The default query timeout can be set in the stardog.properties file, which should be stored in $STARDOG_HOME. You can find more documentation on this here. If you would like to override it for only one query, you can pass a timeout argument to the select function. You can see the pystardog docs on that here.


Hi Clark,

Thanks for your explanation. I used conn.select(query, timeout=0) for eliminating the timeout. But I faced an issue. I executed a query through the python code and after a while I received an error which is below:

"StardogException: [400] 0D0TU2: 6bcb59b8-178b-4efa-b8ce-7d49a0182110 is not a known transaction."

I assume that although I used timeout=0, the connection was lost due to the long execution time. Is there any way that I can solve this problem?


@shahrzadkhb are you behind a load balancer.

This is one possible scenario that cause this error occurs. Essentially the connection timeout at the LB level and in many case the maximum timeout you can configure a LB is 30 minutes.

Personally I try to keep my chunk within 10 minute for this exact reason. Another benefit, if something does occur I only loose 10 minutes at most.


Hi, serge,

I have created the instance of Stardog on docker on my local computer and trying to execute the queries through the python code with the Stardog python library. So, I assume there is no load balancer.


This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.