-
Notifications
You must be signed in to change notification settings - Fork 1
updating javalin #256
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
base: master
Are you sure you want to change the base?
updating javalin #256
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR updates the project from Javalin 3.13.10 to 6.7.0, requiring significant API migration changes. The update involves adapting to breaking changes in the Javalin framework's configuration system, session handling, and file upload APIs.
Key changes include:
- Migration from Javalin 3.x to 6.x configuration syntax and API patterns
- Updated file upload handling from
getContent()tocontent()method calls - Modified session management and test cleanup patterns
- Updated URL path parameter syntax from
:paramto{param}format
Reviewed Changes
Copilot reviewed 14 out of 16 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| pom.xml | Updates Javalin dependency from 3.13.10 to 6.7.0 and adds Kotlin stdlib dependency |
| src/main/Config/AppConfig.java | Migrates Javalin configuration syntax to v6 API patterns |
| src/main/Config/SessionConfig.java | Adds session handler reset functionality for test isolation |
| src/main/User/UserController.java | Updates session handling and file upload API calls |
| src/main/PDF/PdfController.java | Migrates file upload method calls to new API |
| src/main/PDF/PdfControllerV2.java | Updates file upload handling methods |
| src/main/File/FileController.java | Adapts file processing logic to new upload API |
| src/main/User/Services/UploadPfpService.java | Updates file content access method |
| src/test/TestUtils/TestUtils.java | Adds session reset and improved error handling |
| src/test/UserTest/UserControllerIntegrationTest.java | Migrates JUnit annotations and adds test cleanup |
| src/test/ProductionAPITest/ProductionControllerIntegrationTests.java | Updates test expectations and removes timing workarounds |
| src/test/PDFTest/PDFV2Test/*.java | Removes unnecessary sleep delays from test setup |
| src/test/DatabaseTest/File/FileDaoImplUnitTests.java | Adds null safety check in test cleanup |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
You can also share your feedback on Copilot code review for a chance to win a $100 gift card. Take the survey.
|
|
||
| if (!Objects.requireNonNull(file.contentType()).startsWith("image")) { | ||
| filestreamToUpload = file.content(); | ||
| } |
Copilot
AI
Aug 18, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Redundant file content retrieval. The condition checks if content type is not an image, then reassigns 'filestreamToUpload = file.content()' which was already assigned on line 125. This appears unnecessary.
| } | |
| // No need to reassign filestreamToUpload for non-image files; already set before switch. |
No description provided.