embulk / embulk-output-jdbc

MySQL, PostgreSQL, Redshift and generic JDBC output plugins for Embulk
Other
88 stars 89 forks source link

OracleOutputPluginTest#testInsertDirectDirectMethod fails #124

Open hito4t opened 8 years ago

hito4t commented 8 years ago
Caused by: java.lang.AssertionError
    at oracle.jdbc.driver.OraclePreparedStatement.executeBatch(OraclePreparedStatement.java:12146)
    at oracle.jdbc.driver.OracleStatementWrapper.executeBatch(OracleStatementWrapper.java:246)
    at org.embulk.output.jdbc.StandardBatchInsert.flush(StandardBatchInsert.java:74)
    at org.embulk.output.jdbc.StandardBatchInsert.finish(StandardBatchInsert.java:87)
    at org.embulk.output.jdbc.AbstractJdbcOutputPlugin$PluginPageOutput$4.run(AbstractJdbcOutputPlugin.java:976)
    at org.embulk.output.jdbc.AbstractJdbcOutputPlugin$RetryableSQLExecution.call(AbstractJdbcOutputPlugin.java:1070)
    at org.embulk.output.jdbc.AbstractJdbcOutputPlugin$RetryableSQLExecution.call(AbstractJdbcOutputPlugin.java:1058)
    at org.embulk.spi.util.RetryExecutor.run(RetryExecutor.java:100)
    at org.embulk.spi.util.RetryExecutor.runInterruptible(RetryExecutor.java:77)
    at org.embulk.output.jdbc.AbstractJdbcOutputPlugin.withRetry(AbstractJdbcOutputPlugin.java:1042)
    at org.embulk.output.jdbc.AbstractJdbcOutputPlugin.withRetry(AbstractJdbcOutputPlugin.java:1035)
    at org.embulk.output.jdbc.AbstractJdbcOutputPlugin$PluginPageOutput.finish(AbstractJdbcOutputPlugin.java:972)
    at org.embulk.exec.LocalExecutorPlugin$ScatterTransactionalPageOutput.finish(LocalExecutorPlugin.java:496)
    at org.embulk.spi.PageBuilder.finish(PageBuilder.java:244)
    at org.embulk.standards.CsvParserPlugin.run(CsvParserPlugin.java:393)
    at org.embulk.spi.FileInputRunner.run(FileInputRunner.java:154)
    at org.embulk.exec.LocalExecutorPlugin$ScatterExecutor.runInputTask(LocalExecutorPlugin.java:294)
    at org.embulk.exec.LocalExecutorPlugin$ScatterExecutor.access$000(LocalExecutorPlugin.java:212)
    at org.embulk.exec.LocalExecutorPlugin$ScatterExecutor$1.call(LocalExecutorPlugin.java:257)
    at org.embulk.exec.LocalExecutorPlugin$ScatterExecutor$1.call(LocalExecutorPlugin.java:253)
    at java.util.concurrent.FutureTask.run(FutureTask.java:262)
    ... 3 more
tadhgpearson commented 7 years ago

I'm seeing the same error in my application when I enable batching in the driver - did you figure out what causes this?

hito4t commented 7 years ago

@tadhgpearson No. insert_method: direct worked if executed in command line ( embulk run xxx.yml). But failed if executed with EmbulkEmbed. How did you execute embulk-output-oracle?

tadhgpearson commented 7 years ago

I wasn't using embark - I got this error in my own Hibernate-based application.

hito4t commented 7 years ago

I see. This problem might be caused by ClassLoader. In Embulk, Oracle JDBC Driver is not loaded by the system class loader, but by a custom class loader of Embulk.