Follow up to bug Bug 183722. Areas for improvement include ensuring all return codes are provided and returned, logging of additional events to the optional conduit log, and adding feedback to the the hotsync manager during conduit operation. David, I don't know winapi threading. CMozABConduitSync::PerformFastSync() looks to me like it always returns success (ends with "return 0"). Does this need to be revised to properly propagate the return code so it can be evaluated? http://lxr.mozilla.org/mozilla/source/mailnews/extensions/palmsync/conduit/MozABConduitSync.cpp#621
examples for improvement with conduit log 1. if name='' then the AB should not probably not be synced. Not sure yet about the '-1' entries. Example log... Getting moz AB List ... Done getting moz AB List. Moz AB category index/synced=-1/0, name='', url='moz-abmdbdirectory://impab-4.mab' ... Moz AB category index/synced=-1/0, name= '', url= 'moz-abmdbdirectory://impab-11.mab' ... 2. after sync hits 15 palm categories and attempts the 16th it should kick an entry in the HSM log. The conduit log entry looks like this. Moz AB category index = 5, name = '' doesn't exist on Palm so needs to be added to palm Creating new Palm AB with 1 record(s) ... Done creating new Palm AB, new category index=-1. retval=-2000. Creating new Palm AB failed. retval=-2000.
Created attachment 263276 [details] [diff] [review] fix retun code in PerformFastSync v1 from comment comment #0, CMozABConduitSync::PerformFastSync() always returns success after finishing CreateThread to run DoFastSync - not good when the return code of the most used sync method (PerformFastSync) is untrustworthy. Also add missing log entry in DoFastSync for GetPCABList return code references: http://www.codeguru.com/cpp/misc/misc/threadsprocesses/article.php/c3791/ http://msdn2.microsoft.com/en-us/library/ms683190.aspx http://msdn2.microsoft.com/en-us/library/ms682512.aspx note: the thread handle is not closed
Assignee: bienvenu → vseerror
Status: NEW → ASSIGNED
Attachment #263276 - Flags: review?(bienvenu)
Comment on attachment 263276 [details] [diff] [review] fix retun code in PerformFastSync v1 (In reply to comment #2) > Created an attachment (id=263276) [details] > fix retun code in PerformFastSync v1 David, neil commented "the code looks vaguely reasonable". Will also need your checkin magic
I can't do this until Monday...I'll try to remember to do it then. Please feel free to ping me again then if I forget.
Comment on attachment 263276 [details] [diff] [review] fix retun code in PerformFastSync v1 fixed on trunk, thx, Wayne
(In reply to comment #7) > (From update of attachment 263276 [details] [diff] [review]) > fixed on trunk, thx, Wayne David this worked OK on trunk. yay! please checkin on branch
Created attachment 266952 [details] [diff] [review] fix retun code in PerformFastSync v1 [1.8 branch] branch version of attachment 263276 [details] [diff] [review] - line # changes only, no code change
fixed on trunk and branch, thx, Wayne!
Status: ASSIGNED → RESOLVED
Last Resolved: 12 years ago
Resolution: --- → FIXED
Comment on attachment 266952 [details] [diff] [review] fix retun code in PerformFastSync v1 [1.8 branch] clearing request - this looks like it's on the 1.8.1 branch already.
Component: Palm Sync → Palm Sync
Product: MailNews Core → MailNews Core Graveyard
You need to log in before you can comment on or make changes to this bug.