The small difference between OK Code and Good Code
This is OK code:
def LockItem(itemKey as string): while true: result = PUT( "lock of "+itemKey, "requiredValue" ) break if result is SuccessfulUpdate // we don't sleep, the remote call take care of spacing the calls in time
And this is good code:
def LockItem(itemKey as string): while true: result = PUT( "lock of "+itemKey, clientName ) break if result is SuccessfulUpdate // we don't sleep, the remote call take care of spacing the calls in time
The only difference is with the value we set, and that is never used by the application.
Why is this important?

Comments
Comment preview