#12362-factory-method-for-JSONbuilders - #1
Open
TillJan wants to merge 24 commits into
Open
Conversation
TillJan
pushed a commit
that referenced
this pull request
Jul 17, 2026
get `podman compose up` working
use JsonUtil.createObjectBuilder and JsonUtil.createArrayBuilder to reuse JsonUtil.builderFactory and avoid inefficient usage of JSON providers/builders.
TillJan
force-pushed
the
#12362-factory-method-for-JSONbuilders
branch
from
July 17, 2026 12:13
bff606e to
04f565f
Compare
added 2 commits
July 17, 2026 14:39
refactored the start import to specific imports
replaced all Json.createObjectBuilder() and Json.createArrayBuilder() calls with the matching JsonUtil methods.
TillJan
force-pushed
the
#12362-factory-method-for-JSONbuilders
branch
from
July 17, 2026 12:45
04f565f to
ac66224
Compare
For now, enable less invasive bundled checks. In addition, adding first rules to disallow usage of JSON-P Json.createX() API.
Disallow more methods for object and array builders using copy-style arguments.
…sonProvider. replaced all remaining Json.createObjectBuilder() and Json.createArrayBuilder() calls with the matching JsonUtil methods.
use JsonUtil.createValue to reuse JsonUtil.provider and avoid usage of Json.createValue. Replaced all Json.createValue to JsonUtil.createValue.
…ch fixes the forbiddenapis signature parsing failure.
…ions - Implemented SonarQube job in Maven CI workflow for enhanced code quality analysis. - Updated `pom.xml` and parent POM with SonarQube configuration properties and plugin definitions. - Refined JaCoCo configuration to support integrated coverage reporting.
- Adjusted artifact handling to include binary class files required by SonarQube. - Set `fetch-depth` to 0 for full Git history to improve Sonar analysis. - Updated JaCoCo XML report path in `pom.xml` for accurate coverage reporting (Sonar needs the full path to the XML file).
* fix required textarea in gbr * release note
* retention null pointer exception * review
Bumps [org.postgresql:postgresql](https://github.com/pgjdbc/pgjdbc) from 42.7.11 to 42.7.12. - [Release notes](https://github.com/pgjdbc/pgjdbc/releases) - [Changelog](https://github.com/pgjdbc/pgjdbc/blob/master/CHANGELOG.md) - [Commits](pgjdbc/pgjdbc@REL42.7.11...REL42.7.12) --- updated-dependencies: - dependency-name: org.postgresql:postgresql dependency-version: 42.7.12 dependency-type: direct:production ... Signed-off-by: dependabot[bot] <support@github.com>
- about fixed NPE for draft file preview - typo in another file name
…verse-parent/org.postgresql-postgresql-42.7.12 chore(deps): bump org.postgresql:postgresql from 42.7.11 to 42.7.12 in /modules/dataverse-parent
Bumps [org.omnifaces:omnifaces](https://github.com/omnifaces/omnifaces) from 4.7.5 to 4.7.12. - [Commits](https://github.com/omnifaces/omnifaces/commits) --- updated-dependencies: - dependency-name: org.omnifaces:omnifaces dependency-version: 4.7.12 dependency-type: direct:production ... Signed-off-by: dependabot[bot] <support@github.com>
…s-omnifaces-4.7.12 chore(deps): bump org.omnifaces:omnifaces from 4.7.5 to 4.7.12
Add SonarQube analysis and coverage reporting to GitHub Actions
…is plugin usage While using the source code analysis config files from a Config JAR is a great idea in general, it will not work in our codebase. As we do not use a parent POM at the root of our project, we cannot make the Maven Reactor pull in the dataverse-sca-config module during a build. We'd need every developer to switch to using `mvn -f modules/dataverse-parent` all the time, which seems unlikely. Bad design choices in the past, not easy to resolve. While we could push a built version to Maven Central, that would not help when modifying the signature file. At the same time, using there is no reliable way to have an absolute path injected into a Maven property. We were using project.basedir within the parent POM before. This will be resolved at build time and always points to the directory where the current POM is running from. The reusability of this centralized plugin definition is rather limited, as it would fail to lookup the file in a different module. The only way out of this: 1. Move the plugin into the dataverse module build chain. 2. This way, the resolved path is always correct, as it is model-bound, not half-parent-bound. 3. To still satisfy the request to avoid clutter in the project root, create a src/maven folder, ready to collect all these configurations.
Cleaning up the root directory, a single directory will now contain any configs related to Maven plugins. This will (mostly) be for Static Code Analysis plugins.
poikilotherm
force-pushed
the
#12362-factory-method-for-JSONbuilders
branch
from
July 31, 2026 13:04
c1d1d91 to
5842cfa
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this PR does / why we need it:
The PR adds methods in the JsonUtil for creating a JsonObjectBuilder and a JsonArrayBuilder. JsonUtil caches a JsonBuilderFactory which is shared by both methods.
All usage of Json.createArrayBuilder() and Json.createObjectBuilder has been replaced by the new methods.
This avoids repeatedly loading a Jakarta JSON-P implementation through the ServiceLoader which caused inefficiency.
Which issue(s) this PR closes:
Special notes for your reviewer:
The JsonBuilderFactory is shared and only created one time, while the methods are returning new Builder everytime.
Suggestions on how to test this:
Does this PR introduce a user interface change? If mockups are available, please link/include them here:
no
Is there a release notes update needed for this change?:
no
Additional documentation: