[osiris-devel] Re: fixing the filters implementation

David Vasil dmvasil at ornl.gov
Mon Nov 20 08:39:12 EST 2006


Douglas K. Fischer wrote:
> David Vasil wrote:
>> I've been looking into why the filters always get rearranged when you do
>> an edit-filters and it turns out this is the way it should work in the
>> current implementation.  Since Osiris stores the filters in a BDB, the
>> BDB choses what order to store the items in based on its own sorting
>> algorithm.
>>
>> Looking at how the osirismd uses the filters during scans, I see no
>> benefit in storing the filters in a database.  In md_scan.c the OsirisMD
>> does a sequential lookup on every filter in the BDB to see if it matches
>> the current input.  To me this seems like it would create more overhead
>> than just a flat file.
>>
>> Changing this to be a flat text file would fix the problem with the
>> filters being rearranged between edits and it may improve performance a
>> small amount on the MD.  What are other's thoughts on this?
>>   
> I'm all for this. The whole rearranging business of BDB is the reason I
> created the --import-filters function. That way I could maintain a text
> file for the filters for ease of management and then just import it into
> the DB and let it do whatever it wanted with them. Eliminating the
> filter DB would simplify things greatly.

I talked with a few programmer friends, and they seem to think that it
would be a better idea to leave the filters in a BDB and store a master
file on the MD (much like how mail aliases are generated for MTA's).  I
almost have this implemented, we will see how it works out.

-- 
-dave



More information about the osiris-devel mailing list