Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
59 commits
Select commit Hold shift + click to select a range
26fadae
Config update
this-Aditya Jun 24, 2025
bfddde6
Config for enabling or disabling security for endpoints
this-Aditya Jul 6, 2025
b1f516d
Project Resource Added
this-Aditya Jul 6, 2025
918f3aa
Making common method inline and utility one
this-Aditya Jul 6, 2025
1ab8806
New Resource class for handling users
this-Aditya Jul 6, 2025
6e50772
Modifications to ProjectResource
this-Aditya Jul 6, 2025
546cea8
Created dockerfile for appserver jersey project
this-Aditya Jul 8, 2025
dc45139
Docker compose for appserver-jersey
this-Aditya Jul 8, 2025
6cef7c3
Resources for docker compose files
this-Aditya Jul 8, 2025
6b8712a
Docker compose setup for facilitating integration tests
this-Aditya Jul 8, 2025
15a1582
Added dependencies for testing
this-Aditya Jul 8, 2025
aecd796
Commons package for supporting integration tests
this-Aditya Jul 8, 2025
8e2be5d
Integration test for project endpoint
this-Aditya Jul 8, 2025
33d08e0
Added integration tests for User Endpoint and minor updates to other …
this-Aditya Jul 9, 2025
55a3284
Added test for notification endpoint
this-Aditya Jul 9, 2025
96463d2
Added license
this-Aditya Jul 9, 2025
3cdb03b
Added fcm data message resource class
this-Aditya Jul 9, 2025
22f28d7
Misc changes
this-Aditya Jul 9, 2025
4ca72d8
New resource class for fcm notifications
this-Aditya Jul 9, 2025
e4b1025
Misc changes
this-Aditya Jul 9, 2025
52c2737
Efficient updates in repository
this-Aditya Jul 18, 2025
b591729
Updates to project resource and service
this-Aditya Jul 18, 2025
7e438fc
Corrected mp port
this-Aditya Jul 20, 2025
f9e94f1
Added mp project service for validation
this-Aditya Jul 20, 2025
597677c
Binding questionnaire schedule service to hk2
this-Aditya Jul 22, 2025
d9f6b76
Factory for retrieving quartz scheduler
this-Aditya Jul 31, 2025
be86dd3
Scheduler configs and coroutines
this-Aditya Aug 1, 2025
d58a0d5
Fine tuned message scheduler service as per jersey quartz
this-Aditya Aug 1, 2025
efa4325
Scheduler service improvements
this-Aditya Aug 1, 2025
562d6d2
Data message state event's stuff
this-Aditya Aug 1, 2025
9abf1e0
Notification state event service work
this-Aditya Aug 1, 2025
0ca2120
Using questionnaire schedule service with the cutom scheduling servic…
this-Aditya Aug 12, 2025
9de49cc
Updates to UserService
this-Aditya Aug 12, 2025
2b389d4
Updated exceptions error status code
this-Aditya Aug 12, 2025
c1faff9
Using the Date field instead of Instant to maintian consistency with …
this-Aditya Aug 12, 2025
988fb08
Misc changes
this-Aditya Aug 12, 2025
2928cb4
Updates to scheduler, quartz listener
this-Aditya Aug 12, 2025
721a03f
Task and TaskStateEvent setup
this-Aditya Aug 13, 2025
e02f99a
Fine tuned message services and listeners
this-Aditya Aug 13, 2025
4e19aef
Misc changes
this-Aditya Aug 13, 2025
1409c81
Misc changes
this-Aditya Aug 14, 2025
6aa0533
Initializing the jobs using hk2 and quartz support
this-Aditya Aug 14, 2025
3351bc7
Corrected misconfiguration between state event listeners, services an…
this-Aditya Aug 15, 2025
31cd3d6
Fine tuned fcm sender side things
this-Aditya Aug 15, 2025
1b012c7
Github and Protocol Resource classes added
this-Aditya Aug 15, 2025
0a4962a
Github protocols dtos transformed to use kotlinx-serialization
this-Aditya Aug 17, 2025
ebe808e
Using kotlinx-serialization in state event services
this-Aditya Aug 17, 2025
8e582dc
Migrated state event listeners to kotlinx-serialization
this-Aditya Aug 17, 2025
93bf738
Migrated state event listeners to kotlinx-serialization
this-Aditya Aug 17, 2025
2245243
Migrated github protocol strategy jackson work to kotlinx-serialization
this-Aditya Aug 17, 2025
92e4faf
Added custom kotlinx Base64 and ReferenceTimestamp serializers
this-Aditya Aug 17, 2025
4e6e5a2
Removed jackson custom deserializer
this-Aditya Aug 17, 2025
f68a1f5
Misc changes
this-Aditya Aug 17, 2025
d048b5d
Resource classes
this-Aditya Aug 17, 2025
4e8f247
Ktlint format
this-Aditya Aug 17, 2025
c3166ee
Misc changes
this-Aditya Aug 17, 2025
c4e8ce4
Config corrections
this-Aditya Aug 18, 2025
2237080
Using dev environment config
this-Aditya Aug 18, 2025
0853d52
Misc changes
this-Aditya Aug 18, 2025
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
42 changes: 42 additions & 0 deletions appserver-jersey/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# Licensed 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.

