Cancel is a transaction from the active state, whereas compensate is a transition from the completed state. In short, it depends where in the lifecycle the tx aborts. See the state diagram on page 8 of the WS-BusinessActivity spec.
From what i understand when the .cancel() is invoked on the participant, the transaction aware web service is either currently executing the business logic or else haven't started executing the business logic yet. (The participant cannot have informed the coordinator that it has completed.)
Am i right?
What is still not clear to me is in what circumstance is the .cancel() method invoked?