Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

设置每个文件过小,如1M或者100K时,会有异常 #8

Open
GoogleCodeExporter opened this issue Jul 13, 2015 · 2 comments
Open

Comments

@GoogleCodeExporter
Copy link

单独使用Fqueue时,设置文件太小,如:
FQueue fQueue = new FQueue("xxxx",100*1024);

写到2,3个文件后就会抛异常
翻看源码后看每次新生成idb文件是有一个单独线程在运行,��
�步怀疑是上一个文件写满,下一个文件还未生成造成的,不�
��道怀疑的对不对

异常信息如下:
com.google.code.fqueue.exception.FileFormatException: file format error
    at com.google.code.fqueue.log.LogEntity.<init>(LogEntity.java:89) --这句也可能在79行抛出,都出现过
    at com.google.code.fqueue.FSQueue.createLogEntity(FSQueue.java:110)
    at com.google.code.fqueue.FSQueue.rotateNextLogWriter(FSQueue.java:126)
    at com.google.code.fqueue.FSQueue.add(FSQueue.java:152)
    at com.google.code.fqueue.FQueue.offer(FQueue.java:66)
    at com.google.code.fqueue.FQueue.offer(FQueue.java:1)
    at java.util.AbstractQueue.add(AbstractQueue.java:68)
    at TestFQueue2.main(TestFQueue2.java:27)
java.lang.IllegalStateException: Queue full
    at java.util.AbstractQueue.add(AbstractQueue.java:71)
    at TestFQueue2.main(TestFQueue2.java:27)

Original issue reported on code.google.com by jiezhip...@gmail.com on 22 Mar 2013 at 6:55

@GoogleCodeExporter
Copy link
Author

你每次写入的数据有多大?

Original comment by sunli1...@gmail.com on 10 Jul 2013 at 6:45

@GoogleCodeExporter
Copy link
Author

每次写入1K数据

Original comment by jiezhip...@gmail.com on 10 Jul 2013 at 5:13

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant