You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by GitBox <gi...@apache.org> on 2021/04/25 16:41:56 UTC
[GitHub] [maven] Dufgui opened a new pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Dufgui opened a new pull request #469:
URL: https://github.com/apache/maven/pull/469
Submitted by: Guillaume Dufour
Following this checklist to help us incorporate your
contribution quickly and easily:
- [ ] Make sure there is a [JIRA issue](https://issues.apache.org/jira/browse/MNG) filed
for the change (usually before you start working on it). Trivial changes like typos do not
require a JIRA issue. Your pull request should address just this issue, without
pulling in other changes.
- [ ] Each commit in the pull request should have a meaningful subject line and body.
- [ ] Format the pull request title like `[MNG-XXX] - Fixes bug in ApproximateQuantiles`,
where you replace `MNG-XXX` with the appropriate JIRA issue. Best practice
is to use the JIRA issue title in the pull request title and in the first line of the
commit message.
- [ ] Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
- [ ] Run `mvn clean verify` to make sure basic checks pass. A more thorough check will
be performed on your pull request automatically.
- [ ] You have run the [Core IT][core-its] successfully.
If your pull request is about ~20 lines of code you don't need to sign an
[Individual Contributor License Agreement](https://www.apache.org/licenses/icla.pdf) if you are unsure
please ask on the developers list.
To make clear that you license your contribution under
the [Apache License Version 2.0, January 2004](http://www.apache.org/licenses/LICENSE-2.0)
you have to acknowledge this by using the following check-box.
- [ ] I hereby declare this contribution to be licenced under the [Apache License Version 2.0, January 2004](http://www.apache.org/licenses/LICENSE-2.0)
- [ ] In any other case, please file an [Apache Individual Contributor License Agreement](https://www.apache.org/licenses/icla.pdf).
[core-its]: https://maven.apache.org/core-its/core-it-suite/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826764676
@Dufgui No need to close, everything is fine. @rfscholte @hboutemy WDYT?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] Dufgui commented on a change in pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
Dufgui commented on a change in pull request #469:
URL: https://github.com/apache/maven/pull/469#discussion_r620165827
##########
File path: apache-maven/src/assembly/shared/mvnwDebug
##########
@@ -27,7 +27,11 @@
# MAVEN_SKIP_RC (Optional) Flag to disable loading of mavenrc files.
# -----------------------------------------------------------------------------
-MAVEN_DEBUG_OPTS="-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=0.0.0.0:8000"
+if [ -z "${MAVEN_DEBUG_HOST}" ]; then
+ MAVEN_DEBUG_HOST='localhost'
Review comment:
ho sorry you are right. i will fix it
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] rfscholte commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
rfscholte commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830832454
See how some lines end
echo "Running Java $version with '$address'"; JAVA_VERSION=$version MAVEN_DE
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debu
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-827484126
>
>
> Is POSIX default value always supported? IIRC I had issues with this mechanism on some OSes. Maybe @hboutemy can refresh my memory.
Old Solaris default shell isn't POSIX compliant, but I don't know to what expect. It does not support `$()` execution. If they haven't moved to Java 8, they don't need to move with Maven anyway.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o edited a comment on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o edited a comment on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830824790
Here is the output on a IPv4 and IPv6 enabled host:
```
$ for version in 8 11 16; do
/usr/local/openjdk$version/bin/java -version
while read -r address; do
echo "Running Java $version with '$address'"; JAVA_VERSION=$version MAVEN_DE BUG_ADDRESS="$address" timeout 2 ~/apache-maven-4.0.0-alpha-1-SNAPSHOT/bin/mvnDe bug
done < input
done
openjdk version "1.8.0_282"
OpenJDK Runtime Environment (build 1.8.0_282-b08)
OpenJDK 64-Bit Server VM (build 25.282-b08, mixed mode)
Running Java 8 with 'localhost'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 37751
Running Java 8 with 'localhost:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 48142
Running Java 8 with 'localhost:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 8 with 'bsd1srv'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 44058
Running Java 8 with 'bsd1srv:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 36811
Running Java 8 with 'bsd1srv:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 8 with '*'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 10145
Running Java 8 with '*:0'
Preparing to execute Maven in debug mode
ERROR: transport error 202: gethostbyname: unknown host
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debu gInit.c:750]
Running Java 8 with '*:8888'
Preparing to execute Maven in debug mode
ERROR: transport error 202: gethostbyname: unknown host
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debu gInit.c:750]
Running Java 8 with '0.0.0.0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 29103
Running Java 8 with '0.0.0.0:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 17075
Running Java 8 with '0.0.0.0:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 8 with '[::]'
Preparing to execute Maven in debug mode
ERROR: transport error 202: gethostbyname: unknown host
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debu gInit.c:750]
Running Java 8 with '[::]:0'
Preparing to execute Maven in debug mode
ERROR: transport error 202: gethostbyname: unknown host
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debu gInit.c:750]
Running Java 8 with '[::]:8888'
Preparing to execute Maven in debug mode
ERROR: transport error 202: gethostbyname: unknown host
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debu gInit.c:750]
openjdk version "11.0.10" 2021-01-19
OpenJDK Runtime Environment (build 11.0.10+9-1)
OpenJDK 64-Bit Server VM (build 11.0.10+9-1, mixed mode)
Running Java 11 with 'localhost'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/ jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with 'localhost:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 29441
Running Java 11 with 'localhost:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 11 with 'bsd1srv'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/ jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with 'bsd1srv:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 20227
Running Java 11 with 'bsd1srv:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 11 with '*'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/ jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with '*:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 63302
Running Java 11 with '*:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 11 with '0.0.0.0'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/ jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with '0.0.0.0:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 11085
Running Java 11 with '0.0.0.0:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 11 with '[::]'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/ jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with '[::]:0'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/ jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with '[::]:8888'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/ jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
openjdk version "16" 2021-03-16
OpenJDK Runtime Environment (build 16+36-1)
OpenJDK 64-Bit Server VM (build 16+36-1, mixed mode, sharing)
Running Java 16 with 'localhost'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/ jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 16 with 'localhost:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 59409
Running Java 16 with 'localhost:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 16 with 'bsd1srv'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 16 with 'bsd1srv:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 27191
Running Java 16 with 'bsd1srv:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 16 with '*'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 16 with '*:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 25905
Running Java 16 with '*:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 16 with '0.0.0.0'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 16 with '0.0.0.0:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 20416
Running Java 16 with '0.0.0.0:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 16 with '[::]'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 16 with '[::]:0'
Preparing to execute Maven in debug mode
ERROR: transport error 202: getaddrinfo: failed to parse address
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 16 with '[::]:8888'
Preparing to execute Maven in debug mode
ERROR: transport error 202: getaddrinfo: failed to parse address
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] Dufgui commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
Dufgui commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826375147
Hello, i do another commit. Is it better for you?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] Dufgui commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
Dufgui commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826356676
Or maybe we can create a mvnHostDebug or something like this to bind on host because there is not so many people which need to debug maven from another host. (But it’s mandatory in case of container)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o edited a comment on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o edited a comment on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830828233
The problem is this:
https://github.com/AdoptOpenJDK/openjdk-jdk11u/blob/fa3ecefdd6eb14a910ae75b7c0aefb1cf8eedcce/src/jdk.jdi/share/classes/com/sun/tools/jdi/SocketTransportService.java#L218-L239
We had the same issue in HttpComponents Core and solved in https://github.com/apache/httpcomponents-core/pull/279
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] Dufgui commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
Dufgui commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830030715
is there any change expected from me ?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] Dufgui commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
Dufgui commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-827090808
I add POSIX default value and align mvnDebug and mvnwDebug
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] Dufgui commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
Dufgui commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826356676
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o edited a comment on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o edited a comment on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830782440
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] Dufgui commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
Dufgui commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830049229
@michael-o done
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826360145
>
>
> Or maybe we can create a mvnHostDebug or something like this to bind on host because there is not so many people which need to debug maven from another host. (But it’s mandatory in case of container)
Just make it `--debug-address ARG` and you are done.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] rfscholte commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
rfscholte commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-827470159
Is POSIX default value always supported? IIRC I had issues with this mechanism on some OSes. Maybe @hboutemy can refresh my memory.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] asfgit closed pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
asfgit closed pull request #469:
URL: https://github.com/apache/maven/pull/469
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] Dufgui commented on a change in pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
Dufgui commented on a change in pull request #469:
URL: https://github.com/apache/maven/pull/469#discussion_r619872748
##########
File path: apache-maven/src/assembly/shared/mvnwDebug
##########
@@ -27,7 +27,11 @@
# MAVEN_SKIP_RC (Optional) Flag to disable loading of mavenrc files.
# -----------------------------------------------------------------------------
-MAVEN_DEBUG_OPTS="-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=0.0.0.0:8000"
+if [ -z "${MAVEN_DEBUG_HOST}" ]; then
+ MAVEN_DEBUG_HOST='localhost'
Review comment:
No it's only available for bash. Not for sh. i prefere to use the most standard simple way.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826355261
>
>
> Guess standard is more "*:8000" but I agree with Sylwester localhost:8000 sounds saner.
`*:8000` and `0..0:8000` are two completely different things. `*:8000` isn't available on Java 8. So this change is the best compromise we have.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830817335
>
>
> My guess is that there is no default port anymore since ... Java 9? Which would mean it is not a bug, right?
> My reproducer is a simple
>
> ```
> "%JAVA_HOME%"\bin\java -Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=localhost
> ```
This should have been documented. If it is not, then it is a regression. I will prepare a full test for you.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830782440
@rfscholte Can you raise an issue with JBS to make this consistent across all versions?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] Dufgui commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
Dufgui commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826385544
> `MAVEN_DEBUG_ADDRESS`
Ok I do it
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] Dufgui commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
Dufgui commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826714633
So what do you propose? I close this? or I do what ? sorry i don't understand
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830822294
On a IPv4 only host:
```
osipovmi@deblndw011x:~
$ for version in 8 11 15; do
> /usr/local/openjdk$version/bin/java -version
> while read -r address; do
> echo "Running Java $version with '$address'"; JAVA_VERSION=$version MAVEN_DEBUG_ADDRESS="$address" timeout 2 ~/apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvnDebug
> done < input
> done
openjdk version "1.8.0_282"
OpenJDK Runtime Environment (build 1.8.0_282-b08)
OpenJDK 64-Bit Server VM (build 25.282-b08, mixed mode)
Running Java 8 with 'localhost'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 60800
Running Java 8 with 'localhost:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 60814
Running Java 8 with 'localhost:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 8 with 'deblndw011x'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 60832
Running Java 8 with 'deblndw011x:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 60839
Running Java 8 with 'deblndw011x:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 8 with '*'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 60850
Running Java 8 with '*:0'
Preparing to execute Maven in debug mode
ERROR: transport error 202: gethostbyname: unknown host
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debugInit.c:750]
Running Java 8 with '*:8888'
Preparing to execute Maven in debug mode
ERROR: transport error 202: gethostbyname: unknown host
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debugInit.c:750]
Running Java 8 with '0.0.0.0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 60858
Running Java 8 with '0.0.0.0:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 60865
Running Java 8 with '0.0.0.0:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 8 with '[::]'
Preparing to execute Maven in debug mode
ERROR: transport error 202: gethostbyname: unknown host
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debugInit.c:750]
Running Java 8 with '[::]:0'
Preparing to execute Maven in debug mode
ERROR: transport error 202: gethostbyname: unknown host
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debugInit.c:750]
Running Java 8 with '[::]:8888'
Preparing to execute Maven in debug mode
ERROR: transport error 202: gethostbyname: unknown host
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debugInit.c:750]
openjdk version "11.0.10" 2021-01-19
OpenJDK Runtime Environment (build 11.0.10+9-1)
OpenJDK 64-Bit Server VM (build 11.0.10+9-1, mixed mode)
Running Java 11 with 'localhost'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with 'localhost:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 60886
Running Java 11 with 'localhost:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 11 with 'deblndw011x'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with 'deblndw011x:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 60901
Running Java 11 with 'deblndw011x:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 11 with '*'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with '*:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 60932
Running Java 11 with '*:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 11 with '0.0.0.0'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with '0.0.0.0:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 60946
Running Java 11 with '0.0.0.0:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 11 with '[::]'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with '[::]:0'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with '[::]:8888'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
openjdk version "15.0.2" 2021-01-19
OpenJDK Runtime Environment (build 15.0.2+7-1)
OpenJDK 64-Bit Server VM (build 15.0.2+7-1, mixed mode, sharing)
Running Java 15 with 'localhost'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 15 with 'localhost:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 60985
Running Java 15 with 'localhost:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 15 with 'deblndw011x'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 15 with 'deblndw011x:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 61014
Running Java 15 with 'deblndw011x:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 15 with '*'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 15 with '*:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 61040
Running Java 15 with '*:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 15 with '0.0.0.0'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 15 with '0.0.0.0:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 61067
Running Java 15 with '0.0.0.0:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 15 with '[::]'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 15 with '[::]:0'
Preparing to execute Maven in debug mode
ERROR: transport error 202: getaddrinfo: failed to parse address
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 15 with '[::]:8888'
Preparing to execute Maven in debug mode
ERROR: transport error 202: getaddrinfo: failed to parse address
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] rfscholte commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
rfscholte commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830816211
My guess is that there is no default port anymore since ... Java 9? Which would mean it is not a bug, right?
My reproducer is a simple
"%JAVA_HOME%"\bin\java -Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=localhost
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] rmannibucau commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
rmannibucau commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826487060
I dont see what ${MAVEN_DEBUG_HOST} solves, it is equivalent to use maven_opts for end users since you have to set something anyway so does not change anything at all except it makes the script more complex without any reason (security could have been one but not in the pr).
localhost:8000 works on java 8, it is even used in the jdk tests.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830782860
Yet another joke:
```
$ JAVA_VERSION=8 MAVEN_DEBUG_ADDRESS="localhost" apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvnDebug
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 65508
^Cosipovmi@deblndw011x:~
$ JAVA_VERSION=11 MAVEN_DEBUG_ADDRESS="localhost" apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvnDebug
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
osipovmi@deblndw011x:~
$ JAVA_VERSION=15 MAVEN_DEBUG_ADDRESS="localhost" apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvnDebug
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o edited a comment on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o edited a comment on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830782440
@rfscholte Can you raise an issue with JBS to make this consistent across all versions?
```
$ JAVA_VERSION=8 MAVEN_DEBUG_ADDRESS="*:8880" apache-maven-4.0.0-alpha-1-SNAPSHO T-1/bin/mvnDebug
Preparing to execute Maven in debug mode
ERROR: transport error 202: gethostbyname: unknown host
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debu gInit.c:750]
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826355168
>
>
> I would say that this is not safe
Please explain!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826360204
>
>
> @michael-o right but 0.0.0.0 will come back next the hour after the release as a CVE so not an option sadly.
> @Dufgui java 8 is the last one with lib/jre so I guess we can test the presence to adjust the option?
That's nonsense because the Java 8 call implicitly binds on all interfaces.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] rfscholte commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
rfscholte commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826775051
these changes are done on the mvnwdebug scripts, i.e. the files that are added to the Maven Project when calling `mvn wrapper` in Maven 4.
These changes need to be in line with https://github.com/apache/maven/tree/master/apache-maven/src/assembly/maven/bin.
It is now maintainted separately to keep the order script in line with Maven 3, but it should be reordered with https://issues.apache.org/jira/browse/MNG-7073 . This should reduce the number of files that are combined to the new script
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830823956
It pretty much seems that Oracle is incapable:
* Making it consistently work across versions
* Update the code from stone age to present days for IPv6.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830834033
@rfscholte Here you go: https://pastebin.com/iHgVdH1d
There are bascially two issues:
* parsing is bad and inconsistent across versions
* Output does not correspond to the input. Just printing the port is nonsense.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] rmannibucau commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
rmannibucau commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830820931
Not sure it changed between j8 and j11 but `MAVEN_DEBUG_ADDRESS="localhost"` means port "localhost", maybe try MAVEN_DEBUG_ADDRESS=5005 instead?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830822186
@rmannibucau No, address means every to the respect of the address family. In this case INET or INET6.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] rmannibucau commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
rmannibucau commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826354122
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o edited a comment on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o edited a comment on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826360204
>
>
> @michael-o right but 0.0.0.0 will come back next the hour after the release as a CVE so not an option sadly.
> @Dufgui java 8 is the last one with lib/jre so I guess we can test the presence to adjust the option?
That's nonsense because the Java 8 call implicitly binds on all interfaces anyway.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o removed a comment on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o removed a comment on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830781618
What a joke from Oracle:
```
$ JAVA_VERSION=15 MAVEN_DEBUG_ADDRESS="[::]:8001" apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvnDebug
Preparing to execute Maven in debug mode
ERROR: transport error 202: getaddrinfo: failed to parse address
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o edited a comment on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o edited a comment on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830832264
@rfscholte Which end? I am confused. I agree with the pure `java`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826355168
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o edited a comment on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o edited a comment on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826360204
>
>
> @michael-o right but 0.0.0.0 will come back next the hour after the release as a CVE so not an option sadly.
> @Dufgui java 8 is the last one with lib/jre so I guess we can test the presence to adjust the option?
That's nonsense because the Java 8 call implicitly binds on all interfaces anyway.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830031625
>
>
> is there any change expected from me ?
Last nit, please document the variable in the header section of the file.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] Dufgui commented on a change in pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
Dufgui commented on a change in pull request #469:
URL: https://github.com/apache/maven/pull/469#discussion_r619872748
##########
File path: apache-maven/src/assembly/shared/mvnwDebug
##########
@@ -27,7 +27,11 @@
# MAVEN_SKIP_RC (Optional) Flag to disable loading of mavenrc files.
# -----------------------------------------------------------------------------
-MAVEN_DEBUG_OPTS="-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=0.0.0.0:8000"
+if [ -z "${MAVEN_DEBUG_HOST}" ]; then
+ MAVEN_DEBUG_HOST='localhost'
Review comment:
No it's only available for bash. Not for sh. i prefere to use the most standard simple way.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] rfscholte commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
rfscholte commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830785343
Can you share with which arguments `java` is being executed?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826765362
This looks OK now for me, will test in the next couple of days... @Dufgui Do you want to convert the default value to POSIX `:-`?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] rmannibucau commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
rmannibucau commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826754315
@Dufgui I'd be to use "localhost:8000" which works on java 8, 11 etc by default and if not sufficient rely on MAVEN_OPTS until we use a script tomcat-like to handle properly the configuration of this option but not a half baked solution, no?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] rmannibucau commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
rmannibucau commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826358233
@michael-o right but 0.0.0.0 will come back next the hour after the release as a CVE so not an option sadly.
@Dufgui java 8 is the last one with lib/jre so I guess we can test the presence to adjust the option?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830828233
The problem is this:
https://github.com/AdoptOpenJDK/openjdk-jdk11u/blob/fa3ecefdd6eb14a910ae75b7c0aefb1cf8eedcce/src/jdk.jdi/share/classes/com/sun/tools/jdi/SocketTransportService.java#L218-L239
We had the same issue in HttpCompnents Core and solved in https://github.com/apache/httpcomponents-core/pull/279
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] rmannibucau commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
rmannibucau commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826361369
@michael-o
> Just make it --debug-address ARG and you are done.
It is called MAVEN_OPTS, issue is mvnDebug script not working OOTB not to enable anything IMHO.
> That's nonsense because the Java 8 call implicitly binds on all interfaces anyway.
Then move to localhost too but issue hit other asf projects already so maybe let's add a JPDA_ADDRESS (like tomcat)? Would make sense to me.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-827149215
I can live with that change. If no one objects in the next couple of days, I'll test and then merge.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] rmannibucau commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
rmannibucau commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826354122
Guess standard is more "*:8000" but I agree with Sylwester localhost:8000 sounds saner.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830824790
Here is the output on a IPv4 and IPv6 enabled host:
``´
$ for version in 8 11 16; do
/usr/local/openjdk$version/bin/java -version
while read -r address; do
echo "Running Java $version with '$address'"; JAVA_VERSION=$version MAVEN_DE BUG_ADDRESS="$address" timeout 2 ~/apache-maven-4.0.0-alpha-1-SNAPSHOT/bin/mvnDe bug
done < input
done
openjdk version "1.8.0_282"
OpenJDK Runtime Environment (build 1.8.0_282-b08)
OpenJDK 64-Bit Server VM (build 25.282-b08, mixed mode)
Running Java 8 with 'localhost'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 37751
Running Java 8 with 'localhost:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 48142
Running Java 8 with 'localhost:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 8 with 'bsd1srv'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 44058
Running Java 8 with 'bsd1srv:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 36811
Running Java 8 with 'bsd1srv:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 8 with '*'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 10145
Running Java 8 with '*:0'
Preparing to execute Maven in debug mode
ERROR: transport error 202: gethostbyname: unknown host
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debu gInit.c:750]
Running Java 8 with '*:8888'
Preparing to execute Maven in debug mode
ERROR: transport error 202: gethostbyname: unknown host
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debu gInit.c:750]
Running Java 8 with '0.0.0.0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 29103
Running Java 8 with '0.0.0.0:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 17075
Running Java 8 with '0.0.0.0:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 8 with '[::]'
Preparing to execute Maven in debug mode
ERROR: transport error 202: gethostbyname: unknown host
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debu gInit.c:750]
Running Java 8 with '[::]:0'
Preparing to execute Maven in debug mode
ERROR: transport error 202: gethostbyname: unknown host
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debu gInit.c:750]
Running Java 8 with '[::]:8888'
Preparing to execute Maven in debug mode
ERROR: transport error 202: gethostbyname: unknown host
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debu gInit.c:750]
openjdk version "11.0.10" 2021-01-19
OpenJDK Runtime Environment (build 11.0.10+9-1)
OpenJDK 64-Bit Server VM (build 11.0.10+9-1, mixed mode)
Running Java 11 with 'localhost'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/ jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with 'localhost:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 29441
Running Java 11 with 'localhost:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 11 with 'bsd1srv'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/ jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with 'bsd1srv:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 20227
Running Java 11 with 'bsd1srv:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 11 with '*'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/ jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with '*:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 63302
Running Java 11 with '*:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 11 with '0.0.0.0'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/ jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with '0.0.0.0:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 11085
Running Java 11 with '0.0.0.0:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 11 with '[::]'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/ jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with '[::]:0'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/ jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
Running Java 11 with '[::]:8888'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/ jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
openjdk version "16" 2021-03-16
OpenJDK Runtime Environment (build 16+36-1)
OpenJDK 64-Bit Server VM (build 16+36-1, mixed mode, sharing)
Running Java 16 with 'localhost'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/ jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 16 with 'localhost:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 59409
Running Java 16 with 'localhost:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 16 with 'bsd1srv'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 16 with 'bsd1srv:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 27191
Running Java 16 with 'bsd1srv:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 16 with '*'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 16 with '*:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 25905
Running Java 16 with '*:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 16 with '0.0.0.0'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 16 with '0.0.0.0:0'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 20416
Running Java 16 with '0.0.0.0:8888'
Preparing to execute Maven in debug mode
Listening for transport dt_socket at address: 8888
Running Java 16 with '[::]'
Preparing to execute Maven in debug mode
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 16 with '[::]:0'
Preparing to execute Maven in debug mode
ERROR: transport error 202: getaddrinfo: failed to parse address
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
Running Java 16 with '[::]:8888'
Preparing to execute Maven in debug mode
ERROR: transport error 202: getaddrinfo: failed to parse address
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on a change in pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on a change in pull request #469:
URL: https://github.com/apache/maven/pull/469#discussion_r619864958
##########
File path: apache-maven/src/assembly/shared/mvnwDebug
##########
@@ -27,7 +27,11 @@
# MAVEN_SKIP_RC (Optional) Flag to disable loading of mavenrc files.
# -----------------------------------------------------------------------------
-MAVEN_DEBUG_OPTS="-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=0.0.0.0:8000"
+if [ -z "${MAVEN_DEBUG_HOST}" ]; then
+ MAVEN_DEBUG_HOST='localhost'
Review comment:
Rather use `${...:-DEFAULT_VALUE}`.
##########
File path: apache-maven/src/assembly/shared/mvnwDebug
##########
@@ -27,7 +27,11 @@
# MAVEN_SKIP_RC (Optional) Flag to disable loading of mavenrc files.
# -----------------------------------------------------------------------------
-MAVEN_DEBUG_OPTS="-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=0.0.0.0:8000"
+if [ -z "${MAVEN_DEBUG_HOST}" ]; then
+ MAVEN_DEBUG_HOST='localhost'
Review comment:
I don't agree: https://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html#tag_18_06_02
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830781618
What a joke from Oracle:
```
$ JAVA_VERSION=15 MAVEN_DEBUG_ADDRESS="[::]:8001" apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvnDebug
Preparing to execute Maven in debug mode
ERROR: transport error 202: getaddrinfo: failed to parse address
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] rmannibucau commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
rmannibucau commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830823506
@michael-o just mentionning that the JDK parses the address by testing if ":" exists and if not uses localhost as host and the string as port. Your 15474 is a random value attributed because no port was set so address=localhost is not expected to work I think. It is explained at https://docs.oracle.com/en/java/javase/11/docs/specs/jpda/conninv.html.
> In contexts where a client is attaching to a server, socket transport addresses have the format "<name>:<port>" where <name> is the host name and <port> is the socket port number at which it attaches or listens. In contexts where a server is waiting for a client to attach, the address consists of the port number alone (the host name is implicit).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-826362087
>
>
> @michael-o
>
> > Just make it --debug-address ARG and you are done.
>
> It is called MAVEN_OPTS, issue is mvnDebug script not working OOTB not to enable anything IMHO.
??? this option it not mandatory otherwise the word option would be abssurd. You can provide, but you don't have to.
> > That's nonsense because the Java 8 call implicitly binds on all interfaces anyway.
>
> Then move to localhost too but issue hit other asf projects already so maybe let's add a JPDA_ADDRESS (like tomcat)? Would make sense to me.
Well, we don't have a `setenv.sh` for this...
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on a change in pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on a change in pull request #469:
URL: https://github.com/apache/maven/pull/469#discussion_r619864958
##########
File path: apache-maven/src/assembly/shared/mvnwDebug
##########
@@ -27,7 +27,11 @@
# MAVEN_SKIP_RC (Optional) Flag to disable loading of mavenrc files.
# -----------------------------------------------------------------------------
-MAVEN_DEBUG_OPTS="-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=0.0.0.0:8000"
+if [ -z "${MAVEN_DEBUG_HOST}" ]; then
+ MAVEN_DEBUG_HOST='localhost'
Review comment:
Rather use `${...:-DEFAULT_VALUE}`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on a change in pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on a change in pull request #469:
URL: https://github.com/apache/maven/pull/469#discussion_r619878372
##########
File path: apache-maven/src/assembly/shared/mvnwDebug
##########
@@ -27,7 +27,11 @@
# MAVEN_SKIP_RC (Optional) Flag to disable loading of mavenrc files.
# -----------------------------------------------------------------------------
-MAVEN_DEBUG_OPTS="-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=0.0.0.0:8000"
+if [ -z "${MAVEN_DEBUG_HOST}" ]; then
+ MAVEN_DEBUG_HOST='localhost'
Review comment:
I don't agree: https://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html#tag_18_06_02
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] rfscholte commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
rfscholte commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830832132
the script seems incomplete, as it strips off the end, please update.
To make is useful for the bugtracker, please reduce it to the pure `java` call as it is unrelated to Maven (which will make it easier to reproduce and fix, just like we handle our issues).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830832601
Oh yes, I guess that is my copy and paste error. Will correct.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] rmannibucau commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
rmannibucau commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830827690
Maybe try to comply to InetAddress api? https://github.com/AdoptOpenJDK/openjdk-jdk11u/blob/fa3ecefdd6eb14a910ae75b7c0aefb1cf8eedcce/src/jdk.jdi/share/classes/com/sun/tools/jdi/SocketTransportService.java#L242
Most of your tests are invalid it seems (host without port, ipv6 address with brackets etc)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830832264
@rfscholte Which end? I am confused.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [maven] michael-o commented on pull request #469: [MNG-7090] mvnDebug socket binds on 0.0.0.0
Posted by GitBox <gi...@apache.org>.
michael-o commented on pull request #469:
URL: https://github.com/apache/maven/pull/469#issuecomment-830802057
@rfscholte
Here you go:
```
$ JAVA_VERSION=8 MAVEN_DEBUG_ADDRESS="*:8880" sh -x apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvnDebug
+ MAVEN_DEBUG_OPTS='-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=*:8880'
+ echo Preparing to execute Maven in debug mode
Preparing to execute Maven in debug mode
+ dirname apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvnDebug
+ env 'MAVEN_OPTS=' 'MAVEN_DEBUG_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=*:8880' apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvn
ERROR: transport error 202: gethostbyname: unknown host
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [debugInit.c:750]
osipovmi@deblndw011x:~
$ JAVA_VERSION=8 MAVEN_DEBUG_ADDRESS="localhost" sh -x apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvnDebug
+ MAVEN_DEBUG_OPTS='-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=localhost'
+ echo Preparing to execute Maven in debug mode
Preparing to execute Maven in debug mode
+ dirname apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvnDebug
+ env 'MAVEN_OPTS=' 'MAVEN_DEBUG_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=localhost' apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvn
Listening for transport dt_socket at address: 15474
^Cosipovmi@deblndw011x:~
$ JAVA_VERSION=11 MAVEN_DEBUG_ADDRESS="localhost" sh -x apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvnDebug
+ MAVEN_DEBUG_OPTS='-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=localhost'
+ echo Preparing to execute Maven in debug mode
Preparing to execute Maven in debug mode
+ dirname apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvnDebug
+ env 'MAVEN_OPTS=' 'MAVEN_DEBUG_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=localhost' apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvn
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:735]
osipovmi@deblndw011x:~
$ JAVA_VERSION=15 MAVEN_DEBUG_ADDRESS="localhost" sh -x apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvnDebug
+ MAVEN_DEBUG_OPTS='-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=localhost'
+ echo Preparing to execute Maven in debug mode
Preparing to execute Maven in debug mode
+ dirname apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvnDebug
+ env 'MAVEN_OPTS=' 'MAVEN_DEBUG_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=localhost' apache-maven-4.0.0-alpha-1-SNAPSHOT-1/bin/mvn
ERROR: transport error 103: invalid port number specified
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [src/jdk.jdwp.agent/share/native/libjdwp/debugInit.c:734]
```
Running on:
```
$ for ver in 8 11 15; do /usr/local/openjdk$ver/bin/java -version; done
openjdk version "1.8.0_282"
OpenJDK Runtime Environment (build 1.8.0_282-b08)
OpenJDK 64-Bit Server VM (build 25.282-b08, mixed mode)
openjdk version "11.0.10" 2021-01-19
OpenJDK Runtime Environment (build 11.0.10+9-1)
OpenJDK 64-Bit Server VM (build 11.0.10+9-1, mixed mode)
openjdk version "15.0.2" 2021-01-19
OpenJDK Runtime Environment (build 15.0.2+7-1)
OpenJDK 64-Bit Server VM (build 15.0.2+7-1, mixed mode, sharing)
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org