Skip to content

elide.pkl reference

Every block and field of Elide's elide.pkl project manifest: metadata, sources, dependencies, JVM, Kotlin, JavaScript, artifacts, testing and workspaces.

On this page

elide.pkl is the project manifest: it declares builds, dependencies, tests and artifacts. Every file starts with:

pkl
amends "elide:project.pkl"
utf-8 · pkl · Lines: 1

elide: resolves to the schema bundled with the running Elide, for this and every other module (elide:Jvm.pkl). To pin a schema version, amend the published URL: pkl.elide.dev/1.6.3/project.pkl.

Schema versions are independent of the Elide runtime version. A development schema can be locked before it is published; the URL above stays on a published version. Published development versions follow main until their stable release, after which they are immutable.

Patch releases within a MAJOR.MINOR line only add properties. A minor release can remove, rename or retype properties and change defaults.

Pinned versionResult
Older than the bundled schemaUses that version; a property removed since fails, naming the version.
Newer than the bundled schemaAllowed; a property the running Elide lacks fails, naming the upgrade.
Another major versionRefused.

elide project export prints the evaluated manifest as JSON; elide build --inspect lists its tasks.

Project metadata

PropertyPurpose
name, version, descriptionProject identity; version also names application archives.
entrypointFile(s) elide run uses when given none.
scriptsNamed shell commands for elide run NAME.
sourcesSource sets; see Sources.
dependenciesMaven, npm and PyPI packages; see Dependencies.
jvm, kotlin, javascriptLanguage and compiler settings.
nativeImageAccepted and not applied; set each artifact’s options.
engineServing contexts; see Engine contexts.
toolchainAccepted Elide versions; see Toolchain.
devSource info, MCP, dev server; see Dev.
webWeb asset settings; see Web.
artifactsBuild outputs; see Artifacts.
testingTest reports; see Testing.
coverageCoverage; see Testing › Coverage.
workspaceMember projects; see Workspaces.

build.flags holds the -f/--flag values; see Build Flags.

Engine contexts

pkl
engine {
  topology = "prespawn"
  contexts { spawn = "auto"; reserve = 2; min = 1; max = 16 }
}
utf-8 · pkl · Lines: 4
PropertyMeaningDefault
topology"prespawn", the only value."prespawn"
contexts.spawnContext count: a positive integer, or "auto" (physical cores minus reserve, clamped).1
contexts.reserveCores subtracted for "auto"; does not pin CPUs.2
contexts.min, contexts.maxBounds for any count.1, none
maxContextsDeprecated fixed count; cannot combine with contexts.—

Each context evaluates the entry module once, with its own globals, before the server is ready. --contexts=N|auto on run, serve and dev overrides spawn. More than one context requires Linux.

OpenTelemetry block

pkl
opentelemetry {
  service { name = "checkout"; version = "1.4.2"; environment = "production" }
  resource { ["cloud.region"] = "us-east-1" }

  destinations {
    ["collector"] { endpoint = "http://localhost:4317"; protocol = "grpc" }
    ["datadog"] { provider = "datadog"; site = "us5" }
    ["sentry"] { provider = "sentry" }
  }

  traces { sampler = "parentbased_traceidratio"; ratio = 0.25 }
  metrics { interval = 30.s }
  logs { level = "info" }
  runtime { logs = "warn" }
}
utf-8 · pkl · Lines: 15

Telemetry is off until a destination exists here, in OTEL_*/ELIDE_OTEL_* variables, or in --otel-* flags. Those override this block, flags first; see Runtime Environment Variables. elide run, elide serve, elide test, elide build and elide install in a project read this block; elide run file.js inside a project reads it when elide.pkl contains the word opentelemetry. See Configuration. Credentials are never written here: name the environment variable that holds them.

PropertyMeaningDefault
enabledfalse turns telemetry off, whatever the environment says.—
service.name, .version, .namespace, .environmentservice.* and deployment.environment.name resource attributes.unknown_service:elide
resourceExtra resource attributes.—
destinationsNamed places to send telemetry.none
traces.enabled, .sampler, .ratio, .propagatorsApplication spans. Samplers as OTEL_TRACES_SAMPLER.on, parentbased_always_on, tracecontext + baggage
metrics.enabled, .interval, .temporalityApplication metrics.on, 60.s, cumulative
logs.enabled, .level, .consoleApplication logs; console exports console.*, Python logging and similar output.on, info, on
profiles.enabled, .frequencyGuest CPU profiles (experimental).off, 100 per second
runtime.traces, .metrics, .logsElide’s own spans, metrics, and log threshold.on, on, warn
propagation.baggageW3C baggage on Elide’s HTTP server and clients; see Baggage.off
shutdownTimeoutFinal export deadline at exit.5.s

Each destination:

PropertyMeaningDefault
providerotlp, sentry, datadog, posthog, honeycomb, or grafana.otlp
endpointBase URL; replaces a provider’s host. /v1/<signal> is appended for HTTP.http://localhost:4318 (4317 for gRPC)
protocolgrpc, http/protobuf, or http/json.http/protobuf
headers, headerEnvLiteral headers, and headers read from named variables.—
credentialVariable holding the provider’s key: DD_API_KEY, POSTHOG_PROJECT_TOKEN, HONEYCOMB_API_KEY, GRAFANA_CLOUD_OTLP_CREDENTIAL.as listed
dsnVariable holding a Sentry DSN.SENTRY_DSN
siteDatadog site: us1, us3, us5, eu, ap1, ap2, gov, or a domain.DD_SITE, then us1
regionus/eu (PostHog, Honeycomb), or a Grafana Cloud zone such as prod-us-east-0.us
signalstraces, metrics, logs, profiles.what the provider accepts
compression, timeoutRequest compression and deadline.gzip, 10.s
perSignalPer-signal endpoint, protocol, headers, headerEnv, compression, timeout.—
ProviderSignals sent by defaultAlso acceptedProtocols
otlptraces, metrics, logsprofilesall
sentrytraces, logs—http/protobuf
datadogmetrics (delta), logstraces (agentless intake preview)http/protobuf; http/json except logs
posthoglogstraceshttp/protobuf
honeycombtraces, metrics, logs—all
grafanatraces, metrics, logs—http/protobuf

Errors are sent as exception log records and span events, plus the elide.errors metric, so every provider that accepts logs, traces, or metrics receives them. See OpenTelemetry for usage and Providers for each provider. Asking a provider for a signal or protocol it does not accept is an error.

Baggage

Elide’s HTTP server and clients propagate traceparent and tracestate. They pass W3C baggage only when you turn a direction on, because baggage arriving from a client is untrusted input:

pkl
opentelemetry {
  propagation {
    baggage {
      inbound = true
      outbound = true
      allow { "tenant"; "region" }
      spanAttributes { "tenant" }
    }
  }
}
utf-8 · pkl · Lines: 10
PropertyMeaningDefault
inboundServed requests’ baggage headers become the handler’s baggage.false
outboundOutgoing fetch and HTTP client requests carry the current baggage, unless the request sets baggage itself.false
allowKeys allowed in both directions.all keys
spanAttributesInbound keys recorded on the server span as baggage.<key>; each must be in allow.none

A header over 8,192 bytes or 180 members, or with any malformed member, is dropped whole. Baggage received from a client reaches outgoing requests only when both directions are on. Application code can always read, set and send baggage through the OpenTelemetry API; OTEL_PROPAGATORS affects only that API.

Sources

pkl
sources {
  ["main"] = "lib/**/*.kt"
  ["integrationTest"] {
    type = "test"
    dependsOn { "main" }
    paths { "it/**/*.kt" }
    resources { "it/fixtures"; new { from = "it/config"; into = "META-INF" } }
  }
}
utf-8 · pkl · Lines: 9
PropertyMeaningEmpty or absent
type"source", "test", "example" or "other".Inferred from the name.
pathsGlobs or directories.src/<name>/<language>.
resourcesPaths, or new { from; into } roots.src/<name>/resources.
dependsOnSource sets visible to this one.Absent: test and example sets see main. Empty: nothing.

See Source Sets.

Dependencies

pkl
dependencies {
  maven {
    packages { "com.google.guava:guava:33.5.0-jre" }
    testPackages { "org.junit.jupiter:junit-jupiter:5.13.4" }
    substitutions { ["com.google.guava:guava"] = "libs/guava-patched.jar" }
  }
  npm { packages { "react@19.0.0" }; devPackages { "typescript@5.6.2" } }
  pypi { packages { "requests>=2" }; optionalPackages { ["dev"] { "pytest>=8" } } }
  spring { version = "4.0.0"; starter { "web" }; testStarter { "test" } }
}
utf-8 · pkl · Lines: 10
BlockProperties
mavenpackages, devPackages, modules, compileOnly, runtimeOnly, processors, testPackages, kotlinPlugins, exclusions, resolutions, substitutions, repositories, enableDefaultRepositories, localRepository
npmpackages, devPackages
pypipackages, optionalPackages (named groups); elide install does not install them.
springversion, starter, testStarter; expands into maven.
ValueForm
Maven entry"group:artifact:version[:classifier]", a MavenPackageSpec (group, name, version, classifier or coordinate), a local JAR path, or a project reference.
RepositoryA URL, or a spec with url, name, description, credentials (username, password, ntlmDomain, ntlmWorkstation).
resolutions keygroup:artifact; the value is an exact version overriding direct and transitive requests, without adding a dependency. See version resolutions.
substitutions keygroup:artifact (any version) or group:artifact:version; the value is a file path.

A substitution keeps the coordinate’s transitive dependencies and puts the file on every classpath in its place. Paths resolve against the declaring manifest; members inherit the root’s. Order the task that generates the file first. Buckets and repositories: Dependencies.

JVM

pkl
jvm {
  main = "example.Main"
  target = 25
  flags { "--add-opens=java.base/java.lang=ALL-UNNAMED" }
  defs { ["app.env"] = "dev" }
  java { release = 25; compiler { flags { "-Xlint:all" } } }
}
utf-8 · pkl · Lines: 7
PropertyMeaningDefault
mainEntrypoint class for elide run, JARs, applications and native images.—
targetBytecode target: 8 … 29, 1.8, "latest", "stable" or "auto"."auto" (21)
javaHomeJava home for external compiles and forked JVMs.Elide’s own
preferBaliExternal JVM runs launch bali from PATH instead of java, or warn and use java.false
features.testingJUnit dependencies on test sets.true
features.automodulesAutomatic modules for JARs without a descriptor.true
features.graalvmorg.graalvm SDK APIs on the compile classpath.false
java.source, java.releaseSource and --release levels; see Java Compiler."auto"
java.compiler.mode"embedded" or "external"."embedded"
java.compiler.flagsExtra javac flags.none
java.sourceSetsPer-source-set release and flags; see Java Compiler.none
java.bindingsNamed C-header binding groups for jextract; see below.none
java.sourceSets["<set>"].bindingsBinding-group names compiled into that source set.none
flagsJVM flags for elide run, the test JVM and start scripts.none
defsSystem properties (-D), applied wherever flags are.none
debugCompile with -g.true

C header bindings

In 1.6.2, declare native bindings under jvm.java.bindings and select them for the Java source set that owns their generated classes:

pkl
jvm {
  java {
    bindings {
      ["api"] {
        headers { "native/api.h" }
        packageName = "example.nativeapi"
        headerClassName = "NativeApi"
        includeDirs { "native/include" }
        libraries { "answer" }
      }
    }
    sourceSets {
      ["main"] { bindings { "api" } }
    }
  }
}
utf-8 · pkl · Lines: 16
Binding propertyContractDefault
headersHeader paths or globs; unmatched globs fail.required
packageNameJava package for generated bindings.required
headerClassNameGenerated header class name.required
includeDirsHeader search directories.empty
definesPreprocessor definitions, such as API_VERSION=1.empty
librariesShared-library specifications used by generated lookup code.empty
useSystemLoadLibraryUse system library loading for the declared libraries.false

Paths resolve against the owning project. A group has one owning source set; dependent sets use its classes through their normal dependencies. Declaring a group does not select it for compilation. These bindings require a distribution with native tools. See C header bindings for generation-only targets, exported sources, incremental inputs, and command-line selections, and jextract for native-library loading at runtime.

Kotlin

pkl
kotlin {
  apiLevel = "auto"
  languageLevel = "auto"
  compilerOptions { allWarningsAsErrors = true; optIn { "kotlin.time.ExperimentalTime" } }
  features { serialization = true; metro = false }
  toolchain = "embedded"
  plugins { ["org.jetbrains.kotlinx.serialization"] { ["mode"] = "json" } }
}
utf-8 · pkl · Lines: 8
PropertyMeaning
apiLevel, languageLevel"auto", "latest", "stable", or "2.2" … "2.5".
compilerOptionsoptIn, progressiveMode, extraWarnings, allWarningsAsErrors, suppressWarnings, verbose, freeCompilerArgs, apiVersion, languageVersion, includeRuntime, noStdlib, javaParameters, jvmTarget, noJdk, jvmTargetValidationMode, incremental
featurestesting, kotlinx, defaultPlugins, serialization, coroutines, atomicfu, powerAssert, metro, compose, reflection. compose defaults to false and requires an explicit Compose runtime dependency.
toolchain"embedded", new Kotlin.ManagedKotlinToolchain { version } or new Kotlin.CustomKotlinToolchain { path }.
pluginsOptions per compiler-plugin id, passed as -P plugin:<id>:<key>=<value>.

