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

CursorWindowAllocationException: Cursor window allocation of 2048 kb failed #85

Open
donndiegoo opened this issue May 4, 2015 · 0 comments

Comments

@donndiegoo
Copy link

Good afternoon,

I have a for that iterates around 700 times. In each iteration, I do a Query.one (among other things).

I have executed this iteration hundred of times without problem, but today it failed with the following error.

Any idea why?

Thank you very much.

05-04 15:58:08.296    3411-4355/com.xxxxxxxxxx E/AndroidRuntime﹕ FATAL EXCEPTION: AsyncTask #5
    Process: xxxxxxxxxx, PID: 3411
    java.lang.RuntimeException: An error occured while executing doInBackground()
            at android.os.AsyncTask$3.done(AsyncTask.java:300)
            at java.util.concurrent.FutureTask.finishCompletion(FutureTask.java:355)
            at java.util.concurrent.FutureTask.setException(FutureTask.java:222)
            at java.util.concurrent.FutureTask.run(FutureTask.java:242)
            at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:231)
            at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112)
            at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587)
            at java.lang.Thread.run(Thread.java:818)
     Caused by: android.database.CursorWindowAllocationException: Cursor window allocation of 2048 kb failed. # Open Cursors=577 (# cursors opened by this proc=577)
            at android.database.CursorWindow.<init>(CursorWindow.java:108)
            at android.database.AbstractWindowedCursor.clearOrCreateWindow(AbstractWindowedCursor.java:198)
            at android.database.sqlite.SQLiteCursor.fillWindow(SQLiteCursor.java:139)
            at android.database.sqlite.SQLiteCursor.getCount(SQLiteCursor.java:133)
            at android.database.AbstractCursor.moveToPosition(AbstractCursor.java:197)
            at android.database.AbstractCursor.moveToFirst(AbstractCursor.java:237)
            at se.emilsjolander.sprinkles.OneQuery.get(OneQuery.java:55)
            at xxxxxxxx.MyModel.oneById(MyModel.java:40)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant