08-20-2014 11:32 AM
The tight memory constraints for headless apps is difficult to contend with. My sql queries seem to fail without of memory errors whenever there is a 'WHERE x = y' in the query.
Something like this
SELECT date, description, stuff from calendar
Works fine and memory usage seems reasonable although non-deterministic.
SELECT date, description from calendar WHERE date = x
Fails frequently with 'out of memory' errors. I can also see from the QNX system information perspective in the IDE that the memory is suddenly peaking near 3MB in the later query. My table has no more than 10 000 records in it.
The question is, why does refining a query further consume more memory? My objective was to limit memory use and I inadverdantly blew the limit in doing so. How can I perform a very specific query but keep memory use low?
Also, will Blackberry revise the memory limits? The two major tools I intended on using (QNetwork and QTSql) and highly non-deterministic in their memory consumption and would cause too much instability to be useful in a headless app.
Solved! Go to Solution.
08-26-2014 10:15 PM
08-26-2014 11:56 PM
08-27-2014 04:02 AM
Are you saying you asked and got a raise in the limit from BlackBerry, I thought this was imposed at the OS level?
I'm sure others will be interested in your response.
Well, it is not openly talked about by BlackBerry...
The memory limitations are managed via the signing key, they can add permissions to your signing key that allow your app to consume more memory.
I gave Enaud a small hint in this direction, but afaik there is no official way to request that, so maybe you ask him who he talked to.
08-27-2014 06:38 AM
08-27-2014 03:58 PM
It's imposed via the debug token, after my request a new 'property' was assigned to the debug token (I had to generate a new one) from the Blackberry side. I learned that you can request a higher memory limit from a forum dicsussion that I can no longer find.