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

rc3 bug with jdk 17 #1214

Closed
ambition-consulting opened this issue Jul 15, 2023 · 3 comments · Fixed by #1217
Closed

rc3 bug with jdk 17 #1214

ambition-consulting opened this issue Jul 15, 2023 · 3 comments · Fixed by #1217

Comments

@ambition-consulting
Copy link

ambition-consulting commented Jul 15, 2023

Reproduce

on execution powershell.exe ./dtcw.ps1 local exportStructurizr

dtcw 0.50 - ##DTCW_GIT_HASH##
docToolchain 3.0.0-rc1
OS/arch: pwsh windows x64
Available docToolchain environments: local docker
Environments with docToolchain [3.0.0-rc1]: local docker
Using environment: local
java : openjdk version "17.0.2" 2022-01-18
At C:\Users\John\work\src\dg\cim.cim\cim-doc\dtcw.ps1:412 char:22
+     $javaversion = ((java -version 2>&1 | Select-String -Pattern 'ver ...
+                      ~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (openjdk version "17.0.2" 2022-01-18:String) [], RemoteException
    + FullyQualifiedErrorId : NativeCommandError

[ERROR] Command execution failed.
org.apache.commons.exec.ExecuteException: Process exited with an error: 1 (Exit value: 1)
    at org.apache.commons.exec.DefaultExecutor.executeInternal (DefaultExecutor.java:404)
    at org.apache.commons.exec.DefaultExecutor.execute (DefaultExecutor.java:166)
    at org.codehaus.mojo.exec.ExecMojo.executeCommandLine (ExecMojo.java:1000)
    at org.codehaus.mojo.exec.ExecMojo.executeCommandLine (ExecMojo.java:947)
    at org.codehaus.mojo.exec.ExecMojo.execute (ExecMojo.java:471)
    at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:137)
    at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:370)
    at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:351)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:215)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:171)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:163)
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:117)
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:81)
    at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:56)
    at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:128)
    at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:298)
    at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:192)
    at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:105)
    at org.apache.maven.cli.MavenCli.execute (MavenCli.java:960)
    at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:293)
    at org.apache.maven.cli.MavenCli.main (MavenCli.java:196)
    at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
    at jdk.internal.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:77)
    at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke (Method.java:568)
    at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:282)
    at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:225)
    at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:406)
    at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:347)

Context

λ mvn -v
Apache Maven 3.8.7 (b89d5959fcde851dcb1c8946a785a163f14e1e29)
Maven home: C:\Users\John\work\tools\apache-maven-3.8.7
Java version: 17.0.2, vendor: Oracle Corporation, runtime: C:\Program Files\Java\jdk-17.0.2
Default locale: en_GB, platform encoding: Cp1252
OS name: "windows 11", version: "10.0", arch: "amd64", family: "windows"

freshly installed doctoolchain before with powershell ./dtcw.ps1 local install doctoolchain

@ambition-consulting
Copy link
Author

Also, I'm experiencing encoding problems, and can't use plantuml:: macros anymore without triggering jruby encoding errors, despite using UTF-8 everywhere and running fixEncodings task before.

rdmueller added a commit that referenced this issue Jul 17, 2023
rdmueller added a commit that referenced this issue Jul 17, 2023
dtcw.ps1: this change fixes problems with the detection and usage of the correct java version #1214 #1216
@rdmueller
Copy link
Member

thanx for reporting this. Your first problem should be fixed. Please download dtcw.ps1 again

@rdmueller
Copy link
Member

for the second problem, I opened a new issue #1218

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