Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automatically forward JDWP connection #584

Merged
merged 1 commit into from
Mar 3, 2015

Conversation

jtulach
Copy link

@jtulach jtulach commented Feb 17, 2015

For your consideration: I'd like to simplify debugging of Android applications when using the android-maven-plugin. I am attaching initial sketch that does the job for me. I am ready to polish it according to your suggestions.

Annoying thing on debugging (at least for me) is to find a PID number of just launched process and establish JDWP forwarding, so I can connect my debugger to it. I believe all of this can be automated.

My pull request allows one to specify port number via -Dandroid.run.debug=1234 and the plugin then takes care about the rest.

@Shusshu
Copy link
Member

Shusshu commented Feb 17, 2015

This would break backwards compatibility

Is there a default port used in most cases? (that could be set if the user uses the old way of android.run.debug=true)

@jtulach
Copy link
Author

jtulach commented Feb 17, 2015

My intent was to keep backward compatibility. The value -Dandroid.run.debug=true is still recognized - in such case no port forwarding is done, as it was the case before my changes.

There is no default port. But what could be done is to find not yet used port and forward the jdwp connection to it - and print its value in the output - something like "Debugger is ready on 5432 port". I can do it if such idea seems useful.

@jtulach
Copy link
Author

jtulach commented Feb 20, 2015

Anything else I can do to help this pull request be accepted?

@Shusshu
Copy link
Member

Shusshu commented Feb 20, 2015

For the moment (next several weeks or month) I'm not able to test anything.

I'd wait for another collaborator to check this out.

@mosabua
Copy link
Member

mosabua commented Feb 20, 2015

I will try to get to it over the next week.

@jtulach
Copy link
Author

jtulach commented Feb 24, 2015

Btw. I am trying to orchestrate this #584 pull request and a necessary change in NetBeans IDE and make sure they work well together. Hopefully interested parties will be able to agree on both ends of the connection.

@mosabua mosabua merged commit 7b722a6 into simpligility:master Mar 3, 2015
@mosabua
Copy link
Member

mosabua commented Mar 3, 2015

I had to update the Run config class to use String as datatype as well so that pom based configuration works. Otherwise this seems to work okay. I updated docs and will add changelog in a sec as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants