Please use the Apache issue tracking system for new NetBeans issues ( !!
Bug 178890 - @BreakpointType.Registration does not work as expected
@BreakpointType.Registration does not work as expected
Product: debugger
Classification: Unclassified
Component: Code
All All
: P1 (vote)
: 6.x
Assigned To: Martin Entlicher
Depends on:
  Show dependency treegraph
Reported: 2009-12-19 16:27 UTC by Vladimir Voskresensky
Modified: 2009-12-23 04:18 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT


Note You need to log in before you can comment on or make changes to this bug.
Description Vladimir Voskresensky 2009-12-19 16:27:51 UTC
Debugger Core SPI have @BreakpointType.Registration.
But it doesn't work as expected:
1) It's not possible to mix old META-INF/debugger/spi.debugger.ui.BreakpointType and new annotation based breakpoint types (layer based takes precedence)
2) Layer-based (generated from annotation) doesn't work as well. listeners are not attached to controller as it was before => It's impossible to create Breakpoint from New Breakpoint dialog, because validation is not called
Comment 1 Vladimir Voskresensky 2009-12-20 13:41:53 UTC
Btw, BreakpointType.Registration has displayName() as lazy variant of BreakpointType.getTypeDisplayName, but it doesn't solve lazy loading problem, because BreakpointType.Registration does not have lazy variant of BreakpointType.getCategoryDisplayName
Comment 2 Martin Entlicher 2009-12-21 10:12:05 UTC
1) Can you please elaborate what do you mean by mix of META-INF/debugger/spi.debugger.ui.BreakpointType and annotation by @BreakpointType.Registration? I've tried to use some breakpoint types defined by the old approach with some defined by annotations and it worked well. At least in JPDA Debugger I did not encounter any problem.

2) Problem identified and fixed in changeset:   156110:25be4aeefba4
Comment 3 Vladimir Voskresensky 2009-12-21 13:36:59 UTC
1) Doesn't work in external application based on NB. I will recheck, because using annotation and old style in CND debugger works fine

What about 3)? lazy variant of BreakpointType.getCategoryDisplayName
Comment 4 Martin Entlicher 2009-12-21 14:52:18 UTC
1) So please include steps how can we reproduce it if you find that it still does not work.

3) lazy variant of BreakpointType.getCategoryDisplayName - we can add it, but I think that the effect is questionable. As soon as AddBreakpointPanel calls BreakpointType.getCategoryDisplayName(), it also calls BreakpointType.isDefault(), which usually involves some logic with respect to the context.
Comment 5 Martin Entlicher 2009-12-21 14:55:48 UTC
Closing as fixed for now, please reopen if you can reproduce 1)

3) I think this needs a separate performance bug to analyze the problem. Do you have some test failing because of this, similar to bug #177561?
Comment 6 Quality Engineering 2009-12-21 23:39:59 UTC
Integrated into 'main-golden', will be available in build *200912220201* on (upload may still be in progress)
Log: #178890 - Override and delegate getController()
Comment 7 Vladimir Voskresensky 2009-12-22 04:16:15 UTC
to 3)
debugger BP type names are used to fill up combobox of BP kinds and it is lazy now.
Category name is used to fill up combobox of different debuggers. And it does not have lazy variant => you have to load all classes from PHP, CND, ... other debuggers even if plan to use Java debugger.

So, why this lazy registration is needed at all if all classes are loaded anyway?
Comment 8 Martin Entlicher 2009-12-23 04:18:47 UTC
3) The lazy display name was needed by ergonomics when issue #153093 was implemented.
It looks like now we need to evaluate the performance point of view and add the declarative parts requested in issue #153093. I'll propose some solution in issue #177561.

By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo