You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by FÖRSTERLING Björn <Bj...@cpb-software.com> on 2022/09/20 08:27:08 UTC

Building Apache Camel

Hello,

I just tried building Apache Camel to get a jar.
According to the documentation you have to execute these two lines:

$ export MAVEN_OPTS="-Xms3000m -Xmx3000m -XX:MaxPermSize=512m"
$ mvn clean source:jar install -Pfastinstall
Unrecognized VM option 'MaxPermSize=512m'
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.

I use openjdk version "17.0.4" 2022-07-19.

Do I need an older java version or is the MaxPermSize option different different in java 17?

Thanks in advance.

Greetings
Björn Försterling

Re: Building Apache Camel

Posted by Maarten Donderwinkel <ma...@aiden.eu>.
The MaxPermSize option has been deleted as of Java 17 (in Java 16 this is marked as obsolete).
You should either remove it or change it to MaxMetaspaceSize.

According to the Java Docs:
-XX:MaxPermSize=size
Sets the maximum permanent generation space size (in bytes). This option was deprecated in JDK 8 and superseded by the -XX:MaxMetaspaceSize option.

https://docs.oracle.com/en/java/javase/17/docs/specs/man/java.html#removed-java-options



Met vriendelijke groet | Kind Regards | Meilleures salutations | Mit freundlichen Grü?en,

Maarten Donderwinkel

Aiden   www.aiden.eu    [data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB0AAAAdCAMAAABhTZc9AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAzUExURQAAAEBQgDhQeDpQejxQeDlTeTpSeDtSeTpSeDtSeTtSejxSeTtReTtTeTtSeTtSeTtSeaJ0QfYAAAAQdFJOUwAQIDBAUGBwgI+fr7/P3+8jGoKKAAAACXBIWXMAABcRAAAXEQHKJvM/AAAAoUlEQVQ4T6WSWw7DIAwE7VACtDRw/9MW7C1Kw0OKOl+wI0C2ob9hb7AaYXPesexgT26uXznOdbl2oUsOvSE5I7bqxEjO1JtFj44Sq00P7C88xXrsrmxi06xdenim+VhqI3aqURV0V7c+rZpT19TYtCHf9Zzf0O6IC10Y6TLnL6KvnQ2Qqh3Sxg4pA+3nadrjAckvVkuLo59QYevD8IvdgegD6EkL94fs/OQAAAAASUVORK5CYII=]  +31 (0) 88 060 5111

Locatie Boxtel  Kastanjelaan 3 | 5283 WE Boxtel [data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB0AAAAdCAMAAABhTZc9AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAzUExURQAAAEBQgDhQeDpQejxQeDlTeTpSeDtSeTpSeDtSeTtSejxSeTtReTtTeTtSeTtSeTtSeaJ0QfYAAAAQdFJOUwAQIDBAUGBwgI+fr7/P3+8jGoKKAAAACXBIWXMAABcRAAAXEQHKJvM/AAAAoUlEQVQ4T6WSWw7DIAwE7VACtDRw/9MW7C1Kw0OKOl+wI0C2ob9hb7AaYXPesexgT26uXznOdbl2oUsOvSE5I7bqxEjO1JtFj44Sq00P7C88xXrsrmxi06xdenim+VhqI3aqURV0V7c+rZpT19TYtCHf9Zzf0O6IC10Y6TLnL6KvnQ2Qqh3Sxg4pA+3nadrjAckvVkuLo59QYevD8IvdgegD6EkL94fs/OQAAAAASUVORK5CYII=]  +31 (0) 88 060 5103

Contact E-mail: maarten.donderwinkel@aiden.eu   [data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB0AAAAdCAMAAABhTZc9AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAhUExURQAAAEBQgDpSeDtSeTpSeDtSejtReTtTeTtSeTtSeTtSeSPg/l8AAAAKdFJOUwAQYHCAn7/P3+9H8icYAAAACXBIWXMAABcRAAAXEQHKJvM/AAAATElEQVQ4T+3Myw6AMAhE0Skgtf7/B6vpNGVBfOx7VmRuAj5Rj5Tr4MelmVq7D+c69CoiNa/7lNTCCyirrhq81TolNfpXjU+7jesT4AQwOwYrLtoZpwAAAABJRU5ErkJggg==]  +31 (0) 6 8683 0832


