Setup Remote debugging with IntelliJ

Hi Team,

Background


I have pulled Ignition8 docker image and gateway application is running on port 9088.
I am able to access Ignition application on localhost:9088
Docker image : Docker

Now I want to setup Remote debugging profile to test a Driver module(OPC XML DA in my case).

Followed steps from here Debugging in IntelliJ - Ignition SDK Programmer's Guide - Ignition Documentation.

ignition.conf

wrapper.java.additional.2=-Xdebug
wrapper.java.additional.3=-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=*:8000

IntelliJ Remote debug command line arguments

-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=*:8000
Host : localhost
Port : 8000


Issue

When tried run in debug mode getting below error in IntelliJ

Error running 'Remote debug': Unable to open debugger port (localhost:8000): java.net.ConnectException "Connection ref

I'm missing some context here.

Can someone help me to resolve this issue and share any doc with all detailed steps to setup Remote debug in IntelliJ.

You should be able to directly enable (without editing of the ignition.conf file) debug mode by using the -d flag of runtime arguments of the container. You’ll also want to probably publish port 8000, e.g.

docker run -p 9088:8088 -p 8000:8000 \
  -v your-vol-name:/usr/local/bin/ignition/data \
  inductiveautomation/ignition:8.1.15 \
  -d

Note: you can replace the backslashes \ with backticks ` for multi-line separators if you’re on Powershell on Windows.

But you shouldn't go along with Microsoft's efforts to Embrace-Extend-Extinguish. ):

2 Likes

I was able to resolve the issue.

docker run -d -p 9088:8088 -p 8000:8000 --name ignition-test inductiveautomation/ignition:8.1.13 -n docker-test -a localhost -h 9088 -s 9043

Thanks for the help.