forked from InseeFr/Trevas
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request InseeFr#295 from InseeFr/feature/docs
Feature/docs
- Loading branch information
Showing
28 changed files
with
589 additions
and
354 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
6 changes: 3 additions & 3 deletions
6
docs/blog/2023-09-01-trevas-1.1.0.mdx → ...log/2023-09-01-trevas-check_hierarchy.mdx
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
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,40 @@ | ||
--- | ||
slug: /trevas-java-17 | ||
title: Trevas - Java 17 | ||
authors: [nicolas] | ||
tags: [Trevas] | ||
--- | ||
|
||
### News | ||
|
||
Trevas 1.2.0 enables Java 17 support. | ||
|
||
### Java modules handling | ||
|
||
Spark does not support Java modules. | ||
|
||
Java 17 client apps, embedding Trevas in Spark mode have to configure `UNNAMED` modules for Spark. | ||
|
||
#### Maven | ||
|
||
Add to your `pom.xml` file, in the `build > plugins` section: | ||
|
||
```xml | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-compiler-plugin</artifactId> | ||
<version>3.11.0</version> | ||
<configuration> | ||
<compilerArgs> | ||
<arg>--add-exports</arg> | ||
<arg>java.base/sun.nio.ch=ALL-UNNAMED</arg> | ||
</compilerArgs> | ||
</configuration> | ||
</plugin> | ||
``` | ||
|
||
#### Docker | ||
|
||
```shell | ||
ENTRYPOINT ["java", "--add-exports", "java.base/sun.nio.ch=ALL-UNNAMED", "mainClass"] | ||
``` |
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,31 @@ | ||
--- | ||
slug: /trevas-persistent-assignments | ||
title: Trevas - Persistent assignments | ||
authors: [nicolas] | ||
tags: [Trevas] | ||
--- | ||
|
||
### News | ||
|
||
Trevas 1.2.0 includes the persistent assignment support: `ds1 <- ds;`. | ||
|
||
In Trevas, persistent datasets are represented as `PersistentDataset`. | ||
|
||
### Handle `PersistentDataset` | ||
|
||
Trevas datasets are represented as `Dataset`. | ||
|
||
After running the Trevas engine, you can use persistent datasets with something like: | ||
|
||
``` | ||
Bindings engineBindings = engine.getContext().getBindings(ScriptContext.ENGINE_SCOPE); | ||
engineBindings.forEach((k, v) -> { | ||
if (v instanceof PersistentDataset) { | ||
fr.insee.vtl.model.Dataset ds = ((PersistentDataset) v).getDelegate(); | ||
if (ds instanceof SparkDataset) { | ||
Dataset<Row> sparkDs = ((SparkDataset) ds).getSparkDataset(); | ||
// Do what you want with sparkDs | ||
} | ||
} | ||
}); | ||
``` |
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
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
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
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
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
6 changes: 3 additions & 3 deletions
6
...-content-blog/2023-09-01-trevas-1.1.0.mdx → ...log/2023-09-01-trevas-check_hierarchy.mdx
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
40 changes: 40 additions & 0 deletions
40
docs/i18n/fr/docusaurus-plugin-content-blog/2023-11-22-trevas-java-17.mdx
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,40 @@ | ||
--- | ||
slug: /trevas-java-17 | ||
title: Trevas - Java 17 | ||
authors: [nicolas] | ||
tags: [Trevas] | ||
--- | ||
|
||
### Nouveautés | ||
|
||
Trevas 1.2.0 permet le support de Java 17. | ||
|
||
### Gestion des modules Java | ||
|
||
Spark ne supporte pas les modules Java. | ||
|
||
Les applications clientes en Java 17 embarquant Trevas doivent configurer les `UNNAMED` modules pour Spark. | ||
|
||
#### Maven | ||
|
||
Ajouter à votre fichier `pom.xml`, dans la section `build > plugins` : | ||
|
||
```xml | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-compiler-plugin</artifactId> | ||
<version>3.11.0</version> | ||
<configuration> | ||
<compilerArgs> | ||
<arg>--add-exports</arg> | ||
<arg>java.base/sun.nio.ch=ALL-UNNAMED</arg> | ||
</compilerArgs> | ||
</configuration> | ||
</plugin> | ||
``` | ||
|
||
#### Docker | ||
|
||
```shell | ||
ENTRYPOINT ["java", "--add-exports", "java.base/sun.nio.ch=ALL-UNNAMED", "mainClass"] | ||
``` |
31 changes: 31 additions & 0 deletions
31
...n/fr/docusaurus-plugin-content-blog/2023-11-22-trevas-persistent-assignment.mdx
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,31 @@ | ||
--- | ||
slug: /trevas-persistent-assignment | ||
title: Trevas - Assignements persistants | ||
authors: [nicolas] | ||
tags: [Trevas] | ||
--- | ||
|
||
### Nouveautés | ||
|
||
Trevas 1.2.0 inclut le support des assignements persistants : `ds1 <- ds;`. | ||
|
||
Dans Trevas, les datatsets persistants sont représentés par `PersistentDataset`. | ||
|
||
### Gérer `PersistentDataset` | ||
|
||
Les datasets Trevas sont représentés par `Dataset`. | ||
|
||
Après avoir executé le moteur Trevas, vous pouvez utiliser les datasets persistants comme suit : | ||
|
||
``` | ||
Bindings engineBindings = engine.getContext().getBindings(ScriptContext.ENGINE_SCOPE); | ||
engineBindings.forEach((k, v) -> { | ||
if (v instanceof PersistentDataset) { | ||
fr.insee.vtl.model.Dataset ds = ((PersistentDataset) v).getDelegate(); | ||
if (ds instanceof SparkDataset) { | ||
Dataset<Row> sparkDs = ((SparkDataset) ds).getSparkDataset(); | ||
// Do what you want with sparkDs | ||
} | ||
} | ||
}); | ||
``` |
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
Oops, something went wrong.