java-sdk
Runtime module for the Java SDK
Installation
dagger install github.com/eunomie/dagger/sdk/java@a8abc51fbdcc23ff9d45b5d84078fe61656bd0f3Entrypoint
Return Type
JavaSdk !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| sdkSourceDir | Directory | - | Directory with the Java SDK source code. dagger-java-samples is not necessary to build, but as it's referenced in the root pom.xml maven will check if it's there. So we keep the pom.xml to fake it. |
Example
dagger -m github.com/eunomie/dagger/sdk/java@a8abc51fbdcc23ff9d45b5d84078fe61656bd0f3 call \
func (m *MyModule) Example() *dagger.JavaSdk {
return dag.
Javasdk()
}@function
def example() -> dagger.JavaSdk:
return (
dag.java_sdk()
)@func()
example(): JavaSdk {
return dag
.javaSdk()
}Types
JavaSdk 🔗
sdksourceDir() 🔗
Return Type
Directory ! Example
dagger -m github.com/eunomie/dagger/sdk/java@a8abc51fbdcc23ff9d45b5d84078fe61656bd0f3 call \
sdksource-dirfunc (m *MyModule) Example() *dagger.Directory {
return dag.
Javasdk().
Sdksourcedir()
}@function
def example() -> dagger.Directory:
return (
dag.java_sdk()
.sdksourcedir()
)@func()
example(): Directory {
return dag
.javaSdk()
.sdksourceDir()
}mavenErrors() 🔗
If true, -e flag will be added to the maven command to display execution error messages
Return Type
Boolean ! Example
dagger -m github.com/eunomie/dagger/sdk/java@a8abc51fbdcc23ff9d45b5d84078fe61656bd0f3 call \
maven-errorsfunc (m *MyModule) Example(ctx context.Context) bool {
return dag.
Javasdk().
Mavenerrors(ctx)
}@function
async def example() -> bool:
return await (
dag.java_sdk()
.mavenerrors()
)@func()
async example(): Promise<boolean> {
return dag
.javaSdk()
.mavenErrors()
}mavenDebugLogging() 🔗
If true, -X flag will be added to the maven command to enable full debug logging
Return Type
Boolean ! Example
dagger -m github.com/eunomie/dagger/sdk/java@a8abc51fbdcc23ff9d45b5d84078fe61656bd0f3 call \
maven-debug-loggingfunc (m *MyModule) Example(ctx context.Context) bool {
return dag.
Javasdk().
Mavendebuglogging(ctx)
}@function
async def example() -> bool:
return await (
dag.java_sdk()
.mavendebuglogging()
)@func()
async example(): Promise<boolean> {
return dag
.javaSdk()
.mavenDebugLogging()
}codegen() 🔗
Return Type
GeneratedCode !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| modSource | ModuleSource ! | - | No description provided |
| introspectionJson | File ! | - | No description provided |
Example
echo 'Custom types are not supported in shell examples'func (m *MyModule) Example(modSource *dagger.ModuleSource, introspectionJson *dagger.File) *dagger.GeneratedCode {
return dag.
Javasdk().
Codegen(modSource, introspectionJson)
}@function
def example(modsource: dagger.ModuleSource, introspectionjson: dagger.File) -> dagger.GeneratedCode:
return (
dag.java_sdk()
.codegen(modsource, introspectionjson)
)@func()
example(modSource: ModuleSource, introspectionJson: File): GeneratedCode {
return dag
.javaSdk()
.codegen(modSource, introspectionJson)
}javaImage() 🔗
Return Type
Container ! Example
dagger -m github.com/eunomie/dagger/sdk/java@a8abc51fbdcc23ff9d45b5d84078fe61656bd0f3 call \
java-imagefunc (m *MyModule) Example() *dagger.Container {
return dag.
Javasdk().
Javaimage()
}@function
def example() -> dagger.Container:
return (
dag.java_sdk()
.javaimage()
)@func()
example(): Container {
return dag
.javaSdk()
.javaImage()
}mavenImage() 🔗
Return Type
Container ! Example
dagger -m github.com/eunomie/dagger/sdk/java@a8abc51fbdcc23ff9d45b5d84078fe61656bd0f3 call \
maven-imagefunc (m *MyModule) Example() *dagger.Container {
return dag.
Javasdk().
Mavenimage()
}@function
def example() -> dagger.Container:
return (
dag.java_sdk()
.mavenimage()
)@func()
example(): Container {
return dag
.javaSdk()
.mavenImage()
}moduleRuntime() 🔗
Return Type
Container !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| modSource | ModuleSource ! | - | No description provided |
| introspectionJson | File ! | - | No description provided |
Example
echo 'Custom types are not supported in shell examples'func (m *MyModule) Example(modSource *dagger.ModuleSource, introspectionJson *dagger.File) *dagger.Container {
return dag.
Javasdk().
Moduleruntime(modSource, introspectionJson)
}@function
def example(modsource: dagger.ModuleSource, introspectionjson: dagger.File) -> dagger.Container:
return (
dag.java_sdk()
.moduleruntime(modsource, introspectionjson)
)@func()
example(modSource: ModuleSource, introspectionJson: File): Container {
return dag
.javaSdk()
.moduleRuntime(modSource, introspectionJson)
}withConfig() 🔗
Return Type
JavaSdk !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| mavenErrors | Boolean ! | false | No description provided |
| mavenDebugLogging | Boolean ! | false | No description provided |
Example
dagger -m github.com/eunomie/dagger/sdk/java@a8abc51fbdcc23ff9d45b5d84078fe61656bd0f3 call \
with-config --maven-errors boolean --maven-debug-logging booleanfunc (m *MyModule) Example(mavenErrors bool, mavenDebugLogging bool) *dagger.JavaSdk {
return dag.
Javasdk().
Withconfig(mavenErrors, mavenDebugLogging)
}@function
def example(mavenerrors: bool, mavendebuglogging: bool) -> dagger.JavaSdk:
return (
dag.java_sdk()
.withconfig(mavenerrors, mavendebuglogging)
)@func()
example(mavenErrors: boolean, mavenDebugLogging: boolean): JavaSdk {
return dag
.javaSdk()
.withConfig(mavenErrors, mavenDebugLogging)
}