Defaults: Kotlin Compiler.

JavaScript

PropertyMeaningDefault
javascript.ecmaDeclared ECMAScript edition: a year 2015 … 2025, "stable" or "latest". elide project info shows it; it does not change which syntax runs or how code is built (JavaScript language)."stable"

Toolchain

pkl
toolchain { engines { ["elide"] = ">=1.6.0" } }
utf-8 · pkl · Lines: 1
PropertyMeaning
engines["elide"]Version or semver range, or new { version = "…" }; a running Elide outside it fails validation.
engines[<other>]Accepted, not enforced.

Dev

pkl
dev {
  source { platform = "github"; project = "example/app" }
  mcp {
    registerElide = true
    advice = true
    resources { new { path = "docs/ARCHITECTURE.md"; name = "architecture" } }
  }
}
utf-8 · pkl · Lines: 8
PropertyMeaningDefault
source.platform, source.project, source.subpathSource host: "github", "gitlab", "bitbucket", "git" or another name.—
mcp.registerElideRegister Elide as an MCP tool.true
mcp.adviceExpose elide project advice as an MCP resource.true
mcp.resourcesExtra MCP resources: path, name, description, mimeType (detected if omitted).none
server.host, server.portUnused by elide dev, which takes --host/--port (default 127.0.0.1:3000)."0.0.0.0", 8080

Web

PropertyMeaningDefault
web.css.minifyMinify built CSS.true
web.css.targetsBrowser targets: new { browser = "chrome"; version = "120" }.none
web.minifyHtmlMinify rendered HTML.true
web.browsersBrowser targets for all outputs; css.targets overrides it for CSS.none

See Web Toolchain.

Artifacts

pkl
import "elide:Jvm.pkl" as Jvm

artifacts {
  ["app"] = new Jvm.Jar {
    name = "app.jar"
    options { entrypoint = "example.Main" }
    sources { "main" }  // optional; empty packages every non-test source set
  }
}
utf-8 · pkl · Lines: 9

The key names the build task. Outputs go under .dev/artifacts/<kind>/.

TypeModuleFields
Jar, SourceJar, JavadocJar, JvmApplicationelide:Jvm.pklJAR Assembly
NativeImageelide:NativeImage.pklNative Image
WebImageelide:NativeImage.pklWebImage
ContainerImageelide:Container.pklJVM Containers
StaticSiteelide:Web.pklStatic Sites
Common fieldMeaning
dependsOnArtifact names to build first.
name (JARs)"app" and "app.jar" both give app.jar; a SourceJar gives app-sources.jar.

WebImage

WebImage takes the NativeImage fields from, name, entrypoint, moduleName, dependsOn and options, has no type, and adds:

PropertyValuesDefault
backend"wasm-gc" (host GC) or "wasm-lm" (linear memory)."wasm-gc"
runtime"generic", "browser" or "node"."generic"
autoRunStart the program when the loader loads.true
sourceMapEmit a JavaScript source map.false

entrypoint (or jvm.main) is required even with autoRun = false. Do not pass raw flags for these four settings. Guide: WebImage; flag-based artifacts: migration.

Publishing

pkl
publishing {
  maven {
    groupId = "dev.example"
    artifactId = "example"                 // default: the project name
    localRepository = "~/.m2/repository"   // the default
    artifacts { "lib"; "lib-sources" }      // default: every Jar, SourceJar and JavadocJar
    pom {
      name = "Example"
      description = "An example library."  // default: the project description
      url = "https://example.dev"
      licenses { new { name = "Apache-2.0"; url = "https://www.apache.org/licenses/LICENSE-2.0" } }
      developers { new { id = "jdoe"; name = "J. Doe" } }
      scm { url = "https://github.com/example/example" }
    }
    repositories {
      ["internal"] = "https://repo.example.dev/releases"  // or new Jvm.MavenRepositorySpec { url = … }
      ["central"] = new Publishing.CentralPortal {}       // Maven Central; import "elide:Publishing.pkl" as Publishing
    }
    signing { gpg { keyName = "0123ABCD" } }  // optional; omit keyName for gpg's default key
  }
}
utf-8 · pkl · Lines: 21

