Closed reprogrammer closed 13 years ago
@reprogrammer:
IProgressMonitor#done()
) and performing a refactoring delay of 2 seconds (and I do not know yet how to avoid this one). Considering that refactorings are performed (exactly performed, rather than undone or redone) not that often, this delay should not make a big different, though it would be really nice to find a way to avoid it. Besides, only refactorings that were recorded in older CodingSpectator versions are replayed. Since the May's release, CodingTracker records and replays low level changes produced by refactorings, and thus, there is no any delay involved. This makes fixing the refactoring delay problem very low priority.@Wanderer777: What concrete actions are you going to take to increase the speed of replays? Are you going to implement the "jump to" action?
@reprogrammer: Yes, I am going to implement the "jump to" action, but first I will stop showing additional information during the fast replay (i.e. moving the current user operation in the sequences and displaying its details).
The previous commit adds the "jump to" action to the CodingTracker's replayer. To properly replay the operation sequence from the "jumped to" operation, make sure that the workspace is clean (e.g. click "Reset"). Also, do not jump inside operations that change the content of a conflict editor. Considering that such operations are very rare and you are interested in jumping to refactorings, this should not be a problem. Please let me know how it works out for you.
In the above commit I fixed the way in which the "jump to" action works. It needs to consider that in between the operation to which a user wants to jump and the actual operation to which the jump is going to happen (which is established as the earliest of the closest snapshots of the files edited after the given "jump to" operation) there could be other file editing operations, which require to establish their corresponding closest snapshot operations and so on. Therefore, CodingTracker establishes the right operation to safely jump to iteratively, i.e. until there are no editing operations without preceding file snapshot operations after this "jump to" operation. As a result, although correct, it could happen that the closest point CodingTracker can safely jump to is quite far from the actual operation a user is interested in. So, as I wrote above, the usefulness of this new feature will be highly dependent on a particular operation sequence and the operation to which a user wants to jump to.
Speaking about a way not to show Eclipse editors, I found that the easiest approach would be to minimize the window of the Eclipse instance that performs the replay. As a result, I measured an improvement in replay time of around 25% - 30%, which is significant. So, at the moment, the fastest possible replay looks like this:
To facilitate this approach, I will add a message box that notifies the user that the replay is over or reached a breakpoint, also displaying the replay time. But, the message box sometimes is not immediately visible if other windows are open, so periodically checking the status of the replay is still needed.
I loaded the change sequence at
cs-111/a59ed788-a72b-435a-b673-8b25e13e7e99/1.0.0.201105300951/codingtracker/codechanges.txt
and left a break point at timestamp 1313081027570. Then, I replayed the sequence in "Fast" mode. It took about half an hour until CodingTracker failed by throwing an exception. I don't know how long it will take CodingTracker to reach my break point.Even half an hour to reach a break point is too long. This long delay makes it impractical to replay CodingTracker change sequences.