forked from dagger/dagger
-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix -XX:UseSVE=0 for non ARM JVM #2
Open
jcsirot
wants to merge
16
commits into
lgtdio:javasdk-modularize
Choose a base branch
from
jcsirot:javasdk-modularize-fix-jvm-option
base: javasdk-modularize
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Fix -XX:UseSVE=0 for non ARM JVM #2
jcsirot
wants to merge
16
commits into
lgtdio:javasdk-modularize
from
jcsirot:javasdk-modularize-fix-jvm-option
Conversation
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
… skeleton This annotation processor will collect type info into a file in order to register objects and functions when the module is called. Signed-off-by: Jean-Christophe Sirot <jcsirot@gmail.com>
Only in case `description` field of the annotation is not set. That way it's still possible to override it, specifically for Dagger, but on the other hand it's now possible to only use Java features and not provide fields so there's no duplication. Before: @ModuleFunction(value="echo", description="Returns a contain...") public Container containerEcho(String stringArg) { After: /// Returns a container that echoes... @ModuleFunction public Container echo(String stringArg) { Signed-off-by: Yves Brissaud <gh@lgtd.io>
Rename annotation classes so they are simpler: Module, Object, Function. As close as possible to the Dagger wording. I also moved the info objects (the ones used to generate the json file) to the dagger-java-sdk part so they can also be used to read the json file. Almost created the registry part of the entrypoint: it creates the right dagger module structure, but now it needs to create the right JSON output. This entrypoint can be used as the entrypoint of a module. It's intended to be generic (based on the json file for now, maybe on the annotation in the future). So the module side only needs to declare the mainClass to io.dagger.module.Entrypoint For instance by adding this to the pom.xml: <dependencies> <dependency> <groupId>io.dagger</groupId> <artifactId>dagger-java-sdk</artifactId> <version>1.0.0-SNAPSHOT</version> </dependency> <dependency> <groupId>io.dagger</groupId> <artifactId>dagger-java-annotation-processor</artifactId> <version>1.0.0-SNAPSHOT</version> <scope>provided</scope> </dependency> </dependencies> <build> <pluginManagement> <plugin> <artifactId>maven-compiler-plugin</artifactId> <version>3.13.0</version> <configuration> <verbose>false</verbose> <annotationProcessorPaths> <path> <groupId>io.dagger</groupId> <artifactId>dagger-java-annotation-processor</artifactId> <version>1.0.0-SNAPSHOT</version> </path> </annotationProcessorPaths> <annotationProcessors> <annotationProcessor>io.dagger.annotation.processor.DaggerModuleAnnotationProcessor</annotationProcessor> </annotationProcessors> </configuration> </plugin> </pluginManagement> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-shade-plugin</artifactId> <version>3.5.0</version> <executions> <execution> <phase>package</phase> <goals> <goal>shade</goal> </goals> <configuration> <transformers> <transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer"> <mainClass>io.dagger.module.Entrypoint</mainClass> </transformer> </transformers> </configuration> </execution> </executions> </plugin> </plugins> </build> This should be good to create a jar with all the dependencies: ./mvnw clean package This includes the management of the annotations. And then the generated jar declares the right entrypoint, so this should be good to run with: dagger run java -jar dagger-module.jar This will not completely work as the module part is not done, so the dagger engine doesn't know about the module and so the registration can't be done. But that's a different story. The goal here was to be able to: - document with annotations - create a first basic entrypoint - declare as much as possible in the SDK so it's easy to integrate Signed-off-by: Yves Brissaud <gh@lgtd.io>
This is a very simple one, just provided so that modules don't have define the `dag` field. In some way this is just to enforce some conventions. Signed-off-by: Yves Brissaud <gh@lgtd.io>
Signed-off-by: Yves Brissaud <gh@lgtd.io>
I'm using gson, but I'll have a second look to avoid it and keep dependencies minimal. But for now it solves the issue. Signed-off-by: Yves Brissaud <gh@lgtd.io>
Signed-off-by: Yves Brissaud <gh@lgtd.io>
start dealing with types, but needs more work to ensure everything is compatible Signed-off-by: Yves Brissaud <gh@lgtd.io>
make the Scalar.convert method public to be able to convert to JSON. Not sure that's the best way, but at least for now it unblocks it. Signed-off-by: Yves Brissaud <gh@lgtd.io>
Signed-off-by: Yves Brissaud <gh@lgtd.io>
As of 2020-10-10, Square's JavaPoet project is deprecated Signed-off-by: Yves Brissaud <gh@lgtd.io>
Signed-off-by: Yves Brissaud <gh@lgtd.io>
Signed-off-by: Yves Brissaud <gh@lgtd.io>
add comments, clean build and final image Signed-off-by: Yves Brissaud <gh@lgtd.io>
Signed-off-by: Yves Brissaud <gh@lgtd.io>
Signed-off-by: Jean-Christophe Sirot <jcsirot@gmail.com>
eunomie
force-pushed
the
javasdk-modularize
branch
7 times, most recently
from
January 24, 2025 21:42
19eaedb
to
b996ee1
Compare
eunomie
force-pushed
the
javasdk-modularize
branch
5 times, most recently
from
January 31, 2025 10:43
f4a5149
to
d75a52f
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The JVM option
-XX:UseSVE=0
does not seem to exist for x64 JVM which prevents the JVM to start