-
Notifications
You must be signed in to change notification settings - Fork 160
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Native-image metadata and docs (#1264)
- Loading branch information
1 parent
d060896
commit 7b8797c
Showing
25 changed files
with
490 additions
and
16 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
43 changes: 43 additions & 0 deletions
43
...image/com.lightbend.akka.management/akka-management-cluster-bootstrap/reflect-config.json
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,43 @@ | ||
[ | ||
{ | ||
"name": "akka.management.cluster.bootstrap.LowestAddressJoinDecider", | ||
"methods": [ | ||
{ | ||
"name": "<init>", | ||
"parameterTypes": ["akka.actor.ActorSystem", "akka.management.cluster.bootstrap.ClusterBootstrapSettings"] | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "akka.management.cluster.bootstrap.ClusterBootstrap$", | ||
"fields": [ | ||
{ | ||
"name": "MODULE$" | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "akka.management.cluster.bootstrap.ClusterBootstrap", | ||
"methods": [ | ||
{ | ||
"name": "<init>", | ||
"parameterTypes": ["akka.actor.ExtendedActorSystem"] | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "akka.management.cluster.bootstrap.contactpoint.HttpBootstrapJsonProtocol$SeedNode", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
}, | ||
{ | ||
"name": "akka.management.cluster.bootstrap.contactpoint.HttpBootstrapJsonProtocol$ClusterMember", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
}, | ||
{ | ||
"name": "akka.management.cluster.bootstrap.contactpoint.HttpBootstrapJsonProtocol$SeedNodes", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
} | ||
] |
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
57 changes: 57 additions & 0 deletions
57
...tive-image/com.lightbend.akka.management/akka-management-cluster-http/reflect-config.json
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,57 @@ | ||
[ | ||
{ | ||
"name": "akka.management.cluster.ClusterHttpManagementRouteProvider$", | ||
"fields": [ { | ||
"name": "MODULE$" | ||
} ] | ||
}, | ||
{ | ||
"name": "akka.management.cluster.javadsl.ClusterMembershipCheck", | ||
"methods": [{ | ||
"name": "<init>", | ||
"parameterTypes": ["akka.actor.ActorSystem"] | ||
}] | ||
}, | ||
{ | ||
"name": "akka.management.cluster.scaladsl.ClusterMembershipCheck", | ||
"methods": [{ | ||
"name": "<init>", | ||
"parameterTypes": ["akka.actor.ActorSystem"] | ||
}] | ||
}, | ||
{ | ||
"name": "akka.management.cluster.ClusterUnreachableMember", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
}, | ||
{ | ||
"name": "akka.management.cluster.ClusterMember", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
}, | ||
{ | ||
"name": "akka.management.cluster.ClusterMembers", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
}, | ||
{ | ||
"name": "akka.management.cluster.ClusterHttpManagementMessage", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
}, | ||
{ | ||
"name": "akka.management.cluster.ShardEntityTypeKeys", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
}, | ||
{ | ||
"name": "akka.management.cluster.ShardRegionInfo", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
}, | ||
{ | ||
"name": "akka.management.cluster.ShardDetails", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
} | ||
] |
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
48 changes: 48 additions & 0 deletions
48
...ive-image/com.lightbend.akka.management/akka-discovery-kubernetes-api/reflect-config.json
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,48 @@ | ||
[ | ||
{ | ||
"name": "akka.discovery.kubernetes.KubernetesApiServiceDiscovery", | ||
"methods": [ | ||
{ | ||
"name": "<init>", | ||
"parameterTypes": [ | ||
"akka.actor.ActorSystem" | ||
] | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "akka.discovery.kubernetes.PodList$ContainerPort", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
}, | ||
{ | ||
"name": "akka.discovery.kubernetes.PodList.Container", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
}, | ||
{ | ||
"name": "akka.discovery.kubernetes.PodList.PodSpec", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
}, | ||
{ | ||
"name": "akka.discovery.kubernetes.PodList.ContainerStatus", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
}, | ||
{ | ||
"name": "akka.discovery.kubernetes.PodList.PodStatus", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
}, | ||
{ | ||
"name": "akka.discovery.kubernetes.PodList.Pod", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
}, | ||
{ | ||
"name": "akka.discovery.kubernetes.PodList.Metadata", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
} | ||
] |
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 |
---|---|---|
@@ -1,4 +1,4 @@ | ||
# Built-in JMX Management | ||
|
||
Akka has built-in JMX beans which you can use to manage the cluster, read more about them in the Akka | ||
documentation: @extref:[Cluster Usage: JMX](akka:cluster-usage.html#cluster-jmx) | ||
documentation: @extref:[Cluster Usage: JMX](akka:additional/operations.html#jmx) |
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,14 @@ | ||
# Building Native Images | ||
|
||
Building native images with Akka Management is supported out of the box for the following modules: | ||
|
||
* akka-management | ||
* akka-management-cluster-bootstrap | ||
* akka-management-cluster-http | ||
* akka-discovery-kubernetes-api | ||
* akka-lease-kubernetes | ||
* akka-rolling-update-kubernetes | ||
|
||
Other modules can likely be used but will require figuring out and adding additional native-image metadata. | ||
|
||
For details about building native images with Akka in general, see the @extref[Akka Documentation](akka:additional/native-image.html). |
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
26 changes: 26 additions & 0 deletions
26
...-INF/native-image/com.lightbend.akka.management/akka-lease-kubernetes/reflect-config.json
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,26 @@ | ||
[ | ||
{ | ||
"name": "akka.coordination.lease.kubernetes.KubernetesLease", | ||
"methods": [ | ||
{ | ||
"name": "<init>", | ||
"parameterTypes": ["akka.coordination.lease.LeaseSettings", "akka.actor.ExtendedActorSystem"] | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "akka.coordination.lease.kubernetes.internal.LeaseCustomResource", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
}, | ||
{ | ||
"name": "akka.coordination.lease.kubernetes.internal.Metadata", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
}, | ||
{ | ||
"name": "akka.coordination.lease.kubernetes.internal.Spec", | ||
"allDeclaredFields": true, | ||
"queryAllPublicMethods": true | ||
} | ||
] |
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
15 changes: 15 additions & 0 deletions
15
...s/META-INF/native-image/com.lightbend.akka.management/akka-management/reflect-config.json
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,15 @@ | ||
[ | ||
{ | ||
"name": "akka.management.scaladsl.AkkaManagement$", | ||
"fields": [ { | ||
"name": "MODULE$" | ||
} ] | ||
}, | ||
{ | ||
"name": "akka.management.HealthCheckRoutes", | ||
"methods": [{ | ||
"name": "<init>", | ||
"parameterTypes": ["akka.actor.ExtendedActorSystem"] | ||
}] | ||
} | ||
] |
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,12 @@ | ||
target/ | ||
|
||
.settings | ||
.project | ||
.classpath | ||
|
||
.idea | ||
*.iml | ||
|
||
.metals | ||
.bloop | ||
.bsp |
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,52 @@ | ||
name := "native-image-tests" | ||
|
||
version := "1.0" | ||
|
||
scalaVersion := "2.13.12" | ||
|
||
resolvers += "Akka library repository".at("https://repo.akka.io/maven") | ||
|
||
lazy val akkaVersion = sys.props.getOrElse("akka.version", "2.9.2") | ||
lazy val akkaHttpVersion = sys.props.getOrElse("akka.http.version", "10.6.1") | ||
|
||
// Note: this default isn't really used anywhere so not important to bump | ||
lazy val akkaManagementVersion = sys.props.getOrElse("akka.management.version", "1.5.0") | ||
|
||
// Run in a separate JVM, to make sure sbt waits until all threads have | ||
// finished before returning. | ||
// If you want to keep the application running while executing other | ||
// sbt tasks, consider https://github.com/spray/sbt-revolver/ | ||
fork := true | ||
|
||
libraryDependencies ++= Seq( | ||
"com.typesafe.akka" %% "akka-actor-typed" % akkaVersion, | ||
"com.typesafe.akka" %% "akka-cluster-typed" % akkaVersion, | ||
"com.typesafe.akka" %% "akka-cluster" % akkaVersion, | ||
"com.typesafe.akka" %% "akka-discovery" % akkaVersion, | ||
"com.typesafe.akka" %% "akka-persistence" % akkaVersion, | ||
"com.typesafe.akka" %% "akka-cluster-sharding" % akkaVersion, | ||
"com.typesafe.akka" %% "akka-remote" % akkaVersion, | ||
"com.typesafe.akka" %% "akka-http" % akkaHttpVersion, | ||
"com.typesafe.akka" %% "akka-http-core" % akkaHttpVersion, | ||
"com.typesafe.akka" %% "akka-http-spray-json" % akkaHttpVersion, | ||
"com.lightbend.akka.management" %% "akka-management" % akkaManagementVersion, | ||
"com.lightbend.akka.management" %% "akka-management-cluster-bootstrap" % akkaManagementVersion, | ||
"com.lightbend.akka.management" %% "akka-management-cluster-http" % akkaManagementVersion, | ||
"com.lightbend.akka.discovery" %% "akka-discovery-kubernetes-api" % akkaManagementVersion, | ||
"com.lightbend.akka.management" %% "akka-lease-kubernetes" % akkaManagementVersion, | ||
"com.lightbend.akka.management" %% "akka-rolling-update-kubernetes" % akkaManagementVersion, | ||
"ch.qos.logback" % "logback-classic" % "1.2.13" | ||
) | ||
|
||
// useful for investigations: sbt nativeImageRunAgent | ||
|
||
// GraalVM native image build | ||
enablePlugins(NativeImagePlugin) | ||
nativeImageJvm := "graalvm-community" | ||
nativeImageVersion := "21.0.2" | ||
nativeImageOptions := Seq( | ||
"--no-fallback", | ||
"--verbose", | ||
"--initialize-at-build-time=ch.qos.logback", | ||
"-Dakka.native-image.debug=true" | ||
) |
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 @@ | ||
sbt.version=1.9.8 |
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 @@ | ||
addSbtPlugin("org.scalameta" % "sbt-native-image" % "0.3.4") |
Oops, something went wrong.