use of org.h2.store.LobStorageMap in project h2database by h2database.
the class TestLob method testBufferedInputStreamBug.
/**
* Test a bug where the usage of BufferedInputStream in LobStorageMap was
* causing a deadlock.
*/
private void testBufferedInputStreamBug() throws SQLException {
deleteDb("lob");
JdbcConnection conn = (JdbcConnection) getConnection("lob");
conn.createStatement().execute("CREATE TABLE TEST(test BLOB)");
PreparedStatement ps = conn.prepareStatement("INSERT INTO TEST(test) VALUES(?)");
ps.setBlob(1, new ByteArrayInputStream(new byte[257]));
ps.executeUpdate();
conn.close();
}
Aggregations