No description
  • Kotlin 81.9%
  • HTML 11.1%
  • Python 3.3%
  • TypeScript 2.4%
  • Dockerfile 0.9%
  • Other 0.4%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Oscar GutierrezRoman e09d70059a
All checks were successful
LinkLab CI / Run tests (push) Successful in 2m44s
LinkLab CI / Build JAR (push) Successful in 2m30s
LinkLab CI / Build and push Docker image (push) Successful in 26s
Merge pull request 'Week 8: Kubernetes replication, health probes and failure experiments' (#6) from week8-kubernetes into main
2026-10-27 14:41:59 +00:00
.forgejo/workflows Complete Week 8 Kubernetes replication lab and verification 2026-10-27 12:31:56 +00:00
frontend Week 7: JWT auth and RBAC 2026-10-19 22:37:47 +01:00
gradle/wrapper Week 5 blueprint 2026-07-10 11:02:36 +01:00
jenkins Week 5 blueprint 2026-07-10 11:02:36 +01:00
k8s Complete Week 8 Kubernetes replication lab and verification 2026-10-27 12:31:56 +00:00
monitoring Week 5 blueprint 2026-07-10 11:02:36 +01:00
nginx Week 5 blueprint 2026-07-10 11:02:36 +01:00
scripts Complete Week 8 Kubernetes replication lab and verification 2026-10-27 12:31:56 +00:00
src Complete Week 8 Kubernetes replication lab and verification 2026-10-27 12:31:56 +00:00
week_02 Organize Labs workspace and complete Week 6 Kafka 2026-10-15 17:49:16 +01:00
week_03 Record Week 6 lab evidence 2026-10-15 18:01:38 +01:00
week_04 Organize Labs workspace and complete Week 6 Kafka 2026-10-15 17:49:16 +01:00
week_05 Record Week 6 lab evidence 2026-10-15 18:01:38 +01:00
week_06 Record Week 6 lab evidence 2026-10-15 18:01:38 +01:00
week_07 Small edits to answers 2026-10-20 12:17:56 +01:00
week_08 Record Week 8 pull request publication 2026-10-27 14:09:09 +00:00
.dockerignore Complete Week 8 Kubernetes replication lab and verification 2026-10-27 12:31:56 +00:00
.gitignore Complete Week 8 Kubernetes replication lab and verification 2026-10-27 12:31:56 +00:00
build.gradle.kts Week 7: JWT auth and RBAC 2026-10-19 22:37:47 +01:00
docker-compose.yml Complete Week 8 Kubernetes replication lab and verification 2026-10-27 12:31:56 +00:00
Dockerfile Week 5 blueprint 2026-07-10 11:02:36 +01:00
Dockerfile.ci Week 5 blueprint 2026-07-10 11:02:36 +01:00
gradlew fix: Made gradelw executable 2026-07-20 21:02:25 +01:00
gradlew.bat Week 5 blueprint 2026-07-10 11:02:36 +01:00
README.md Complete Week 8 Kubernetes replication lab and verification 2026-10-27 12:31:56 +00:00
settings.gradle.kts Week 5 blueprint 2026-07-10 11:02:36 +01:00

CS4297 LinkLab workspace

This directory is the single Git repository and working copy for the LinkLab application. Do not clone or copy the application into individual week folders.

Layout

Labs/
├── src/, frontend/, build.gradle.kts, ...           # the LinkLab application
├── week_02/                                         # Week 2 handouts and notes
├── week_03/                                         # Week 3 handouts and notes
├── week_04/                                         # Week 4 handouts and notes
├── week_05/                                         # Week 5 handouts, worksheets, and Postman collection
├── week_06/                                         # Week 6 handouts and evidence
├── week_07/                                         # Week 7 brief, answers, and evidence
├── week_08/                                         # Week 8 brief, design answers, and evidence
└── k8s/                                            # Week 8 application deployment

The repository root contains the current cumulative solution. Each week builds on that same application. The week_XX/ folders contain teaching material only: PDFs, worksheets, troubleshooting notes, and any week-specific supporting files. They must not contain another .git directory or a second src/ tree.

Working convention

  1. Read the relevant handout in week_XX/.
  2. Make application changes from this directory, Labs/.
  3. Run Gradle and Docker Compose from this directory.
  4. Keep written answers or screenshots for a lab in its matching week_XX/ folder.
  5. Commit the code and the handouts or notes that should be retained together.

Useful commands:

./gradlew test
./gradlew bootRun
docker compose up -d mysql redis dynamodb-local dynamodb-admin elasticsearch kafka
docker compose ps

Current state: Week 8

The original Week 8 brief is a Kubernetes replication and health-probe lab, with eleven design questions. It does not require a new application feature. See week_08/requirements.md, week_08/answers.md, and k8s/README.md. Recorded runtime results and limitations are in week_08/verification.md.

The API runs as two replaceable Kubernetes pods, with the same Compose datastores outside the cluster. Kafka adds a pod-accessible listener at port 9094. JPA uses update rather than create-drop so replacing a pod preserves shared tables. The lab deliberately uses dependency-sensitive liveness probes to demonstrate a shared failure; this is not a production health-probe recommendation.

Week 7 authentication foundation

The application now uses bcrypt for password storage and HS384-signed JWTs for stateless authentication. Register and login are under /api/auth; authenticated requests send the token as Authorization: Bearer <token>. Registration retains the lab's deliberate role selector so the RBAC vulnerability can be discussed.

Method security restricts link reindexing, link statistics, and Kafka consumer lag to ROLE_ADMIN. The Week 6 consumer-lag implementation remains optional, so an authorized administrator reaches its intentional 501 Not Implemented response. JWT expiry is restored to 3600 seconds.

The Week 7 brief is in week_07/lab-week7-instructions.pdf, answers are in week_07/answers.md, and redacted command output is in week_07/evidence/.

Week 6 foundation

The application includes the Week 6 Kafka work. A link creation saves the source record in MySQL, then publishes a link-created event. A consumer updates ElasticSearch and the Redis leaderboard. Redirects publish link-clicked events, and a second consumer records clicks in DynamoDB.

Kafka runs in KRaft mode through the root docker-compose.yml. The two application topics are link-created and link-clicked. Events use the short code as their Kafka key so events for the same link retain their order if the topics gain partitions later.

Run the app from the repository root. The Week 6 instructions are in week_06/lab-week6-instructions.pdf, with troubleshooting in week_06/lab-week6-troubleshooting.pdf.

Repository remotes

origin is your personal Forgejo repository. upstream is the professor repository for the previous supplied baseline. Push only to origin.