-
Notifications
You must be signed in to change notification settings - Fork 161
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
25 changed files
with
694 additions
and
60 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# Polaris Admin Tool | ||
|
||
This module contains a maintenance tool for performing administrative tasks on the Polaris database. | ||
It is a Quarkus application that can be used to perform various maintenance tasks targeting the | ||
Polaris database directly. | ||
|
||
Building this module will create a runnable uber-jar that can be executed from the command line. | ||
|
||
To also build the Docker image, you can use the following command: | ||
|
||
```shell | ||
./gradlew :polaris-quarkus-admin:assemble -Dquarkus.container-image.build=true | ||
``` | ||
|
||
## Running the Admin Tool | ||
|
||
The admin tool can be run from the command line using the following command: | ||
|
||
```shell | ||
java -jar polaris-quarkus-admin-<version>-runner.jar --help | ||
``` | ||
|
||
Using the Docker image, you can run the admin tool with the following command: | ||
|
||
```shell | ||
docker run --rm -it polaris-admin-tool:<version> --help | ||
``` |
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,86 @@ | ||
/* | ||
* Licensed to the Apache Software Foundation (ASF) under one | ||
* or more contributor license agreements. See the NOTICE file | ||
* distributed with this work for additional information | ||
* regarding copyright ownership. The ASF licenses this file | ||
* to you under the Apache License, Version 2.0 (the | ||
* "License"); you may not use this file except in compliance | ||
* with the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, | ||
* software distributed under the License is distributed on an | ||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
* KIND, either express or implied. See the License for the | ||
* specific language governing permissions and limitations | ||
* under the License. | ||
*/ | ||
|
||
import io.quarkus.gradle.tasks.QuarkusBuild | ||
|
||
plugins { | ||
alias(libs.plugins.quarkus) | ||
alias(libs.plugins.openapi.generator) | ||
id("polaris-server") | ||
id("polaris-license-report") | ||
} | ||
|
||
dependencies { | ||
implementation(project(":polaris-core")) | ||
implementation(project(":polaris-api-management-service")) | ||
implementation(project(":polaris-api-iceberg-service")) | ||
implementation(project(":polaris-service-common")) | ||
implementation(project(":polaris-quarkus-service")) | ||
|
||
implementation(platform(libs.quarkus.bom)) | ||
implementation("io.quarkus:quarkus-picocli") | ||
implementation("io.quarkus:quarkus-container-image-docker") | ||
|
||
implementation("org.jboss.slf4j:slf4j-jboss-logmanager") | ||
|
||
// override dnsjava version in dependencies due to https://github.com/dnsjava/dnsjava/issues/329 | ||
implementation(platform(libs.dnsjava)) | ||
|
||
testImplementation(enforcedPlatform(libs.quarkus.bom)) | ||
testImplementation("io.quarkus:quarkus-junit5") | ||
|
||
testImplementation(platform(libs.junit.bom)) | ||
testImplementation(libs.bundles.junit.testing) | ||
} | ||
|
||
tasks.withType<ProcessResources>().configureEach { | ||
from("src/main/resources") { | ||
expand("polarisVersion" to version) | ||
duplicatesStrategy = DuplicatesStrategy.INCLUDE | ||
} | ||
} | ||
|
||
quarkus { | ||
quarkusBuildProperties.put("quarkus.package.type", "uber-jar") | ||
// Pull manifest attributes from the "main" `jar` task to get the | ||
// release-information into the jars generated by Quarkus. | ||
quarkusBuildProperties.putAll( | ||
provider { | ||
tasks | ||
.named("jar", Jar::class.java) | ||
.get() | ||
.manifest | ||
.attributes | ||
.map { e -> "quarkus.package.jar.manifest.attributes.\"${e.key}\"" to e.value.toString() } | ||
.toMap() | ||
} | ||
) | ||
} | ||
|
||
publishing { | ||
publications { | ||
named<MavenPublication>("maven") { | ||
val quarkusBuild = tasks.getByName<QuarkusBuild>("quarkusBuild") | ||
artifact(quarkusBuild.runnerJar) { | ||
classifier = "runner" | ||
builtBy(quarkusBuild) | ||
} | ||
} | ||
} | ||
} |
Oops, something went wrong.