elide publish builds the selected JARs and installs them with a POM into the local Maven repository. The version is the project’s version. A publication needs a groupId, a version and exactly one Jar. A SourceJar publishes under its classifier (default sources), a JavadocJar under javadoc. A relative localRepository resolves against the manifest that declares it.

ManifestPublished POM
packages, modulescompile dependencies
runtimeOnlyruntime dependencies
compileOnly, devPackages, processors, kotlinPlugins, testPackagesOmitted
Versionless exclusionsAn <exclusion> on every dependency
A sibling projectThe sibling’s own publishing coordinates
A Jar.from siblingIts packages, modules and runtimeOnly, unless already listed
A local JAR pathAn error; consumers cannot resolve it

The POM also lists libraries Elide puts on a Kotlin project’s classpath without a declaration, as compile dependencies, because consumers need them at run time: kotlin-stdlib and kotlin-reflect at the project’s Kotlin version, and the runtimes kotlin.features turns on (kotlinx-coroutines-core, kotlinx-serialization, the Metro runtime). These appear in the published POM even though elide.pkl doesn’t name them. Turn one off where it comes from (kotlin.features, or kotlin.compilerOptions.noStdlib), or declare it yourself to pin a different version. jvm.features.graalvm adds the GraalVM SDK at runtime scope.

elide publish --to <name> publishes to a repository from repositories instead, with .md5, .sha1, .sha256 and .sha512 checksums for every file. Credentials come from ELIDE_MAVEN_<NAME>_USERNAME and ELIDE_MAVEN_<NAME>_PASSWORD, where <NAME> is the repository name uppercased with every character other than a letter or digit turned into _ (internal → ELIDE_MAVEN_INTERNAL_USERNAME, my-repo → ELIDE_MAVEN_MY_REPO_…), and otherwise from the repository’s credentials. Two names that map to the same variables (my-repo and my_repo) are refused. Plain http:// repositories other than localhost are refused without --allow-http-repositories.

With signing set, a remote publish signs every file with the gpg binary (<file>.asc); signing {} signs with gpg’s default key, and signing { gpg { keyName = "…" } } picks one. A local publish signs only with --sign, and --no-sign turns signing off. gpg-agent asks for the passphrase. For CI, set ELIDE_GPG_PASSPHRASE and Elide passes it to gpg through loopback pinentry. Elide never reads the key itself.

A CentralPortal repository publishes to Maven Central through the Central Publisher Portal. Create a user token in the Portal and pass it as ELIDE_MAVEN_<NAME>_USERNAME and ELIDE_MAVEN_<NAME>_PASSWORD. Every project of the run goes into one signed, checksummed bundle and one deployment, which the Portal validates and releases as a unit. Elide waits until the Portal has validated it, and fails with the Portal’s errors if it does not pass. --no-wait returns right after the upload instead.

CentralPortal propertyMeaningDefault
publishingTypeUSER_MANAGED: release the validated deployment in the Portal yourself. AUTOMATIC: release once validated.USER_MANAGED
urlPortal to upload to.https://central.sonatype.com

Before building, Elide checks what Central requires and reports everything missing at once: pom name, description, url, licenses, developers and scm.url; a SourceJar and a JavadocJar artifact; signing (so --no-sign is refused); and a version that is not a -SNAPSHOT.

In a workspace, members inherit the root’s publishing block except artifactId and artifacts, and a member’s own settings win field by field. Repositories are inherited by name. A project that builds no JAR publishes nothing it inherits.

To publish only some of a workspace’s projects, name them (elide publish core util) rather than changing their publishing blocks, or pass --skip-existing to leave out every version already in the target; see elide publish.

Testing

pkl
import "elide:Testing.pkl" as Testing

testing { reports { Testing.xmlReport() } }
utf-8 · pkl · Lines: 3
PropertyMeaning
testing.reportsReport formats for every runner, written to .dev/reports/tests/<language>/<source-set>/; same as --reporter=junit.

Coverage

pkl
import "elide:Coverage.pkl" as Coverage

coverage {
  enabled = true
  scope = "tests"
  jvm {
    excludes { "org.example.generated.*" }
    reports { Coverage.xmlReport(); Coverage.htmlReport() }
  }
  js { paths { "src" } }
}
utf-8 · pkl · Lines: 11
PropertyMeaningDefault
coverage.enabledCollect coverage without --coverage.false
coverage.scopeTasks that collect: "tests", "runs" or "all". --coverage always covers the task it is passed to."tests"
coverage.jvm.reportsJVM report formats: Coverage.htmlReport(), xmlReport(), csvReport(), written to .dev/reports/coverage/jvm/<task>/.none
coverage.jvm.excludesClass-name patterns (*, ?) left uninstrumented, such as generated code.none
coverage.js.pathsJavaScript and TypeScript source roots to report, as LCOV in .dev/reports/coverage/js/lcov.info. Empty reports the whole project.none

See Testing › Coverage.

Workspaces

pkl
workspace { members { "core"; "app" } }
utf-8 · pkl · Lines: 1

Each member is a directory with its own elide.pkl; members cannot have members. elide init --template workspace creates a root with a core library and an app that depends on it.

BehaviorRule
Build scopeFrom the root, elide build/elide test cover every project; from a member, only that member.
Cross-project taskselide build core:compile-kotlin-main, or elide build core for its default tasks.
Shared stateResolved dependencies and build state live in the root .dev; outputs stay in each project’s .dev.
Version pinsA member can omit a Maven version and take the root’s; a conflicting version is an error.
pkl
// core/elide.pkl
import "elide:Jvm.pkl" as Jvm

dependencies {
  maven {
    packages { "com.google.guava:guava" }  // version from the root
  }
}

artifacts {
  ["jar"] = new Jvm.Jar { name = "core" }
}
utf-8 · pkl · Lines: 12
pkl
// app/elide.pkl
local core = project("core")

dependencies { maven { packages { core } } }
utf-8 · pkl · Lines: 4
ReferenceMeaning
project("core")The project’s Jvm.Jar artifact and its compile classpath, built when needed. JVM sources alone do not count.
project("core").artifact("fat")Pick one JAR when the project declares several.
project("core").friend()Also see core’s Kotlin internal declarations, not its dependencies’. Only in packages, modules, compileOnly, testPackages.
new Jvm.Jar { from { core } }Unpack core’s JAR into this one, building it first; no dependency needed.
module.project("core")Use in place, inside an object body; bare project(…) does not resolve there.
new Artifacts.ProjectArtifact { project = "core"; artifact = "fat" }Explicit form; import "elide:Artifacts.pkl" as Artifacts.

A reference to a project with no JAR, or a misplaced friend(), fails when the build is configured.

Micronaut

See the Micronaut guide for complete build, test, and Native Image workflows.

Use the Micronaut Core version, not the platform BOM version. Core module names expand to io.micronaut:micronaut-<name>:<version>; the matching micronaut-inject-java processor is installed and used by Java compilation. Independently versioned modules, such as Micronaut Serialization, remain ordinary Maven coordinates.

pkl
dependencies {
  micronaut {
    version = "4.10.23"
    modules { "runtime"; "http-server-netty" }
    testModules { "http-client" }
  }
}
jvm {
  micronaut {
    config {
      micronaut {
        application { name = "example" }
        server { port = 8080 }
      }
      custom {
        enabled = true
        origins = new Listing { "https://example.com" }
      }
    }
  }
}
utf-8 · pkl · Lines: 21

The optional jvm.micronaut.config accepts arbitrary JSON-compatible keys and values. Elide renders it with Pkl’s JSON renderer and stages application.json on production classpaths and in JARs. Elide adds the matching micronaut-jackson-core runtime dependency for the JSON configuration loader. When supplying your own JSON resources, declare that loader yourself. An authored application.json conflicts with this generated resource and fails the build; omit the block to supply your own configuration through resources. Environment-specific files may still be provided through resources. Changes to generated configuration invalidate resource and JAR tasks.

Direct io.micronaut:micronaut-* Core dependencies also select the matching processor after workspace version pins are applied. Conflicting Core or processor versions fail validation. Satellite-module versions and transitive-only framework dependencies do not select a processor: declare a Core module or use the shorthand. This integration uses the existing Java annotation-processing path; it does not enable KSP or Kotlin-source annotation processing in project builds.

Runnable examples are in tools/smoketests/micronaut-pkl and tools/smoketests/micronaut-resources. The sample guide includes run, packaging, and smoke-test commands.

Test containers

testing.testcontainers describes disposable infrastructure shared by the project’s selected test runners. Declare named entries in containers, each with an image, optional command and environment, exposed TCP ports, and a wait strategy. environment on the outer block binds container connection values into JavaScript/TypeScript and JVM test environments. startupTimeoutSeconds bounds total startup.

See Shared test containers for the complete configuration, readiness options, prerequisites, and lifecycle.

Was this page helpful?