Vertica - After a large query all subsequent queries error

Note: please leave bug reports and feature requests on GitHub

Vertica - After a large query all subsequent queries error

Postby erk123 » Tue Oct 11, 2011 2:00 am

Hello,

I'm connecting to a Vertica database !
After a query on a large table that is canceled all subsequent queries return error

!ENTRY org.jkiss.dbeaver.core 4 0 2011-10-11 12:39:24.003
!MESSAGE org.jkiss.dbeaver.model.exec.DBCException: SQL Error [08006]: An I/O error occured while sending to the backend.
!STACK 0
org.jkiss.dbeaver.model.exec.DBCException: SQL Error [08006]: An I/O error occured while sending to the backend.
at org.jkiss.dbeaver.model.impl.jdbc.api.JDBCPreparedStatementImpl.executeStatement(JDBCPreparedStatementImpl.java:59)
at org.jkiss.dbeaver.runtime.sql.SQLQueryJob.executeSingleQuery(SQLQueryJob.java:312)
at org.jkiss.dbeaver.runtime.sql.SQLQueryJob.extractData(SQLQueryJob.java:476)
at org.jkiss.dbeaver.ui.editors.sql.SQLEditor$DataContainer.readData(SQLEditor.java:773)
at org.jkiss.dbeaver.ui.controls.resultset.ResultSetDataPumpJob.run(ResultSetDataPumpJob.java:47)
at org.jkiss.dbeaver.runtime.AbstractJob.run(AbstractJob.java:81)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
Caused by: com.vertica.util.PSQLException: An I/O error occured while sending to the backend.
at com.vertica.core.v3.QueryExecutorImpl.execute(Unknown Source)
at com.vertica.jdbc2.AbstractJdbc2Statement.execute(Unknown Source)
at com.vertica.jdbc2.AbstractJdbc2Statement.executeWithFlags(Unknown Source)
at com.vertica.jdbc2.AbstractJdbc2Statement.execute(Unknown Source)
at org.jkiss.dbeaver.model.impl.jdbc.api.JDBCPreparedStatementImpl.execute(JDBCPreparedStatementImpl.java:98)
at org.jkiss.dbeaver.model.impl.jdbc.api.JDBCPreparedStatementImpl.executeStatement(JDBCPreparedStatementImpl.java:56)
... 6 more
Caused by: java.io.IOException: Stream closed
at sun.nio.cs.StreamEncoder.ensureOpen(Unknown Source)
at sun.nio.cs.StreamEncoder.flush(Unknown Source)
at java.io.OutputStreamWriter.flush(Unknown Source)
at com.vertica.core.PGStream.flush(Unknown Source)
at com.vertica.core.v3.QueryExecutorImpl.sendSync(Unknown Source)
... 12 more
!SUBENTRY 1 org.jkiss.dbeaver.core 4 0 2011-10-11 12:39:24.003
!MESSAGE SQL Error [08006]: An I/O error occured while sending to the backend.
!SUBENTRY 2 org.jkiss.dbeaver.core 4 0 2011-10-11 12:39:24.003
!MESSAGE An I/O error occured while sending to the backend.
!SUBENTRY 3 org.jkiss.dbeaver.core 4 0 2011-10-11 12:39:24.003
!MESSAGE Stream closed

A connection reset is required to reset.

Thanks
erk123
 
Posts: 3
Joined: Tue Oct 11, 2011 1:52 am

Re: Vertica - After a large query all subsequent queries err

Postby Serge » Tue Oct 11, 2011 2:50 pm

Generally when you do query interruption DBeaver tries to use standard query cancelation mechanism. If if not supported by driver or it fails then DBeaver cancels entire connection. In this case all subsequent queries will fail (obviously). Now you need to invalidate or reopen connection manually.

Probably we have to add automatic connection invalidation after query cancelation by second scenario. I'll add it to feature requests..

Thanks for report!
Serge
 
Posts: 1526
Joined: Sat Feb 26, 2011 8:24 pm
Location: SPb

Re: Vertica - After a large query all subsequent queries err

Postby ignorant » Thu May 09, 2013 8:34 pm

Question though.. how do you interrupt a running query? I am using Vertica as well and I don't see a way to stop a long running query. If I try to disconnect, it still waits. The only thing I can do is kill the program but that's not ideal.

Ideas?
ignorant
 
Posts: 1
Joined: Tue Apr 02, 2013 4:12 pm

Re: Vertica - After a large query all subsequent queries err

Postby Serge » Fri May 10, 2013 10:58 am

Hello,

I'm not very familiar with Vertica but afaik it is based on PostgreSQL and query cancel works fine in PostgreSQL.
But of course it depends. If query hangs due to some network problems then it won't be canceled and you have to wait for socket timeout.
However I'm not sure that Vertica jdbc driver even supports query cancel feature.

BTW usually there is no need to kill process - there is "Emergency Exit" command in main menu.

Thanks.
Serge
 
Posts: 1526
Joined: Sat Feb 26, 2011 8:24 pm
Location: SPb


Return to Support



Who is online

Users browsing this forum: Google [Bot] and 22 guests