FROM --platform=$BUILDPLATFORM gradle:8.5-jdk17 as builder

RUN mkdir /code
WORKDIR code
ENV GRADLE_USER_HOME=/code/.gradlecache \
GRADLE_OPTS="-Djdk.lang.Process.launchMechanism=vfork -Dorg.gradle.vfs.watch=false"

COPY ../buildSrc /code/buildSrc
COPY ../build.gradle.kts ../settings.gradle.kts /code/
COPY ./build.gradle.kts /code/radar-appserver

RUN gradle downloadDependencies copyDependencies

COPY ./src /code/radar-appserver/src

RUN gradle jar

FROM eclipse-temurin:17-jre

COPY --from=builder /code/radar-appserver/build/scripts/* /usr/bin/
COPY --from=builder /code/radar-appserver/build/third-party/* /usr/lib/
COPY --from=builder /code/radar-appserver/build/libs/*.jar /usr/lib/

USER 101

EXPOSE 8080

CMD ["radar-appserver"]


38 changes: 15 additions & 23 deletions appserver-jersey/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
plugins {
application
kotlin("plugin.serialization") version Versions.kotlinVersion
id("org.radarbase.radar-kotlin") version Versions.radarCommonsVersion
kotlin("plugin.allopen")
kotlin("plugin.noarg")
id("org.jetbrains.kotlin.plugin.spring")
id("org.jetbrains.kotlin.plugin.jpa")

}

application {
Expand All @@ -20,7 +18,6 @@ application {
)
}


description = "RADAR Appserver for scheduling tasks and notifications."

val integrationTestSourceSet = sourceSets.create("integrationTest") {
Expand Down Expand Up @@ -51,11 +48,9 @@ allOpen {
}

dependencies {
// implementation(kotlin("stdlib-jdk8"))
implementation(kotlin("reflect"))

// implementation("org.radarbase:radar-commons:${Versions.radarCommons}")
// implementation("org.radarbase:radar-commons-kotlin:${Versions.radarCommons}")
implementation("org.radarbase:radar-commons-kotlin:${Versions.radarCommonsVersion}")
implementation("org.radarbase:radar-jersey:${Versions.radarJerseyVersion}")
implementation("org.radarbase:radar-jersey-hibernate:${Versions.radarJerseyVersion}") {
runtimeOnly("org.postgresql:postgresql:${Versions.postgresqlVersion}")
Expand All @@ -76,27 +71,24 @@ dependencies {
}
}
}
implementation("org.jetbrains.kotlinx:kotlinx-serialization-json:1.6.3")

implementation("com.google.guava:guava:32.1.3-jre")
implementation("org.quartz-scheduler:quartz:2.5.0")

// implementation("org.radarbase:managementportal-client:${Versions.radarAuth}")
// implementation("org.radarbase:lzfse-decode:${Versions.lzfse}")
// implementation("org.radarbase:radar-auth:${Versions.radarAuth}")
testImplementation("io.mockk:mockk:1.14.4")
testImplementation("org.mockito.kotlin:mockito-kotlin:3.2.0")
testImplementation("org.hamcrest:hamcrest:2.1")
testImplementation("org.assertj:assertj-core:3.24.2")

// implementation(platform("io.ktor:ktor-bom:${Versions.ktor}"))
// implementation("io.ktor:ktor-client-auth")

// runtimeOnly("org.glassfish.grizzly:grizzly-framework-monitoring:${Versions.grizzly}")
// runtimeOnly("org.glassfish.grizzly:grizzly-http-monitoring:${Versions.grizzly}")
// runtimeOnly("org.glassfish.grizzly:grizzly-http-server-monitoring:${Versions.grizzly}")
//
// testImplementation("org.mockito.kotlin:mockito-kotlin:${Versions.mockitoKotlin}")
// testImplementation("org.hamcrest:hamcrest:${Versions.hamcrest}")
// testImplementation("com.squareup.okhttp3:mockwebserver:${Versions.okHttp}")
integrationTestImplementation(platform("io.ktor:ktor-bom:${Versions.ktorVersion}"))
integrationTestImplementation("io.ktor:ktor-client-content-negotiation")
integrationTestImplementation("io.ktor:ktor-serialization-kotlinx-json")
}

// integrationTestImplementation(platform("io.ktor:ktor-bom:${Versions.ktor}"))
// integrationTestImplementation("io.ktor:ktor-client-content-negotiation")
// integrationTestImplementation("io.ktor:ktor-serialization-kotlinx-json")
ktlint {
ignoreFailures.set(false)
outputColorName.set("RED")
}

radarKotlin {
Expand Down
59 changes: 59 additions & 0 deletions appserver-jersey/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
version: '3.8'

services:
#---------------------------------------------------------------------------#
# ManagementPortal Postgres #
#---------------------------------------------------------------------------#
managementportal-postgresql:
image: postgres
environment:
POSTGRES_USER: radarbase
POSTGRES_PASSWORD: radarbase
POSTGRES_DB: managementportal


#---------------------------------------------------------------------------#
# Management Portal #
#---------------------------------------------------------------------------#
managementportal:
image: radarbase/management-portal:2.1.0
environment:
SERVER_PORT: 8081
SPRING_PROFILES_ACTIVE: prod
SPRING_DATASOURCE_URL: jdbc:postgresql://managementportal-postgresql:5432/managementportal
SPRING_DATASOURCE_USERNAME: radarbase
SPRING_DATASOURCE_PASSWORD: radarbase
SPRING_LIQUIBASE_CONTEXTS: dev #includes testing_data, remove for production builds
JHIPSTER_SLEEP: 10 # gives time for the database to boot before the application
JAVA_OPTS: -Xmx512m # maximum heap size for the JVM running ManagementPortal, increase this as necessary
MANAGEMENTPORTAL_COMMON_BASE_URL: http://localhost:8081/managementportal
MANAGEMENTPORTAL_COMMON_MANAGEMENT_PORTAL_BASE_URL: http://localhost:8081/managementportal
MANAGEMENTPORTAL_FRONTEND_CLIENT_SECRET:
MANAGEMENTPORTAL_OAUTH_CLIENTS_FILE: /mp-includes/config/oauth_client_details.csv
volumes:
- ./src/integrationTest/resources/docker/etc/:/mp-includes/

#---------------------------------------------------------------------------#
# Appserver Postgres #
#---------------------------------------------------------------------------#
appserver-postgres:
image: postgres
environment:
POSTGRES_DB: appserver
POSTGRES_USER: radar
POSTGRES_PASSWORD: radar

#---------------------------------------------------------------------------#
# Appserver #
#---------------------------------------------------------------------------#
appserver:
image: radarbase/radar-appserver
build: ./
restart: always
ports:
- "8080:8080"
environment:
JDK_JAVA_OPTIONS: -Xmx4G -Djava.security.egd=file:/dev/./urandom
FCMSERVER_SENDERID: "1043784930865"
FCMSERVER_SERVERKEY: "AAAA8wZuFjE:APA91bGpJQ3Sft0mZAaVMjDJGNLjFsdDLTo-37ZN69r4lKlHiRN78t4bCfkNKcXG5c9cJg-eGtWB7FqceQUDVtf7B1Zvw_2ycynqwKe2YqXFeyaq83Gf0R3AS1EKSWFS60GCr8eUEliz"
APPSERVER_JDBC_URL: jdbc:postgresql://postgres:5432/radar
Loading
Loading