Skip to content

Commit a632309

Browse files
author
Dennis Labordus
committed
Removed building native runner, because of issues. Now default Java Application.
Signed-off-by: Dennis Labordus <[email protected]>
1 parent c3a011e commit a632309

File tree

5 files changed

+13
-49
lines changed

5 files changed

+13
-49
lines changed

.github/workflows/build-project.yml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,5 @@ jobs:
5050
with:
5151
output_file: custom_maven_settings.xml
5252
servers: '[{ "id": "github-packages-compas", "username": "OWNER", "password": "${{ secrets.GITHUB_TOKEN }}" }]'
53-
- name: Build Native with Maven
54-
if: ${{ github.event_name == 'pull_request' }}
55-
run: ./mvnw -s custom_maven_settings.xml -B -Pnative clean verify
5653
- name: Build with Maven
57-
if: ${{ github.event_name == 'push' }}
5854
run: ./mvnw -s custom_maven_settings.xml -B clean verify

.github/workflows/release-project.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,6 @@ jobs:
5959
env:
6060
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
6161
- name: Deploy with Maven to GitHub Packages and Docker Hub
62-
run: ./mvnw -B -s custom_maven_settings.xml -Prelease,native clean deploy
62+
run: ./mvnw -B -s custom_maven_settings.xml -Prelease clean deploy
6363
env:
6464
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

DEVELOPMENT.md

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -76,22 +76,3 @@ If you want to build an _über-jar_, execute the following command:
7676

7777
The application is now runnable using `java -jar app/target/quarkus-app/quarkus-run.jar`.
7878

79-
## Creating a native executable
80-
81-
You can create a native executable using:
82-
83-
```shell script
84-
./mvnw package -Pnative
85-
```
86-
87-
Or, if you don't have GraalVM installed, you can run the native executable build in a container using:
88-
89-
```shell script
90-
./mvnw package -Pnative -Dquarkus.native.container-build=true
91-
```
92-
93-
You can then execute your native executable with: `./app/target/code-with-quarkus-local-SNAPSHOT-runner`
94-
95-
If you want to learn more about building native executables, please consult https://quarkus.io/guides/maven-tooling.html
96-
.
97-

app/src/main/resources/application.properties

Lines changed: 2 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -9,20 +9,8 @@ quarkus.http.cors = false
99
quarkus.http.root-path = /compas-scl-validator/
1010
quarkus.http.limits.max-body-size = 150M
1111

12-
quarkus.log.level = DEBUG
13-
#quarkus.log.level = INFO
14-
quarkus.log.category."org.lfenergy.compas.scl.validator".level = DEBUG
15-
#quarkus.log.category."org.lfenergy.compas.scl.validator".level = INFO
16-
17-
# Add scanning these dependencies for scanning, also used by native compilation.
18-
quarkus.index-dependency.scl2007b4.group-id=org.lfenergy.compas.core
19-
quarkus.index-dependency.scl2007b4.artifact-id=commons
20-
21-
quarkus.index-dependency.jaxb-api.group-id=org.jboss.spec.javax.xml.bind
22-
quarkus.index-dependency.jaxb-api.artifact-id=jboss-jaxb-api_2.3_spec
23-
24-
# Settings needed for native compilation of the project.
25-
quarkus.native.resources.includes=ocl/*.*
12+
quarkus.log.level = INFO
13+
quarkus.log.category."org.lfenergy.compas.scl.validator".level = INFO
2614

2715
# Dev Profile overrides.
2816
%dev.compas.validator.ocl.custom.directory = ./src/test/data/ocl

riseclipse/validator-riseclipse/src/main/java/org/lfenergy/compas/scl/validator/impl/SclRiseClipseValidator.java

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -60,25 +60,24 @@ public List<ValidationError> validate(SclFileType type, String sclData) {
6060
OclFileLoader oclFileLoader = new OclFileLoader(ocl, tempDirectory);
6161
try {
6262
// Load all the OCL Files, adding them to the OCL Instance.
63-
if (!oclFiles.isEmpty()) {
64-
oclFiles.stream()
65-
.filter(uri -> OclFileUtil.includeOnType(uri, type))
66-
.forEach(oclFileLoader::addOCLDocument);
67-
}
63+
LOGGER.info("Loading OCL Files for type '{}'.", type);
64+
oclFiles.stream()
65+
.filter(uri -> OclFileUtil.includeOnType(uri, type))
66+
.forEach(oclFileLoader::addOCLDocument);
6867

6968
// Create the validator and prepare it with the OCL Files.
7069
var validator = ComposedEValidator.install(SclPackage.eINSTANCE);
7170
oclFileLoader.prepareValidator(validator);
7271

7372
// Load the SCL File as Resource ready to be processed.
73+
LOGGER.info("Loading SCL Data for type '{}'.", type);
7474
var sclLoader = new SclModelLoader(ocl);
7575
var resource = sclLoader.load(sclData);
76-
if (resource != null) {
77-
LOGGER.info("Validating SCL Data for type '{}'.", type);
78-
var diagnostician = new CompasDiagnostician();
79-
var diagnostic = diagnostician.validate(resource);
80-
processDiagnostic(diagnostic, validationErrors);
81-
}
76+
77+
LOGGER.info("Validating SCL Data for type '{}'.", type);
78+
var diagnostician = new CompasDiagnostician();
79+
var diagnostic = diagnostician.validate(resource);
80+
processDiagnostic(diagnostic, validationErrors);
8281
} finally {
8382
oclFileLoader.cleanup();
8483
}

0 commit comments

Comments
 (0)