Skip to content

Commit

Permalink
Add debugging instructions (#1451)
Browse files Browse the repository at this point in the history
* Add debugging instructions

* Apply suggestions from code review

* Update CONTRIBUTING.md

---------

Co-authored-by: Kris Stern <krisstern@outlook.com>
  • Loading branch information
harsh-ps-2003 and krisstern authored Apr 17, 2023
1 parent 8f19ed3 commit 7036fde
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,17 @@ Before submitting your change make sure that:

See https://github.com/jenkinsci/gitlab-plugin/tree/master/src/docker/README.md

## Using IntelliJ's Debugger

When testing with a Docker Jenkins instance, the debugger can be setup in the following way:
* From the main menu, select Run -> Edit Configurations.
* In the Run/Debug Configurations dialog, click the Add New Configuration button `+` and select Remote JVM Debug.
* Enter any relevant name, the Host (the address of the machine where the host app will run. If running it on the same machine, it needs to be localhost. If the program is running on another machine, specify its address here) and the Port (by default use 50000). The Command Line argument will be automatically setup.
* Enter Apply.

Now start your Jenkins instance and debugger and you should get something like this - `Connected to the target VM, address: 'localhost:50000', transport: 'socket'`.
Breakpoints can now be set up to halt the debugger at the required break point to understand the flow of the program.

## Release Workflow

To perform a full plugin release, maintainers can run ``mvn release:prepare release:perform`` To release a snapshot, e.g. with a bug fix for users to test, just run ``mvn deploy``

0 comments on commit 7036fde

Please sign in to comment.