-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* init for graalvm workshops * init for graalvm workshops * init for graalvm workshops
- Loading branch information
1 parent
571b0ff
commit ff89709
Showing
2 changed files
with
160 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
# Develop with Oracle Database 23ai and GraalVM using Helidon | ||
|
||
## Introduction | ||
|
||
This lab walks you through the steps to develop with Oracle Database 23ai and GraalVM using Helidon. | ||
|
||
Estimated Time: 30 minutes | ||
|
||
### Objectives | ||
|
||
In this lab, you will: | ||
- Develop with Oracle Database 23ai and GraalVM using Helidon | ||
|
||
|
||
### Prerequisites | ||
|
||
This lab assumes you have: | ||
- Provisioned environment with Git and Maven (Cloud Shell). | ||
|
||
|
||
## Task 1: Clone the repos | ||
|
||
1. Clone the following repos: | ||
|
||
``` | ||
<copy> | ||
git clone | ||
</copy> | ||
``` | ||
## Task 2: Build and run | ||
1. To ensure that the sample application is configured to talk to the | ||
Oracle ATP database running in OCI, verify that the | ||
following lines (among others) are set to correct values in | ||
`src/main/resources/META-INF/microprofile-config.properties`: | ||
```properties | ||
javax.sql.DataSource.example.connectionFactoryClassName=oracle.jdbc.pool.OracleDataSource | ||
javax.sql.DataSource.example.URL=jdbc:oracle:thin:@<tnsServiceName>?TNS_ADMIN=/path/to/wallet | ||
javax.sql.DataSource.example.user=<user> | ||
javax.sql.DataSource.example.password=<password> | ||
``` | ||
|
||
|
||
2. Build and run | ||
|
||
``` | ||
<copy> | ||
mvn package ; java -jar target/com-oracle-helidon-datasource.jar | ||
</copy> | ||
``` | ||
``` | ||
<copy> | ||
curl http://localhost:8080/tables | ||
</copy> | ||
``` | ||
3. Build and run native image | ||
``` | ||
<copy> | ||
mvn -Pnative-image install -DskipTests | ||
</copy> | ||
``` | ||
``` | ||
<copy> | ||
./com-oracle-helidon-datasource | ||
</copy> | ||
``` | ||
``` | ||
<copy> | ||
curl http://localhost:8080/tables | ||
</copy> | ||
``` | ||
## Acknowledgements | ||
* **Author** - Paul Parkinson, Architect and Developer Advocate; Arjav Desai, Helidon Developer | ||
* **Last Updated By/Date** - Paul Parkinson, 2024 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
# Develop with Oracle Database 23ai and GraalVM using Micronaut | ||
|
||
## Introduction | ||
|
||
This lab walks you through the steps to develop with Oracle Database 23ai and GraalVM using Spring Boot | ||
Estimated Time: 30 minutes | ||
|
||
### Objectives | ||
|
||
In this lab, you will: | ||
- Develop with Oracle Database 23ai and GraalVM using Spring Boot | ||
|
||
### Prerequisites | ||
|
||
This lab assumes you have: | ||
- Provisioned environment with Git and Maven (Cloud Shell). | ||
|
||
|
||
## Task 1: Clone the repos | ||
|
||
1. Clone the following repos: | ||
|
||
``` | ||
<copy> | ||
git clone https://github.com/juarezjuniorgithub/jdbc-driver-graalvm-nativeimage.git | ||
</copy> | ||
``` | ||
## Task 2: Build and run | ||
1. To ensure that the sample application is configured to talk to the | ||
Oracle ATP database running in OCI, verify that the | ||
following lines (among others) are set to correct values in | ||
`src/main/resources/META-INF/microprofile-config.properties`: | ||
```properties | ||
javax.sql.DataSource.example.connectionFactoryClassName=oracle.jdbc.pool.OracleDataSource | ||
javax.sql.DataSource.example.URL=jdbc:oracle:thin:@<tnsServiceName>?TNS_ADMIN=/path/to/wallet | ||
javax.sql.DataSource.example.user=<user> | ||
javax.sql.DataSource.example.password=<password> | ||
``` | ||
|
||
|
||
2. Build and run | ||
|
||
``` | ||
<copy> | ||
mvn clean package exec:java -Dexec.mainClass="com.oracle.jdbc.graalvm.App" | ||
</copy> | ||
``` | ||
3. Build and run native image | ||
``` | ||
<copy> | ||
mvn -Pnative packagemvn -Pnative package | ||
</copy> | ||
``` | ||
``` | ||
<copy> | ||
target/jdbc-driver-graalvm-nativeimage | ||
</copy> | ||
``` | ||
## Acknowledgements | ||
* **Author** - Paul Parkinson, Architect and Developer Advocate; Juarez Barbosa, Sr. Principal Java Developer Evangelist, Java Database Access | ||
* **Last Updated By/Date** - Paul Parkinson, 2024 |