Skip to content

Commit be37153

Browse files
committed
Review and move native-image-configuration-examples to archive/class-initialization-examples
1 parent 773dab2 commit be37153

File tree

21 files changed

+8
-17
lines changed

21 files changed

+8
-17
lines changed

native-image-configure-examples/README.md renamed to archive/class-initialization-examples/README.md

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -20,28 +20,28 @@ In both examples we use the Jackson framework to parse a JSON file to determine
2020

2121
1. Download and install the latest GraalVM JDK using [SDKMAN!](https://sdkman.io/).
2222
```bash
23-
sdk install java 21.0.1-graal
23+
sdk install java 21.0.5-graal
2424
```
2525

26-
2. Download or clone the repository and navigate into the `native-image-configure-examples` directory:
26+
2. Download or clone the repository and navigate into the `class-initialization-examples` directory:
2727
```bash
2828
git clone https://github.com/graalvm/graalvm-demos
2929
```
3030
```bash
31-
cd graalvm-demos/native-image-configure-examples
31+
cd graalvm-demos/archive/class-initialization-examples
3232
```
3333

3434
## Build and Run Examples
3535

3636
1. Change to one of the demo subdirectories, for example, `configure-at-runtime-example`:
3737
```bash
38-
cd graalvm-demos/native-image-configure-examples/configure-at-runtime-example
38+
cd configure-at-runtime-example
3939
```
4040
2. Build the project:
4141
```bash
4242
mvn package
4343
```
44-
3. Once the Maven build succeeds, a native executable called "runtime-example" will be generated in the `configure-at-runtime-example/target/` directory. Run it:
44+
3. Once the Maven build succeeds, a native executable called "runtime-example" will be generated in the _configure-at-runtime-example/target/_ directory. Run it:
4545
```bash
4646
./target/runtime-example
4747
```
@@ -63,7 +63,4 @@ In both examples we use the Jackson framework to parse a JSON file to determine
6363

6464
Loading application configuration at executable build time can speed up application startup.
6565

66-
### Related Documentation
67-
68-
- [Build-Time Initialization](https://www.graalvm.org/latest/reference-manual/native-image/optimizations-and-performance/ClassInitialization/)
69-
- [Initialize Once, Start Fast: Application Initialization at Build Time](http://www.christianwimmer.at/Publications/Wimmer19a/Wimmer19a.pdf)
66+
Learn more about [Class Initialization in Native Image](https://www.graalvm.org/latest/reference-manual/native-image/optimizations-and-performance/ClassInitialization/) at the website, and from the blog post [Understanding Class Initialization in GraalVM Native Image Generation](https://medium.com/graalvm/understanding-class-initialization-in-graalvm-native-image-generation-d765b7e4d6ed).

native-image-configure-examples/configure-at-buildtime-example/pom.xml renamed to archive/class-initialization-examples/configure-at-buildtime-example/pom.xml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
<properties>
1212
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
13-
<native.maven.plugin.version>0.10.2</native.maven.plugin.version>
13+
<native.maven.plugin.version>0.10.4</native.maven.plugin.version>
1414
<jackson.version>2.16.0</jackson.version>
1515
</properties>
1616

@@ -83,9 +83,6 @@
8383
<configuration>
8484
<skip>false</skip>
8585
<imageName>buildtime-example</imageName>
86-
<buildArgs>
87-
--no-fallback
88-
</buildArgs>
8986
</configuration>
9087
</plugin>
9188
</plugins>

native-image-configure-examples/configure-at-runtime-example/pom.xml renamed to archive/class-initialization-examples/configure-at-runtime-example/pom.xml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
<properties>
1212
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
13-
<native.maven.plugin.version>0.10.2</native.maven.plugin.version>
13+
<native.maven.plugin.version>0.10.4</native.maven.plugin.version>
1414
<jackson.version>2.16.0</jackson.version>
1515
</properties>
1616

@@ -83,9 +83,6 @@
8383
</executions>
8484
<configuration>
8585
<imageName>runtime-example</imageName>
86-
<buildArgs>
87-
--no-fallback
88-
</buildArgs>
8986
</configuration>
9087
</plugin>
9188
</plugins>

0 commit comments

Comments
 (0)