Skip to content

Update development branch - #1501

Merged
KochTobi merged 7 commits into
developmentfrom
main
Aug 11, 2026
Merged

Update development branch#1501
KochTobi merged 7 commits into
developmentfrom
main

Conversation

@KochTobi

Copy link
Copy Markdown
Contributor

Desciption

The development branch needs to be updated to match the main branch.

KochTobi and others added 7 commits July 30, 2026 09:57
Remove outdated triage labeling.
This commit upgrades from vaadin 24 to vaadin 25 alongside an upgrade from spring boot 3 to spring boot 4.




* Upgrade spring boot from 3.5.9 to 3.5.14

Disables code signing plugin. Needs to be re-enabled when migration is finished.

* Remove deprecated class from SecurityConfiguration.java

Replaces the VaadinWebSecurity as it is deprecated.

* Remove use of deprecated getOboId method

* Replace deprecated StreamResource for images

* Replace deprecated findSample method

* Replace deprecated Vaadin stream download with DownloadHandler

* Remove deprecated plugin option

* Address code warnings and remove dead code

* Replace deprecated method

* Remove unused code

* refactor(upload): migrate UploadWithDisplay to UploadHandler API

Replace deprecated Receiver/StreamResource pattern with UploadHandler
for Vaadin 24.8+ compatibility.

* Introduce new SmartUploadComponent

* Fix isEmpty method

Avoids Nullpointer

* Fix UploadConfiguration

* Add upload component to component demo

* feat(upload): add UploadFileDisplay and UploadContentValidator interfaces

- UploadFileDisplay: single onFilesChanged(List) method with FileEntry record and ValidationStatus enum
- UploadContentValidator: validate(String fileName, InputStream) returning Optional<String>
- Pre-commit design: single method approach avoids race conditions; validator returns empty Optional on success, error message on failure

* Add change type to interface

* docs(upload): add Javadoc to UploadFileDisplay and UploadContentValidator

Document interface contracts, method semantics, ChangeType enum,
FileEntry record fields, ValidationStatus lifecycle, and the
caller-closes-stream ownership rule.

* Add multi-file functionality to SmartUploadComponent.java

* Continue on SmartUploadComponent.java

* Rename SmartUploadComponent.java to ContentUploadComponent.java

* Move validation out of upload component

This commit removes the validation whithin the upload component. This makes the ContentUploadComponent.java simpler.
Also, the ContentUploadComponent.java now supports uploading multiple files. This can be configured by ContentUploadComponent#setMaxFiles.
Also, the max file size can be provided using the UploadConfiguration.java or in the application.properties. Negative values remove the constraint.

* Address code warnings

* Fix wrong html tree for display

* Move restrictions display to the Upload component

* Fix restriction positioning

* Display file rejections

* add fixme comment to be tackled in vaadin25.1

* Migrate EditSampleBatchDialog to ContentUploadComponent (Vaadin 25)

- Replace UploadWithDisplay with ContentUploadComponent
- Add EditSampleUploadDisplayController for validation handling
- Reuse SampleUploadDisplay for file display
- Remove deprecated onUploadSucceeded method

* Revert "Migrate EditSampleBatchDialog to ContentUploadComponent (Vaadin 25)"

This reverts commit b8c4188.

* extract SampleUploadDisplay.java

* Use vaadin25 upload for EditSampleBatchDialog.java

* Fix constructor parameters

* Fix wrong files removed

* Fix parallelism in CompletableFuture

Previously it looked parallel but was executed sequentially. Switching to reactive is to much for this PR, however the asynchronicity was fixed.

* Switch FileSizeFormatter to 1024

* Migrate UploadPurchaseDialog.java to Vaadin25 upload

* Migrate QualityControlUpload to new upload process

* Fix test

* Add JavaDoc to ContentUploadComponent