[cid:afbeelding1_eb30b6f7-44ba-411f-af30-95d95824f737.png]<https://www.facebook.com/weareAiden.eu> [cid:afbeelding2_ae36edb4-28f1-4ddd-b314-097daeb787bd.png] <https://www.linkedin.com/company/aiden-eu/>  [cid:afbeelding3_88fd1a9e-f670-41ca-b591-7b87eb136bfe.png] <https://twitter.com/weareAiden>  [cid:afbeelding4_53e3956d-90a9-4883-9fc2-fac4ed0659da.png] <https://www.youtube.com/channel/UCcLccRfot11DrZLNhlAS8fA>     [cid:aidenlogowithstrapline_royalblue_cmyk_9d2ff840-c0a7-46c9-b176-e08fc6dd5956.png] <https://www.aiden.eu/>  <https://www.twitter.com/user_name_here>   <https://www.youtube.com/user/user_name_here>


From: ski n <ra...@gmail.com>
Date: Tuesday, 20 September 2022 at 10:35
To: users@camel.apache.org <us...@camel.apache.org>
Subject: Re: Building Apache Camel
You can either build with OpenJDK 11 with the option or build it with
OpenJDK 17 without the option.

The option:

-XX:MaxPermSize=size

Was already deprecated for a while and has been removed in Java 17.

Raymond


On Tue, Sep 20, 2022 at 10:27 AM FÖRSTERLING Björn <
Bjoern.Foersterling@cpb-software.com> wrote:

> Hello,
>
> I just tried building Apache Camel to get a jar.
> According to the documentation you have to execute these two lines:
>
> $ export MAVEN_OPTS="-Xms3000m -Xmx3000m -XX:MaxPermSize=512m"
> $ mvn clean source:jar install -Pfastinstall
> Unrecognized VM option 'MaxPermSize=512m'
> Error: Could not create the Java Virtual Machine.
> Error: A fatal exception has occurred. Program will exit.
>
> I use openjdk version "17.0.4" 2022-07-19.
>
> Do I need an older java version or is the MaxPermSize option different
> different in java 17?
>
> Thanks in advance.
>
> Greetings
> Björn Försterling
>

Re: Building Apache Camel

Posted by ski n <ra...@gmail.com>.
You can either build with OpenJDK 11 with the option or build it with
OpenJDK 17 without the option.

The option:

-XX:MaxPermSize=size

Was already deprecated for a while and has been removed in Java 17.

Raymond


On Tue, Sep 20, 2022 at 10:27 AM FÖRSTERLING Björn <
Bjoern.Foersterling@cpb-software.com> wrote:

> Hello,
>
> I just tried building Apache Camel to get a jar.
> According to the documentation you have to execute these two lines:
>
> $ export MAVEN_OPTS="-Xms3000m -Xmx3000m -XX:MaxPermSize=512m"
> $ mvn clean source:jar install -Pfastinstall
> Unrecognized VM option 'MaxPermSize=512m'
> Error: Could not create the Java Virtual Machine.
> Error: A fatal exception has occurred. Program will exit.
>
> I use openjdk version "17.0.4" 2022-07-19.
>
> Do I need an older java version or is the MaxPermSize option different
> different in java 17?
>
> Thanks in advance.
>
> Greetings
> Björn Försterling
>

Re: Building Apache Camel

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

That website info is a bit outdated as today these settings are automatic
set in the .mvn sub folder of the source code, eg see the file
.mvn/jvm.confiig

.mvn/jvm.config
-Xmx3584m -Djava.awt.headless=true -XX:+UseG1GC -XX:+UseStringDeduplication

So you dont need to tweak just use mvn clean install -P fastinstall

On Tue, Sep 20, 2022 at 10:27 AM FÖRSTERLING Björn <
Bjoern.Foersterling@cpb-software.com> wrote:

> Hello,
>
> I just tried building Apache Camel to get a jar.
> According to the documentation you have to execute these two lines:
>
> $ export MAVEN_OPTS="-Xms3000m -Xmx3000m -XX:MaxPermSize=512m"
> $ mvn clean source:jar install -Pfastinstall
> Unrecognized VM option 'MaxPermSize=512m'
> Error: Could not create the Java Virtual Machine.
> Error: A fatal exception has occurred. Program will exit.
>
> I use openjdk version "17.0.4" 2022-07-19.
>
> Do I need an older java version or is the MaxPermSize option different
> different in java 17?
>
> Thanks in advance.
>
> Greetings
> Björn Försterling
>


-- 
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2