Re: [v8-users] Sample code illustrating working V8 debugger

2016-08-12 Thread Abhishek Singh
Was able to solve the problem I had. Just thought of sharing sample standalone code based on C++ api in case anyone else on v8-users group wanted to have initial understanding of V8 debugger protocol - https://github.com/abhi-bit/v8_debugging_progs/blob/master/breakpoint_simulation.cc > On 04-A

Re: [v8-users] Sample code illustrating working V8 debugger

2016-08-04 Thread Ben Noordhuis
On Thu, Aug 4, 2016 at 12:01 PM, Abhishek Singh wrote: > Appreciate your help so far. > > Sample user JS code[0] looks like this now: > > {code} > function OnUpdate(doc, meta) { > log("doc meta id: ", meta.key); > > if (meta.type === "json" && doc.ssn) { > .. > .. >} > } > > Debug = de

Re: [v8-users] Sample code illustrating working V8 debugger

2016-08-04 Thread Abhishek Singh
Appreciate your help so far. Sample user JS code[0] looks like this now: {code} function OnUpdate(doc, meta) { log("doc meta id: ", meta.key); if (meta.type === "json" && doc.ssn) { .. .. } } Debug = debug.Debug; log(Debug.showBreakPoints(OnUpdate)); Function OnDelete() {} // more

Re: [v8-users] Sample code illustrating working V8 debugger

2016-08-04 Thread Ben Noordhuis
On Thu, Aug 4, 2016 at 6:50 AM, Abhishek Singh wrote: > >> On 03-Aug-2016, at 8:13 PM, Ben Noordhuis wrote: >> >> Quick sanity check: what does Debug.showBreakPoints() print for that >> function after setting the breakpoint? > > Just to confirm, is below the right way to leverage JS Debug API in

Re: [v8-users] Sample code illustrating working V8 debugger

2016-08-03 Thread Abhishek Singh
> On 03-Aug-2016, at 8:13 PM, Ben Noordhuis wrote: > > Quick sanity check: what does Debug.showBreakPoints() print for that > function after setting the breakpoint? Just to confirm, is below the right way to leverage JS Debug API in a user supplied JS code? (I tried setting up breakpoint again

Re: [v8-users] Sample code illustrating working V8 debugger

2016-08-03 Thread Ben Noordhuis
On Wed, Aug 3, 2016 at 12:55 PM, Abhishek Singh wrote: > >> On 03-Aug-2016, at 3:48 PM, Ben Noordhuis wrote: >> >> On Wed, Aug 3, 2016 at 11:40 AM, Abhishek Singh >> wrote: >>> Hi Ben, >>> >>> Apologies for not providing the background. I’m trying to leverage C++ API >>> to drive V8 JSON debugg

Re: [v8-users] Sample code illustrating working V8 debugger

2016-08-03 Thread Abhishek Singh
> On 03-Aug-2016, at 3:48 PM, Ben Noordhuis wrote: > > On Wed, Aug 3, 2016 at 11:40 AM, Abhishek Singh > wrote: >> Hi Ben, >> >> Apologies for not providing the background. I’m trying to leverage C++ API >> to drive V8 JSON debugger for embedded V8 use case, not sure if leveraging >> JS API

Re: [v8-users] Sample code illustrating working V8 debugger

2016-08-03 Thread Ben Noordhuis
On Wed, Aug 3, 2016 at 11:40 AM, Abhishek Singh wrote: > Hi Ben, > > Apologies for not providing the background. I’m trying to leverage C++ API to > drive V8 JSON debugger for embedded V8 use case, not sure if leveraging JS > API to drive debugger would be of utility in this situation. Here is h

Re: [v8-users] Sample code illustrating working V8 debugger

2016-08-03 Thread Abhishek Singh
Hi Ben, Apologies for not providing the background. I’m trying to leverage C++ API to drive V8 JSON debugger for embedded V8 use case, not sure if leveraging JS API to drive debugger would be of utility in this situation. Here is high level workflow pipeline for this use case: * There is a Gol

Re: [v8-users] Sample code illustrating working V8 debugger

2016-08-03 Thread Ben Noordhuis
On Wed, Aug 3, 2016 at 8:17 AM, Abhishek Singh wrote: > Hi, > > Sorry to bother again about V8 JSON protocol debugger. I’ve looked through > debug_agent.cc/.h and _debug_agent.js implementation in node.js in order to > understand to understand correct way to enable breakpoints(and fire other > dif

[v8-users] Sample code illustrating working V8 debugger

2016-08-02 Thread Abhishek Singh
Hi, Sorry to bother again about V8 JSON protocol debugger. I’ve looked through debug_agent.cc/.h and _debug_agent.js implementation in node.js in order to understand to understand correct way to enable breakpoints(and fire other different types of requests). But even after reading though node.j