* Fix dependencies for spring boot 3.5.16 (#1465)

Goal
Upgrade Spring Boot to the latest 3.x version (3.5.16). Fix all remaining deprecation warnings for spring boot and create a clean dependency structure.

* Use spring boot 3.5.15

* use java version by property

* update vaadin to 24.10.7

* Restructure poms

* try something

* fix: comment out Vaadin prepare-frontend execution

Vaadin 24.10.7 prepare-frontend goal throws NoSuchMethodError on
ObjectNode.toPrettyString() due to ReflectorClassLoader bug.

Commented out the execution block; developers can run
mvn vaadin:prepare-frontend manually in IDE when needed.

* fix: add jakarta.jms-api dependency to identity-infrastructure

spring-jms doesn't transitively include jakarta.jms-api, causing
compilation failure for JmsTemplate.convertAndSend().

Added explicit jakarta.jms-api dependency to match existing pattern
in project-management-infrastructure/pom.xml.

* Add test dependencies

* Fix logging tests to use captor instead of System.out assertions

System.out assertions fail because SLF4J/Logback captures the original
System.out reference at bootstrap time, so System.setOut() redirection
in tests doesn't affect where log output is written.

LoggerFacadeSpec now uses a Stub publisher with a MessageCaptor to
verify the LogMessage fields actually published.

Slf4jWrapperSpec now verifies delegation methods don't throw exceptions
instead of checking system output.

* Add spring-boot-test to remaining modules and inherit Surefire version

Add spring-boot-test dependency to datamanager-app and
project-management-infrastructure so Spock tests can be discovered.

Remove hardcoded surefire version (3.5.2) from parent pom so all
modules inherit it from the Spring Boot parent (3.5.6).

* Fix spock dependency

* add missing spock-core

* remove duplicate dependency

* work in progress

* feat(datamanager-app): replace individual Vaadin components with vaadin-spring-boot-starter

- Replaced 20+ individual vaadin-*-flow dependencies with the single vaadin-spring-boot-starter
- Also excludes transitive commons-logging from docx4j-core
- Also excludes transitive commons-logging from ro-crate-java

* switch to vaadin-spring-boot-starter

* move openbis to the very bottom of the bom

* feat: add download provider, upload components, measurement presenter, QC dialogs, and haproxy config

* WIP: use mvn dependency:analyze

* switch to shedlock-spring

* fix missing test dependencies

* Qwen3.6 Plus doing dependency fixing?

* satisfy dependency:analyze

* Fix dependencies

* add infrastructure dependency

Needed for implementation and spring wiring

* Add missing runtime dependencies

* Upgrade to spring boot 3.5.16

* clean up properties

---------

Co-authored-by: KochTobi <kochtobi@users.noreply.github.com>
Co-authored-by: KochTobi-Agent <kochtobi-agent@users.noreply.github.com>

* Remove unused class

* Re-enable test

* Fix weird merge rollback

Somewhere the changes to the UploadQualityControlDialog were overwritten. This commit changes it back to the new upload component.

* fix deprecated url methods

* pin snakeyaml version

* fix switched arguments

* set vaadin version to 25.2.1

* bum spring and groovy

* chore: upgrade JobRunr to 8.7.1 and Shedlock to 7.7.0 for Spring Boot 4

* chore: migrate Jackson imports from com.fasterxml.jackson to tools.jackson

* chore: add Jackson namespace references to child module POMs

* Adjust maven group-id and Java package for jackson

* replace caught jackson exceptions

* Fix JsonComponent

* Fix compilation

* fix spring boot version

# Co-authored-by: steffengreiner <steffen.greiner@qbic.uni-tuebingen.de>
# Co-authored-by: Sven F. <sven1103@users.noreply.github.com>
# Co-authored-by: Shraddha Pawar <Shraddha0903@users.noreply.github.com>

* remove duplicate dependency
# Co-authored-by: steffengreiner <steffen.greiner@qbic.uni-tuebingen.de>
# Co-authored-by: Sven F. <sven1103@users.noreply.github.com>
# Co-authored-by: Shraddha Pawar <Shraddha0903@users.noreply.github.com>

* fix: resolve Jackson 3 runtime injection failures

- Add explicit ObjectMapper bean in JacksonConfig for converter injection
- Remove @ReadingConverter (absent in Spring Data with Jackson 3)
- Wrap readValue in try-catch (Jackson 3 no longer throws checked IOException)
- Remove jackson-datatype-jsr310 from BOM (Jackson 2 artifact causing dual classpath)
- Add spring-boot-starter-cache and JAXB deps for ehcache/AclSecurityConfiguration

* fix: add spring-boot-starter-oauth2-client for ClientRegistrationRepository bean

Spring Security 7 auto-configuration requires the starter, not the raw
spring-security-oauth2-client library, to create ClientRegistrationRepository.

* fix: resolve Vaadin 25 dev mode startup failure

- Remove deprecated lumoImports from theme.json (auto-loaded in Vaadin 25)
- Add placeholder to empty theme-editor.css (Vite 8 fails on empty CSS)
- Set vaadin.productionMode=true in application.properties

* Select Task executor for vaadin

* Fix jackson issues and make it run

Makes it run. Breaks for ORCID users after authenticating with ORCID and redirection to the data manager. Also screws up the CSS somehow.

* Fix OAuth2 login failures after Spring Boot 4 upgrade

- Replace Jetty HTTP client with JDK client in OAuth2 token exchange
  (openbis-api fat JAR bundles Jetty 9, incompatible with Spring Framework 7)
- Configure RestClient with required OAuth2 message converters
- Add user-name-attribute to ORCID provider configuration
- Add OAuth2 failure handler with logging for better diagnostics
- Show distinct error message for OAuth2 failures on login page

* Fix anonymous access to registration and public pages

Add @AnonymousAllowed to DataManagerLayout and LandingPageLayout.
Vaadin 25 enforces stricter access control: views with @AnonymousAllowed
cannot be nested inside layouts without it, causing access denied errors
for unregistered users trying to access the registration flow.

* Fix password-based login by adding explicit formLogin configuration

Spring Security does not auto-enable form login when oauth2Login is configured.
The old VaadinWebSecurity auto-configured it, but VaadinSecurityConfigurer in
Vaadin 25 does not. Without explicit formLogin(), the UsernamePasswordAuthenticationFilter
is not properly set up, causing password-based login to hang after credentials submission.

* Fix password login by uncommenting LoginForm.setAction("login")

The LoginForm needs setAction("login") to POST credentials to Spring Security's
form login endpoint. Without it, the form only fires a server-side LoginEvent
that does not perform actual authentication, causing login to hang.

* Remove redundant formLogin() configuration

VaadinSecurityConfigurer.loginView() automatically applies FormLoginConfigurer,
making the explicit http.formLogin() call unnecessary.

* fix: resolve Vaadin 25 LoginForm and AppLayout drawer styling issues

- Update login form CSS to use new ::part(form) selector (vaadin-login-form-wrapper removed in V25)
- Add compact input field styling to restore Vaadin 24 appearance
- Hide AppLayout drawer by default when no content is added (V25 behavior change)
- Add CSS rule to hide drawer part when drawer-opened attribute is not set

* Provide style sheets

* fix: improve AppLayout drawer hiding for Vaadin 25

- Use JavaScript to set drawerOpened property instead of attribute
- Add !important to CSS rule to ensure drawer is hidden
- Target both ::part(drawer) and [part="drawer"] selectors

* feat: open drawer by default when navigating to project

- Set drawerOpened=true in ProjectMainLayout.initializeDrawer()
- Drawer state persists after user manually toggles it

* refactor: use proper Vaadin API setDrawerOpened() instead of JS injection

- Replace getElement().executeJs() with setDrawerOpened() method
- Cleaner, type-safe approach using Vaadin's official API

* Fix sample update TemplateProviderOpenXML.java

Tried to sort unmodifiable list, now streams, sorts and collects into new sorted list.

# Co-authored-by: steffengreiner <steffen.greiner@qbic.uni-tuebingen.de>
# Co-authored-by: Sven F. <sven1103@users.noreply.github.com>
# Co-authored-by: Shraddha Pawar <Shraddha0903@users.noreply.github.com>

* Remove unrelated files

# Co-authored-by: steffengreiner <steffen.greiner@qbic.uni-tuebingen.de>
# Co-authored-by: Sven F. <sven1103@users.noreply.github.com>
# Co-authored-by: Shraddha Pawar <Shraddha0903@users.noreply.github.com>

* Remove confusing and inconsequential file

# Co-authored-by: steffengreiner <steffen.greiner@qbic.uni-tuebingen.de>
# Co-authored-by: Sven F. <sven1103@users.noreply.github.com>
# Co-authored-by: Shraddha Pawar <Shraddha0903@users.noreply.github.com>

* remove unrelated files

# Co-authored-by: steffengreiner <steffen.greiner@qbic.uni-tuebingen.de>
# Co-authored-by: Sven F. <sven1103@users.noreply.github.com>
# Co-authored-by: Shraddha Pawar <Shraddha0903@users.noreply.github.com>

* remove autogenerated file

# Co-authored-by: steffengreiner <steffen.greiner@qbic.uni-tuebingen.de>
# Co-authored-by: Sven F. <sven1103@users.noreply.github.com>
# Co-authored-by: Shraddha Pawar <Shraddha0903@users.noreply.github.com>

* Revert "fix: improve AppLayout drawer hiding for Vaadin 25"

This reverts commit 4162222

* Fix auto open drawer

* Re-enable code signing and signature verification

* Move from javax.xml.bind to jakarta.xml.bind

Co-Authored-By: Biscuit <kochtobi-agent@users.noreply.github.com>

* Add distributionManagement to the bom so it is deployed on release

* Fix sonar prefix in GitHub Action

* Fix code signing

* remove unused variables

* remove commented-out code

* add usage of reject method

* fix missed switch to jspecify

* correct placement of annotations

* remove debug statement in Github Actions

* Fix duplicate dialog and wrong one used.

---------

Co-authored-by: KochTobi <kochtobi@users.noreply.github.com>
Co-authored-by: KochTobi-Agent <kochtobi-agent@users.noreply.github.com>
Co-authored-by: Masterful Biscuit Agent (MBA) <263631132+KochTobi-Agent@users.noreply.github.com>
Co-authored-by: sven1103-agent <261423644+sven1103-agent@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@KochTobi
KochTobi requested a review from a team as a code owner August 10, 2026 15:11
@KochTobi
KochTobi merged commit c0dbd98 into development Aug 11, 2026
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants