Skip to content
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

Release 0.5.1 #53

Merged
merged 26 commits into from
Jul 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
dfedaad
Fix docker-compose postgres
blootsvoets Sep 28, 2023
1196bab
fix broken mp url
Bdegraaf1234 Nov 22, 2023
2fb215e
alternative login button, all localhost urls to 127.0.0.1 and update …
Bdegraaf1234 Nov 22, 2023
1bb26b1
reorganising the docker-compose files to centralize configurations fo…
Bdegraaf1234 Jan 9, 2024
c36e2f7
fix bug in app-config-frontend
Bdegraaf1234 Jan 9, 2024
1cec3ba
add liquibase checksums
Bdegraaf1234 Feb 13, 2024
12b10b7
Bump gradle
blootsvoets Mar 13, 2023
e456649
Use coroutines inside app-config
blootsvoets Mar 13, 2023
fba9a0f
Use radar-commons plugins for build
blootsvoets Mar 28, 2023
6171bfe
Build improvements
blootsvoets Mar 29, 2023
9f899b8
Update dependencies
blootsvoets Aug 31, 2023
8de061b
Updated dependencies and fixed style check
blootsvoets Oct 2, 2023
4143828
bump gradle in the dockerfile
Bdegraaf1234 Feb 13, 2024
9a05fb0
Fix broken dockerfile, remove joris as developer
Bdegraaf1234 Feb 16, 2024
5a1f483
remove alternate login button, its not needed
Bdegraaf1234 Feb 16, 2024
518a7ea
Merge pull request #49 from RADAR-base/Update-radar-auth-3
Bdegraaf1234 Feb 16, 2024
3cc1729
Liquibase checksums added
Bdegraaf1234 Feb 16, 2024
8bc8bac
adapt github actions to the new project structure
Bdegraaf1234 Feb 16, 2024
a964346
Merge pull request #50 from RADAR-base/liquibase-hotfix
Bdegraaf1234 Feb 16, 2024
ec507a0
bump hazelcast and radar-jersey
Bdegraaf1234 Mar 18, 2024
7912c7b
run snyk on dev branch
Bdegraaf1234 Mar 18, 2024
5c67174
Merge pull request #52 from RADAR-base/security-updates
Bdegraaf1234 Mar 18, 2024
e0d0901
Merge branch 'master' into dev
Bdegraaf1234 Jun 5, 2024
7811ee6
Snyk severity threshold to high
Bdegraaf1234 Jun 5, 2024
a0051a8
security updates
Bdegraaf1234 Jun 5, 2024
93243a6
Set java version to 17 and clean up build.gradle files
Bdegraaf1234 Jul 11, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# EditorConfig is awesome: https://EditorConfig.org

# top-most EditorConfig file
root = true

# Unix-style newlines with a newline ending every file
[*]
end_of_line = lf
insert_final_newline = true
charset = utf-8
indent_style = space
indent_size = 4

[{*.yml, *.yaml}]
indent_size = 2

1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
radar-app-config-frontend/docker/30-env-subst.sh text eol=lf
2 changes: 1 addition & 1 deletion .github/workflows/publish_snapshots.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:

- name: Has SNAPSHOT version
id: is-snapshot
run: grep 'version = ".*-SNAPSHOT"' build.gradle.kts
run: grep 'project = ".*-SNAPSHOT"' buildSrc/src/main/kotlin/Versions.kt

- uses: actions/setup-java@v3
with:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:

# Compile code
- name: Compile code
run: ./gradlew assemble
run: ./gradlew assemble collectLicense

- name: Use Node.js 16
uses: actions/setup-node@v3
Expand All @@ -51,7 +51,7 @@ jobs:
- name: Upload to GitHub
uses: AButler/[email protected]
with:
files: '*/build/libs/*;radar-app-config/build/distributions/*;radar-app-config-frontend/dist/radar-app-config-frontend.zip'
files: '*/build/libs/*;radar-app-config/build/distributions/*;radar-app-config-frontend/dist/radar-app-config-frontend.zip;*/build/reports/*.tar.gz'
repo-token: ${{ secrets.GITHUB_TOKEN }}

- name: Install gpg secret key
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/snyk.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
name: Snyk test
on:
pull_request:
branches:
- master
branches: [ master, dev ]
jobs:
security:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -34,3 +33,4 @@ jobs:
--configuration-matching='^runtimeClasspath$'
--org=radar-base
--policy-path=$PWD/.snyk
--severity-threshold=high
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ out/

.idea/

etc/smtp.env
docker/etc/smtp.env
231 changes: 47 additions & 184 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,50 +1,46 @@
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
import com.github.benmanes.gradle.versions.updates.DependencyUpdatesTask
import org.radarbase.gradle.plugin.radarKotlin
import org.radarbase.gradle.plugin.radarPublishing

plugins {
kotlin("jvm") apply false
id("org.jetbrains.gradle.plugin.idea-ext") version "1.1.7"
id("com.github.ben-manes.versions")
id("org.jetbrains.dokka") apply false
`maven-publish`
signing
id("io.github.gradle-nexus.publish-plugin")
id("org.radarbase.radar-root-project") version Versions.radarCommons
id("org.radarbase.radar-dependency-management") version Versions.radarCommons
id("org.radarbase.radar-kotlin") version Versions.radarCommons apply false
id("org.radarbase.radar-publishing") version Versions.radarCommons apply false
kotlin("plugin.serialization") version Versions.kotlin apply false
}

allprojects {
group = "org.radarbase"
version = "0.5.0"
radarRootProject {
projectVersion.set(Versions.project)
}

val githubRepoName = "RADAR-base/radar-app-config"
val githubUrl = "https://github.com/$githubRepoName.git"
val githubIssueUrl = "https://github.com/$githubRepoName/issues"
configure(listOf(
project(":radar-expression-lang"),
project(":radar-app-config"),
project(":radar-app-config-core"),
project(":radar-app-config-client"),
project(":radar-expression-lang"),
)) {
apply(plugin = "org.radarbase.radar-kotlin")

radarKotlin {
javaVersion.set(Versions.java)
kotlinVersion.set(Versions.kotlin)
slf4jVersion.set(Versions.slf4j)
log4j2Version.set(Versions.log4j2)
junitVersion.set(Versions.junit)
}
}

project(":radar-expression-lang-antlr") {
apply(plugin = "java")
apply(plugin = "org.gradle.antlr")

subprojects {
repositories {
mavenCentral()
mavenLocal()
maven(url = "https://oss.sonatype.org/content/repositories/snapshots")
}
tasks.withType<JavaCompile> {
options.release.set(17)
}
tasks.withType<KotlinCompile> {
kotlinOptions {
jvmTarget = "17"
languageVersion = "1.8"
apiVersion = "1.8"
}
}
afterEvaluate {
configurations.all {
resolutionStrategy.cacheChangingModulesFor(0, TimeUnit.SECONDS)
resolutionStrategy.cacheDynamicVersionsFor(0, TimeUnit.SECONDS)
}
}
}

project(":radar-expression-lang-antlr") {
tasks.withType<JavaCompile> {
options.release.set(11)
}
Expand All @@ -55,162 +51,29 @@ configure(listOf(
project(":radar-app-config-core"),
project(":radar-app-config-client"),
)) {
val myProject = this
apply(plugin = "org.jetbrains.kotlin.jvm")
apply(plugin = "org.jetbrains.dokka")
apply(plugin = "maven-publish")
apply(plugin = "signing")

dependencies {
val dokkaVersion: String by project
val dokkaHtmlPlugin by configurations
dokkaHtmlPlugin("org.jetbrains.dokka:kotlin-as-java-plugin:$dokkaVersion")

val jacksonVersion: String by project
val dokkaPlugin by configurations
dokkaPlugin(platform("com.fasterxml.jackson:jackson-bom:$jacksonVersion"))
val dokkaRuntime by configurations
dokkaRuntime(platform("com.fasterxml.jackson:jackson-bom:$jacksonVersion"))

val jsoupVersion: String by project
dokkaPlugin("org.jsoup:jsoup:$jsoupVersion")
dokkaRuntime("org.jsoup:jsoup:$jsoupVersion")
}

tasks.withType<JavaCompile> {
options.release.set(11)
}

tasks.withType<KotlinCompile> {
kotlinOptions {
jvmTarget = "11"
}
}

val sourcesJar by tasks.registering(Jar::class) {
from(myProject.the<SourceSetContainer>()["main"].allSource)
archiveClassifier.set("sources")
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
val classes by tasks
dependsOn(classes)
}

val dokkaJar by tasks.registering(Jar::class) {
from("$buildDir/dokka/javadoc")
archiveClassifier.set("javadoc")
val dokkaJavadoc by tasks
dependsOn(dokkaJavadoc)
}

tasks.withType<Tar> {
compression = Compression.GZIP
archiveExtension.set("tar.gz")
}
apply(plugin = "org.radarbase.radar-publishing")

tasks.withType<Jar> {
manifest {
attributes(
"Implementation-Title" to project.name,
"Implementation-Version" to project.version
)
}
radarKotlin {
javaVersion.set(17)
}

val assemble by tasks
assemble.dependsOn(sourcesJar)
assemble.dependsOn(dokkaJar)
radarPublishing {
val githubRepoName = "RADAR-base/radar-app-config"
githubUrl.set("https://github.com/$githubRepoName.git")

val mavenJar by publishing.publications.creating(MavenPublication::class) {
from(components["java"])

artifact(sourcesJar)
artifact(dokkaJar)

afterEvaluate {
pom {
name.set(myProject.name)
description.set(myProject.description)
url.set(githubUrl)
licenses {
license {
name.set("The Apache Software License, Version 2.0")
url.set("https://www.apache.org/licenses/LICENSE-2.0.txt")
distribution.set("repo")
}
}
developers {
developer {
id.set("blootsvoets")
name.set("Joris Borgdorff")
email.set("[email protected]")
organization.set("The Hyve")
}
developer {
id.set("nivemaham")
name.set("Nivethika Mahasivam")
email.set("[email protected]")
organization.set("The Hyve")
}
}
issueManagement {
system.set("GitHub")
url.set(githubIssueUrl)
}
organization {
name.set("RADAR-base")
url.set("https://radar-base.org")
}
scm {
connection.set("scm:git:$githubUrl")
url.set(githubUrl)
}
developers {
developer {
id.set("blootsvoets")
name.set("Bastiaan de Graaf")
email.set("[email protected]")
organization.set("The Hyve")
}
}
}

signing {
useGpgCmd()
isRequired = true
sign(tasks["sourcesJar"], tasks["dokkaJar"])
sign(mavenJar)
}

tasks.withType<Sign> {
onlyIf { gradle.taskGraph.hasTask(myProject.tasks["publish"]) }
}
}

tasks.withType<DependencyUpdatesTask> {
doFirst {
allprojects {
repositories.removeAll {
it is MavenArtifactRepository && it.url.toString().endsWith("/snapshots")
developer {
id.set("nivemaham")
name.set("Nivethika Mahasivam")
email.set("[email protected]")
organization.set("The Hyve")
}
}
}
val isStable = "(^[0-9,.v-]+(-r)?|RELEASE|FINAL|GA|-CE)$".toRegex(RegexOption.IGNORE_CASE)
rejectVersionIf {
!isStable.containsMatchIn(candidate.version)
}
}

fun Project.propertyOrEnv(propertyName: String, envName: String): String? {
return if (hasProperty(propertyName)) {
property(propertyName)?.toString()
} else {
System.getenv(envName)
}
}

nexusPublishing {
repositories {
sonatype {
username.set(propertyOrEnv("ossrh.user", "OSSRH_USER"))
password.set(propertyOrEnv("ossrh.password", "OSSRH_PASSWORD"))
}
}
}

tasks.wrapper {
gradleVersion = "8.0.2"
}
10 changes: 10 additions & 0 deletions buildSrc/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile

plugins {
kotlin("jvm") version "1.9.10"
}

repositories {
mavenCentral()
}
23 changes: 23 additions & 0 deletions buildSrc/src/main/kotlin/Versions.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
object Versions {
const val project = "0.5.1"

const val java = 17
const val kotlin = "1.9.23"
const val kotlinxSerialization = "1.6.3"

const val radarCommons = "1.1.2"
const val jackson = "2.15.2"
const val antlr = "4.13.1"
const val ktor = "2.3.11"
const val coroutines = "1.7.2"
const val radarJersey = "0.11.1"
const val log4j2 = "2.20.0"
const val slf4j = "2.0.13"
const val hazelcast = "5.4.0"
const val hazelcastHibernate = "5.1.0"
const val hazelcastKubernetes = "2.2.3"

const val junit = "5.9.3"
const val hamcrest = "2.2"
const val mockitoKotlin = "5.3.1"
}
Loading
Loading