Apache OpenOffice (AOO) Bugzilla – Full Text Issue Listing |
Summary: | No Maximum Records set when using Mozilla LDAP Address Book | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | Base | Reporter: | john.marmion | ||||||
Component: | code | Assignee: | john.marmion | ||||||
Status: | CLOSED FIXED | QA Contact: | issues@dba <issues> | ||||||
Severity: | Trivial | ||||||||
Priority: | P3 | CC: | issues | ||||||
Version: | OOo 1.0.1 | Keywords: | oooqa | ||||||
Target Milestone: | --- | ||||||||
Hardware: | All | ||||||||
OS: | All | ||||||||
Issue Type: | DEFECT | Latest Confirmation in: | --- | ||||||
Developer Difficulty: | --- | ||||||||
Attachments: |
|
Description
john.marmion
2002-10-08 11:17:13 UTC
confirming. John, do you know anything about the possibility to transfer such a setting to a Mozilla address book (which is only a "masked" LDAP data source)? IOW, when we offer such a setting, can we pass it to Mozilla and leave it up to Mozilla, or would we need to handle this restriction ourself in the SDBC driver? Ocke, please have a closer look at this, thanks, Dirk I will look after this. in this case, it's better if you are the owner, John :) Quickly looking at this. Mozilla only supports a limit with LDAP Address Books only. We pass this value over as a parameter to the DoQuery() method in Mozilla. For LDAP we get the value from our UI. For all other Address Books (i.e. including Mozilla LDAP Address Books) we always pass over -1. I presume that -1 results in no limit getting set or presumably should be set by the setting of the LDAP Server. Mozilla defaults to 100 records for an LDAP Address Book. But it only writes out this value to its preferences file if this value is changed. This is a possible hook for us. As we effectively create the Mozilla Address Books from the mozilla preferences, we could determine if this is a Mozilla LDAP Address Book and read the corresponding preference attribute 'maxHits'. If this exists use it, otherwise default to 100. One other alternative is that we add the UI capability for OOo to support this for all Address Book types. The only caveats I see is that we could set it to one value and mozilla to another and this limit is really only applicable to Corporate LDAP Directory Servers. I will get Frank's wise counsel on this. ehm, well, I'll try my best wisdom ... The first way sounds good. If we can * determine that we're an LDAP source masked as Mozilla address book * find this value in the preferences * pass the pref-parameter to the query (and from what you said it looks we can all of this) then I probably would prefer this solution. The second way (an own option) has it's charme, too, but would make us inconsistent with Mozilla. I'd like to keep the access to Mozilla address books as similar (in OOo and Mozilla) as possible. It's not really really strict - if we see that the first solution is not possible, it will be not too hard for me to lose this restriction :), but for the moment I suggest going with the preference way. Created attachment 3105 [details]
Patch to fix this
Hi John, your patch looks good - I especially like the extensive comments explaining what's going on :). The only thing I am not sure about is that it checks for write permissions on the book to see if it's an LDAP book. This looks like it may, by accident, hit other book types as well (e.g. a MORK address book when the underlying file is write protected). Don't we have another chance of determining the LDAP type? Frank filed issue 8210 about accessing readonly address book files for completeness I take your point Frank that determining whether a Mozilla Address Book type is "Writeable" may appear open to misinterpretation. But in mozilla, ldap is only type which overrides the default attributes of write|read|search of all other types with 'search' only. This attribute does not refer to the read-write property of the physical file, but to the operations that can be carried out on a particular Address Book type. I will document this is the code, update the patch and go ahead with the fix. Created attachment 3120 [details]
Update the patch
okay, didn't know this difference between the capabilities of the backend and the flags. It seems the flags are just a "letter of intent", and the actual capabilities may differ. An the more when it's the Mozilla way to check for an LDAP book ...I'm fine with this :) This fix is now in the tree. Verified Marking this issue closed change subcomponent to 'none' |