I have this exeption and i would not change the max_allowed_packet but i want
to limit the size of file


Exception in thread "Lucene Merge Thread #0"
org.apache.lucene.index.MergePolicy$MergeException:
org.apache.lucene.store.jdbc.JdbcStoreException: Failed to execute sql
[insert into search_lucene (name_, value_, size_, lf_, deleted_) values ( ?,
?, ?, current_timestamp, ? )]; nested exception is
com.mysql.jdbc.PacketTooBigException: Packet for query is too large (1286944
> 1048576). You can change this value on the server by setting the
max_allowed_packet' variable.
        at
org.apache.lucene.index.ConcurrentMergeScheduler.handleMergeException(ConcurrentMergeScheduler.java:309)
        at
org.apache.lucene.index.ConcurrentMergeScheduler$MergeThread.run(ConcurrentMergeScheduler.java:286)
Caused by: org.apache.lucene.store.jdbc.JdbcStoreException: Failed to
execute sql [insert into search_lucene (name_, value_, size_, lf_, deleted_)
values ( ?, ?, ?, current_timestamp, ? )]; nested exception is
com.mysql.jdbc.PacketTooBigException: Packet for query is too large (1286944
> 1048576). You can change this value on the server by setting the
max_allowed_packet' variable.
        at
org.apache.lucene.store.jdbc.support.JdbcTemplate.executeUpdate(JdbcTemplate.java:185)
        at
org.apache.lucene.store.jdbc.index.AbstractJdbcIndexOutput.close(AbstractJdbcIndexOutput.java:47)
        at
org.apache.lucene.store.jdbc.index.RAMAndFileJdbcIndexOutput.close(RAMAndFileJdbcIndexOutput.java:81)
        at
org.apache.lucene.index.CompoundFileWriter.close(CompoundFileWriter.java:203)
        at
org.apache.lucene.index.SegmentMerger.createCompoundFile(SegmentMerger.java:204)
        at 
org.apache.lucene.index.IndexWriter.mergeMiddle(IndexWriter.java:4263)
        at org.apache.lucene.index.IndexWriter.merge(IndexWriter.java:3884)
        at
org.apache.lucene.index.ConcurrentMergeScheduler.doMerge(ConcurrentMergeScheduler.java:205)
        at
org.apache.lucene.index.ConcurrentMergeScheduler$MergeThread.run(ConcurrentMergeScheduler.java:260)
Caused by: com.mysql.jdbc.PacketTooBigException: Packet for query is too
large (1286944 > 1048576). You can change this value on the server by
setting the max_allowed_packet' variable.
        at com.mysql.jdbc.MysqlIO.send(MysqlIO.java:3915)
        at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2598)
        at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2778)
        at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2825)
        at
com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:2156)
        at
com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2459)
        at
com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2376)
        at
com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2360)
        at
org.apache.lucene.store.jdbc.support.JdbcTemplate.executeUpdate(JdbcTemplate.java:175)




-----
HDH
--
View this message in context: 
http://lucene.472066.n3.nabble.com/Limit-lunce-files-size-tp4131939.html
Sent from the Lucene - Java Developer mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to