Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 315135

Summary: Existing breakpoints are added and removed for no reason with new debug targets
Product: [WebTools] JSDT Reporter: Michael Rennie <Michael_Rennie>
Component: DebugAssignee: Michael Rennie <Michael_Rennie>
Status: RESOLVED FIXED QA Contact: Simon Kaegi <simon_kaegi>
Severity: normal    
Priority: P3 CC: thatnitind
Version: 3.2Keywords: performance
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:
Bug Depends on:    
Bug Blocks: 327019    
Attachments:
Description Flags
proposed fix none

Description Michael Rennie CLA 2010-05-31 16:01:27 EDT
code from HEAD

Steps:

1. set a breakpoint in a script that is loaded in the Rhino VM
2. connect the debugger to the VM
3. trace the socket communication 

Expected:

when the target connects I would expect to see a setbreakpoint request sent for the existing breakpoint, and the VMs' response

Happens:

we do send out the request, and we do get the VMs' response, but immediately following we send out a clearbreakpoint request for the bp we just requested to be set. We then get the VMs' response confirming the bp is cleared, and we then send another setbreakpoint request for the same bp we just set/removed.

Not only is this 2x the work, but we are also artificially inflating the breakpoint ids
Comment 1 Michael Rennie CLA 2010-10-05 16:13:07 EDT
Created attachment 180282 [details]
proposed fix

I found that is the breakpoint is touched in any way we hit a call-back in our debug target the kills + recreates the bp. The patch removes this behavior.
Comment 2 Michael Rennie CLA 2010-10-05 16:13:35 EDT
applied patch to HEAD