You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@netbeans.apache.org by Sean Carrick <se...@pekinsoft.com> on 2023/02/10 16:38:22 UTC
How To Add a Custom Bug Report Feature to ErrorManager or Exceptions
Hey All!
I am working on an NBP application and am wondering how I can create a
custom "Submit Bug Report" action when using the ErrorManager or
Exceptions APIs.
Basically, I moved all of my projects from GitHub to GitLab because of a
certain feature offered by the latter: Service Desk. This feature allows
for anonymous bug reports to be submitted to a special email address for
the project's issues tracking system.
In my standard J2SE/Swing applications, I have an error handling API
that provides a button on the error message that allows the user to
submit a bug report. When the user chooses to do so, s/he:
1. Clicks the "Submit Bug Report" button on the error message
1. This starts a bug report wizard to gather information
2. Steps through the bug report wizard, which:
1. Gathers system information
2. Gathers Java information
3. Gathers application log files
4. Requests information from the user, such as:
1. Expected results
2. Actual results
3. Steps to reproduce the error
3. Clicks the "Submit" button at the end of the wizard, which:
1. Creates an email message:
1. Exception class and message becomes the title of the email,
with "[BUG] " prepended to it
2. User-provided information becomes the body of the email
3. Gathered system and Java information is placed below the
user-provided data in the email body
4. Gathered application log files are attached to the email
2. Opens the transport layer
3. Sends the email to my GitLab Service Desk, which causes an Issue
to be opened in the issue tracker
Now that I am developing a larger application on the NBP, I am unsure of
how to provide this same functionality. I figure that I will need to
implement something in the API, but I have no idea of where to start
looking to figure out what to implement or override.
Any suggestions and pointers are greatly appreciated. Thank you in
advance for your assistance.
-Sean C.
Re: How To Add a Custom Bug Report Feature to ErrorManager or Exceptions
Posted by Sean Carrick <se...@pekinsoft.com>.
Patrik,
Thank you very much! That is perfect!
My Google search game must need some work, because that link did not
come up in my searches at all. I truly appreciate your assistance on
this question.
-Sean C.
On 2/10/23 11:16 AM, Patrik Karlström wrote:
> Might this help?
> https://netbeans.apache.org/wiki/DevFaqCustomizingUnexpectedExceptionDialog.html
> <https://netbeans.apache.org/wiki/DevFaqCustomizingUnexpectedExceptionDialog.html>
>
>
> Den fre 10 feb. 2023 17:39Sean Carrick <sean@pekinsoft.com
> <ma...@pekinsoft.com>> skrev:
>
> Hey All!
>
> I am working on an NBP application and am wondering how I can
> create a custom "Submit Bug Report" action when using the
> ErrorManager or Exceptions APIs.
>
> Basically, I moved all of my projects from GitHub to GitLab
> because of a certain feature offered by the latter: Service Desk.
> This feature allows for anonymous bug reports to be submitted to a
> special email address for the project's issues tracking system.
>
> In my standard J2SE/Swing applications, I have an error handling
> API that provides a button on the error message that allows the
> user to submit a bug report. When the user chooses to do so, s/he:
>
> 1. Clicks the "Submit Bug Report" button on the error message
> 1. This starts a bug report wizard to gather information
> 2. Steps through the bug report wizard, which:
> 1. Gathers system information
> 2. Gathers Java information
> 3. Gathers application log files
> 4. Requests information from the user, such as:
> 1. Expected results
> 2. Actual results
> 3. Steps to reproduce the error
> 3. Clicks the "Submit" button at the end of the wizard, which:
> 1. Creates an email message:
> 1. Exception class and message becomes the title of the
> email, with "[BUG] " prepended to it
> 2. User-provided information becomes the body of the email
> 3. Gathered system and Java information is placed below
> the user-provided data in the email body
> 4. Gathered application log files are attached to the email
> 2. Opens the transport layer
> 3. Sends the email to my GitLab Service Desk, which causes an
> Issue to be opened in the issue tracker
>
> Now that I am developing a larger application on the NBP, I am
> unsure of how to provide this same functionality. I figure that I
> will need to implement something in the API, but I have no idea of
> where to start looking to figure out what to implement or override.
>
> Any suggestions and pointers are greatly appreciated. Thank you in
> advance for your assistance.
>
> -Sean C.
>
Re: How To Add a Custom Bug Report Feature to ErrorManager or Exceptions
Posted by Patrik Karlström <pa...@trixon.se>.
Might this help?
https://netbeans.apache.org/wiki/DevFaqCustomizingUnexpectedExceptionDialog.html
Den fre 10 feb. 2023 17:39Sean Carrick <se...@pekinsoft.com> skrev:
> Hey All!
>
> I am working on an NBP application and am wondering how I can create a
> custom "Submit Bug Report" action when using the ErrorManager or
> Exceptions APIs.
>
> Basically, I moved all of my projects from GitHub to GitLab because of a
> certain feature offered by the latter: Service Desk. This feature allows
> for anonymous bug reports to be submitted to a special email address for
> the project's issues tracking system.
>
> In my standard J2SE/Swing applications, I have an error handling API that
> provides a button on the error message that allows the user to submit a bug
> report. When the user chooses to do so, s/he:
>
> 1. Clicks the "Submit Bug Report" button on the error message
> 1. This starts a bug report wizard to gather information
> 2. Steps through the bug report wizard, which:
> 1. Gathers system information
> 2. Gathers Java information
> 3. Gathers application log files
> 4. Requests information from the user, such as:
> 1. Expected results
> 2. Actual results
> 3. Steps to reproduce the error
> 3. Clicks the "Submit" button at the end of the wizard, which:
> 1. Creates an email message:
> 1. Exception class and message becomes the title of the email,
> with "[BUG] " prepended to it
> 2. User-provided information becomes the body of the email
> 3. Gathered system and Java information is placed below the
> user-provided data in the email body
> 4. Gathered application log files are attached to the email
> 2. Opens the transport layer
> 3. Sends the email to my GitLab Service Desk, which causes an Issue
> to be opened in the issue tracker
>
> Now that I am developing a larger application on the NBP, I am unsure of
> how to provide this same functionality. I figure that I will need to
> implement something in the API, but I have no idea of where to start
> looking to figure out what to implement or override.
>
> Any suggestions and pointers are greatly appreciated. Thank you in advance
> for your assistance.
>
> -Sean C.
>
Re: How To Add a Custom Bug Report Feature to ErrorManager or Exceptions
Posted by Sean Carrick <se...@pekinsoft.com>.
Michael,
I know what you're saying. I had changed the JDK for the project to
JDK19, but for some reason it didn't take...No worries, I don't mind
developing in 11 and have been practically since it came out...
-SC
On 2/14/23 1:12 AM, Michael Bien wrote:
> this sounds like your project was still configured to use JDK 11 while
> you tried to bump the language level (?).
>
> JDK version has to be >= language level, which is just a compiler
> setting (e.g --release=17 won't work on JDK 11 since it doesn't have
> the API and the compiler for that).
>
> best regards,
> michael
>
>
> On 13.02.23 19:42, Scott Palmer wrote:
>> That's strange.
>> How did you configure the JDK for your project?
>>
>> On Mon, Feb 13, 2023 at 7:52 AM Sean Carrick <se...@pekinsoft.com> wrote:
>>
>> Hey, Ernie! I don't mind at all.
>>
>> I'm using JDK 11 now. I tried using JDK 19, but it didn't
>> work…the compiler kept stating that source level XX is not
>> supported for every version from 19 down to 11, so I switched
>> back to 11.
>>
>> -SC
>>
>> On Sun, Feb 12, 2023, 23:30 Ernie Rael <er...@raelity.com> wrote:
>>
>> On 23/02/10 8:38 AM, Sean Carrick wrote:
>> >
>> > Hey All!
>> >
>> > I am working on an NBP application and am wondering how I
>> can create a
>> > custom "Submit Bug Report" action when using the
>> ErrorManager or
>> > Exceptions APIs.
>> >
>> Hey Sean,
>>
>> Do you mind saying what JRE your NBP app(s) run on?
>>
>> -ernie
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@netbeans.apache.org
>> For additional commands, e-mail: users-help@netbeans.apache.org
>>
>> For further information about the NetBeans mailing lists, visit:
>> https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
>>
>
Re: How To Add a Custom Bug Report Feature to ErrorManager or Exceptions
Posted by Michael Bien <mb...@gmail.com>.
this sounds like your project was still configured to use JDK 11 while
you tried to bump the language level (?).
JDK version has to be >= language level, which is just a compiler
setting (e.g --release=17 won't work on JDK 11 since it doesn't have the
API and the compiler for that).
best regards,
michael
On 13.02.23 19:42, Scott Palmer wrote:
> That's strange.
> How did you configure the JDK for your project?
>
> On Mon, Feb 13, 2023 at 7:52 AM Sean Carrick <se...@pekinsoft.com> wrote:
>
> Hey, Ernie! I don't mind at all.
>
> I'm using JDK 11 now. I tried using JDK 19, but it didn't work…the
> compiler kept stating that source level XX is not supported for
> every version from 19 down to 11, so I switched back to 11.
>
> -SC
>
> On Sun, Feb 12, 2023, 23:30 Ernie Rael <er...@raelity.com> wrote:
>
> On 23/02/10 8:38 AM, Sean Carrick wrote:
> >
> > Hey All!
> >
> > I am working on an NBP application and am wondering how I
> can create a
> > custom "Submit Bug Report" action when using the
> ErrorManager or
> > Exceptions APIs.
> >
> Hey Sean,
>
> Do you mind saying what JRE your NBP app(s) run on?
>
> -ernie
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@netbeans.apache.org
> For additional commands, e-mail: users-help@netbeans.apache.org
>
> For further information about the NetBeans mailing lists, visit:
> https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
>
Re: How To Add a Custom Bug Report Feature to ErrorManager or Exceptions
Posted by Sean Carrick <se...@pekinsoft.com>.
Scott,
I didn't really configure it...I just set the project's Java Platform to
JDK 19, then set the target source to 17. When I compiled it, the
compiler said, "source target 17 is not supported" (or some such
thing...I've slept since then 😉). So, I reduced the target source to 16
with the same results, then 15...when I got to 11, there was no such
error, so I just switched the project back to using JDK 11. It's no big
deal because I don't use the Java enhancements all that much, I was just
hoping to be able to use that nifty Record deal that began being
previewed in JDK 14 and became permanent in JDK 16. Needing to do the
boilerplate coding to create my JavaBeans is not a big deal to me
because I've been doing that for a little over 20 years now anyway, so
it's second nature...Plus, I use the IDE features and have the IDE put
in the getter/setter, equals, hashcode, and toString boilerplate code
anyway, so it's not like it would have saved me all that much anyway.😁
If you know of the best way (a link to a document or something) to
reconfigure the project to use the latest JDK when I started it with JDK
11, I would be more than excited to check it out. Like I said, that
Record deal seems pretty cool to me...well, plus the other enhancements
that have been made, but that record keyword is just super intriguing to
me for some reason.
-SC
On 2/13/23 12:42 PM, Scott Palmer wrote:
> That's strange.
> How did you configure the JDK for your project?
>
> On Mon, Feb 13, 2023 at 7:52 AM Sean Carrick <sean@pekinsoft.com
> <ma...@pekinsoft.com>> wrote:
>
> Hey, Ernie! I don't mind at all.
>
> I'm using JDK 11 now. I tried using JDK 19, but it didn't work…the
> compiler kept stating that source level XX is not supported for
> every version from 19 down to 11, so I switched back to 11.
>
> -SC
>
> On Sun, Feb 12, 2023, 23:30 Ernie Rael <errael@raelity.com
> <ma...@raelity.com>> wrote:
>
> On 23/02/10 8:38 AM, Sean Carrick wrote:
> >
> > Hey All!
> >
> > I am working on an NBP application and am wondering how I
> can create a
> > custom "Submit Bug Report" action when using the
> ErrorManager or
> > Exceptions APIs.
> >
> Hey Sean,
>
> Do you mind saying what JRE your NBP app(s) run on?
>
> -ernie
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@netbeans.apache.org
> <ma...@netbeans.apache.org>
> For additional commands, e-mail:
> users-help@netbeans.apache.org
> <ma...@netbeans.apache.org>
>
> For further information about the NetBeans mailing lists, visit:
> https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
> <https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists>
>
Re: How To Add a Custom Bug Report Feature to ErrorManager or Exceptions
Posted by Scott Palmer <sw...@gmail.com>.
That's strange.
How did you configure the JDK for your project?
On Mon, Feb 13, 2023 at 7:52 AM Sean Carrick <se...@pekinsoft.com> wrote:
> Hey, Ernie! I don't mind at all.
>
> I'm using JDK 11 now. I tried using JDK 19, but it didn't work…the
> compiler kept stating that source level XX is not supported for every
> version from 19 down to 11, so I switched back to 11.
>
> -SC
>
> On Sun, Feb 12, 2023, 23:30 Ernie Rael <er...@raelity.com> wrote:
>
>> On 23/02/10 8:38 AM, Sean Carrick wrote:
>> >
>> > Hey All!
>> >
>> > I am working on an NBP application and am wondering how I can create a
>> > custom "Submit Bug Report" action when using the ErrorManager or
>> > Exceptions APIs.
>> >
>> Hey Sean,
>>
>> Do you mind saying what JRE your NBP app(s) run on?
>>
>> -ernie
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@netbeans.apache.org
>> For additional commands, e-mail: users-help@netbeans.apache.org
>>
>> For further information about the NetBeans mailing lists, visit:
>> https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
>>
>>
Re: How To Add a Custom Bug Report Feature to ErrorManager or Exceptions
Posted by Sean Carrick <se...@pekinsoft.com>.
Hey, Ernie! I don't mind at all.
I'm using JDK 11 now. I tried using JDK 19, but it didn't work…the compiler
kept stating that source level XX is not supported for every version from
19 down to 11, so I switched back to 11.
-SC
On Sun, Feb 12, 2023, 23:30 Ernie Rael <er...@raelity.com> wrote:
> On 23/02/10 8:38 AM, Sean Carrick wrote:
> >
> > Hey All!
> >
> > I am working on an NBP application and am wondering how I can create a
> > custom "Submit Bug Report" action when using the ErrorManager or
> > Exceptions APIs.
> >
> Hey Sean,
>
> Do you mind saying what JRE your NBP app(s) run on?
>
> -ernie
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@netbeans.apache.org
> For additional commands, e-mail: users-help@netbeans.apache.org
>
> For further information about the NetBeans mailing lists, visit:
> https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
>
>
Re: How To Add a Custom Bug Report Feature to ErrorManager or Exceptions
Posted by Ernie Rael <er...@raelity.com>.
On 23/02/10 8:38 AM, Sean Carrick wrote:
>
> Hey All!
>
> I am working on an NBP application and am wondering how I can create a
> custom "Submit Bug Report" action when using the ErrorManager or
> Exceptions APIs.
>
Hey Sean,
Do you mind saying what JRE your NBP app(s) run on?
-ernie
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@netbeans.apache.org
For additional commands, e-mail: users-help@netbeans.apache.org
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists