The forum will be unavailable for maintenance at some point from Friday, April 13 at 19:00 EDT until Sunday, April 15 at 23:59 EDT. Downtime will be minimized but the exact timing is unknown.

Hi, on-line documentation for ConfigPersistent interface responsible for setting database store options, like: setWriteAdEnd or setShadowPaging has a comment: “This method has no effect on UltraLite databases running on Android smartphones”. So, what persistent store configurations are available for Ultralite on Android?


asked 29 Aug '11, 07:34

David's gravatar image

accept rate: 50%

The defaults are supposed to be appropriate for most circumstances, so you should not have to pay much attention to the Configuration Object options until you wish to tune performance or address security issues. I typically use

ConfigFileAndroid config = DatabaseManager.createConfigurationFileAndroid(dbf, context);

I would say the ones of most importance are:

  • setCacheSize (initial cache for the database)
  • setPageSize (when creating a database)
  • enableAesDBEncryption (when creating a database) and
  • setDatabaseKey() for encryption
permanent link

answered 29 Aug '11, 09:05

Tom%20Slee's gravatar image

Tom Slee
accept rate: 29%

edited 29 Aug '11, 09:27

Volker%20Barth's gravatar image

Volker Barth


And I'll add further:

  • the cache is dynamically sized, so you shouldn't have to worry about that

  • the page size only needs to be changed if you have large rows which don't fit on 4k pages (the default) -- you'll know if this is the case because you'll receive an error to that effect on insert; sometimes applications can perform better with a smaller page size, but as Tom said that's a minor performance tuning issue

(29 Aug '11, 12:43) Tim McClements
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text]( "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:


question asked: 29 Aug '11, 07:34

question was seen: 1,256 times

last updated: 29 Aug '11, 12:43