[jsword-devel] Out of Memory Issues Loading repo module lists

DM Smith dmsmith at crosswire.org
Sat Jan 9 19:06:02 MST 2016


I’ll be adding a filter to IniSection. Something like:
if  (filter.test(key)) {
	use the key
} else {
	do nothing
}

SwordBookMetaData will be responsible for building the filter. At least for a first go around. A single object should do.

DM

> On Jan 9, 2016, at 6:29 PM, DM Smith <dmsmith at crosswire.org> wrote:
> 
>> 
>> Yes, like you I have thought of streamlining conf loading for repo lists.  One idea I had was to enable specification of a filter to SwordBookMetaData to limit the conf values that are stored.
> 
> I was thinking of something similar. My ideas aren’t good enough to be put into practice, but some kind of flag indicating empty, partially or fully loaded. Empty would mean that it hasn’t gone to disk to get the conf. Partial means that it read everything, but threw away most as not interesting (since the conf does not have order you have to read and parse it all). Full would mean that nothing was pitched. SwordBookMetaData.getProperty would need to be changed to determine whether the key is in memory or might be on disk and do the right thing. Or we could keep getProperty as it is and if you want one of the fields that is not stored (e.g. About) you have to call reload().
> 
> Maybe we could also cache that info into a separate file(s)? When mods.d.tar.gz is updated then the cache would be recomputed. In doing the computation, each conf would be read then pitched. Basically, the storage would be o.c.c.utils.Ini, if one file or IniSection, if many files.
> 
> What do you think?
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/jsword-devel/attachments/20160109/43b04b48/attachment.html>


More information about the jsword-devel mailing list