You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tomee.apache.org by "Cesar Hernandez (Jira)" <ji...@apache.org> on 2022/06/14 16:33:00 UTC

[jira] [Commented] (TOMEE-3979) service.bat issue when using JRE_HOME on Windows

    [ https://issues.apache.org/jira/browse/TOMEE-3979?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17554188#comment-17554188 ] 

Cesar Hernandez commented on TOMEE-3979:
----------------------------------------

PRs available:

[https://github.com/apache/tomee/pull/886]

[https://github.com/apache/tomee/pull/887]

 

> service.bat issue when using JRE_HOME on Windows 
> -------------------------------------------------
>
>                 Key: TOMEE-3979
>                 URL: https://issues.apache.org/jira/browse/TOMEE-3979
>             Project: TomEE
>          Issue Type: Bug
>    Affects Versions: 9.0.0-M7, 8.0.11, 8.0.12
>            Reporter: Cesar Hernandez
>            Assignee: Cesar Hernandez
>            Priority: Major
>             Fix For: 8.0.13
>
>
> Pre requisites to reproduce this issue:
>  # Windows environment
>  # set JRE_HOME instead of JAVA_HOME
> Example:
>  
> {code:java}
> >set JRE_HOME=C:\java\jre-8
> >service.bat install tomee_service
> Installing the service 'tomee_service' ...
> Using CATALINA_HOME:    "C:\Users\Administrator\Documents\apache-tomee-8.0.11-plus\apache-tomee-plus-8.0.11"
> Using CATALINA_BASE:    "C:\Users\Administrator\Documents\apache-tomee-8.0.11-plus\apache-tomee-plus-8.0.11"
> Using JAVA_HOME:        ""
> Using JRE_HOME:         "C:\java\jre-8"
> Using JVM:              "C:\java\jre-8\bin\server\jvm.dll"
> Using Service User:     ""
> Installed, will now configure TomEE
> 11 was unexpected at this time. {code}
>  
> As part of the work done in https://issues.apache.org/jira/browse/TOMEE-2261,  The origin of the issue happens in this validation: 
> [https://github.com/apache/tomee/blob/45b1ba51ebfc31691bbf517d9d3d00c7fe86e48f/tomee/apache-tomee/src/main/resources/service.bat#L242-L248] because `JAVA_MAJOR_VERSION` is note defined when JRE_HOME is used (independently if it's Java 8, 11 etc.):[https://github.com/apache/tomee/blob/45b1ba51ebfc31691bbf517d9d3d00c7fe86e48f/tomee/apache-tomee/src/main/resources/service.bat#L88-L90]
>  
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.7#820007)