From ea9e9214e2095af22d984435695ba314a5f33c83 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Fri, 16 Feb 2024 15:25:28 +0100 Subject: [PATCH 01/98] Initialise Antora Docs --- .github/workflows/antora-build.yml | 51 +++++ docs/antora-playbook.yml | 36 +++ docs/antora.yml | 12 + docs/modules/ROOT/nav.adoc | 0 docs/modules/ROOT/pages/index.adoc | 3 + docs/package.json | 9 + docs/supplemental-ui/css/site-extra.css | 47 ++++ docs/supplemental-ui/img/Favicon_16x16.png | Bin 0 -> 365 bytes docs/supplemental-ui/img/Favicon_32x32.png | Bin 0 -> 632 bytes docs/supplemental-ui/img/Header_logo.svg | 210 ++++++++++++++++++ .../partials/footer-content.hbs | 2 + docs/supplemental-ui/partials/head-meta.hbs | 3 + .../partials/header-content.hbs | 203 +++++++++++++++++ 13 files changed, 576 insertions(+) create mode 100644 .github/workflows/antora-build.yml create mode 100644 docs/antora-playbook.yml create mode 100644 docs/antora.yml create mode 100644 docs/modules/ROOT/nav.adoc create mode 100644 docs/modules/ROOT/pages/index.adoc create mode 100644 docs/package.json create mode 100644 docs/supplemental-ui/css/site-extra.css create mode 100644 docs/supplemental-ui/img/Favicon_16x16.png create mode 100644 docs/supplemental-ui/img/Favicon_32x32.png create mode 100644 docs/supplemental-ui/img/Header_logo.svg create mode 100644 docs/supplemental-ui/partials/footer-content.hbs create mode 100644 docs/supplemental-ui/partials/head-meta.hbs create mode 100644 docs/supplemental-ui/partials/header-content.hbs diff --git a/.github/workflows/antora-build.yml b/.github/workflows/antora-build.yml new file mode 100644 index 00000000..2781a576 --- /dev/null +++ b/.github/workflows/antora-build.yml @@ -0,0 +1,51 @@ +name: Antora Documentation Build # Name of the GitHub Actions workflow + +on: workflow_dispatch # This workflow is triggered manually + +env: + ACTIONS_STEP_DEBUG : true + +# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages +permissions: + contents: read # Read permission for repository contents + pages: write # Write permission for GitHub Pages + id-token: write # Write permission for ID token + +jobs: + build: + runs-on: ubuntu-latest # Run the job on a machine with the latest version of Ubuntu + + environment: + name: github-pages # Environment name + url: https://github.com/xdev-software/spring-data-eclipse-store + + steps: + - name: Checkout repository # Step to check out the repository + uses: actions/checkout@v4 + + - name: Install Node.js # Step to install Node.js + uses: actions/setup-node@v3 + with: + node-version: 18 # Specify Node.js version + + - name: Install Antora and the Antora Lunr Extension # Step to install Antora and the Lunr extension + run: npm i antora @antora/lunr-extension + + - name: Generate Site # Step to generate the documentation site + run: GIT_CREDENTIALS=https://${{ secrets.GITHUB_TOKEN }}:@github.com npx antora docs/antora-playbook.yml --fetch --stacktrace #GIT_CREDENTIALS are needed if the source repo with the documentation is private! + + - name: Setup Pages # Step to set up GitHub Pages + uses: actions/configure-pages@v3 + + - name: Upload artifact # Step to upload an artifact + uses: actions/upload-pages-artifact@v2 + with: + name: site # Specify the name of the artifact + path: docs/site # Specify the path to the artifact + + - name: Deploy to GitHub Pages # Step to deploy the site to GitHub Pages + id: deployment + uses: actions/deploy-pages@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} # Specify the GitHub token for deployment + artifact_name: site # Specify the name of the artifact to deploy diff --git a/docs/antora-playbook.yml b/docs/antora-playbook.yml new file mode 100644 index 00000000..f8090254 --- /dev/null +++ b/docs/antora-playbook.yml @@ -0,0 +1,36 @@ +site: + title: Spring-Data-Eclipse-Store + url: https://xdev-software.github.io/spring-data-eclipse-store/ + robots: allow + +# see https://docs.antora.org/antora/2.3/playbook/configure-runtime/ +runtime: + cache_dir: ./.cache/antora + log: + # use pretty even on CI + format: pretty + # set to info to get details from the Antora extensions + level: info + # Antora exits with a non-zero exit code if an error is logged -> https://docs.antora.org/antora/latest/playbook/runtime-log-failure-level + failure_level: error + +content: + sources: + # url of the repo + - url: https://github.com/xdev-software/spring-data-eclipse-store + start_path: docs + branches: + - "master" + +ui: + bundle: + url: https://gitlab.com/antora/antora-ui-default/-/jobs/artifacts/master/raw/build/ui-bundle.zip?job=bundle-stable + snapshot: true + supplemental_files: ./supplemental-ui + +output: + dir: ./site + +antora: + extensions: + - require: '@antora/lunr-extension' diff --git a/docs/antora.yml b/docs/antora.yml new file mode 100644 index 00000000..1894c607 --- /dev/null +++ b/docs/antora.yml @@ -0,0 +1,12 @@ +name: manual +title: Spring-Data-Eclipse-Store +version: master +display_version: '1.0' +start_page: index.adoc # The starting page for the documentation. +nav: +- modules/ROOT/nav.adoc # Navigation information, specifying the location of the navigation file. +asciidoc: + attributes: + varVersion: 1.0 # AsciiDoc attributes, such as 'varVersion' with its value. + page-editable: false # Whether pages are editable (in this case, set to 'false'). + page-out-of-support: false # Whether pages are out of support (in this case, set to 'false'). \ No newline at end of file diff --git a/docs/modules/ROOT/nav.adoc b/docs/modules/ROOT/nav.adoc new file mode 100644 index 00000000..e69de29b diff --git a/docs/modules/ROOT/pages/index.adoc b/docs/modules/ROOT/pages/index.adoc new file mode 100644 index 00000000..c46d4194 --- /dev/null +++ b/docs/modules/ROOT/pages/index.adoc @@ -0,0 +1,3 @@ += Overview + +== About Spring-Data-Eclipse-Store \ No newline at end of file diff --git a/docs/package.json b/docs/package.json new file mode 100644 index 00000000..81428ad6 --- /dev/null +++ b/docs/package.json @@ -0,0 +1,9 @@ +{ + "dependencies": { + "@antora/lunr-extension": "^1.0.0-alpha.8" + }, + "devDependencies": { + "@antora/cli": "3.1.4", + "@antora/site-generator": "3.1.4" + } +} \ No newline at end of file diff --git a/docs/supplemental-ui/css/site-extra.css b/docs/supplemental-ui/css/site-extra.css new file mode 100644 index 00000000..f4e4f1f0 --- /dev/null +++ b/docs/supplemental-ui/css/site-extra.css @@ -0,0 +1,47 @@ +body { + font-family: sans-serif; +} + +.navbar { + background-color: #fff; +} + +footer.footer { + color: #fff; + background-color: #333333; +} + +footer.footer a, +footer.footer .link-separator +{ + color: #c02222; +} + +.navbar-item { + padding: 0px 8px; +} + +.navbar-brand .navbar-item.logo { + align-self: center; + padding: 0; +} + +.navbar-brand .navbar-item.logo img { + width: inherit; +} + +.navbar-brand .navbar-item.title { + align-self: center; + color: var(--navbar-font-color); + font-size: 1rem; + line-height: 1; + position: relative; + top: 0.06em; /* compensate for built-in line height in font */ + letter-spacing: -0.02em; + padding: 0; + margin: 0 1rem; +} + +.doc h1 { + color: #333333; +} diff --git a/docs/supplemental-ui/img/Favicon_16x16.png b/docs/supplemental-ui/img/Favicon_16x16.png new file mode 100644 index 0000000000000000000000000000000000000000..47845d383e54273de7d1ef73338cd1572efaa95b GIT binary patch literal 365 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`oCO|{#Xx#72s3^-KI6o;^ z-=F!;|DL7NbwqU0e>caM;Ztt5GawKY-oyXxi|+?QFS zcCy|49ZUED?hN4@OhwJxiXWdd;YpbEqW$5n?@QHIaOy~xq*~1~uis`QQ}?Yo<9Icn zp;<%Ulc=pGnaU@t5+!Doi{{uwo%nn_Yu3L1C!YVG+AUtg_@gLi!bJIoqrgyL@O1Ta JS?83{1OU5Hnmqsj literal 0 HcmV?d00001 diff --git a/docs/supplemental-ui/img/Favicon_32x32.png b/docs/supplemental-ui/img/Favicon_32x32.png new file mode 100644 index 0000000000000000000000000000000000000000..d061272ebf2e77ffcd2e4eb43f75bcae19dffca6 GIT binary patch literal 632 zcmV-;0*C#HP)Tvz6YR?Ob^O&vVL8mtqfF)#YTf{D;TbY=3~kl^Z{Am zgu!fxciXQl&m+m|Kcj`Aq1N_K>sL+WfGdFalL0g@Y-%IeoV~cZy0IrXmANdl9MTwY zG-AD!Y--yJ9$YAw*P}gq0HS);)6xNANnTYijc<9hf5boriON?UNK%9%zd;uN- zxBNrNG{Uy>nr0&B=Sab3E~3U~zHhpb`G58hZtQQBD5~Vt^PR28aQg4)6`f_1Ulb SpqN?!0000 + + + diff --git a/docs/supplemental-ui/partials/footer-content.hbs b/docs/supplemental-ui/partials/footer-content.hbs new file mode 100644 index 00000000..7b55a4b0 --- /dev/null +++ b/docs/supplemental-ui/partials/footer-content.hbs @@ -0,0 +1,2 @@ +
+
diff --git a/docs/supplemental-ui/partials/head-meta.hbs b/docs/supplemental-ui/partials/head-meta.hbs new file mode 100644 index 00000000..69dbe3b1 --- /dev/null +++ b/docs/supplemental-ui/partials/head-meta.hbs @@ -0,0 +1,3 @@ + + + diff --git a/docs/supplemental-ui/partials/header-content.hbs b/docs/supplemental-ui/partials/header-content.hbs new file mode 100644 index 00000000..3f4a88c6 --- /dev/null +++ b/docs/supplemental-ui/partials/header-content.hbs @@ -0,0 +1,203 @@ +
+ +
From 8514615e08a85f96d6bc60d221bee1994a1948ed Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Mon, 4 Mar 2024 08:25:38 +0100 Subject: [PATCH 02/98] Updated check Build java version --- .github/workflows/checkBuild.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/checkBuild.yml b/.github/workflows/checkBuild.yml index 5f2678b6..da4fbd43 100644 --- a/.github/workflows/checkBuild.yml +++ b/.github/workflows/checkBuild.yml @@ -29,7 +29,7 @@ jobs: strategy: matrix: - java: [17, 21.0.1] + java: [17, 21] distribution: [temurin] steps: From a774083a1ec92e14a0f409e03b89dd433c30aac8 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Mon, 4 Mar 2024 10:25:47 +0100 Subject: [PATCH 03/98] Added some Docs --- docs/antora.yml | 12 +++--- docs/modules/ROOT/nav.adoc | 3 ++ docs/modules/ROOT/pages/index.adoc | 23 ++++++++++- docs/modules/ROOT/pages/installation.adoc | 45 +++++++++++++++++++++ docs/modules/ROOT/pages/working-copies.adoc | 12 ++++++ 5 files changed, 89 insertions(+), 6 deletions(-) create mode 100644 docs/modules/ROOT/pages/installation.adoc create mode 100644 docs/modules/ROOT/pages/working-copies.adoc diff --git a/docs/antora.yml b/docs/antora.yml index 1894c607..ebd3a7dd 100644 --- a/docs/antora.yml +++ b/docs/antora.yml @@ -2,11 +2,13 @@ name: manual title: Spring-Data-Eclipse-Store version: master display_version: '1.0' -start_page: index.adoc # The starting page for the documentation. +start_page: index.adoc nav: -- modules/ROOT/nav.adoc # Navigation information, specifying the location of the navigation file. + - modules/ROOT/nav.adoc asciidoc: attributes: - varVersion: 1.0 # AsciiDoc attributes, such as 'varVersion' with its value. - page-editable: false # Whether pages are editable (in this case, set to 'false'). - page-out-of-support: false # Whether pages are out of support (in this case, set to 'false'). \ No newline at end of file + product-name: 'Spring-Data-Eclipse-Store' + display-version: '1.0.3' + maven-version: '1.0.3' + page-editable: false + page-out-of-support: false diff --git a/docs/modules/ROOT/nav.adoc b/docs/modules/ROOT/nav.adoc index e69de29b..c3318e55 100644 --- a/docs/modules/ROOT/nav.adoc +++ b/docs/modules/ROOT/nav.adoc @@ -0,0 +1,3 @@ +* xref:index.adoc[Home] +* xref:installation.adoc[Installation] +* xref:working-copies.adoc[Working Copies] diff --git a/docs/modules/ROOT/pages/index.adoc b/docs/modules/ROOT/pages/index.adoc index c46d4194..e53034a1 100644 --- a/docs/modules/ROOT/pages/index.adoc +++ b/docs/modules/ROOT/pages/index.adoc @@ -1,3 +1,24 @@ = Overview -== About Spring-Data-Eclipse-Store \ No newline at end of file +== About Spring-Data-Eclipse-Store + +A library to simplify using https://eclipsestore.io/[EclipseStore] in the https://spring.io/projects/spring-data/[Spring environment]. + +What makes this library special is, that it creates a xref:working-copies.adoc[working copy] of the data. +This way EclipseStore behaves almost exactly like relational database from a coding perspective. + +== Features + +The library provides following features: + +* Enforces the +https://docs.spring.io/spring-data/jpa/reference/repositories/core-concepts.html[Spring data repository concept] +for EclipseStore by using xref:working-copies.adoc[working copies]. +* xref:installation.adoc#drop-in-compatible[Drop in compatible] for your existing Spring application +* Utilizes *ultra-fast EclipseStore serializing and storing* +* Enables your application to select any https://docs.eclipsestore.io/manual/storage/storage-targets/index.html[EclipseStore target] (e.g. +https://docs.eclipsestore.io/manual/storage/storage-targets/sql-databases/postgresql.html[PostgreSQL], +https://docs.eclipsestore.io/manual/storage/storage-targets/blob-stores/aws-s3.html[AWS S3] or +https://github.com/xdev-software/eclipse-store-afs-ibm-cos[IBM COS]) +* Can save up to *99%footnote:[If the COS Connector is used in the IBM Cloud instead of a PostgreSQL and approx. 10,000 entries with a total size of 1 GB of data are stored. (https://cloud.ibm.com/estimator/estimates[IBM Cloud Pricing], as of 08.01.2024)] of monthly costs* in the IBM Cloud and up to 82%footnote:[If the S3 connector is used instead of DynamoDB under the same conditions at AWS. +(https://calculator.aws/#/estimate?id=ab85cddf77f0d1aa0457111ed82785dfb836b1d8[AWS Pricing Calculator], as of 08.01.2024)] in the AWS Cloud diff --git a/docs/modules/ROOT/pages/installation.adoc b/docs/modules/ROOT/pages/installation.adoc new file mode 100644 index 00000000..7e77c552 --- /dev/null +++ b/docs/modules/ROOT/pages/installation.adoc @@ -0,0 +1,45 @@ += Installation + +== Build Configuration + +You can find the {product-name} libraries in the Maven Central repository. + +Simply add the following dependency to your maven project + +[source,xml,subs=attributes+,title="Maven [pom.xml]"] +---- + + + software.xdev + spring-data-eclipse-store + {maven-version} + + +---- + +Also see the https://github.com/xdev-software/spring-data-eclipse-store/releases/latest#Installation[installation guide for the latest release]. + +== Configuration + +After adding the library in your dependencies, using it is as easy as adding the ``@EnableEclipseStoreRepositories`` annotation to your ``@SpringBootApplication`` annotation. + +[NOTE] +==== +Since the library is using reflection to copy data, the following JVM-Arguments may have to be set. + +[source,title="JVM Arguments"] +---- +--add-opens=java.base/java.util=ALL-UNNAMED +--add-exports java.base/jdk.internal.misc=ALL-UNNAMED +--add-opens=java.base/java.lang=ALL-UNNAMED +--add-opens=java.base/java.time=ALL-UNNAMED +---- +==== + +== Demo + +To see how easy it is to implement EclipseStore in your Spring project, take a look at the three https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo[demos]: +A https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/simple[simple], a more https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex[complex demo] and a https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-jpa/src/main/java/software/xdev/spring/data/eclipse/store/jpa[demo with coexisting JPA]. + +== Drop in compatible [[drop-in-compatible]] + diff --git a/docs/modules/ROOT/pages/working-copies.adoc b/docs/modules/ROOT/pages/working-copies.adoc new file mode 100644 index 00000000..b639839f --- /dev/null +++ b/docs/modules/ROOT/pages/working-copies.adoc @@ -0,0 +1,12 @@ += Working copies + +If you use EclipseStore without our library, EclipseStore loads the data from the datastore directly into memory. You make your changes on these loaded Java objects and by calling ``store`` EclipseStore writes it directly from memory to the datastore. + +![Native behavior of EclipseStore](assets/WorkingCopy_1.svg) + +If you e.g. change the address of a person, the changed address is already in your data model, **even before storing** this person. +This is very different from the behavior a Spring user expects. + +With *Spring-Data-Eclipse-Store* every time an object is loaded from the datastore, a working copy of that object (or rather the object tree) is created and returned to the user. Therefore, the user can make the changes on the working copy without any changes to the actual data model. The changes are only persisted after calling ``save`` on a repository. + +![Behavior of EclipseStore with Spring-Data-Eclipse-Store](assets/WorkingCopy_2.svg) From 9231ff82a12a73620dfca72b9618fe9f9cdeb098 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Mon, 4 Mar 2024 15:09:45 +0100 Subject: [PATCH 04/98] Extended docs --- .../ROOT/assets/images/WorkingCopy_1.svg | 4 +++ .../ROOT/assets/images/WorkingCopy_2.svg | 4 +++ docs/modules/ROOT/nav.adoc | 2 ++ docs/modules/ROOT/pages/installation.adoc | 2 +- docs/modules/ROOT/pages/known-issues.adoc | 4 +++ docs/modules/ROOT/pages/migration.adoc | 31 +++++++++++++++++++ docs/modules/ROOT/pages/working-copies.adoc | 10 +++--- 7 files changed, 52 insertions(+), 5 deletions(-) create mode 100644 docs/modules/ROOT/assets/images/WorkingCopy_1.svg create mode 100644 docs/modules/ROOT/assets/images/WorkingCopy_2.svg create mode 100644 docs/modules/ROOT/pages/known-issues.adoc create mode 100644 docs/modules/ROOT/pages/migration.adoc diff --git a/docs/modules/ROOT/assets/images/WorkingCopy_1.svg b/docs/modules/ROOT/assets/images/WorkingCopy_1.svg new file mode 100644 index 00000000..1a26daa4 --- /dev/null +++ b/docs/modules/ROOT/assets/images/WorkingCopy_1.svg @@ -0,0 +1,4 @@ + + + +
Native behavior of EclipseStore
Native behavior of EclipseStore
EclipseStore
Data
Eclipse...
User
Application
User...
Memory
Memory
Load from
and store to
L...
Load from 
and store to
L...
Java Objects from EclipseStore
Java Objects from EclipseStore
Person
Person
Invoice
Invoice
Warehouse
Warehouse
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/modules/ROOT/assets/images/WorkingCopy_2.svg b/docs/modules/ROOT/assets/images/WorkingCopy_2.svg new file mode 100644 index 00000000..8fd645c0 --- /dev/null +++ b/docs/modules/ROOT/assets/images/WorkingCopy_2.svg @@ -0,0 +1,4 @@ + + + +
Behavior of EclipseStore with Spring-Data-Eclipse-Store
Behavior of EclipseStore with Spring-Data-Eclipse-Store
EclipseStore
Data
Eclipse...
User
Application
User...
Memory
Memory
Load from
and store to
L...
Load from 
and store to
L...
Data from EclipseStore
Data from EclipseStore
Person
Person
Invoice
Invoice
Warehouse
Warehouse
Working Copy of Data
Working Copy of Data
Load data
and create 
working copy
Load data...
Store data
back to
original data
Store data...
Person
Person
Invoice
Invoice
Warehouse
Warehouse
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/modules/ROOT/nav.adoc b/docs/modules/ROOT/nav.adoc index c3318e55..8fd7ab9b 100644 --- a/docs/modules/ROOT/nav.adoc +++ b/docs/modules/ROOT/nav.adoc @@ -1,3 +1,5 @@ * xref:index.adoc[Home] * xref:installation.adoc[Installation] * xref:working-copies.adoc[Working Copies] +* xref:migration.adoc[Migration] +* xref:known-issues.adoc[Known issues] diff --git a/docs/modules/ROOT/pages/installation.adoc b/docs/modules/ROOT/pages/installation.adoc index 7e77c552..48ddee02 100644 --- a/docs/modules/ROOT/pages/installation.adoc +++ b/docs/modules/ROOT/pages/installation.adoc @@ -42,4 +42,4 @@ To see how easy it is to implement EclipseStore in your Spring project, take a l A https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/simple[simple], a more https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex[complex demo] and a https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-jpa/src/main/java/software/xdev/spring/data/eclipse/store/jpa[demo with coexisting JPA]. == Drop in compatible [[drop-in-compatible]] - +//TODO diff --git a/docs/modules/ROOT/pages/known-issues.adoc b/docs/modules/ROOT/pages/known-issues.adoc new file mode 100644 index 00000000..f60ff7cf --- /dev/null +++ b/docs/modules/ROOT/pages/known-issues.adoc @@ -0,0 +1,4 @@ += Known issues + + +//TODO diff --git a/docs/modules/ROOT/pages/migration.adoc b/docs/modules/ROOT/pages/migration.adoc new file mode 100644 index 00000000..09aa70a6 --- /dev/null +++ b/docs/modules/ROOT/pages/migration.adoc @@ -0,0 +1,31 @@ += Migration + +Migrating from Spring Data JPA is very easy. +We implemented a https://github.com/xdev-software/spring-data-eclipse-store-migration[OpenRewrite recipe] for that. +It can be executed with a simple Maven command: + +[source,title="Maven"] +---- +mvn org.openrewrite.maven:rewrite-maven-plugin:run \ +-Drewrite.recipeArtifactCoordinates=software.xdev:spring-data-eclipse-store-migration \ +-Drewrite.activeRecipes=software.xdev.spring.data.eclipse.store.JpaMigration +---- + +== Data + +To import data from different data sources like JPA, you can simply let the ``EclipseStoreDataImporterComponent`` get injected and then call ``importData()``. +This reads all instances of ``EntityManagerFactory``, creates EclipseStoreRepositories for it and then imports that data. +This can take quite some time if you have a lot of data. + +[source,java,title="Maven"] +---- + @Autowired + private EclipseStoreDataImporterComponent eclipseStoreDataImporter; + + void importDataFromJpaToEclipseStore() + { + final List> repositories = this.eclipseStoreDataImporter.importData(); + } +---- + +After that you can change your JpaRepositories to EclipseStoreRepositories and you're done. diff --git a/docs/modules/ROOT/pages/working-copies.adoc b/docs/modules/ROOT/pages/working-copies.adoc index b639839f..929aabfa 100644 --- a/docs/modules/ROOT/pages/working-copies.adoc +++ b/docs/modules/ROOT/pages/working-copies.adoc @@ -2,11 +2,13 @@ If you use EclipseStore without our library, EclipseStore loads the data from the datastore directly into memory. You make your changes on these loaded Java objects and by calling ``store`` EclipseStore writes it directly from memory to the datastore. -![Native behavior of EclipseStore](assets/WorkingCopy_1.svg) +image::../images/WorkingCopy_1.svg[Native behavior of EclipseStore] -If you e.g. change the address of a person, the changed address is already in your data model, **even before storing** this person. +If you e.g. change the address of a person, the changed address is already in your data model, *even before storing* this person. This is very different from the behavior a Spring user expects. -With *Spring-Data-Eclipse-Store* every time an object is loaded from the datastore, a working copy of that object (or rather the object tree) is created and returned to the user. Therefore, the user can make the changes on the working copy without any changes to the actual data model. The changes are only persisted after calling ``save`` on a repository. +With {product-name} every time an object is loaded from the datastore, a working copy of that object (or rather the object tree) is created and returned to the user. +Therefore, the user can make the changes on the working copy without any changes to the actual data model. +The changes are only persisted after calling ``save`` on a repository. -![Behavior of EclipseStore with Spring-Data-Eclipse-Store](assets/WorkingCopy_2.svg) +image::../images/WorkingCopy_2.svg[Behavior of EclipseStore with Spring-Data-Eclipse-Store] From ce893a5d3867fb58d6332ac53b838acfb31d524d Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 5 Mar 2024 10:25:22 +0100 Subject: [PATCH 05/98] Added more docs --- docs/modules/ROOT/pages/known-issues.adoc | 37 ++++++++++++++++++++- docs/modules/ROOT/pages/migration.adoc | 19 +++++++---- docs/modules/ROOT/pages/working-copies.adoc | 3 +- 3 files changed, 50 insertions(+), 9 deletions(-) diff --git a/docs/modules/ROOT/pages/known-issues.adoc b/docs/modules/ROOT/pages/known-issues.adoc index f60ff7cf..54706e47 100644 --- a/docs/modules/ROOT/pages/known-issues.adoc +++ b/docs/modules/ROOT/pages/known-issues.adoc @@ -1,4 +1,39 @@ = Known issues +== Lazy references -//TODO +One of the core features of EclipseStore is its https://docs.eclipsestore.io/manual/storage/loading-data/lazy-loading/index.html[Lazy references]. +Unfortunately this requires our library to implement some kind of proxy. +That's something that takes a lot of effort to implement in our {product-name}. + +We created https://github.com/xdev-software/spring-data-eclipse-store/issues/31[an issue] for that but right now we *do not support Lazy references*. + +== Query annotations + +In Spring-Data-JPA you can write a Query over methods of repositories like this: + +[source,java,title="From https://github.com/spring-projects/spring-petclinic/blob/main/src/main/java/org/springframework/samples/petclinic/owner/OwnerRepository.java[spring-petclinic]"] +---- +@Query("SELECT ptype FROM PetType ptype ORDER BY ptype.name") +List findPetTypes(); +---- + +We created https://github.com/xdev-software/spring-data-eclipse-store/issues/32[an issue] for that but right now we *do not support Query annotations*. + +== Data changes + +There are two basic ways to keep your data up to date. + +=== Structural + +As with most projects, data that needs persisting changes over time. +In EclipseStore that's handled through https://docs.eclipsestore.io/manual/storage/legacy-type-mapping/index.html[Legacy Type Mapping]. + +That consists of https://docs.eclipsestore.io/manual/storage/legacy-type-mapping/index.html#_automatic_mapping[Automatic Mapping] through EclipseStores internal heuristic and https://docs.eclipsestore.io/manual/storage/legacy-type-mapping/index.html#explicit-mapping[Explicit Mapping] by the user. + +=== Values + +There is a library to version your data in the store called https://github.com/xdev-software/micro-migration[XDEV MicroMigration]. +This helps you keep your data up to date regardless of the current version. + +We created https://github.com/xdev-software/spring-data-eclipse-store/issues/33[an issue] for that but right now we *do not support XDEVs MicroMigration*. diff --git a/docs/modules/ROOT/pages/migration.adoc b/docs/modules/ROOT/pages/migration.adoc index 09aa70a6..24148348 100644 --- a/docs/modules/ROOT/pages/migration.adoc +++ b/docs/modules/ROOT/pages/migration.adoc @@ -11,21 +11,26 @@ mvn org.openrewrite.maven:rewrite-maven-plugin:run \ -Drewrite.activeRecipes=software.xdev.spring.data.eclipse.store.JpaMigration ---- +[CAUTION] +==== +Since {product-name} can't handle ``@Query``-Annotations, these annotations are getting removed by the Rewrite-Recipe. +==== + == Data To import data from different data sources like JPA, you can simply let the ``EclipseStoreDataImporterComponent`` get injected and then call ``importData()``. This reads all instances of ``EntityManagerFactory``, creates EclipseStoreRepositories for it and then imports that data. This can take quite some time if you have a lot of data. -[source,java,title="Maven"] +[source,java] ---- - @Autowired - private EclipseStoreDataImporterComponent eclipseStoreDataImporter; +@Autowired +private EclipseStoreDataImporterComponent eclipseStoreDataImporter; - void importDataFromJpaToEclipseStore() - { - final List> repositories = this.eclipseStoreDataImporter.importData(); - } +void importDataFromJpaToEclipseStore() +{ + final List> repositories = this.eclipseStoreDataImporter.importData(); +} ---- After that you can change your JpaRepositories to EclipseStoreRepositories and you're done. diff --git a/docs/modules/ROOT/pages/working-copies.adoc b/docs/modules/ROOT/pages/working-copies.adoc index 929aabfa..1ac4c86a 100644 --- a/docs/modules/ROOT/pages/working-copies.adoc +++ b/docs/modules/ROOT/pages/working-copies.adoc @@ -7,8 +7,9 @@ image::../images/WorkingCopy_1.svg[Native behavior of EclipseStore] If you e.g. change the address of a person, the changed address is already in your data model, *even before storing* this person. This is very different from the behavior a Spring user expects. +image::../images/WorkingCopy_2.svg[Behavior of EclipseStore with Spring-Data-Eclipse-Store] + With {product-name} every time an object is loaded from the datastore, a working copy of that object (or rather the object tree) is created and returned to the user. Therefore, the user can make the changes on the working copy without any changes to the actual data model. The changes are only persisted after calling ``save`` on a repository. -image::../images/WorkingCopy_2.svg[Behavior of EclipseStore with Spring-Data-Eclipse-Store] From 1be668aea84d191d5b4698c92e679ac86a013ce9 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 5 Mar 2024 10:47:31 +0100 Subject: [PATCH 06/98] Adjust Antora GitHub Action --- .github/workflows/antora-build.yml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/antora-build.yml b/.github/workflows/antora-build.yml index 2781a576..ab0cf21b 100644 --- a/.github/workflows/antora-build.yml +++ b/.github/workflows/antora-build.yml @@ -1,6 +1,9 @@ name: Antora Documentation Build # Name of the GitHub Actions workflow -on: workflow_dispatch # This workflow is triggered manually +on: + workflow_dispatch: + branches: + - develop env: ACTIONS_STEP_DEBUG : true @@ -32,7 +35,7 @@ jobs: run: npm i antora @antora/lunr-extension - name: Generate Site # Step to generate the documentation site - run: GIT_CREDENTIALS=https://${{ secrets.GITHUB_TOKEN }}:@github.com npx antora docs/antora-playbook.yml --fetch --stacktrace #GIT_CREDENTIALS are needed if the source repo with the documentation is private! + run: GIT_CREDENTIALS=https://${{ secrets.GITHUB_TOKEN }}:@github.com#${{ github.ref }} npx antora docs/antora-playbook.yml --fetch --stacktrace #GIT_CREDENTIALS are needed if the source repo with the documentation is private! - name: Setup Pages # Step to set up GitHub Pages uses: actions/configure-pages@v3 From 74024847a89aa4eb278c5155153ab45f53aee588 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 5 Mar 2024 10:50:47 +0100 Subject: [PATCH 07/98] Adjust Antora GitHub Action --- .github/workflows/antora-build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/antora-build.yml b/.github/workflows/antora-build.yml index ab0cf21b..817fd686 100644 --- a/.github/workflows/antora-build.yml +++ b/.github/workflows/antora-build.yml @@ -35,7 +35,7 @@ jobs: run: npm i antora @antora/lunr-extension - name: Generate Site # Step to generate the documentation site - run: GIT_CREDENTIALS=https://${{ secrets.GITHUB_TOKEN }}:@github.com#${{ github.ref }} npx antora docs/antora-playbook.yml --fetch --stacktrace #GIT_CREDENTIALS are needed if the source repo with the documentation is private! + run: GIT_CREDENTIALS=https://${{ secrets.GITHUB_TOKEN }}:@github.com npx antora docs/antora-playbook.yml --fetch=${{ github.ref }} --stacktrace #GIT_CREDENTIALS are needed if the source repo with the documentation is private! - name: Setup Pages # Step to set up GitHub Pages uses: actions/configure-pages@v3 From 836a9055e4e2c81ec153a359ec473a7d98d453c6 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 5 Mar 2024 10:54:10 +0100 Subject: [PATCH 08/98] Adjust Antora GitHub Action --- .github/workflows/antora-build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/antora-build.yml b/.github/workflows/antora-build.yml index 817fd686..0289cb67 100644 --- a/.github/workflows/antora-build.yml +++ b/.github/workflows/antora-build.yml @@ -35,7 +35,7 @@ jobs: run: npm i antora @antora/lunr-extension - name: Generate Site # Step to generate the documentation site - run: GIT_CREDENTIALS=https://${{ secrets.GITHUB_TOKEN }}:@github.com npx antora docs/antora-playbook.yml --fetch=${{ github.ref }} --stacktrace #GIT_CREDENTIALS are needed if the source repo with the documentation is private! + run: npx antora docs/antora-playbook.yml - name: Setup Pages # Step to set up GitHub Pages uses: actions/configure-pages@v3 From 95f5d1af811f602ae62b14024cf5d309c5771498 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 5 Mar 2024 11:04:25 +0100 Subject: [PATCH 09/98] Adjust Antora GitHub Action --- .github/workflows/antora-build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/antora-build.yml b/.github/workflows/antora-build.yml index 0289cb67..55425d7c 100644 --- a/.github/workflows/antora-build.yml +++ b/.github/workflows/antora-build.yml @@ -35,7 +35,7 @@ jobs: run: npm i antora @antora/lunr-extension - name: Generate Site # Step to generate the documentation site - run: npx antora docs/antora-playbook.yml + run: npx antora ./docs/antora-playbook.yml - name: Setup Pages # Step to set up GitHub Pages uses: actions/configure-pages@v3 From bdae87e737c8387c2af8f0d46897eeda8233ccaf Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 5 Mar 2024 11:16:44 +0100 Subject: [PATCH 10/98] Adjust Antora GitHub Action --- .github/workflows/antora-build.yml | 4 +--- docs/antora-playbook.yml | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/antora-build.yml b/.github/workflows/antora-build.yml index 55425d7c..40f8a7fb 100644 --- a/.github/workflows/antora-build.yml +++ b/.github/workflows/antora-build.yml @@ -2,8 +2,6 @@ name: Antora Documentation Build # Name of the GitHub Actions workflow on: workflow_dispatch: - branches: - - develop env: ACTIONS_STEP_DEBUG : true @@ -35,7 +33,7 @@ jobs: run: npm i antora @antora/lunr-extension - name: Generate Site # Step to generate the documentation site - run: npx antora ./docs/antora-playbook.yml + run: npx antora docs/antora-playbook.yml - name: Setup Pages # Step to set up GitHub Pages uses: actions/configure-pages@v3 diff --git a/docs/antora-playbook.yml b/docs/antora-playbook.yml index f8090254..1c388c23 100644 --- a/docs/antora-playbook.yml +++ b/docs/antora-playbook.yml @@ -20,7 +20,7 @@ content: - url: https://github.com/xdev-software/spring-data-eclipse-store start_path: docs branches: - - "master" + - "develop" ui: bundle: From 4d16e4c49b48eae97de53b6333e7c5ec1fb2a9be Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 5 Mar 2024 11:24:37 +0100 Subject: [PATCH 11/98] Add Antora Docs for check build --- .github/workflows/antora-build.yml | 31 +++++++++++++++--------------- .github/workflows/checkBuild.yml | 18 +++++++++++++++++ 2 files changed, 33 insertions(+), 16 deletions(-) diff --git a/.github/workflows/antora-build.yml b/.github/workflows/antora-build.yml index 40f8a7fb..c648762a 100644 --- a/.github/workflows/antora-build.yml +++ b/.github/workflows/antora-build.yml @@ -1,4 +1,4 @@ -name: Antora Documentation Build # Name of the GitHub Actions workflow +name: Antora Documentation Build on: workflow_dispatch: @@ -14,39 +14,38 @@ permissions: jobs: build: - runs-on: ubuntu-latest # Run the job on a machine with the latest version of Ubuntu + runs-on: ubuntu-latest environment: - name: github-pages # Environment name - url: https://github.com/xdev-software/spring-data-eclipse-store + name: github-pages steps: - - name: Checkout repository # Step to check out the repository + - name: Checkout repository uses: actions/checkout@v4 - - name: Install Node.js # Step to install Node.js + - name: Install Node.js uses: actions/setup-node@v3 with: - node-version: 18 # Specify Node.js version + node-version: 18 - - name: Install Antora and the Antora Lunr Extension # Step to install Antora and the Lunr extension + - name: Install Antora and the Antora Lunr Extension run: npm i antora @antora/lunr-extension - - name: Generate Site # Step to generate the documentation site + - name: Generate Site run: npx antora docs/antora-playbook.yml - - name: Setup Pages # Step to set up GitHub Pages + - name: Setup Pages uses: actions/configure-pages@v3 - - name: Upload artifact # Step to upload an artifact + - name: Upload artifact uses: actions/upload-pages-artifact@v2 with: - name: site # Specify the name of the artifact - path: docs/site # Specify the path to the artifact + name: site + path: docs/site - - name: Deploy to GitHub Pages # Step to deploy the site to GitHub Pages + - name: Deploy to GitHub Pages id: deployment uses: actions/deploy-pages@v2 with: - token: ${{ secrets.GITHUB_TOKEN }} # Specify the GitHub token for deployment - artifact_name: site # Specify the name of the artifact to deploy + token: ${{ secrets.GITHUB_TOKEN }} + artifact_name: site diff --git a/.github/workflows/checkBuild.yml b/.github/workflows/checkBuild.yml index da4fbd43..691c26a8 100644 --- a/.github/workflows/checkBuild.yml +++ b/.github/workflows/checkBuild.yml @@ -90,3 +90,21 @@ jobs: - name: Run Checkstyle run: mvn -B checkstyle:check -P checkstyle -T2C + + docs: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + + - name: Install Node.js + uses: actions/setup-node@v3 + with: + node-version: 18 + + - name: Install Antora and the Antora Lunr Extension + run: npm i antora @antora/lunr-extension + + - name: Generate Site + run: npx antora docs/antora-playbook.yml + From 55f886f305091114f5b7fd5d24753b289bf1fc01 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 5 Mar 2024 11:24:45 +0100 Subject: [PATCH 12/98] Fix doc images --- docs/modules/ROOT/pages/working-copies.adoc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/modules/ROOT/pages/working-copies.adoc b/docs/modules/ROOT/pages/working-copies.adoc index 1ac4c86a..b4a0f3b7 100644 --- a/docs/modules/ROOT/pages/working-copies.adoc +++ b/docs/modules/ROOT/pages/working-copies.adoc @@ -2,12 +2,12 @@ If you use EclipseStore without our library, EclipseStore loads the data from the datastore directly into memory. You make your changes on these loaded Java objects and by calling ``store`` EclipseStore writes it directly from memory to the datastore. -image::../images/WorkingCopy_1.svg[Native behavior of EclipseStore] +image::WorkingCopy_1.svg[Native behavior of EclipseStore] If you e.g. change the address of a person, the changed address is already in your data model, *even before storing* this person. This is very different from the behavior a Spring user expects. -image::../images/WorkingCopy_2.svg[Behavior of EclipseStore with Spring-Data-Eclipse-Store] +image::WorkingCopy_2.svg[Behavior of EclipseStore with Spring-Data-Eclipse-Store] With {product-name} every time an object is loaded from the datastore, a working copy of that object (or rather the object tree) is created and returned to the user. Therefore, the user can make the changes on the working copy without any changes to the actual data model. From 666db36af3f54adb9fff7cec81252558c5d63efa Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 5 Mar 2024 11:43:18 +0100 Subject: [PATCH 13/98] Adjust Antora GitHub Action --- .github/workflows/antora-build.yml | 6 +++--- docs/antora.yml | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/antora-build.yml b/.github/workflows/antora-build.yml index c648762a..550871b4 100644 --- a/.github/workflows/antora-build.yml +++ b/.github/workflows/antora-build.yml @@ -40,12 +40,12 @@ jobs: - name: Upload artifact uses: actions/upload-pages-artifact@v2 with: - name: site - path: docs/site + name: manual + path: docs/site/manual - name: Deploy to GitHub Pages id: deployment uses: actions/deploy-pages@v2 with: token: ${{ secrets.GITHUB_TOKEN }} - artifact_name: site + artifact_name: manual diff --git a/docs/antora.yml b/docs/antora.yml index ebd3a7dd..7462a22c 100644 --- a/docs/antora.yml +++ b/docs/antora.yml @@ -1,7 +1,7 @@ name: manual title: Spring-Data-Eclipse-Store version: master -display_version: '1.0' +display_version: '1.0.3' start_page: index.adoc nav: - modules/ROOT/nav.adoc From fc28d131e4d90ad4dd9d403661769cba29cb66b3 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 5 Mar 2024 11:50:51 +0100 Subject: [PATCH 14/98] Adjust Antora GitHub Action --- .github/workflows/antora-build.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/antora-build.yml b/.github/workflows/antora-build.yml index 550871b4..c648762a 100644 --- a/.github/workflows/antora-build.yml +++ b/.github/workflows/antora-build.yml @@ -40,12 +40,12 @@ jobs: - name: Upload artifact uses: actions/upload-pages-artifact@v2 with: - name: manual - path: docs/site/manual + name: site + path: docs/site - name: Deploy to GitHub Pages id: deployment uses: actions/deploy-pages@v2 with: token: ${{ secrets.GITHUB_TOKEN }} - artifact_name: manual + artifact_name: site From 970eaf21a47aa6a63b9e7bbaf0a38bd05b9195ab Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 5 Mar 2024 12:37:31 +0100 Subject: [PATCH 15/98] Adjust Antora GitHub Action --- docs/antora.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/antora.yml b/docs/antora.yml index 7462a22c..c7ed9c14 100644 --- a/docs/antora.yml +++ b/docs/antora.yml @@ -1,4 +1,4 @@ -name: manual +name: ROOT title: Spring-Data-Eclipse-Store version: master display_version: '1.0.3' From 44e4daaa33d5486d46b3213cb5bf0461d9a1d78b Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 5 Mar 2024 13:28:31 +0100 Subject: [PATCH 16/98] Adjusted Readme and extended docs --- README.md | 27 ++-- assets/WorkingCopy_1.svg | 4 - assets/WorkingCopy_2.svg | 4 - docs/modules/ROOT/assets/images/Logo.svg | 154 ++++++++++++++++++++++ docs/modules/ROOT/pages/index.adoc | 6 +- docs/modules/ROOT/pages/installation.adoc | 4 +- 6 files changed, 169 insertions(+), 30 deletions(-) delete mode 100644 assets/WorkingCopy_1.svg delete mode 100644 assets/WorkingCopy_2.svg create mode 100644 docs/modules/ROOT/assets/images/Logo.svg diff --git a/README.md b/README.md index 40cf0f50..28b5aded 100644 --- a/README.md +++ b/README.md @@ -19,8 +19,9 @@ The library provides following features: * Enforces the **[Spring data repository concept](https://docs.spring.io/spring-data/jpa/reference/repositories/core-concepts.html)** - for EclipseStore by using [working copies](#working-copies) -* **[Drop in compatible](#usage)** for your existing Spring application + for EclipseStore by + using [working copies](https://xdev-software.github.io/spring-data-eclipse-store/working-copies.html) +* **[Drop in compatible](https://xdev-software.github.io/spring-data-eclipse-store/installation.html#drop-in-compatible)** for your existing Spring application * Utilizes **ultra-fast EclipseStore serializing and storing** * Enables your application to **select any [EclipseStore target](https://docs.eclipsestore.io/manual/storage/storage-targets/index.html)** (e.g. @@ -37,21 +38,13 @@ GB of data are stored. ([IBM Cloud Pricing](https://cloud.ibm.com/estimator/esti AWS. ([AWS Pricing Calculator](https://calculator.aws/#/estimate?id=ab85cddf77f0d1aa0457111ed82785dfb836b1d8), as of 08.01.2024) -### Working copies +## Installation & Usage -If you use EclipseStore without our library, EclipseStore loads the data from the datastore directly into memory. You make your changes on these loaded Java objects and by calling ``store`` EclipseStore writes it directly from memory to the datastore. +[**Installation +guide** for the latest release](https://github.com/xdev-software/spring-data-eclipse-store/releases/latest#Installation) -![Native behavior of EclipseStore](assets/WorkingCopy_1.svg) - -If you e.g. change the address of a person, the changed address is already in your data model, **even before storing** this person. -This is very different from the behavior a Spring user expects. - -With *Spring-Data-Eclipse-Store* every time an object is loaded from the datastore, a working copy of that object (or rather the object tree) is created and returned to the user. Therefore, the user can make the changes on the working copy without any changes to the actual data model. The changes are only persisted after calling ``save`` on a repository. - -![Behavior of EclipseStore with Spring-Data-Eclipse-Store](assets/WorkingCopy_2.svg) - -## Installation -[Installation guide for the latest release](https://github.com/xdev-software/spring-data-eclipse-store/releases/latest#Installation) +[**Detailed +instructions** are in the documentation](https://xdev-software.github.io/spring-data-eclipse-store/installation.html) ### Supported versions @@ -60,10 +53,6 @@ With *Spring-Data-Eclipse-Store* every time an object is loaded from the datasto | ``<= 1.0.2`` | ``17`` | ``3.2.2`` | ``1.1.0`` | | ``1.0.3`` | ``17`` | ``3.2.3`` | ``1.2.0`` | -### Usage - -After adding the library in your dependencies, using it is as easy as adding the ``@EnableEclipseStoreRepositories`` annotation to your ``@SpringBootApplication`` annotation. - ## Demo To see how easy it is to implement EclipseStore in your Spring project, take a look at the three diff --git a/assets/WorkingCopy_1.svg b/assets/WorkingCopy_1.svg deleted file mode 100644 index 1a26daa4..00000000 --- a/assets/WorkingCopy_1.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - -
Native behavior of EclipseStore
Native behavior of EclipseStore
EclipseStore
Data
Eclipse...
User
Application
User...
Memory
Memory
Load from
and store to
L...
Load from 
and store to
L...
Java Objects from EclipseStore
Java Objects from EclipseStore
Person
Person
Invoice
Invoice
Warehouse
Warehouse
Text is not SVG - cannot display
\ No newline at end of file diff --git a/assets/WorkingCopy_2.svg b/assets/WorkingCopy_2.svg deleted file mode 100644 index 8fd645c0..00000000 --- a/assets/WorkingCopy_2.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - -
Behavior of EclipseStore with Spring-Data-Eclipse-Store
Behavior of EclipseStore with Spring-Data-Eclipse-Store
EclipseStore
Data
Eclipse...
User
Application
User...
Memory
Memory
Load from
and store to
L...
Load from 
and store to
L...
Data from EclipseStore
Data from EclipseStore
Person
Person
Invoice
Invoice
Warehouse
Warehouse
Working Copy of Data
Working Copy of Data
Load data
and create 
working copy
Load data...
Store data
back to
original data
Store data...
Person
Person
Invoice
Invoice
Warehouse
Warehouse
Text is not SVG - cannot display
\ No newline at end of file diff --git a/docs/modules/ROOT/assets/images/Logo.svg b/docs/modules/ROOT/assets/images/Logo.svg new file mode 100644 index 00000000..042c2710 --- /dev/null +++ b/docs/modules/ROOT/assets/images/Logo.svg @@ -0,0 +1,154 @@ + + + diff --git a/docs/modules/ROOT/pages/index.adoc b/docs/modules/ROOT/pages/index.adoc index e53034a1..58fc8243 100644 --- a/docs/modules/ROOT/pages/index.adoc +++ b/docs/modules/ROOT/pages/index.adoc @@ -1,8 +1,10 @@ = Overview -== About Spring-Data-Eclipse-Store +image::Logo.svg[Logo XDEV Spring-Data-Eclipse-Store,200] -A library to simplify using https://eclipsestore.io/[EclipseStore] in the https://spring.io/projects/spring-data/[Spring environment]. +== About {product-name} + +A Open-Source library to simplify using https://eclipsestore.io/[EclipseStore] in a https://spring.io/projects/spring-data/[Spring environment]. What makes this library special is, that it creates a xref:working-copies.adoc[working copy] of the data. This way EclipseStore behaves almost exactly like relational database from a coding perspective. diff --git a/docs/modules/ROOT/pages/installation.adoc b/docs/modules/ROOT/pages/installation.adoc index 48ddee02..fdd469b3 100644 --- a/docs/modules/ROOT/pages/installation.adoc +++ b/docs/modules/ROOT/pages/installation.adoc @@ -42,4 +42,6 @@ To see how easy it is to implement EclipseStore in your Spring project, take a l A https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/simple[simple], a more https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex[complex demo] and a https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-jpa/src/main/java/software/xdev/spring/data/eclipse/store/jpa[demo with coexisting JPA]. == Drop in compatible [[drop-in-compatible]] -//TODO + +After adding the dependency and the annotation you are ready to go. +This makes this library drop in compatible for Spring-Data projects. From 0a730dab64995e85904aabfbc93b17376555b644 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 5 Mar 2024 13:48:03 +0100 Subject: [PATCH 17/98] Minified logo --- docs/modules/ROOT/assets/images/Logo.svg | 155 +---------------------- 1 file changed, 1 insertion(+), 154 deletions(-) diff --git a/docs/modules/ROOT/assets/images/Logo.svg b/docs/modules/ROOT/assets/images/Logo.svg index 042c2710..79b8e3ec 100644 --- a/docs/modules/ROOT/assets/images/Logo.svg +++ b/docs/modules/ROOT/assets/images/Logo.svg @@ -1,154 +1 @@ - - - + \ No newline at end of file From d05e769006436635f53c555ad9f73108b9501ff7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 6 Mar 2024 00:25:31 +0000 Subject: [PATCH 18/98] Bump actions/setup-node from 3 to 4 Bumps [actions/setup-node](https://github.com/actions/setup-node) from 3 to 4. - [Release notes](https://github.com/actions/setup-node/releases) - [Commits](https://github.com/actions/setup-node/compare/v3...v4) --- updated-dependencies: - dependency-name: actions/setup-node dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/antora-build.yml | 2 +- .github/workflows/checkBuild.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/antora-build.yml b/.github/workflows/antora-build.yml index c648762a..cb705b24 100644 --- a/.github/workflows/antora-build.yml +++ b/.github/workflows/antora-build.yml @@ -24,7 +24,7 @@ jobs: uses: actions/checkout@v4 - name: Install Node.js - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: node-version: 18 diff --git a/.github/workflows/checkBuild.yml b/.github/workflows/checkBuild.yml index 691c26a8..770c009c 100644 --- a/.github/workflows/checkBuild.yml +++ b/.github/workflows/checkBuild.yml @@ -98,7 +98,7 @@ jobs: - uses: actions/checkout@v4 - name: Install Node.js - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: node-version: 18 From 95034bbad5afe242c3caebb5a0089410b8d2b37a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 6 Mar 2024 00:25:39 +0000 Subject: [PATCH 19/98] Bump actions/deploy-pages from 2 to 4 Bumps [actions/deploy-pages](https://github.com/actions/deploy-pages) from 2 to 4. - [Release notes](https://github.com/actions/deploy-pages/releases) - [Commits](https://github.com/actions/deploy-pages/compare/v2...v4) --- updated-dependencies: - dependency-name: actions/deploy-pages dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/antora-build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/antora-build.yml b/.github/workflows/antora-build.yml index c648762a..db0bb9a6 100644 --- a/.github/workflows/antora-build.yml +++ b/.github/workflows/antora-build.yml @@ -45,7 +45,7 @@ jobs: - name: Deploy to GitHub Pages id: deployment - uses: actions/deploy-pages@v2 + uses: actions/deploy-pages@v4 with: token: ${{ secrets.GITHUB_TOKEN }} artifact_name: site From 0c05dfed6222b6b327c09a23ea701724fbdbb559 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 6 Mar 2024 00:25:47 +0000 Subject: [PATCH 20/98] Bump actions/configure-pages from 3 to 4 Bumps [actions/configure-pages](https://github.com/actions/configure-pages) from 3 to 4. - [Release notes](https://github.com/actions/configure-pages/releases) - [Commits](https://github.com/actions/configure-pages/compare/v3...v4) --- updated-dependencies: - dependency-name: actions/configure-pages dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/antora-build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/antora-build.yml b/.github/workflows/antora-build.yml index c648762a..00d23321 100644 --- a/.github/workflows/antora-build.yml +++ b/.github/workflows/antora-build.yml @@ -35,7 +35,7 @@ jobs: run: npx antora docs/antora-playbook.yml - name: Setup Pages - uses: actions/configure-pages@v3 + uses: actions/configure-pages@v4 - name: Upload artifact uses: actions/upload-pages-artifact@v2 From 4c16be424609151c363b969606c04f53244fc392 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 6 Mar 2024 00:25:56 +0000 Subject: [PATCH 21/98] Bump actions/upload-pages-artifact from 2 to 3 Bumps [actions/upload-pages-artifact](https://github.com/actions/upload-pages-artifact) from 2 to 3. - [Release notes](https://github.com/actions/upload-pages-artifact/releases) - [Commits](https://github.com/actions/upload-pages-artifact/compare/v2...v3) --- updated-dependencies: - dependency-name: actions/upload-pages-artifact dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/antora-build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/antora-build.yml b/.github/workflows/antora-build.yml index c648762a..4f571e3c 100644 --- a/.github/workflows/antora-build.yml +++ b/.github/workflows/antora-build.yml @@ -38,7 +38,7 @@ jobs: uses: actions/configure-pages@v3 - name: Upload artifact - uses: actions/upload-pages-artifact@v2 + uses: actions/upload-pages-artifact@v3 with: name: site path: docs/site From 4be49328f632217e02c2b7194e63507389a8af9f Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Wed, 6 Mar 2024 08:30:04 +0100 Subject: [PATCH 22/98] Dual Storage: Implemented basic structure --- .run/Run Dual Storage Demo.run.xml | 17 ++++++ .../storage/DualStorageDemoApplication.java | 58 +++++++++++++++++++ .../demo/dual/storage/invoice/Invoice.java | 5 ++ .../storage/invoice/InvoiceRepository.java | 8 +++ .../PersistenceInvoiceConfiguration.java | 12 ++++ .../PersistencePersonConfiguration.java | 12 ++++ .../demo/dual/storage/person/Person.java | 5 ++ .../dual/storage/person/PersonRepository.java | 8 +++ 8 files changed, 125 insertions(+) create mode 100644 .run/Run Dual Storage Demo.run.xml create mode 100644 spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/DualStorageDemoApplication.java create mode 100644 spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/Invoice.java create mode 100644 spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/InvoiceRepository.java create mode 100644 spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/PersistenceInvoiceConfiguration.java create mode 100644 spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/PersistencePersonConfiguration.java create mode 100644 spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/Person.java create mode 100644 spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/PersonRepository.java diff --git a/.run/Run Dual Storage Demo.run.xml b/.run/Run Dual Storage Demo.run.xml new file mode 100644 index 00000000..65f11f49 --- /dev/null +++ b/.run/Run Dual Storage Demo.run.xml @@ -0,0 +1,17 @@ + + + + \ No newline at end of file diff --git a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/DualStorageDemoApplication.java b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/DualStorageDemoApplication.java new file mode 100644 index 00000000..92c1faec --- /dev/null +++ b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/DualStorageDemoApplication.java @@ -0,0 +1,58 @@ +package software.xdev.spring.data.eclipse.store.demo.dual.storage; + +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; +import org.springframework.boot.CommandLineRunner; +import org.springframework.boot.SpringApplication; +import org.springframework.boot.autoconfigure.SpringBootApplication; +import org.springframework.context.ConfigurableApplicationContext; + +import software.xdev.spring.data.eclipse.store.demo.dual.storage.invoice.Invoice; +import software.xdev.spring.data.eclipse.store.demo.dual.storage.invoice.InvoiceRepository; +import software.xdev.spring.data.eclipse.store.demo.dual.storage.person.Person; +import software.xdev.spring.data.eclipse.store.demo.dual.storage.person.PersonRepository; + + +@SpringBootApplication +public class DualStorageDemoApplication implements CommandLineRunner +{ + private static final Logger LOG = LoggerFactory.getLogger(DualStorageDemoApplication.class); + private final InvoiceRepository invoiceRepository; + private final PersonRepository personRepository; + + public DualStorageDemoApplication( + final InvoiceRepository invoiceRepository, + final PersonRepository personRepository) + { + this.invoiceRepository = invoiceRepository; + this.personRepository = personRepository; + } + + public static void main(final String[] args) + { + final ConfigurableApplicationContext run = SpringApplication.run(DualStorageDemoApplication.class, args); + run.close(); + } + + @Override + public void run(final String... args) + { + LOG.info("----Invoices-BeforeDeleteAll----"); + this.invoiceRepository.findAll().forEach(i -> LOG.info(i.toString())); + this.invoiceRepository.deleteAll(); + + LOG.info("----Invoices-AfterDeleteAll----"); + this.invoiceRepository.findAll().forEach(i -> LOG.info(i.toString())); + + this.invoiceRepository.save(new Invoice("N1", 100.0)); + + LOG.info("----Persons-BeforeDeleteAll----"); + this.personRepository.findAll().forEach(i -> LOG.info(i.toString())); + this.personRepository.deleteAll(); + + LOG.info("----Persons-AfterDeleteAll----"); + this.personRepository.findAll().forEach(i -> LOG.info(i.toString())); + + this.personRepository.save(new Person("Stevie", "Nicks")); + } +} diff --git a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/Invoice.java b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/Invoice.java new file mode 100644 index 00000000..1bf25541 --- /dev/null +++ b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/Invoice.java @@ -0,0 +1,5 @@ +package software.xdev.spring.data.eclipse.store.demo.dual.storage.invoice; + +public record Invoice(String id, double sum) +{ +} diff --git a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/InvoiceRepository.java b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/InvoiceRepository.java new file mode 100644 index 00000000..639b3304 --- /dev/null +++ b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/InvoiceRepository.java @@ -0,0 +1,8 @@ +package software.xdev.spring.data.eclipse.store.demo.dual.storage.invoice; + +import org.springframework.data.repository.CrudRepository; + + +public interface InvoiceRepository extends CrudRepository +{ +} diff --git a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/PersistenceInvoiceConfiguration.java b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/PersistenceInvoiceConfiguration.java new file mode 100644 index 00000000..e49618e8 --- /dev/null +++ b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/PersistenceInvoiceConfiguration.java @@ -0,0 +1,12 @@ +package software.xdev.spring.data.eclipse.store.demo.dual.storage.invoice; + +import org.springframework.context.annotation.Configuration; + +import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; + + +@Configuration +@EnableEclipseStoreRepositories("software.xdev.spring.data.eclipse.store.demo.dual.storage.invoice") +public class PersistenceInvoiceConfiguration +{ +} diff --git a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/PersistencePersonConfiguration.java b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/PersistencePersonConfiguration.java new file mode 100644 index 00000000..2562bd4c --- /dev/null +++ b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/PersistencePersonConfiguration.java @@ -0,0 +1,12 @@ +package software.xdev.spring.data.eclipse.store.demo.dual.storage.person; + +import org.springframework.context.annotation.Configuration; + +import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; + + +@Configuration +@EnableEclipseStoreRepositories("software.xdev.spring.data.eclipse.store.demo.dual.storage.person") +public class PersistencePersonConfiguration +{ +} diff --git a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/Person.java b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/Person.java new file mode 100644 index 00000000..d53cfdb3 --- /dev/null +++ b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/Person.java @@ -0,0 +1,5 @@ +package software.xdev.spring.data.eclipse.store.demo.dual.storage.person; + +public record Person(String firstName, String lastName) +{ +} diff --git a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/PersonRepository.java b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/PersonRepository.java new file mode 100644 index 00000000..2ad7bdcc --- /dev/null +++ b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/PersonRepository.java @@ -0,0 +1,8 @@ +package software.xdev.spring.data.eclipse.store.demo.dual.storage.person; + +import org.springframework.data.repository.CrudRepository; + + +public interface PersonRepository extends CrudRepository +{ +} From 71b3121f0cd196ed4cd92efa8def7123d0b00498 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Wed, 6 Mar 2024 15:48:09 +0100 Subject: [PATCH 23/98] Implemented useful Configuration through Spring --- .gitignore | 2 + .../PersistenceInvoiceConfiguration.java | 19 +++++- .../PersistencePersonConfiguration.java | 19 +++++- .../jpa/integration/IntegrationTest.java | 8 +-- .../jpa/integration/TestConfiguration.java | 10 +-- .../importer/EclipseStoreDataImporter.java | 16 ++--- .../EclipseStoreDataImporterComponent.java | 6 +- .../store/repository/EclipseStoreStorage.java | 19 ++---- ...efaultEclipseStoreClientConfiguration.java | 24 +++++++ .../EclipseStoreClientConfiguration.java | 63 +++++++++++++++++++ ...StoreRepositoryConfigurationExtension.java | 20 ++++++ ...EclipseStoreStorageFoundationProvider.java | 24 +++++++ .../EnableEclipseStoreRepositories.java | 8 +++ .../EclipseStoreRepositoryFactoryBean.java | 16 ++--- .../data/eclipse/store/helper/TestUtil.java | 10 +-- .../store/integration/TestConfiguration.java | 12 ++-- .../tests/IsolatedTestConfiguration.java | 10 +-- .../isolated/tests/keywords/KeywordsTest.java | 6 +- .../tests/special/types/TypesTest.java | 12 ++-- .../integration/tests/ChangeRootTests.java | 12 ++-- .../integration/tests/ConcurrencyTest.java | 10 +-- .../store/integration/tests/FinalTest.java | 8 +-- .../store/integration/tests/HashSetTest.java | 18 +++--- .../store/integration/tests/IdTest.java | 41 ++++++------ .../integration/tests/InheritanceTest.java | 22 +++---- .../tests/JpaCompatibilityTest.java | 13 ++-- .../store/integration/tests/QueryTest.java | 41 ++++++------ .../integration/tests/RealLifeTests.java | 28 ++++----- .../integration/tests/SimpleMultipleTest.java | 14 ++--- .../integration/tests/SimpleSingleTest.java | 30 +++++---- .../tests/SpecificInterfacesTest.java | 14 ++--- .../store/integration/tests/StressTest.java | 10 +-- .../integration/tests/WorkingCopyTests.java | 16 ++--- 33 files changed, 373 insertions(+), 208 deletions(-) create mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/DefaultEclipseStoreClientConfiguration.java create mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreClientConfiguration.java create mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreStorageFoundationProvider.java diff --git a/.gitignore b/.gitignore index a6d5c6d3..fb4acbe5 100644 --- a/.gitignore +++ b/.gitignore @@ -68,6 +68,8 @@ target/ # EclipseStore storage +storage-person +storage-invoice storage-jpa # == IntelliJ == diff --git a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/PersistenceInvoiceConfiguration.java b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/PersistenceInvoiceConfiguration.java index e49618e8..a4080493 100644 --- a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/PersistenceInvoiceConfiguration.java +++ b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/PersistenceInvoiceConfiguration.java @@ -1,12 +1,27 @@ package software.xdev.spring.data.eclipse.store.demo.dual.storage.invoice; +import static org.eclipse.store.storage.embedded.types.EmbeddedStorage.Foundation; + +import java.nio.file.Path; + +import org.eclipse.store.storage.embedded.types.EmbeddedStorageFoundation; +import org.eclipse.store.storage.types.Storage; import org.springframework.context.annotation.Configuration; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; @Configuration -@EnableEclipseStoreRepositories("software.xdev.spring.data.eclipse.store.demo.dual.storage.invoice") -public class PersistenceInvoiceConfiguration +@EnableEclipseStoreRepositories( + value = "software.xdev.spring.data.eclipse.store.demo.dual.storage.invoice", + clientConfiguration = "persistenceInvoiceConfiguration" +) +public class PersistenceInvoiceConfiguration extends EclipseStoreClientConfiguration { + @Override + public EmbeddedStorageFoundation getEmbeddedStorageFoundation() + { + return Foundation(Storage.Configuration(Storage.FileProvider(Path.of("storage-invoice")))); + } } diff --git a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/PersistencePersonConfiguration.java b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/PersistencePersonConfiguration.java index 2562bd4c..afa502e1 100644 --- a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/PersistencePersonConfiguration.java +++ b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/PersistencePersonConfiguration.java @@ -1,12 +1,27 @@ package software.xdev.spring.data.eclipse.store.demo.dual.storage.person; +import static org.eclipse.store.storage.embedded.types.EmbeddedStorage.Foundation; + +import java.nio.file.Path; + +import org.eclipse.store.storage.embedded.types.EmbeddedStorageFoundation; +import org.eclipse.store.storage.types.Storage; import org.springframework.context.annotation.Configuration; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; @Configuration -@EnableEclipseStoreRepositories("software.xdev.spring.data.eclipse.store.demo.dual.storage.person") -public class PersistencePersonConfiguration +@EnableEclipseStoreRepositories( + value = "software.xdev.spring.data.eclipse.store.demo.dual.storage.person", + clientConfigurationClass = PersistencePersonConfiguration.class +) +public class PersistencePersonConfiguration extends EclipseStoreClientConfiguration { + @Override + public EmbeddedStorageFoundation getEmbeddedStorageFoundation() + { + return Foundation(Storage.Configuration(Storage.FileProvider(Path.of("storage-person")))); + } } diff --git a/spring-data-eclipse-store-jpa/src/test/java/software/xdev/spring/data/eclipse/store/jpa/integration/IntegrationTest.java b/spring-data-eclipse-store-jpa/src/test/java/software/xdev/spring/data/eclipse/store/jpa/integration/IntegrationTest.java index 3a8f91d0..3eef8849 100644 --- a/spring-data-eclipse-store-jpa/src/test/java/software/xdev/spring/data/eclipse/store/jpa/integration/IntegrationTest.java +++ b/spring-data-eclipse-store-jpa/src/test/java/software/xdev/spring/data/eclipse/store/jpa/integration/IntegrationTest.java @@ -27,7 +27,7 @@ import software.xdev.spring.data.eclipse.store.jpa.integration.repository.PersonToTestInEclipseStoreRepository; import software.xdev.spring.data.eclipse.store.jpa.integration.repository.PersonToTestInJpa; import software.xdev.spring.data.eclipse.store.jpa.integration.repository.PersonToTestInJpaRepository; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; import software.xdev.spring.data.eclipse.store.repository.support.SimpleEclipseStoreRepository; @@ -44,7 +44,7 @@ class IntegrationTest private EclipseStoreDataImporterComponent eclipseStoreDataImporter; @Autowired - private EclipseStoreStorage eclipseStoreStorage; + private EclipseStoreClientConfiguration configuration; /** * Super simple test if there are any start-up errors when running parallel to a JPA configuration @@ -72,10 +72,10 @@ void testEclipseStoreImport() final List allEntities = simpleEclipseStoreRepositories.get(0).findAll(); Assertions.assertEquals(1, allEntities.size()); - this.eclipseStoreStorage.stop(); + this.configuration.getStorageInstance().stop(); Assertions.assertEquals( 1, - this.eclipseStoreStorage.getEntityCount(PersonToTestInJpa.class), + this.configuration.getStorageInstance().getEntityCount(PersonToTestInJpa.class), "After restart the imported entities are not there anymore."); } diff --git a/spring-data-eclipse-store-jpa/src/test/java/software/xdev/spring/data/eclipse/store/jpa/integration/TestConfiguration.java b/spring-data-eclipse-store-jpa/src/test/java/software/xdev/spring/data/eclipse/store/jpa/integration/TestConfiguration.java index bb73884f..157a276c 100644 --- a/spring-data-eclipse-store-jpa/src/test/java/software/xdev/spring/data/eclipse/store/jpa/integration/TestConfiguration.java +++ b/spring-data-eclipse-store-jpa/src/test/java/software/xdev/spring/data/eclipse/store/jpa/integration/TestConfiguration.java @@ -28,7 +28,7 @@ import org.springframework.context.event.EventListener; import org.springframework.util.FileSystemUtils; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; @@ -40,7 +40,7 @@ public class TestConfiguration implements DisposableBean { @Autowired - EclipseStoreStorage storage; + EclipseStoreClientConfiguration configuration; @Value("${org.eclipse.store.storage-directory}") private String storageDirectory; @@ -49,15 +49,15 @@ public class TestConfiguration implements DisposableBean public void handleContextRefresh(final ContextRefreshedEvent event) { // Init with empty root object - this.storage.clearData(); + this.configuration.getStorageInstance().clearData(); } @Override public void destroy() throws Exception { // End with empty root object - this.storage.clearData(); - this.storage.stop(); + this.configuration.getStorageInstance().clearData(); + this.configuration.getStorageInstance().stop(); FileSystemUtils.deleteRecursively(Path.of(this.storageDirectory)); } } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporter.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporter.java index d5256f34..18adb2d0 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporter.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporter.java @@ -31,6 +31,7 @@ import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; import software.xdev.spring.data.eclipse.store.repository.SupportedChecker; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; import software.xdev.spring.data.eclipse.store.repository.support.SimpleEclipseStoreRepository; import software.xdev.spring.data.eclipse.store.repository.support.copier.working.RecursiveWorkingCopier; @@ -41,11 +42,11 @@ public class EclipseStoreDataImporter { private static final Logger LOG = LoggerFactory.getLogger(EclipseStoreDataImporter.class); - private final EclipseStoreStorage eclipseStoreStorage; + private final EclipseStoreClientConfiguration configuration; - public EclipseStoreDataImporter(final EclipseStoreStorage eclipseStoreStorage) + public EclipseStoreDataImporter(final EclipseStoreClientConfiguration configuration) { - this.eclipseStoreStorage = eclipseStoreStorage; + this.configuration = configuration; } /** @@ -196,13 +197,14 @@ private void createRepositoryForType( private SimpleEclipseStoreRepository createEclipseStoreRepo(final Class domainClass) { + final EclipseStoreStorage storageInstance = this.configuration.getStorageInstance(); return new SimpleEclipseStoreRepository<>( - this.eclipseStoreStorage, + storageInstance, new RecursiveWorkingCopier<>( domainClass, - this.eclipseStoreStorage.getRegistry(), - this.eclipseStoreStorage, - this.eclipseStoreStorage, + storageInstance.getRegistry(), + storageInstance, + storageInstance, new SupportedChecker.Implementation()), domainClass); } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporterComponent.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporterComponent.java index adf1b878..4c024223 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporterComponent.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporterComponent.java @@ -23,7 +23,7 @@ import org.springframework.context.ApplicationContext; import org.springframework.stereotype.Component; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; import software.xdev.spring.data.eclipse.store.repository.support.SimpleEclipseStoreRepository; @@ -37,10 +37,10 @@ public class EclipseStoreDataImporterComponent private final ApplicationContext applicationContext; public EclipseStoreDataImporterComponent( - final EclipseStoreStorage eclipseStoreStorage, + final EclipseStoreClientConfiguration configuration, final ApplicationContext applicationContext) { - this.importer = new EclipseStoreDataImporter(eclipseStoreStorage); + this.importer = new EclipseStoreDataImporter(configuration); this.applicationContext = applicationContext; } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java index da2c3312..58a1605c 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java @@ -26,22 +26,19 @@ import org.eclipse.serializer.persistence.binary.jdk17.java.util.BinaryHandlerImmutableCollectionsList12; import org.eclipse.serializer.persistence.binary.jdk17.java.util.BinaryHandlerImmutableCollectionsSet12; import org.eclipse.serializer.persistence.types.Storer; -import org.eclipse.store.integrations.spring.boot.types.EclipseStoreProvider; -import org.eclipse.store.integrations.spring.boot.types.configuration.EclipseStoreProperties; import org.eclipse.store.storage.embedded.types.EmbeddedStorageFoundation; import org.eclipse.store.storage.types.StorageManager; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import org.springframework.stereotype.Component; import software.xdev.spring.data.eclipse.store.core.IdentitySet; import software.xdev.spring.data.eclipse.store.exceptions.AlreadyRegisteredException; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreStorageFoundationProvider; import software.xdev.spring.data.eclipse.store.repository.support.copier.id.IdSetter; import software.xdev.spring.data.eclipse.store.repository.support.reposyncer.RepositorySynchronizer; import software.xdev.spring.data.eclipse.store.repository.support.reposyncer.SimpleRepositorySynchronizer; - -@Component public class EclipseStoreStorage implements EntityListProvider, IdSetterProvider, PersistableChecker { @@ -50,8 +47,7 @@ public class EclipseStoreStorage private final Map, IdSetter> entityClassToIdSetter = new HashMap<>(); private EntitySetCollector entitySetCollector; private PersistableChecker persistenceChecker; - private final EclipseStoreProperties storeConfiguration; - private final EclipseStoreProvider storeProvider; + private final EclipseStoreStorageFoundationProvider foundationProvider; private StorageManager storageManager; private Root root; @@ -59,12 +55,9 @@ public class EclipseStoreStorage private final WorkingCopyRegistry registry = new WorkingCopyRegistry(); private RepositorySynchronizer repositorySynchronizer; - public EclipseStoreStorage( - final EclipseStoreProperties storeConfiguration, - final EclipseStoreProvider storeProvider) + public EclipseStoreStorage(final EclipseStoreClientConfiguration storeConfiguration) { - this.storeConfiguration = storeConfiguration; - this.storeProvider = storeProvider; + this.foundationProvider = storeConfiguration; } private synchronized StorageManager getInstanceOfStorageManager() @@ -85,7 +78,7 @@ private synchronized void ensureEntitiesInRoot() LOG.info("Starting storage..."); this.root = new Root(); final EmbeddedStorageFoundation embeddedStorageFoundation = - this.storeProvider.createStorageFoundation(this.storeConfiguration); + this.foundationProvider.getEmbeddedStorageFoundation(); embeddedStorageFoundation.registerTypeHandler(BinaryHandlerImmutableCollectionsSet12.New()); embeddedStorageFoundation.registerTypeHandler(BinaryHandlerImmutableCollectionsList12.New()); this.storageManager = embeddedStorageFoundation.start(this.root); diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/DefaultEclipseStoreClientConfiguration.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/DefaultEclipseStoreClientConfiguration.java new file mode 100644 index 00000000..c3aab703 --- /dev/null +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/DefaultEclipseStoreClientConfiguration.java @@ -0,0 +1,24 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.repository.config; + +import org.springframework.context.annotation.Configuration; + + +@Configuration(proxyBeanMethods = false) +public class DefaultEclipseStoreClientConfiguration extends EclipseStoreClientConfiguration +{ +} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreClientConfiguration.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreClientConfiguration.java new file mode 100644 index 00000000..c7ad20b2 --- /dev/null +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreClientConfiguration.java @@ -0,0 +1,63 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.repository.config; + +import org.eclipse.store.integrations.spring.boot.types.EclipseStoreProvider; +import org.eclipse.store.integrations.spring.boot.types.EclipseStoreProviderImpl; +import org.eclipse.store.integrations.spring.boot.types.configuration.EclipseStoreProperties; +import org.eclipse.store.storage.embedded.types.EmbeddedStorageFoundation; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Configuration; + +import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; + + +@Configuration(proxyBeanMethods = false) +public abstract class EclipseStoreClientConfiguration implements EclipseStoreStorageFoundationProvider +{ + @Autowired + private EclipseStoreProperties defaultEclipseStoreProperties; + + @Autowired + private EclipseStoreProviderImpl defaultEclipseStoreProvider; + + private EclipseStoreStorage storageInstance; + + public EclipseStoreProperties getStoreConfiguration() + { + return this.defaultEclipseStoreProperties; + } + + public EclipseStoreProvider getStoreProvider() + { + return this.defaultEclipseStoreProvider; + } + + @Override + public EmbeddedStorageFoundation getEmbeddedStorageFoundation() + { + return this.getStoreProvider().createStorageFoundation(this.getStoreConfiguration()); + } + + public EclipseStoreStorage getStorageInstance() + { + if(this.storageInstance == null) + { + this.storageInstance = new EclipseStoreStorage(this); + } + return this.storageInstance; + } +} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoryConfigurationExtension.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoryConfigurationExtension.java index ee36979c..af8ca5ca 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoryConfigurationExtension.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoryConfigurationExtension.java @@ -15,6 +15,9 @@ */ package software.xdev.spring.data.eclipse.store.repository.config; +import static software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories.CLIENT_CONFIGURATION_ANNOTATION_VALUE; +import static software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories.CLIENT_CONFIGURATION_CLASS_ANNOTATION_VALUE; + import java.lang.annotation.Annotation; import java.util.Collection; import java.util.Collections; @@ -22,8 +25,12 @@ import jakarta.annotation.Nonnull; +import org.springframework.beans.factory.support.BeanDefinitionBuilder; +import org.springframework.core.annotation.AnnotationAttributes; +import org.springframework.data.repository.config.AnnotationRepositoryConfigurationSource; import org.springframework.data.repository.config.RepositoryConfigurationExtension; import org.springframework.data.repository.config.RepositoryConfigurationExtensionSupport; +import org.springframework.util.ClassUtils; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreCrudRepository; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreCustomRepository; @@ -63,6 +70,19 @@ public String getRepositoryFactoryBeanClassName() return EclipseStoreRepositoryFactoryBean.class.getName(); } + @Override + public void postProcess(final BeanDefinitionBuilder builder, final AnnotationRepositoryConfigurationSource config) + { + final AnnotationAttributes attributes = config.getAttributes(); + final Class configurationClass = attributes.getClass(CLIENT_CONFIGURATION_CLASS_ANNOTATION_VALUE); + String configurationString = attributes.getString(CLIENT_CONFIGURATION_ANNOTATION_VALUE); + if(!configurationClass.equals(DefaultEclipseStoreClientConfiguration.class)) + { + configurationString = ClassUtils.getShortNameAsProperty(configurationClass); + } + builder.addPropertyReference("configuration", configurationString); + } + @Override @Nonnull public String getModuleIdentifier() diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreStorageFoundationProvider.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreStorageFoundationProvider.java new file mode 100644 index 00000000..df9e6015 --- /dev/null +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreStorageFoundationProvider.java @@ -0,0 +1,24 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.repository.config; + +import org.eclipse.store.storage.embedded.types.EmbeddedStorageFoundation; + + +public interface EclipseStoreStorageFoundationProvider +{ + EmbeddedStorageFoundation getEmbeddedStorageFoundation(); +} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EnableEclipseStoreRepositories.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EnableEclipseStoreRepositories.java index c200a994..9ccc8208 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EnableEclipseStoreRepositories.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EnableEclipseStoreRepositories.java @@ -81,6 +81,14 @@ */ Filter[] excludeFilters() default {}; + String CLIENT_CONFIGURATION_ANNOTATION_VALUE = "clientConfiguration"; + + String clientConfiguration() default "defaultEclipseStoreClientConfiguration"; + + String CLIENT_CONFIGURATION_CLASS_ANNOTATION_VALUE = "clientConfigurationClass"; + + Class clientConfigurationClass() default DefaultEclipseStoreClientConfiguration.class; + /** * Returns the postfix to be used when looking up custom repository implementations. Defaults to {@literal Impl} . * So for a repository named {@code PersonRepository} the corresponding implementation class will be looked up diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreRepositoryFactoryBean.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreRepositoryFactoryBean.java index 4c54c4b9..6ab1907f 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreRepositoryFactoryBean.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreRepositoryFactoryBean.java @@ -25,7 +25,7 @@ import org.springframework.data.repository.core.support.RepositoryFactorySupport; import org.springframework.stereotype.Component; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; @ComponentScan({ @@ -35,20 +35,22 @@ public class EclipseStoreRepositoryFactoryBean, S, ID extends Serializable> extends RepositoryFactoryBeanSupport { - private final EclipseStoreStorage storage; + private EclipseStoreClientConfiguration configuration; - public EclipseStoreRepositoryFactoryBean( - final Class repositoryInterface, - final EclipseStoreStorage storage) + public EclipseStoreRepositoryFactoryBean(final Class repositoryInterface) { super(repositoryInterface); - this.storage = storage; + } + + public void setConfiguration(final EclipseStoreClientConfiguration configuration) + { + this.configuration = configuration; } @Override @Nonnull protected RepositoryFactorySupport createRepositoryFactory() { - return new EclipseStoreRepositoryFactory(this.storage); + return new EclipseStoreRepositoryFactory(this.configuration.getStorageInstance()); } } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/TestUtil.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/TestUtil.java index 98cb7550..5def490f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/TestUtil.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/TestUtil.java @@ -20,7 +20,7 @@ import org.opentest4j.AssertionFailedError; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; public final class TestUtil @@ -32,14 +32,14 @@ public static List iterableToList(final Iterable iterable) return list; } - public static void restartDatastore(final EclipseStoreStorage storage) + public static void restartDatastore(final EclipseStoreClientConfiguration configuration) { - storage.stop(); + configuration.getStorageInstance().stop(); // Storage starts automatically again, if the repo is accessed } public static void doBeforeAndAfterRestartOfDatastore( - final EclipseStoreStorage storage, + final EclipseStoreClientConfiguration configuration, final Runnable thingToDoBeforeAndAfterRestart) { try @@ -50,7 +50,7 @@ public static void doBeforeAndAfterRestartOfDatastore( { throw new AssertionFailedError("Error before restart of storage", error); } - restartDatastore(storage); + restartDatastore(configuration); try { thingToDoBeforeAndAfterRestart.run(); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java index 5c0ea1fa..967b026a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java @@ -18,14 +18,14 @@ import java.nio.file.Path; import org.springframework.beans.factory.DisposableBean; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Value; import org.springframework.context.annotation.Configuration; import org.springframework.context.event.ContextRefreshedEvent; import org.springframework.context.event.EventListener; import org.springframework.util.FileSystemUtils; -import org.springframework.beans.factory.annotation.Autowired; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; @@ -34,7 +34,7 @@ public class TestConfiguration implements DisposableBean { @Autowired - EclipseStoreStorage storage; + EclipseStoreClientConfiguration configuration; @Value("${org.eclipse.store.storage-directory}") private String storageDirectory; @@ -43,15 +43,15 @@ public class TestConfiguration implements DisposableBean public void handleContextRefresh(final ContextRefreshedEvent event) { // Init with empty root object - this.storage.clearData(); + this.configuration.getStorageInstance().clearData(); } @Override public void destroy() throws Exception { // End with empty root object - this.storage.clearData(); - this.storage.stop(); + this.configuration.getStorageInstance().clearData(); + this.configuration.getStorageInstance().stop(); FileSystemUtils.deleteRecursively(Path.of(this.storageDirectory)); } } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/IsolatedTestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/IsolatedTestConfiguration.java index a5be2ce0..7a5cd37d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/IsolatedTestConfiguration.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/IsolatedTestConfiguration.java @@ -25,7 +25,7 @@ import org.springframework.context.event.EventListener; import org.springframework.util.FileSystemUtils; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; @@ -34,7 +34,7 @@ public class IsolatedTestConfiguration implements DisposableBean { @Autowired - EclipseStoreStorage storage; + EclipseStoreClientConfiguration configuration; @Value("${org.eclipse.store.storage-directory}") private String storageDirectory; @@ -43,15 +43,15 @@ public class IsolatedTestConfiguration implements DisposableBean public void handleContextRefresh(final ContextRefreshedEvent event) { // Init with empty root object - this.storage.clearData(); + this.configuration.getStorageInstance().clearData(); } @Override public void destroy() throws Exception { // End with empty root object - this.storage.clearData(); - this.storage.stop(); + this.configuration.getStorageInstance().clearData(); + this.configuration.getStorageInstance().stop(); FileSystemUtils.deleteRecursively(Path.of(this.storageDirectory)); } } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java index 61c012ca..90d377b8 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java @@ -23,7 +23,7 @@ import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.isolated.tests.IsolatedTestAnnotations; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; /** @@ -39,7 +39,7 @@ class KeywordsTest { @Autowired - private EclipseStoreStorage storage; + private EclipseStoreClientConfiguration configuration; @Test @Disabled("For now we don't need 'existsBy'") @@ -48,7 +48,7 @@ void simpleStoreAndRead(final MinimalRepository repository) repository.save(new MinimalDaoObject("1")); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { Assertions.assertTrue(repository.existsByValue("1")); Assertions.assertFalse(repository.existsByValue("2")); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java index 8c28d405..56cac8f8 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java @@ -31,7 +31,7 @@ import software.xdev.spring.data.eclipse.store.exceptions.DataTypeNotSupportedException; import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.isolated.tests.IsolatedTestAnnotations; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; @@ -50,7 +50,7 @@ class TypesTest + ".TypesData#generateNotWorkingData"; @Autowired - private EclipseStoreStorage storage; + private EclipseStoreClientConfiguration configuration; @ParameterizedTest @MethodSource(TYPES_DATA_SOURCE) @@ -65,7 +65,7 @@ > void simpleStoreAndRead( repository.save(objectToStore); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> this.dynamicAssertEquals(1, repository, objectToStore) ); } @@ -113,7 +113,7 @@ > void simpleChangeAfterStore( repository.save(storedObject.get()); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> this.dynamicAssertEquals(1, repository, storedObject.get()) ); } @@ -134,7 +134,7 @@ > void doubleStoreSameEntityWithChange( repository.save(objectToStore); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> this.dynamicAssertEquals(1, repository, objectToStore) ); } @@ -153,7 +153,7 @@ > void simpleChangeBeforeStore( repository.save(objectToStore); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> this.dynamicAssertEquals(1, repository, objectToStore) ); } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ChangeRootTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ChangeRootTests.java index 4ce74c8f..bf55a1ec 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ChangeRootTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ChangeRootTests.java @@ -19,13 +19,13 @@ import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; - import org.springframework.beans.factory.annotation.Autowired; + import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; import software.xdev.spring.data.eclipse.store.integration.repositories.Node; import software.xdev.spring.data.eclipse.store.integration.repositories.NodeRepository; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; @DefaultTestAnnotations @@ -39,7 +39,7 @@ public class ChangeRootTests @Autowired private NodeRepository repository; @Autowired - private EclipseStoreStorage storage; + private EclipseStoreClientConfiguration configuration; //@formatter:off /** @@ -55,7 +55,7 @@ void testSaveParentAndFindAll() this.repository.save(parentNode); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List nodes = TestUtil.iterableToList(this.repository.findAll()); Assertions.assertEquals(3, nodes.size()); @@ -82,7 +82,7 @@ void testSaveRecursive() this.repository.save(parentNode1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List nodes = TestUtil.iterableToList(this.repository.findAll()); Assertions.assertEquals(3, nodes.size()); @@ -110,7 +110,7 @@ void testSaveGraph() this.repository.save(parentNode); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List nodes = TestUtil.iterableToList(this.repository.findAll()); Assertions.assertEquals(3, nodes.size()); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ConcurrencyTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ConcurrencyTest.java index cfe1039a..f953f421 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ConcurrencyTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ConcurrencyTest.java @@ -29,13 +29,13 @@ import org.apache.logging.log4j.util.Strings; import org.junit.jupiter.api.Test; - import org.springframework.beans.factory.annotation.Autowired; + import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; @SuppressWarnings("OptionalGetWithoutIsPresent") @@ -47,7 +47,7 @@ class ConcurrencyTest private CustomerRepository repository; @Autowired - private EclipseStoreStorage storage; + private EclipseStoreClientConfiguration configuration; private final List testCustomers = IntStream.range(1, 100).mapToObj((i) -> new Customer(CUSTOMER_NO + i, "")).toList(); @@ -72,7 +72,7 @@ void testSaveConcurrently() throws InterruptedException final List customers = TestUtil.iterableToList(this.repository.findAll()); assertEquals(this.testCustomers.size(), customers.size()); - restartDatastore(this.storage); + restartDatastore(this.configuration); final List customers2 = TestUtil.iterableToList(this.repository.findAll()); assertEquals(this.testCustomers.size(), customers2.size()); } @@ -98,7 +98,7 @@ void testDeleteConcurrently() throws InterruptedException final List customers2 = TestUtil.iterableToList(this.repository.findAll()); assertTrue(customers2.isEmpty()); - restartDatastore(this.storage); + restartDatastore(this.configuration); final List customers3 = TestUtil.iterableToList(this.repository.findAll()); assertTrue(customers3.isEmpty()); } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/FinalTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/FinalTest.java index 77d4f989..38b17145 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/FinalTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/FinalTest.java @@ -31,7 +31,7 @@ import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalId; import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalIdRepository; import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalRepository; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; @DefaultTestAnnotations @@ -45,7 +45,7 @@ class FinalTest CustomerWithFinalIdRepository withFinalIdRepository; @Autowired - EclipseStoreStorage storage; + EclipseStoreClientConfiguration configuration; @Test void testSaveAndFindSingle() @@ -54,7 +54,7 @@ void testSaveAndFindSingle() this.repository.save(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.repository.findAll()); Assertions.assertEquals(1, customers.size()); @@ -71,7 +71,7 @@ void testSaveAndFindSingleWithChild() this.withChildRepository.save(originalCustomer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.withChildRepository.findAll()); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/HashSetTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/HashSetTest.java index 3c4acc2a..6c7624bd 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/HashSetTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/HashSetTest.java @@ -29,7 +29,7 @@ import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepositoryWithNonFinalHashSet; import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithHashSet; import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithNonFinalHashSet; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; @DefaultTestAnnotations @@ -41,7 +41,7 @@ class HashSetTest private CustomerRepositoryWithNonFinalHashSet nonFinalRepository; @Autowired - private EclipseStoreStorage storage; + private EclipseStoreClientConfiguration configuration; @Test void testSaveAndFindAll() @@ -51,7 +51,7 @@ void testSaveAndFindAll() this.repository.save(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.repository.findAll()); Assertions.assertEquals(1, customers.size()); @@ -73,7 +73,7 @@ void testSaveAndResaveFindAll() this.repository.save(customerWithHashSet); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.repository.findAll()); Assertions.assertEquals(1, customers.size()); @@ -91,7 +91,7 @@ void testSaveAndFindAllNonFinal() this.nonFinalRepository.save(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.nonFinalRepository.findAll()); @@ -110,7 +110,7 @@ void testSaveAndSetAndFindAllNonFinal() this.nonFinalRepository.save(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.nonFinalRepository.findAll()); @@ -134,7 +134,7 @@ void testSaveAndResetAndFindAllNonFinal() this.nonFinalRepository.save(customerWithHashSet); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.nonFinalRepository.findAll()); @@ -153,7 +153,7 @@ void testSaveAndSetNullAndFindAllNonFinal() this.nonFinalRepository.save(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.nonFinalRepository.findAll()); @@ -174,7 +174,7 @@ void testDoubleSaveWithNewInstanceAndFindAll() this.repository.save(reloadedCustomer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.repository.findAll()); Assertions.assertEquals(1, customers.size()); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/IdTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/IdTest.java index 0557f6e1..5208f727 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/IdTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/IdTest.java @@ -41,6 +41,7 @@ import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithPurchaseRepository; import software.xdev.spring.data.eclipse.store.integration.repositories.id.Purchase; import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; @SuppressWarnings("OptionalGetWithoutIsPresent") @@ -48,7 +49,7 @@ class IdTest { @Autowired - private EclipseStoreStorage storage; + private EclipseStoreClientConfiguration configuration; @Test void testCreateSingleWithAutoIdInteger(@Autowired final CustomerWithIdIntegerRepository customerRepository) @@ -57,7 +58,7 @@ void testCreateSingleWithAutoIdInteger(@Autowired final CustomerWithIdIntegerRep customerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Optional loadedCustomer = customerRepository.findById(0); Assertions.assertTrue(loadedCustomer.isPresent()); @@ -73,12 +74,12 @@ void testCreateSingleWithAutoIdInteger(@Autowired final CustomerWithIdIntegerRep @Test void testSaveSingleWithoutAnyPreviousCall(@Autowired final CustomerWithIdIntegerRepository customerRepository) { - restartDatastore(this.storage); + restartDatastore(this.configuration); final CustomerWithIdInteger customer1 = new CustomerWithIdInteger(TestData.FIRST_NAME, TestData.LAST_NAME); customerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Optional loadedCustomer = customerRepository.findById(0); Assertions.assertTrue(loadedCustomer.isPresent()); @@ -107,7 +108,7 @@ void testCreateMultipleWithAutoIdInteger(@Autowired final CustomerWithIdIntegerR customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List loadedCustomers = TestUtil.iterableToList(customerRepository.findAllById(List.of(0, 1))); @@ -128,7 +129,7 @@ void testCreateMultipleWithAutoIdIntegerSingleFinds( customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Optional loadedCustomer1 = customerRepository.findById(0); Assertions.assertEquals(customer1, loadedCustomer1.get()); @@ -145,7 +146,7 @@ void testCreateSingleWithAutoIdInt(@Autowired final CustomerWithIdIntRepository customerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Optional loadedCustomer = customerRepository.findById(0); Assertions.assertTrue(loadedCustomer.isPresent()); @@ -161,7 +162,7 @@ void testCreateSingleWithAutoIdString(@Autowired final CustomerWithIdStringRepos customerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Optional loadedCustomer = customerRepository.findById("0"); Assertions.assertTrue(loadedCustomer.isPresent()); @@ -180,7 +181,7 @@ void testCreateMultipleWithAutoIdString(@Autowired final CustomerWithIdStringRep customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List loadedCustomers = TestUtil.iterableToList(customerRepository.findAllById(List.of("0", "1"))); @@ -197,7 +198,7 @@ void testCreateSingleWithAutoIdLong(@Autowired final CustomerWithIdLongRepositor customerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Optional loadedCustomer = customerRepository.findById(0L); Assertions.assertTrue(loadedCustomer.isPresent()); @@ -217,13 +218,13 @@ void testCreateMultipleWithAutoIdLong(@Autowired final CustomerWithIdLongReposit customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List loadedCustomers = TestUtil.iterableToList(customerRepository.findAllById(List.of(0L, 1L))); Assertions.assertEquals(2, loadedCustomers.size()); Assertions.assertNotEquals(loadedCustomers.get(0), loadedCustomers.get(1)); - final List idList = loadedCustomers.stream().map(c -> c.getId()).toList(); + final List idList = loadedCustomers.stream().map(CustomerWithIdLong::getId).toList(); Assertions.assertTrue(idList.contains(0L)); Assertions.assertTrue(idList.contains(1L)); } @@ -239,7 +240,7 @@ void testCreateSingleWithNoAutoIdInteger( customerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Optional loadedCustomer = customerRepository.findById(0); Assertions.assertTrue(loadedCustomer.isPresent()); @@ -261,7 +262,7 @@ void testCreateMultipleWithNoAutoIdInteger( customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List loadedCustomers = TestUtil.iterableToList(customerRepository.findAllById(List.of(0, 1))); @@ -280,7 +281,7 @@ void testSaveSingleWithAutoIdInteger( customerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List loadedCustomer = TestUtil.iterableToList(customerRepository.findAll()); @@ -300,7 +301,7 @@ void testSaveSingleWithNoAutoIdInteger( customerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List loadedCustomer = TestUtil.iterableToList(customerRepository.findAll()); @@ -322,7 +323,7 @@ void testAutoIdWithSubnodeWithId( customerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List loadedCustomer = TestUtil.iterableToList(customerRepository.findAll()); @@ -345,7 +346,7 @@ void testAutoIdWithTwoSubnodeWithId( customerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List loadedCustomer = TestUtil.iterableToList(customerRepository.findAll()); @@ -370,7 +371,7 @@ void testAutoIdWithTwoSameSubnodesWithSameIdDifferentNod( customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List loadedCustomer = TestUtil.iterableToList(customerRepository.findAll()); @@ -400,7 +401,7 @@ void testAutoIdWithTwoSameSubnodesWithSameIdSameNode( customerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List loadedCustomer = TestUtil.iterableToList(customerRepository.findAll()); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/InheritanceTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/InheritanceTest.java index b28c3c01..5f67f29a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/InheritanceTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/InheritanceTest.java @@ -30,7 +30,7 @@ import software.xdev.spring.data.eclipse.store.integration.repositories.ParentCustomerRepository; import software.xdev.spring.data.eclipse.store.integration.repositories.SubCustomer; import software.xdev.spring.data.eclipse.store.integration.repositories.SubCustomerRepository; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; @DefaultTestAnnotations @@ -43,7 +43,7 @@ class InheritanceTest @Autowired private SubCustomerRepository subCustomerRepository; @Autowired - private EclipseStoreStorage storage; + private EclipseStoreClientConfiguration configuration; @Test void testSaveChildFindParent() @@ -53,7 +53,7 @@ void testSaveChildFindParent() this.childCustomerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List parentCustomers = TestUtil.iterableToList(this.parentCustomerRepository.findAll()); @@ -77,7 +77,7 @@ void testRemoveChildFindParent() this.childCustomerRepository.delete(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List parentCustomers = TestUtil.iterableToList(this.parentCustomerRepository.findAll()); @@ -102,7 +102,7 @@ void testAddChildAndParent() this.parentCustomerRepository.save(parentCustomer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List parentCustomers = TestUtil.iterableToList(this.parentCustomerRepository.findAll()); @@ -125,7 +125,7 @@ void testRemoveOnlyChildFindParent() this.childCustomerRepository.delete(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List parentCustomers = TestUtil.iterableToList(this.parentCustomerRepository.findAll()); @@ -152,7 +152,7 @@ void testRemoveOnlyParentFindParent() this.parentCustomerRepository.delete(parentCustomer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List parentCustomers = TestUtil.iterableToList(this.parentCustomerRepository.findAll()); @@ -179,7 +179,7 @@ void testRemoveAllChildren() this.childCustomerRepository.deleteAll(); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List parentCustomers = TestUtil.iterableToList(this.parentCustomerRepository.findAll()); @@ -206,7 +206,7 @@ void testRemoveAllParents() this.parentCustomerRepository.deleteAll(); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List parentCustomers = TestUtil.iterableToList(this.parentCustomerRepository.findAll()); @@ -233,7 +233,7 @@ void testChangeChildFindParent() this.childCustomerRepository.save(foundCustomer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List parentCustomers = TestUtil.iterableToList(this.parentCustomerRepository.findAll()); @@ -255,7 +255,7 @@ void testRecursiveFindByFirstNameOneResult() this.subCustomerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final SubCustomer foundCustomer = this.subCustomerRepository.findByFirstName(TestData.FIRST_NAME); Assertions.assertNotNull(foundCustomer); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/JpaCompatibilityTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/JpaCompatibilityTest.java index 4a130e3d..41b87838 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/JpaCompatibilityTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/JpaCompatibilityTest.java @@ -18,17 +18,16 @@ import java.util.List; import java.util.Optional; -import org.springframework.beans.factory.annotation.Autowired; - import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; +import org.springframework.beans.factory.annotation.Autowired; import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepositoryWithQuery; import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithQuery; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; @DefaultTestAnnotations @@ -38,7 +37,7 @@ class JpaCompatibilityTest private CustomerRepositoryWithQuery customerRepository; @Autowired - private EclipseStoreStorage storage; + private EclipseStoreClientConfiguration configuration; @Test void testUseQueryAnnotationFindAll() @@ -47,7 +46,7 @@ void testUseQueryAnnotationFindAll() this.customerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.customerRepository.findAll()); Assertions.assertEquals(1, customers.size()); @@ -64,7 +63,7 @@ void testUseQueryAnnotationFindByFirstName() this.customerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Optional foundCustomer = this.customerRepository.findByFirstName(TestData.FIRST_NAME); @@ -82,7 +81,7 @@ void testUseQueryAnnotationFindAllByLastName() this.customerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.customerRepository.findAllByLastName(TestData.LAST_NAME)); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/QueryTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/QueryTest.java index 7ed3c8f9..0808fcb6 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/QueryTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/QueryTest.java @@ -18,10 +18,9 @@ import java.util.List; import java.util.Optional; -import org.springframework.beans.factory.annotation.Autowired; - import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.data.domain.PageRequest; import org.springframework.data.domain.Pageable; import org.springframework.data.domain.Sort; @@ -34,7 +33,7 @@ import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithChild; import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithChildRepository; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; @DefaultTestAnnotations @@ -46,7 +45,7 @@ class QueryTest private CustomerWithChildRepository customerWithChildRepository; @Autowired - private EclipseStoreStorage storage; + private EclipseStoreClientConfiguration configuration; @Test void testBasicFindAllByLastNameTwoResults() @@ -57,7 +56,7 @@ void testBasicFindAllByLastNameTwoResults() this.customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.customerRepository.findAllByLastName(TestData.LAST_NAME)); @@ -79,7 +78,7 @@ void testBasicFindAllByLastNameOneResult() this.customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.customerRepository.findAllByLastName(TestData.LAST_NAME_ALTERNATIVE)); @@ -96,7 +95,7 @@ void testBasicFindByFirstNameOneResult() this.customerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Optional foundCustomer = this.customerRepository.findByFirstName(TestData.FIRST_NAME); Assertions.assertTrue(foundCustomer.isPresent()); @@ -114,7 +113,7 @@ void testPageableFindAllTwoPages() this.customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Pageable pageable = PageRequest.of(0, 1); final List customersPage1 = @@ -139,7 +138,7 @@ void testPageableFindAllUnpaged() this.customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Pageable pageable = Pageable.unpaged(); final List customersPage = TestUtil.iterableToList(this.customerRepository.findAll(pageable)); @@ -158,7 +157,7 @@ void testPageableFindAllOnePage() this.customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Pageable pageable = PageRequest.of(0, 2); final List customersPage1 = @@ -183,7 +182,7 @@ void testPageableFindByLastName() this.customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Pageable pageable = PageRequest.of(0, 10); final List customersPage = @@ -203,7 +202,7 @@ void testPageableFindByFirstNameWithList() this.customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Pageable pageable = PageRequest.of(0, 10); final List customersPage = @@ -223,7 +222,7 @@ void testSortFindByLastNameDefault() this.customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Sort sort = Sort.by("firstName"); final List customersPage = @@ -244,7 +243,7 @@ void testSortFindByFirstNameAscending() this.customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Sort sort = Sort.by("firstName").ascending(); final List customersPage = @@ -265,7 +264,7 @@ void testSortFindByFirstNameAscendingVariant() this.customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Sort sort = Sort.by(Sort.Direction.ASC, "lastName"); final List customersPage = @@ -286,7 +285,7 @@ void testFindByOrderByLastNameAsc() this.customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customersPage = TestUtil.iterableToList(this.customerRepository.findByOrderByLastNameAsc()); @@ -306,7 +305,7 @@ void testSortFindByLastNameDescending() this.customerRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Sort sort = Sort.by("firstName").descending(); final List customersPage = @@ -326,7 +325,7 @@ void testFindByChildExistingChild() this.customerWithChildRepository.save(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Optional foundCustomer = this.customerWithChildRepository.findByChild(child); Assertions.assertTrue(foundCustomer.isPresent()); @@ -342,7 +341,7 @@ void testFindByChildNewChild() this.customerWithChildRepository.save(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Child queryChild = new Child(TestData.FIRST_NAME_ALTERNATIVE, TestData.LAST_NAME_ALTERNATIVE); final Optional foundCustomer = @@ -360,7 +359,7 @@ void testFindByChildWhenNullNotExists() this.customerWithChildRepository.save(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Optional foundCustomer = this.customerWithChildRepository.findByChild(null); Assertions.assertTrue(foundCustomer.isEmpty()); @@ -375,7 +374,7 @@ void testFindByChildWhenNullExists() this.customerWithChildRepository.save(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Optional foundCustomer = this.customerWithChildRepository.findByChild(null); Assertions.assertTrue(foundCustomer.isPresent()); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/RealLifeTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/RealLifeTests.java index 75bdba68..ff8c6669 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/RealLifeTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/RealLifeTests.java @@ -24,8 +24,8 @@ import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; - import org.springframework.beans.factory.annotation.Autowired; + import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Article; @@ -35,7 +35,7 @@ import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Position; import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.PositionRepository; import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Warehouse; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; @SuppressWarnings("OptionalGetWithoutIsPresent") @@ -54,7 +54,7 @@ public class RealLifeTests @Autowired PositionRepository positionRepository; @Autowired - private EclipseStoreStorage storage; + private EclipseStoreClientConfiguration configuration; private Invoice buildDefaultModel() { @@ -90,7 +90,7 @@ void testReplacePositionWithExistingArticle() this.invoiceRepository.save(invoice); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Invoice loadedInvoice = TestUtil.iterableToList(this.invoiceRepository.findAll()).get(0); Assertions.assertEquals(2, loadedInvoice.getPositions().size()); @@ -121,7 +121,7 @@ void testReplacePositionWithNewArticleThroughInvoiceRepository() this.invoiceRepository.save(invoice); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Invoice loadedInvoice = TestUtil.iterableToList(this.invoiceRepository.findAll()).get(0); final Optional @@ -154,7 +154,7 @@ void testAddNewArticleWithSameWarehouse() this.invoiceRepository.save(invoice); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Invoice loadedInvoice = TestUtil.iterableToList(this.invoiceRepository.findAll()).get(0); final Optional @@ -191,7 +191,7 @@ void testReplacePositionWithNewArticleThroughPositionRepository() this.positionRepository.saveAll(positions); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List loadedPositions = TestUtil.iterableToList(this.positionRepository.findAll()); final Optional @@ -223,7 +223,7 @@ void testReplacePositionWithNewArticleAndUseImmutableList() this.positionRepository.saveAll(positions); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List loadedPositions = TestUtil.iterableToList(this.positionRepository.findAll()); Assertions.assertSame( @@ -238,7 +238,7 @@ void testSaveTwoObjectsWithSameReferenceThroughPositionRepository() { this.buildDefaultModelAndSaveIt(); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List positions = TestUtil.iterableToList(this.positionRepository.findAll()); Assertions.assertSame( @@ -253,7 +253,7 @@ void testSaveTwoObjectsWithSameReferenceThroughInvoiceRepository() { this.buildDefaultModelAndSaveIt(); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List invoices = TestUtil.iterableToList(this.invoiceRepository.findAll()); Assertions.assertSame( @@ -268,7 +268,7 @@ void testCreateTwoWorkingCopiesThroughTwoRepositories() { this.buildDefaultModelAndSaveIt(); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List invoices = TestUtil.iterableToList(this.invoiceRepository.findAll()); final List positions = TestUtil.iterableToList(this.positionRepository.findAll()); @@ -286,7 +286,7 @@ void testCreateTwoWorkingCopiesThroughOneRepository() { this.buildDefaultModelAndSaveIt(); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List invoices1 = TestUtil.iterableToList(this.invoiceRepository.findAll()); final List invoices2 = TestUtil.iterableToList(this.invoiceRepository.findAll()); @@ -308,7 +308,7 @@ void testChangeSharedWarehouse() this.positionRepository.save(position1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Position position2 = TestUtil.iterableToList(this.positionRepository.findAll()).get(1); Assertions.assertEquals(newWarehouseName, position2.getArticle().getWarehouses().get(0).getName()); @@ -328,7 +328,7 @@ void testSaveSubRepositoryEntities() this.invoiceRepository.save(invoice); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List positions2 = TestUtil.iterableToList(this.positionRepository.findAll()); Assertions.assertEquals(2, positions2.size()); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleMultipleTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleMultipleTest.java index 78869b9b..3c406bde 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleMultipleTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleMultipleTest.java @@ -19,8 +19,8 @@ import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; - import org.springframework.beans.factory.annotation.Autowired; + import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; @@ -28,7 +28,7 @@ import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; import software.xdev.spring.data.eclipse.store.integration.repositories.Owner; import software.xdev.spring.data.eclipse.store.integration.repositories.OwnerRepository; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; @DefaultTestAnnotations @@ -39,7 +39,7 @@ class SimpleMultipleTest @Autowired private OwnerRepository ownerRepository; @Autowired - private EclipseStoreStorage storage; + private EclipseStoreClientConfiguration configuration; @Test void testBasicSaveAndFindAll() @@ -53,7 +53,7 @@ void testBasicSaveAndFindAll() this.ownerRepository.save(owner); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.customerRepository.findAll()); Assertions.assertEquals(1, customers.size()); @@ -84,7 +84,7 @@ void testMultipleSaveAndFindAll() this.ownerRepository.save(owner2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.customerRepository.findAll()); Assertions.assertEquals(2, customers.size()); @@ -115,7 +115,7 @@ void testBasicRemove() this.ownerRepository.delete(owner); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.customerRepository.findAll()); Assertions.assertTrue(customers.isEmpty()); @@ -150,7 +150,7 @@ void testBasicChange() this.ownerRepository.save(owner); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { // Check saved customer final List customers = TestUtil.iterableToList(this.customerRepository.findAll()); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleSingleTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleSingleTest.java index 992d2e01..d4402950 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleSingleTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleSingleTest.java @@ -18,8 +18,6 @@ import java.util.List; import java.util.Optional; -import org.springframework.beans.factory.annotation.Autowired; - import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; import org.springframework.beans.factory.annotation.Autowired; @@ -33,7 +31,7 @@ import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerNotCrud; import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerNotCrudRepository; import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; @DefaultTestAnnotations @@ -45,13 +43,13 @@ class SimpleSingleTest private CustomerAsRecordRepository recordRepository; @Autowired - private EclipseStoreStorage storage; + private EclipseStoreClientConfiguration configuration; @Test void testNullFindAll() { TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.repository.findAll()); Assertions.assertTrue(customers.isEmpty()); @@ -66,7 +64,7 @@ void testBasicSaveAndFindSingleRecords() this.recordRepository.save(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.recordRepository.findAll()); Assertions.assertEquals(1, customers.size()); @@ -84,7 +82,7 @@ void testBasicSaveAndFindMultipleRecords() this.recordRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.recordRepository.findAll()); final CustomerAsRecord foundCustomer = @@ -108,7 +106,7 @@ void testBasicSaveAndFindByFirstNameRecords() this.recordRepository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Optional foundCustomer = this.recordRepository.findByFirstName(TestData.FIRST_NAME); @@ -139,7 +137,7 @@ void testBasicSaveAndFindAll() this.repository.save(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.repository.findAll()); Assertions.assertEquals(1, customers.size()); @@ -157,7 +155,7 @@ void testDoubleSaveAndFindAll() this.repository.save(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Optional foundCustomer = this.repository.findByFirstName(TestData.FIRST_NAME_ALTERNATIVE); @@ -173,7 +171,7 @@ void testBasicSaveAndFindAllWithNotCrudRepository(@Autowired final CustomerNotCr notCrudRepository.save(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(notCrudRepository.findAll()); Assertions.assertEquals(1, customers.size()); @@ -191,7 +189,7 @@ void testMultipleSaveAndFindAll() this.repository.save(customer2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.repository.findAll()); Assertions.assertEquals(2, customers.size()); @@ -213,7 +211,7 @@ void testBasicRemove() this.repository.delete(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.repository.findAll()); Assertions.assertTrue(customers.isEmpty()); @@ -234,7 +232,7 @@ void testBasicChange() this.repository.save(customer); // Check saved customer TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.repository.findAll()); Assertions.assertEquals(1, customers.size()); @@ -247,7 +245,7 @@ void testBasicChange() @Test void testRestart() { - TestUtil.restartDatastore(this.storage); + TestUtil.restartDatastore(this.configuration); final List customers = TestUtil.iterableToList(this.repository.findAll()); Assertions.assertTrue(customers.isEmpty()); } @@ -257,7 +255,7 @@ void testSaveWithRestart() { final Customer customer = new Customer(TestData.FIRST_NAME, TestData.LAST_NAME); this.repository.save(customer); - TestUtil.restartDatastore(this.storage); + TestUtil.restartDatastore(this.configuration); // Automatically restarts if needed final List customers = TestUtil.iterableToList(this.repository.findAll()); Assertions.assertEquals(1, customers.size()); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SpecificInterfacesTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SpecificInterfacesTest.java index 613c1c39..fd8deb26 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SpecificInterfacesTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SpecificInterfacesTest.java @@ -35,7 +35,7 @@ import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerListPagingAndSorting; import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerPagingAndSorting; import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerSimple; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; @DefaultTestAnnotations @@ -53,7 +53,7 @@ class SpecificInterfacesTest private CustomerEclipseStoreListPagingAndSortingRepository listPagingAndSortingRepository; @Autowired - private EclipseStoreStorage storage; + private EclipseStoreClientConfiguration configuration; @Test void testSimple() @@ -62,7 +62,7 @@ void testSimple() this.repository.save(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = this.repository.findAll(); Assertions.assertEquals(1, customers.size()); @@ -78,7 +78,7 @@ void testCrud() this.crudRepository.save(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.crudRepository.findAll()); Assertions.assertEquals(1, customers.size()); @@ -94,7 +94,7 @@ void testListCrud() this.listCrudRepository.save(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = this.listCrudRepository.findAll(); Assertions.assertEquals(1, customers.size()); @@ -107,7 +107,7 @@ void testListCrud() void testPagingAndSorting() { TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.pagingAndSortingRepository.findAll( @@ -121,7 +121,7 @@ void testPagingAndSorting() void testListPagingAndSorting() { TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = this.listPagingAndSortingRepository.findAll( Sort.unsorted()); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/StressTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/StressTest.java index 8d97fcd0..1c226687 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/StressTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/StressTest.java @@ -21,13 +21,13 @@ import org.junit.jupiter.api.Assertions; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.ValueSource; - import org.springframework.beans.factory.annotation.Autowired; + import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; @DefaultTestAnnotations @@ -37,7 +37,7 @@ class StressTest private CustomerRepository repository; @Autowired - private EclipseStoreStorage storage; + private EclipseStoreClientConfiguration configuration; /** * @param customerCount beyond 5_000 takes quite a long time. That's why 5_000 is the biggest number for single @@ -52,7 +52,7 @@ void testSaveSingleAndRestoreManyCustomers(final int customerCount) ); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.repository.findAll()); Assertions.assertEquals(customerCount, customers.size()); @@ -71,7 +71,7 @@ void testSaveBulkAndRestoreManyCustomers(final int customerCount) ); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List customers = TestUtil.iterableToList(this.repository.findAll()); Assertions.assertEquals(customerCount, customers.size()); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/WorkingCopyTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/WorkingCopyTests.java index 55974dec..df65f9ee 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/WorkingCopyTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/WorkingCopyTests.java @@ -29,7 +29,7 @@ import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; import software.xdev.spring.data.eclipse.store.integration.repositories.Node; import software.xdev.spring.data.eclipse.store.integration.repositories.NodeRepository; -import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; @SuppressWarnings("OptionalGetWithoutIsPresent") @@ -44,7 +44,7 @@ public class WorkingCopyTests @Autowired NodeRepository nodeRepository; @Autowired - private EclipseStoreStorage storage; + private EclipseStoreClientConfiguration configuration; @Test void testBasicChangeOnlyAfterSave() @@ -66,7 +66,7 @@ void testBasicChangeOnlyAfterSave() this.customerRepository.save(customer); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { // Check saved customer final List customers2 = TestUtil.iterableToList(this.customerRepository.findAll()); @@ -115,7 +115,7 @@ void testStoreGraphWithCircularRelation() this.nodeRepository.save(parentNode1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List loadedNodes = TestUtil.iterableToList(this.nodeRepository.findAll()); Assertions.assertEquals(3, loadedNodes.size()); @@ -154,7 +154,7 @@ void testStoreGraphWithCircularRelationWithDoubleSave() this.nodeRepository.save(parentNode2); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List loadedNodes = TestUtil.iterableToList(this.nodeRepository.findAll()); Assertions.assertEquals(3, loadedNodes.size()); @@ -194,7 +194,7 @@ void testStoreGraphWithCircularRelationWithTrippleSave() this.nodeRepository.save(childNode); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List loadedNodes = TestUtil.iterableToList(this.nodeRepository.findAll()); Assertions.assertEquals(3, loadedNodes.size()); @@ -250,7 +250,7 @@ void testModifyGraph() this.nodeRepository.saveAll(loadedNodes1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final List loadedNodes3 = TestUtil.iterableToList(this.nodeRepository.findAll()); final Node loadedChildNode2 = @@ -267,7 +267,7 @@ void testBasicFindByFirstNameOneResult() this.customerRepository.save(customer1); TestUtil.doBeforeAndAfterRestartOfDatastore( - this.storage, + this.configuration, () -> { final Optional foundCustomer = this.customerRepository.findByFirstName(TestData.FIRST_NAME); Assertions.assertNotSame(customer1, foundCustomer.get()); From ea9987441716dbc585a19af6a81f721ea5dd2131 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Wed, 6 Mar 2024 15:48:17 +0100 Subject: [PATCH 24/98] Added Java Version to root module --- pom.xml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pom.xml b/pom.xml index 8d2e0206..18253e0f 100644 --- a/pom.xml +++ b/pom.xml @@ -14,6 +14,11 @@ https://xdev.software + + 17 + ${javaVersion} + + spring-data-eclipse-store spring-data-eclipse-store-demo From 733314350e0c3445af2016309da333f26ebc1842 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Thu, 7 Mar 2024 07:35:31 +0100 Subject: [PATCH 25/98] Added Javadoc --- .../PersistenceInvoiceConfiguration.java | 2 +- .../PersistencePersonConfiguration.java | 2 +- .../store/repository/EclipseStoreStorage.java | 2 +- ...efaultEclipseStoreClientConfiguration.java | 5 +++++ .../EclipseStoreClientConfiguration.java | 22 ++++++++++++++++++- ...StoreRepositoryConfigurationExtension.java | 6 +++++ ...EclipseStoreStorageFoundationProvider.java | 6 ++++- .../EnableEclipseStoreRepositories.java | 8 +++++++ 8 files changed, 48 insertions(+), 5 deletions(-) diff --git a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/PersistenceInvoiceConfiguration.java b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/PersistenceInvoiceConfiguration.java index a4080493..319ac98e 100644 --- a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/PersistenceInvoiceConfiguration.java +++ b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/PersistenceInvoiceConfiguration.java @@ -20,7 +20,7 @@ public class PersistenceInvoiceConfiguration extends EclipseStoreClientConfiguration { @Override - public EmbeddedStorageFoundation getEmbeddedStorageFoundation() + public EmbeddedStorageFoundation createEmbeddedStorageFoundation() { return Foundation(Storage.Configuration(Storage.FileProvider(Path.of("storage-invoice")))); } diff --git a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/PersistencePersonConfiguration.java b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/PersistencePersonConfiguration.java index afa502e1..5beffdf0 100644 --- a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/PersistencePersonConfiguration.java +++ b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/person/PersistencePersonConfiguration.java @@ -20,7 +20,7 @@ public class PersistencePersonConfiguration extends EclipseStoreClientConfiguration { @Override - public EmbeddedStorageFoundation getEmbeddedStorageFoundation() + public EmbeddedStorageFoundation createEmbeddedStorageFoundation() { return Foundation(Storage.Configuration(Storage.FileProvider(Path.of("storage-person")))); } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java index 58a1605c..32800225 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java @@ -78,7 +78,7 @@ private synchronized void ensureEntitiesInRoot() LOG.info("Starting storage..."); this.root = new Root(); final EmbeddedStorageFoundation embeddedStorageFoundation = - this.foundationProvider.getEmbeddedStorageFoundation(); + this.foundationProvider.createEmbeddedStorageFoundation(); embeddedStorageFoundation.registerTypeHandler(BinaryHandlerImmutableCollectionsSet12.New()); embeddedStorageFoundation.registerTypeHandler(BinaryHandlerImmutableCollectionsList12.New()); this.storageManager = embeddedStorageFoundation.start(this.root); diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/DefaultEclipseStoreClientConfiguration.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/DefaultEclipseStoreClientConfiguration.java index c3aab703..d621947d 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/DefaultEclipseStoreClientConfiguration.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/DefaultEclipseStoreClientConfiguration.java @@ -18,6 +18,11 @@ import org.springframework.context.annotation.Configuration; +/** + * Provides the Default implementation of an {@link EclipseStoreClientConfiguration}. The class can't be final because + * of the {@link Configuration}-Annotation. It's mostly used to check if the user wants the default implementation or if + * he created a different {@link EclipseStoreClientConfiguration}. + */ @Configuration(proxyBeanMethods = false) public class DefaultEclipseStoreClientConfiguration extends EclipseStoreClientConfiguration { diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreClientConfiguration.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreClientConfiguration.java index c7ad20b2..698cf321 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreClientConfiguration.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreClientConfiguration.java @@ -20,15 +20,31 @@ import org.eclipse.store.integrations.spring.boot.types.configuration.EclipseStoreProperties; import org.eclipse.store.storage.embedded.types.EmbeddedStorageFoundation; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.beans.factory.annotation.Qualifier; import org.springframework.context.annotation.Configuration; import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; +/** + * Defines the configuration of a single EclipseStore-Storage. + *

+ * Configuration is possible through default EclipseStore-Behavior.
See EclipseStore documentation + *

+ *

+ * It's also possible to inherit this configuration and override {@link #createEmbeddedStorageFoundation()} + *

+ *

+ * Also creates a singleton reference to a {@link EclipseStoreStorage}. This is to only create one EclipseStore-Storage + * for one configuration. + *

+ */ @Configuration(proxyBeanMethods = false) public abstract class EclipseStoreClientConfiguration implements EclipseStoreStorageFoundationProvider { @Autowired + @Qualifier("eclipseStoreProperties") private EclipseStoreProperties defaultEclipseStoreProperties; @Autowired @@ -46,8 +62,12 @@ public EclipseStoreProvider getStoreProvider() return this.defaultEclipseStoreProvider; } + /** + * Creates a {@link EmbeddedStorageFoundation} out of the two other provided functions {@link #getStoreProvider()} + * and {@link #getStoreConfiguration()}. + */ @Override - public EmbeddedStorageFoundation getEmbeddedStorageFoundation() + public EmbeddedStorageFoundation createEmbeddedStorageFoundation() { return this.getStoreProvider().createStorageFoundation(this.getStoreConfiguration()); } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoryConfigurationExtension.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoryConfigurationExtension.java index af8ca5ca..ecba9603 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoryConfigurationExtension.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoryConfigurationExtension.java @@ -70,6 +70,12 @@ public String getRepositoryFactoryBeanClassName() return EclipseStoreRepositoryFactoryBean.class.getName(); } + /** + * This method puts the {@link EclipseStoreRepositoryFactoryBean#configuration} in the created + * {@link EclipseStoreRepositoryFactoryBean}. This is important to link + * {@link EnableEclipseStoreRepositories#clientConfiguration()} with the actual + * {@link software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage}. + */ @Override public void postProcess(final BeanDefinitionBuilder builder, final AnnotationRepositoryConfigurationSource config) { diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreStorageFoundationProvider.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreStorageFoundationProvider.java index df9e6015..259c87e4 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreStorageFoundationProvider.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreStorageFoundationProvider.java @@ -18,7 +18,11 @@ import org.eclipse.store.storage.embedded.types.EmbeddedStorageFoundation; +/** + * Wraps access to a {@link EmbeddedStorageFoundation} into a single interface to have looser coupling towards + * EclipseStore. + */ public interface EclipseStoreStorageFoundationProvider { - EmbeddedStorageFoundation getEmbeddedStorageFoundation(); + EmbeddedStorageFoundation createEmbeddedStorageFoundation(); } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EnableEclipseStoreRepositories.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EnableEclipseStoreRepositories.java index 9ccc8208..52c149e2 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EnableEclipseStoreRepositories.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EnableEclipseStoreRepositories.java @@ -83,10 +83,18 @@ String CLIENT_CONFIGURATION_ANNOTATION_VALUE = "clientConfiguration"; + /** + * @return the name of a {@link EclipseStoreClientConfiguration} to use. + * {@link DefaultEclipseStoreClientConfiguration} is used if not defined. + */ String clientConfiguration() default "defaultEclipseStoreClientConfiguration"; String CLIENT_CONFIGURATION_CLASS_ANNOTATION_VALUE = "clientConfigurationClass"; + /** + * @return the class of a {@link EclipseStoreClientConfiguration} to use. + * {@link DefaultEclipseStoreClientConfiguration} is used if not defined. + */ Class clientConfigurationClass() default DefaultEclipseStoreClientConfiguration.class; /** From 29d503b50a3386b718b0457d8cf996595390c9c8 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Thu, 7 Mar 2024 08:45:14 +0100 Subject: [PATCH 26/98] Refactored tests --- .../EclipseStoreClientConfiguration.java | 2 + .../helper/StorageDirectoryNameProvider.java | 29 ++++++++++++++ .../{tests => }/IsolatedTestAnnotations.java | 2 +- .../IsolatedTestConfiguration.java | 38 +++++++++++-------- .../isolated/tests/keywords/KeywordsTest.java | 11 ++---- .../tests/special/types/TypesTest.java | 11 ++---- .../{ => shared}/DefaultTestAnnotations.java | 4 +- .../{ => shared}/TestConfiguration.java | 38 +++++++++++-------- .../{ => shared}/repositories/Child.java | 2 +- .../repositories/ChildCustomer.java | 2 +- .../repositories/ChildCustomerRepository.java | 2 +- .../{ => shared}/repositories/Customer.java | 2 +- .../repositories/CustomerAsRecord.java | 2 +- .../CustomerAsRecordRepository.java | 2 +- .../repositories/CustomerNotCrud.java | 2 +- .../CustomerNotCrudRepository.java | 2 +- .../repositories/CustomerRepository.java | 2 +- .../CustomerRepositoryWithHashSet.java | 2 +- ...CustomerRepositoryWithNonFinalHashSet.java | 2 +- .../CustomerRepositoryWithQuery.java | 2 +- .../repositories/CustomerWithChild.java | 2 +- .../CustomerWithChildRepository.java | 2 +- .../repositories/CustomerWithHashSet.java | 2 +- .../CustomerWithNonFinalHashSet.java | 2 +- .../repositories/CustomerWithQuery.java | 2 +- .../{ => shared}/repositories/Node.java | 2 +- .../repositories/NodeRepository.java | 2 +- .../{ => shared}/repositories/Owner.java | 2 +- .../repositories/OwnerRepository.java | 2 +- .../repositories/ParentCustomer.java | 2 +- .../ParentCustomerRepository.java | 2 +- .../repositories/SubCustomer.java | 2 +- .../repositories/SubCustomerRepository.java | 2 +- .../repositories/id/CustomerWithIdInt.java | 2 +- .../id/CustomerWithIdIntRepository.java | 2 +- .../id/CustomerWithIdInteger.java | 2 +- .../CustomerWithIdIntegerNoAutoGenerate.java | 2 +- ...WithIdIntegerNoAutoGenerateRepository.java | 2 +- .../id/CustomerWithIdIntegerRepository.java | 2 +- .../repositories/id/CustomerWithIdLong.java | 2 +- .../id/CustomerWithIdLongRepository.java | 2 +- .../repositories/id/CustomerWithIdString.java | 2 +- .../id/CustomerWithIdStringRepository.java | 2 +- .../repositories/id/CustomerWithPurchase.java | 2 +- .../id/CustomerWithPurchaseRepository.java | 2 +- .../repositories/id/Purchase.java | 2 +- .../immutables/CustomerWithFinal.java | 2 +- .../immutables/CustomerWithFinalChild.java | 4 +- .../CustomerWithFinalChildRepository.java | 2 +- .../immutables/CustomerWithFinalId.java | 2 +- .../CustomerWithFinalIdRepository.java | 2 +- .../CustomerWithFinalRepository.java | 2 +- .../repositories/interfaces/CustomerCrud.java | 2 +- .../CustomerEclipseStoreCrudRepository.java | 2 +- ...ustomerEclipseStoreListCrudRepository.java | 2 +- ...seStoreListPagingAndSortingRepository.java | 2 +- ...clipseStorePagingAndSortingRepository.java | 2 +- .../CustomerEclipseStoreRepository.java | 2 +- .../interfaces/CustomerListCrud.java | 2 +- .../CustomerListPagingAndSorting.java | 2 +- .../interfaces/CustomerPagingAndSorting.java | 2 +- .../interfaces/CustomerSimple.java | 2 +- .../real/life/example/Article.java | 2 +- .../real/life/example/ArticleGroup.java | 2 +- .../real/life/example/Invoice.java | 2 +- .../real/life/example/InvoiceRepository.java | 2 +- .../real/life/example/Position.java | 2 +- .../real/life/example/PositionRepository.java | 2 +- .../real/life/example/Warehouse.java | 2 +- .../{ => shared}/tests/ChangeRootTests.java | 12 +++--- .../{ => shared}/tests/ConcurrencyTest.java | 12 +++--- .../{ => shared}/tests/FinalTest.java | 20 +++++----- .../{ => shared}/tests/HashSetTest.java | 16 ++++---- .../{ => shared}/tests/IdTest.java | 34 ++++++++--------- .../{ => shared}/tests/InheritanceTest.java | 20 +++++----- .../tests/JpaCompatibilityTest.java | 12 +++--- .../{ => shared}/tests/QueryTest.java | 18 ++++----- .../{ => shared}/tests/RealLifeTests.java | 24 ++++++------ .../tests/SimpleMultipleTest.java | 16 ++++---- .../{ => shared}/tests/SimpleSingleTest.java | 20 +++++----- .../tests/SpecificInterfacesTest.java | 28 +++++++------- .../{ => shared}/tests/StressTest.java | 12 +++--- .../{ => shared}/tests/WorkingCopyTests.java | 16 ++++---- .../src/test/resources/application.properties | 1 - 84 files changed, 277 insertions(+), 243 deletions(-) create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/StorageDirectoryNameProvider.java rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/{tests => }/IsolatedTestAnnotations.java (99%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/{tests => }/IsolatedTestConfiguration.java (55%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/DefaultTestAnnotations.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/TestConfiguration.java (53%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/Child.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/ChildCustomer.java (92%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/ChildCustomerRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/Customer.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerAsRecord.java (92%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerAsRecordRepository.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerNotCrud.java (94%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerNotCrudRepository.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerRepository.java (94%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerRepositoryWithHashSet.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerRepositoryWithNonFinalHashSet.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerRepositoryWithQuery.java (93%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerWithChild.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerWithChildRepository.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerWithHashSet.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerWithNonFinalHashSet.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerWithQuery.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/Node.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/NodeRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/Owner.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/OwnerRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/ParentCustomer.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/ParentCustomerRepository.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/SubCustomer.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/SubCustomerRepository.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdInt.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdIntRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdInteger.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdIntegerRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdLong.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdLongRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdString.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdStringRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithPurchase.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithPurchaseRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/Purchase.java (94%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/immutables/CustomerWithFinal.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/immutables/CustomerWithFinalChild.java (92%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/immutables/CustomerWithFinalChildRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/immutables/CustomerWithFinalId.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/immutables/CustomerWithFinalIdRepository.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/immutables/CustomerWithFinalRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerCrud.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerEclipseStoreCrudRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerEclipseStoreRepository.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerListCrud.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerListPagingAndSorting.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerPagingAndSorting.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerSimple.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/real/life/example/Article.java (93%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/real/life/example/ArticleGroup.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/real/life/example/Invoice.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/real/life/example/InvoiceRepository.java (88%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/real/life/example/Position.java (93%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/real/life/example/PositionRepository.java (88%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/real/life/example/Warehouse.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/ChangeRootTests.java (88%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/ConcurrencyTest.java (92%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/FinalTest.java (73%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/HashSetTest.java (88%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/IdTest.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/InheritanceTest.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/JpaCompatibilityTest.java (85%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/QueryTest.java (94%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/RealLifeTests.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/SimpleMultipleTest.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/SimpleSingleTest.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/SpecificInterfacesTest.java (69%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/StressTest.java (82%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/WorkingCopyTests.java (93%) delete mode 100644 spring-data-eclipse-store/src/test/resources/application.properties diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreClientConfiguration.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreClientConfiguration.java index 698cf321..4247b395 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreClientConfiguration.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreClientConfiguration.java @@ -21,6 +21,7 @@ import org.eclipse.store.storage.embedded.types.EmbeddedStorageFoundation; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Qualifier; +import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; @@ -72,6 +73,7 @@ public EmbeddedStorageFoundation createEmbeddedStorageFoundation() return this.getStoreProvider().createStorageFoundation(this.getStoreConfiguration()); } + @Bean public EclipseStoreStorage getStorageInstance() { if(this.storageInstance == null) diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/StorageDirectoryNameProvider.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/StorageDirectoryNameProvider.java new file mode 100644 index 00000000..d34205b1 --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/StorageDirectoryNameProvider.java @@ -0,0 +1,29 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.helper; + +import java.util.concurrent.atomic.AtomicInteger; + + +public final class StorageDirectoryNameProvider +{ + private static final AtomicInteger seqNumber = new AtomicInteger(1); + + public static String getNewStorageDirectoryPath() + { + return String.format("./target/tempstorage-%05d", seqNumber.getAndIncrement()); + } +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/IsolatedTestAnnotations.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java similarity index 99% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/IsolatedTestAnnotations.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java index 61d27ef1..223efa00 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/IsolatedTestAnnotations.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests; +package software.xdev.spring.data.eclipse.store.integration.isolated; import static org.springframework.test.annotation.DirtiesContext.ClassMode.BEFORE_EACH_TEST_METHOD; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/IsolatedTestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestConfiguration.java similarity index 55% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/IsolatedTestConfiguration.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestConfiguration.java index 7a5cd37d..443c75a6 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/IsolatedTestConfiguration.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestConfiguration.java @@ -13,45 +13,53 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests; +package software.xdev.spring.data.eclipse.store.integration.isolated; +import static org.eclipse.store.storage.embedded.types.EmbeddedStorage.Foundation; + +import java.io.IOException; import java.nio.file.Path; -import org.springframework.beans.factory.DisposableBean; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.beans.factory.annotation.Value; +import org.eclipse.store.storage.embedded.types.EmbeddedStorageFoundation; +import org.eclipse.store.storage.types.Storage; import org.springframework.context.annotation.Configuration; +import org.springframework.context.event.ContextClosedEvent; import org.springframework.context.event.ContextRefreshedEvent; import org.springframework.context.event.EventListener; import org.springframework.util.FileSystemUtils; +import software.xdev.spring.data.eclipse.store.helper.StorageDirectoryNameProvider; import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; @Configuration -@EnableEclipseStoreRepositories -public class IsolatedTestConfiguration implements DisposableBean +@EnableEclipseStoreRepositories( + value = "software.xdev.spring.data.eclipse.store.integration.isolated", + clientConfigurationClass = IsolatedTestConfiguration.class) +public class IsolatedTestConfiguration extends EclipseStoreClientConfiguration { - @Autowired - EclipseStoreClientConfiguration configuration; + private final String storageDirectory = StorageDirectoryNameProvider.getNewStorageDirectoryPath(); - @Value("${org.eclipse.store.storage-directory}") - private String storageDirectory; + @Override + public EmbeddedStorageFoundation createEmbeddedStorageFoundation() + { + return Foundation(Storage.Configuration(Storage.FileProvider(Path.of(this.storageDirectory)))); + } @EventListener public void handleContextRefresh(final ContextRefreshedEvent event) { // Init with empty root object - this.configuration.getStorageInstance().clearData(); + this.getStorageInstance().clearData(); } - @Override - public void destroy() throws Exception + @EventListener + public void handleContextClosed(final ContextClosedEvent event) throws IOException { // End with empty root object - this.configuration.getStorageInstance().clearData(); - this.configuration.getStorageInstance().stop(); + this.getStorageInstance().clearData(); + this.getStorageInstance().stop(); FileSystemUtils.deleteRecursively(Path.of(this.storageDirectory)); } } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java index 90d377b8..0a8e14db 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java @@ -19,11 +19,10 @@ import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Test; import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.test.context.TestPropertySource; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.isolated.tests.IsolatedTestAnnotations; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; +import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestConfiguration; /** @@ -32,14 +31,10 @@ * keywords */ @IsolatedTestAnnotations -@TestPropertySource( - properties = - "org.eclipse.store.storage-directory=./target/keywords-tests-storage" -) class KeywordsTest { @Autowired - private EclipseStoreClientConfiguration configuration; + private IsolatedTestConfiguration configuration; @Test @Disabled("For now we don't need 'existsBy'") diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java index 56cac8f8..1e1c84e3 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java @@ -26,20 +26,15 @@ import org.junit.jupiter.params.provider.MethodSource; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.context.ApplicationContext; -import org.springframework.test.context.TestPropertySource; import software.xdev.spring.data.eclipse.store.exceptions.DataTypeNotSupportedException; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.isolated.tests.IsolatedTestAnnotations; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; +import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestConfiguration; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; @IsolatedTestAnnotations -@TestPropertySource( - properties = - "org.eclipse.store.storage-directory=./target/isolated-tests-storage" -) class TypesTest { public static final String TYPES_DATA_SOURCE = @@ -50,7 +45,7 @@ class TypesTest + ".TypesData#generateNotWorkingData"; @Autowired - private EclipseStoreClientConfiguration configuration; + private IsolatedTestConfiguration configuration; @ParameterizedTest @MethodSource(TYPES_DATA_SOURCE) diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/DefaultTestAnnotations.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/DefaultTestAnnotations.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/DefaultTestAnnotations.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/DefaultTestAnnotations.java index 299800c4..a3ebc833 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/DefaultTestAnnotations.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/DefaultTestAnnotations.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration; +package software.xdev.spring.data.eclipse.store.integration.shared; import static org.springframework.test.annotation.DirtiesContext.ClassMode.BEFORE_EACH_TEST_METHOD; @@ -25,7 +25,6 @@ import org.junit.jupiter.api.extension.ExtendWith; import org.springframework.test.annotation.DirtiesContext; import org.springframework.test.context.ContextConfiguration; -import org.springframework.test.context.TestPropertySource; import org.springframework.test.context.junit.jupiter.SpringExtension; @@ -34,7 +33,6 @@ @ExtendWith(SpringExtension.class) @ContextConfiguration(classes = {TestConfiguration.class}) @DirtiesContext(classMode = BEFORE_EACH_TEST_METHOD) -@TestPropertySource("/application.properties") public @interface DefaultTestAnnotations { } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/TestConfiguration.java similarity index 53% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/TestConfiguration.java index 967b026a..933b0058 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/TestConfiguration.java @@ -13,45 +13,53 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration; +package software.xdev.spring.data.eclipse.store.integration.shared; +import static org.eclipse.store.storage.embedded.types.EmbeddedStorage.Foundation; + +import java.io.IOException; import java.nio.file.Path; -import org.springframework.beans.factory.DisposableBean; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.beans.factory.annotation.Value; +import org.eclipse.store.storage.embedded.types.EmbeddedStorageFoundation; +import org.eclipse.store.storage.types.Storage; import org.springframework.context.annotation.Configuration; +import org.springframework.context.event.ContextClosedEvent; import org.springframework.context.event.ContextRefreshedEvent; import org.springframework.context.event.EventListener; import org.springframework.util.FileSystemUtils; +import software.xdev.spring.data.eclipse.store.helper.StorageDirectoryNameProvider; import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; @Configuration -@EnableEclipseStoreRepositories -public class TestConfiguration implements DisposableBean +@EnableEclipseStoreRepositories( + value = "software.xdev.spring.data.eclipse.store.integration.shared", + clientConfigurationClass = TestConfiguration.class) +public class TestConfiguration extends EclipseStoreClientConfiguration { - @Autowired - EclipseStoreClientConfiguration configuration; + private final String storageDirectory = StorageDirectoryNameProvider.getNewStorageDirectoryPath(); - @Value("${org.eclipse.store.storage-directory}") - private String storageDirectory; + @Override + public EmbeddedStorageFoundation createEmbeddedStorageFoundation() + { + return Foundation(Storage.Configuration(Storage.FileProvider(Path.of(this.storageDirectory)))); + } @EventListener public void handleContextRefresh(final ContextRefreshedEvent event) { // Init with empty root object - this.configuration.getStorageInstance().clearData(); + this.getStorageInstance().clearData(); } - @Override - public void destroy() throws Exception + @EventListener + public void handleContextClosed(final ContextClosedEvent event) throws IOException { // End with empty root object - this.configuration.getStorageInstance().clearData(); - this.configuration.getStorageInstance().stop(); + this.getStorageInstance().clearData(); + this.getStorageInstance().stop(); FileSystemUtils.deleteRecursively(Path.of(this.storageDirectory)); } } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Child.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Child.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Child.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Child.java index c0d24c1a..549da2db 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Child.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Child.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomer.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomer.java similarity index 92% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomer.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomer.java index 7af466b3..a243bdfe 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomer.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomer.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; public class ChildCustomer extends ParentCustomer { diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomerRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomerRepository.java index 46979d77..08622099 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Customer.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Customer.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Customer.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Customer.java index 89e7d4f7..2ef2e24d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Customer.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Customer.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecord.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecord.java similarity index 92% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecord.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecord.java index 0e082bc9..9c9df6c7 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecord.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecord.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecordRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecordRepository.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecordRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecordRepository.java index 0061c6de..a28803fa 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecordRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecordRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.Optional; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrud.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrud.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrud.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrud.java index 99140aa9..fe960ddd 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrud.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrud.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrudRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrudRepository.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrudRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrudRepository.java index abf8c087..df0ff39e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrudRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrudRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepository.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepository.java index cd2a570b..7c90c670 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.List; import java.util.Optional; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithHashSet.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithHashSet.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithHashSet.java index 045d6c17..cf53de00 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithHashSet.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithHashSet.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithNonFinalHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithNonFinalHashSet.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithNonFinalHashSet.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithNonFinalHashSet.java index 3c729c1b..e459843e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithNonFinalHashSet.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithNonFinalHashSet.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithQuery.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithQuery.java similarity index 93% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithQuery.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithQuery.java index 69baff3c..f845fed8 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithQuery.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithQuery.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.List; import java.util.Optional; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChild.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChild.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChild.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChild.java index 668e67f2..272318d8 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChild.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChild.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChildRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChildRepository.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChildRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChildRepository.java index 65a8cf5e..e74bc81b 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChildRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChildRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.Optional; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithHashSet.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithHashSet.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithHashSet.java index e6a2c95c..b46e5b72 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithHashSet.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithHashSet.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.HashSet; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithNonFinalHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithNonFinalHashSet.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithNonFinalHashSet.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithNonFinalHashSet.java index dc8bbefd..45009fd3 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithNonFinalHashSet.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithNonFinalHashSet.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.HashSet; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithQuery.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithQuery.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithQuery.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithQuery.java index a4ad8257..43d6d234 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithQuery.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithQuery.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Node.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Node.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Node.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Node.java index d359f8a4..27764c50 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Node.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Node.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.ArrayList; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/NodeRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/NodeRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/NodeRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/NodeRepository.java index 53555be9..efa0d716 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/NodeRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/NodeRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Owner.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Owner.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Owner.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Owner.java index f49d78f4..896ed6a2 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Owner.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Owner.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/OwnerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/OwnerRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/OwnerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/OwnerRepository.java index e3b5b5dc..ce29f850 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/OwnerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/OwnerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomer.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomer.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomer.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomer.java index c897bc62..2256d706 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomer.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomer.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomerRepository.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomerRepository.java index a76780b6..29057f43 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import org.springframework.data.repository.CrudRepository; import org.springframework.data.repository.PagingAndSortingRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomer.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomer.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomer.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomer.java index d7cd1a98..e72316ff 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomer.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomer.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; public class SubCustomer extends Customer { diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomerRepository.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomerRepository.java index e95e3785..321323a2 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInt.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInt.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInt.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInt.java index ba16d8d4..4b4f4562 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInt.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInt.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntRepository.java index b000d441..888a123d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInteger.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInteger.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInteger.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInteger.java index 096d2466..b0a9e1e8 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInteger.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInteger.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java index 5fa96ed0..7618633b 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java index c86528c3..7ddc6171 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerRepository.java index 79a534da..f6de36f0 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLong.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLong.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLong.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLong.java index e2c003ce..49d3f384 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLong.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLong.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLongRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLongRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLongRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLongRepository.java index 29f340f0..e86acdcc 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLongRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLongRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdString.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdString.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdString.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdString.java index 43045152..eaa32ad8 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdString.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdString.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdStringRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdStringRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdStringRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdStringRepository.java index 85e75ec9..c40f899e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdStringRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdStringRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchase.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchase.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchase.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchase.java index 69e1e80d..c37d67c5 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchase.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchase.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import java.util.ArrayList; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchaseRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchaseRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchaseRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchaseRepository.java index aa8264e3..2f986e3a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchaseRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchaseRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/Purchase.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/Purchase.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/Purchase.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/Purchase.java index 69479540..52de0753 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/Purchase.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/Purchase.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinal.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinal.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinal.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinal.java index 5eae308e..d0ddd64d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinal.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinal.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChild.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChild.java similarity index 92% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChild.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChild.java index f74c8326..1bde2eae 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChild.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChild.java @@ -13,12 +13,12 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; import java.util.List; import java.util.Objects; -import software.xdev.spring.data.eclipse.store.integration.repositories.Child; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Child; public class CustomerWithFinalChild diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChildRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChildRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChildRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChildRepository.java index 0eb44e4a..22e9d951 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChildRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChildRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; import org.springframework.data.repository.CrudRepository; import org.springframework.data.repository.PagingAndSortingRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalId.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalId.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalId.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalId.java index f4cad237..c10b2d74 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalId.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalId.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalIdRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalIdRepository.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalIdRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalIdRepository.java index 7ce5b1fd..ebb4df9e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalIdRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalIdRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalRepository.java index 607c3bf3..519b3f95 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; import org.springframework.data.repository.CrudRepository; import org.springframework.data.repository.PagingAndSortingRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerCrud.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerCrud.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerCrud.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerCrud.java index 9e7d49ce..7d9778f7 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerCrud.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerCrud.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreCrudRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreCrudRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreCrudRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreCrudRepository.java index 4c9bd223..64ff9274 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreCrudRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreCrudRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreCrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java index cc4337fa..5fb57f8f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreListCrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java index 9fbfea7e..c0d0fb6d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreListPagingAndSortingRepositoryRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java index 7d45e15a..14b444c2 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStorePagingAndSortingRepositoryRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreRepository.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreRepository.java index b3feecb1..0a476e5f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListCrud.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListCrud.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListCrud.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListCrud.java index 56e2087d..fe5c0c02 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListCrud.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListCrud.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListPagingAndSorting.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListPagingAndSorting.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListPagingAndSorting.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListPagingAndSorting.java index 2e848482..89ef5b9f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListPagingAndSorting.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListPagingAndSorting.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerPagingAndSorting.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerPagingAndSorting.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerPagingAndSorting.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerPagingAndSorting.java index 06ba144f..4cf9b1c3 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerPagingAndSorting.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerPagingAndSorting.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerSimple.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerSimple.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerSimple.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerSimple.java index 775f3198..e5f8404b 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerSimple.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerSimple.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Article.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Article.java similarity index 93% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Article.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Article.java index dd418fcb..f67cc905 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Article.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Article.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; import java.util.ArrayList; import java.util.Collections; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/ArticleGroup.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/ArticleGroup.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/ArticleGroup.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/ArticleGroup.java index fd6e4bac..d8378911 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/ArticleGroup.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/ArticleGroup.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; public class ArticleGroup { diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Invoice.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Invoice.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Invoice.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Invoice.java index 8af20a95..498f7492 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Invoice.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Invoice.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/InvoiceRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/InvoiceRepository.java similarity index 88% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/InvoiceRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/InvoiceRepository.java index 93c9e286..b86bd835 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/InvoiceRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/InvoiceRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Position.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Position.java similarity index 93% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Position.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Position.java index 29b55bc6..85f40363 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Position.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Position.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; import java.util.List; import java.util.Optional; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/PositionRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/PositionRepository.java similarity index 88% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/PositionRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/PositionRepository.java index d7e98068..3692bbc5 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/PositionRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/PositionRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Warehouse.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Warehouse.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Warehouse.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Warehouse.java index 9f7bd011..ce814b84 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Warehouse.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Warehouse.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; import java.util.HashSet; import java.util.Set; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ChangeRootTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ChangeRootTests.java similarity index 88% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ChangeRootTests.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ChangeRootTests.java index bf55a1ec..a229a91b 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ChangeRootTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ChangeRootTests.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; @@ -22,10 +22,10 @@ import org.springframework.beans.factory.annotation.Autowired; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.repositories.Node; -import software.xdev.spring.data.eclipse.store.integration.repositories.NodeRepository; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Node; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.NodeRepository; @DefaultTestAnnotations @@ -39,7 +39,7 @@ public class ChangeRootTests @Autowired private NodeRepository repository; @Autowired - private EclipseStoreClientConfiguration configuration; + private TestConfiguration configuration; //@formatter:off /** diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ConcurrencyTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ConcurrencyTest.java similarity index 92% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ConcurrencyTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ConcurrencyTest.java index f953f421..9cf7b0fa 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ConcurrencyTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ConcurrencyTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; @@ -32,10 +32,10 @@ import org.springframework.beans.factory.annotation.Autowired; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; @SuppressWarnings("OptionalGetWithoutIsPresent") @@ -47,7 +47,7 @@ class ConcurrencyTest private CustomerRepository repository; @Autowired - private EclipseStoreClientConfiguration configuration; + private TestConfiguration configuration; private final List testCustomers = IntStream.range(1, 100).mapToObj((i) -> new Customer(CUSTOMER_NO + i, "")).toList(); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/FinalTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/FinalTest.java similarity index 73% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/FinalTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/FinalTest.java index 38b17145..c50022cb 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/FinalTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/FinalTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; @@ -24,14 +24,14 @@ import software.xdev.spring.data.eclipse.store.exceptions.IdFieldFinalException; import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinal; -import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalChild; -import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalChildRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalId; -import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalIdRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalRepository; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinal; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinalChild; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinalChildRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinalId; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinalIdRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinalRepository; @DefaultTestAnnotations @@ -45,7 +45,7 @@ class FinalTest CustomerWithFinalIdRepository withFinalIdRepository; @Autowired - EclipseStoreClientConfiguration configuration; + TestConfiguration configuration; @Test void testSaveAndFindSingle() diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/HashSetTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/HashSetTest.java similarity index 88% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/HashSetTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/HashSetTest.java index 6c7624bd..df152e5f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/HashSetTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/HashSetTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; import java.util.Set; @@ -24,12 +24,12 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepositoryWithHashSet; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepositoryWithNonFinalHashSet; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithHashSet; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithNonFinalHashSet; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepositoryWithHashSet; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepositoryWithNonFinalHashSet; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerWithHashSet; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerWithNonFinalHashSet; @DefaultTestAnnotations @@ -41,7 +41,7 @@ class HashSetTest private CustomerRepositoryWithNonFinalHashSet nonFinalRepository; @Autowired - private EclipseStoreClientConfiguration configuration; + private TestConfiguration configuration; @Test void testSaveAndFindAll() diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/IdTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/IdTest.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/IdTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/IdTest.java index 5208f727..6c100760 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/IdTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/IdTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import static software.xdev.spring.data.eclipse.store.helper.TestUtil.restartDatastore; @@ -26,22 +26,22 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdInt; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdIntRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdInteger; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdIntegerNoAutoGenerate; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdIntegerNoAutoGenerateRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdIntegerRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdLong; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdLongRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdString; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdStringRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithPurchase; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithPurchaseRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.Purchase; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdInt; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdIntRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdInteger; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdIntegerNoAutoGenerate; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdIntegerNoAutoGenerateRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdIntegerRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdLong; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdLongRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdString; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdStringRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithPurchase; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithPurchaseRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.Purchase; import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; @SuppressWarnings("OptionalGetWithoutIsPresent") @@ -49,7 +49,7 @@ class IdTest { @Autowired - private EclipseStoreClientConfiguration configuration; + private TestConfiguration configuration; @Test void testCreateSingleWithAutoIdInteger(@Autowired final CustomerWithIdIntegerRepository customerRepository) diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/InheritanceTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/InheritanceTest.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/InheritanceTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/InheritanceTest.java index 5f67f29a..3920782f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/InheritanceTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/InheritanceTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; @@ -23,14 +23,14 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.repositories.ChildCustomer; -import software.xdev.spring.data.eclipse.store.integration.repositories.ChildCustomerRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.ParentCustomer; -import software.xdev.spring.data.eclipse.store.integration.repositories.ParentCustomerRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.SubCustomer; -import software.xdev.spring.data.eclipse.store.integration.repositories.SubCustomerRepository; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.ChildCustomer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.ChildCustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.ParentCustomer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.ParentCustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.SubCustomer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.SubCustomerRepository; @DefaultTestAnnotations @@ -43,7 +43,7 @@ class InheritanceTest @Autowired private SubCustomerRepository subCustomerRepository; @Autowired - private EclipseStoreClientConfiguration configuration; + private TestConfiguration configuration; @Test void testSaveChildFindParent() diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/JpaCompatibilityTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/JpaCompatibilityTest.java similarity index 85% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/JpaCompatibilityTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/JpaCompatibilityTest.java index 41b87838..73ab0455 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/JpaCompatibilityTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/JpaCompatibilityTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; import java.util.Optional; @@ -24,10 +24,10 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepositoryWithQuery; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithQuery; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepositoryWithQuery; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerWithQuery; @DefaultTestAnnotations @@ -37,7 +37,7 @@ class JpaCompatibilityTest private CustomerRepositoryWithQuery customerRepository; @Autowired - private EclipseStoreClientConfiguration configuration; + private TestConfiguration configuration; @Test void testUseQueryAnnotationFindAll() diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/QueryTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/QueryTest.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/QueryTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/QueryTest.java index 0808fcb6..a18af6fb 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/QueryTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/QueryTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; import java.util.Optional; @@ -27,13 +27,13 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.repositories.Child; -import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithChild; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithChildRepository; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Child; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerWithChild; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerWithChildRepository; @DefaultTestAnnotations @@ -45,7 +45,7 @@ class QueryTest private CustomerWithChildRepository customerWithChildRepository; @Autowired - private EclipseStoreClientConfiguration configuration; + private TestConfiguration configuration; @Test void testBasicFindAllByLastNameTwoResults() diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/RealLifeTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/RealLifeTests.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/RealLifeTests.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/RealLifeTests.java index ff8c6669..47d1b1bf 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/RealLifeTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/RealLifeTests.java @@ -13,9 +13,9 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; -import static software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Position.getPositionWithArticleWithName; +import static software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.Position.getPositionWithArticleWithName; import java.util.ArrayList; import java.util.Arrays; @@ -27,15 +27,15 @@ import org.springframework.beans.factory.annotation.Autowired; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Article; -import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.ArticleGroup; -import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Invoice; -import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.InvoiceRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Position; -import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.PositionRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Warehouse; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.Article; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.ArticleGroup; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.Invoice; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.InvoiceRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.Position; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.PositionRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.Warehouse; @SuppressWarnings("OptionalGetWithoutIsPresent") @@ -54,7 +54,7 @@ public class RealLifeTests @Autowired PositionRepository positionRepository; @Autowired - private EclipseStoreClientConfiguration configuration; + private TestConfiguration configuration; private Invoice buildDefaultModel() { diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleMultipleTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleMultipleTest.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleMultipleTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleMultipleTest.java index 3c406bde..d2d36f00 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleMultipleTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleMultipleTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; @@ -23,12 +23,12 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.Owner; -import software.xdev.spring.data.eclipse.store.integration.repositories.OwnerRepository; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Owner; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.OwnerRepository; @DefaultTestAnnotations @@ -39,7 +39,7 @@ class SimpleMultipleTest @Autowired private OwnerRepository ownerRepository; @Autowired - private EclipseStoreClientConfiguration configuration; + private TestConfiguration configuration; @Test void testBasicSaveAndFindAll() diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleSingleTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleSingleTest.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleSingleTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleSingleTest.java index d4402950..4c95363c 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleSingleTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleSingleTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; import java.util.Optional; @@ -24,14 +24,14 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerAsRecord; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerAsRecordRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerNotCrud; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerNotCrudRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerAsRecord; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerAsRecordRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerNotCrud; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerNotCrudRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; @DefaultTestAnnotations @@ -43,7 +43,7 @@ class SimpleSingleTest private CustomerAsRecordRepository recordRepository; @Autowired - private EclipseStoreClientConfiguration configuration; + private TestConfiguration configuration; @Test void testNullFindAll() diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SpecificInterfacesTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SpecificInterfacesTest.java similarity index 69% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SpecificInterfacesTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SpecificInterfacesTest.java index fd8deb26..54256c45 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SpecificInterfacesTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SpecificInterfacesTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; @@ -24,18 +24,18 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerCrud; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerEclipseStoreCrudRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerEclipseStoreListCrudRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerEclipseStoreListPagingAndSortingRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerEclipseStorePagingAndSortingRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerEclipseStoreRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerListCrud; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerListPagingAndSorting; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerPagingAndSorting; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerSimple; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerCrud; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerEclipseStoreCrudRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerEclipseStoreListCrudRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerEclipseStoreListPagingAndSortingRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerEclipseStorePagingAndSortingRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerEclipseStoreRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerListCrud; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerListPagingAndSorting; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerPagingAndSorting; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerSimple; @DefaultTestAnnotations @@ -53,7 +53,7 @@ class SpecificInterfacesTest private CustomerEclipseStoreListPagingAndSortingRepository listPagingAndSortingRepository; @Autowired - private EclipseStoreClientConfiguration configuration; + private TestConfiguration configuration; @Test void testSimple() diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/StressTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/StressTest.java similarity index 82% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/StressTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/StressTest.java index 1c226687..7da4d9c1 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/StressTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/StressTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; import java.util.stream.IntStream; @@ -24,10 +24,10 @@ import org.springframework.beans.factory.annotation.Autowired; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; @DefaultTestAnnotations @@ -37,7 +37,7 @@ class StressTest private CustomerRepository repository; @Autowired - private EclipseStoreClientConfiguration configuration; + private TestConfiguration configuration; /** * @param customerCount beyond 5_000 takes quite a long time. That's why 5_000 is the biggest number for single diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/WorkingCopyTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/WorkingCopyTests.java similarity index 93% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/WorkingCopyTests.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/WorkingCopyTests.java index df65f9ee..b580ec8a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/WorkingCopyTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/WorkingCopyTests.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; import java.util.Optional; @@ -24,12 +24,12 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.Node; -import software.xdev.spring.data.eclipse.store.integration.repositories.NodeRepository; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Node; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.NodeRepository; @SuppressWarnings("OptionalGetWithoutIsPresent") @@ -44,7 +44,7 @@ public class WorkingCopyTests @Autowired NodeRepository nodeRepository; @Autowired - private EclipseStoreClientConfiguration configuration; + private TestConfiguration configuration; @Test void testBasicChangeOnlyAfterSave() diff --git a/spring-data-eclipse-store/src/test/resources/application.properties b/spring-data-eclipse-store/src/test/resources/application.properties deleted file mode 100644 index 8f7f502f..00000000 --- a/spring-data-eclipse-store/src/test/resources/application.properties +++ /dev/null @@ -1 +0,0 @@ -org.eclipse.store.storage-directory=./target/tempstorage From aef12a7ad1a528badd4794e4a38730c8771a2402 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Thu, 7 Mar 2024 08:51:41 +0100 Subject: [PATCH 27/98] Fix Checkstyle error --- .../repository/config/EnableEclipseStoreRepositories.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EnableEclipseStoreRepositories.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EnableEclipseStoreRepositories.java index 52c149e2..405e033a 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EnableEclipseStoreRepositories.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EnableEclipseStoreRepositories.java @@ -95,7 +95,8 @@ * @return the class of a {@link EclipseStoreClientConfiguration} to use. * {@link DefaultEclipseStoreClientConfiguration} is used if not defined. */ - Class clientConfigurationClass() default DefaultEclipseStoreClientConfiguration.class; + Class clientConfigurationClass() + default DefaultEclipseStoreClientConfiguration.class; /** * Returns the postfix to be used when looking up custom repository implementations. Defaults to {@literal Impl} . From d509676ad2a15cdde93407048b2fa27b07a06877 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Thu, 7 Mar 2024 09:07:03 +0100 Subject: [PATCH 28/98] Added documentation for configuration --- CHANGELOG.md | 4 +++ README.md | 14 ++++----- docs/modules/ROOT/nav.adoc | 1 + docs/modules/ROOT/pages/configuration.adoc | 30 +++++++++++++++++++ docs/modules/ROOT/pages/installation.adoc | 8 +++-- .../PersistenceInvoiceConfiguration.java | 5 ++-- 6 files changed, 50 insertions(+), 12 deletions(-) create mode 100644 docs/modules/ROOT/pages/configuration.adoc diff --git a/CHANGELOG.md b/CHANGELOG.md index faad4e2e..96797abe 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,7 @@ +# 1.0.4 + +* Added possibility to use multiple storages + # 1.0.3 * Added the EclipseStoreDataImporter to import data from JPA repositories. diff --git a/README.md b/README.md index 28b5aded..1affa186 100644 --- a/README.md +++ b/README.md @@ -55,12 +55,13 @@ instructions** are in the documentation](https://xdev-software.github.io/spring- ## Demo -To see how easy it is to implement EclipseStore in your Spring project, take a look at the three -[demos](./spring-data-eclipse-store-demo):
-A [simple](./spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/simple), a -more [complex demo](./spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex) -and -a [demo with coexisting JPA](./spring-data-eclipse-store-jpa/src/main/java/software/xdev/spring/data/eclipse/store/jpa). +To see how easy it is to implement EclipseStore in your Spring project, take a look at +the [demos](./spring-data-eclipse-store-demo): + +* [Simple demo](https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/simple) +* [Complex demo](https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex) +* [Demo with coexisting JPA](https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-jpa/src/main/java/software/xdev/spring/data/eclipse/store/jpa) +* [Dual storage demo](https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage) > [!NOTE] > Since the library is using reflection to copy data, the following JVM-Arguments may have to be set: @@ -71,7 +72,6 @@ a [demo with coexisting JPA](./spring-data-eclipse-store-jpa/src/main/java/softw > --add-opens=java.base/java.time=ALL-UNNAMED > ``` - ## Support If you need support as soon as possible, and you can't wait for any pull request, feel free to diff --git a/docs/modules/ROOT/nav.adoc b/docs/modules/ROOT/nav.adoc index 8fd7ab9b..86dc85bc 100644 --- a/docs/modules/ROOT/nav.adoc +++ b/docs/modules/ROOT/nav.adoc @@ -1,5 +1,6 @@ * xref:index.adoc[Home] * xref:installation.adoc[Installation] +* xref:configuration.adoc[Configuration] * xref:working-copies.adoc[Working Copies] * xref:migration.adoc[Migration] * xref:known-issues.adoc[Known issues] diff --git a/docs/modules/ROOT/pages/configuration.adoc b/docs/modules/ROOT/pages/configuration.adoc new file mode 100644 index 00000000..57659125 --- /dev/null +++ b/docs/modules/ROOT/pages/configuration.adoc @@ -0,0 +1,30 @@ += Configuration + +== EclipseStore Spring-Boot Configuration + +The simplest way to configure your storage is by using the key/value pairs in a configuration file as described in the https://docs.eclipsestore.io/manual/misc/integrations/spring-boot.html[EclipseStore documentation]. + +== Detailed Configuration + +If you need more control or want to configure your storage in code, we provide a simple Configuration class which can be used as follows: + +[source,java,title="Demo configuration"] +---- +import org.eclipse.store.storage.embedded.types.EmbeddedStorage; +import org.eclipse.store.storage.embedded.types.EmbeddedStorageFoundation; +import org.eclipse.store.storage.types.Storage; +... +@Configuration +@EnableEclipseStoreRepositories(clientConfigurationClass = DemoConfiguration.class) +public class DemoConfiguration extends EclipseStoreClientConfiguration +{ + @Override + public EmbeddedStorageFoundation createEmbeddedStorageFoundation() + { + return EmbeddedStorage.Foundation(Storage.Configuration(Storage.FileProvider(Path.of("demo-storage")))); + } +} +---- +The method ``createEmbeddedStorageFoundation`` could return a much more complicated ``EmbeddedStorageFoundation`` as described here in the https://docs.eclipsestore.io/manual/storage/configuration/index.html[EclipseStore documentation about configuration and foundations]. + +This also enables you to use multiple EclipseStore-Storages in one project. See the https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage[Dual storages demo]. diff --git a/docs/modules/ROOT/pages/installation.adoc b/docs/modules/ROOT/pages/installation.adoc index fdd469b3..f37272e9 100644 --- a/docs/modules/ROOT/pages/installation.adoc +++ b/docs/modules/ROOT/pages/installation.adoc @@ -38,8 +38,12 @@ Since the library is using reflection to copy data, the following JVM-Arguments == Demo -To see how easy it is to implement EclipseStore in your Spring project, take a look at the three https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo[demos]: -A https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/simple[simple], a more https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex[complex demo] and a https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-jpa/src/main/java/software/xdev/spring/data/eclipse/store/jpa[demo with coexisting JPA]. +To see how easy it is to implement EclipseStore in your Spring project, take a look at the https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo[demos]: + +* https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/simple[Simple demo] +* https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex[Complex demo] +* https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-jpa/src/main/java/software/xdev/spring/data/eclipse/store/jpa[Demo with coexisting JPA] +* https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage[Dual storage demo] == Drop in compatible [[drop-in-compatible]] diff --git a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/PersistenceInvoiceConfiguration.java b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/PersistenceInvoiceConfiguration.java index 319ac98e..81a1c2f2 100644 --- a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/PersistenceInvoiceConfiguration.java +++ b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/dual/storage/invoice/PersistenceInvoiceConfiguration.java @@ -1,9 +1,8 @@ package software.xdev.spring.data.eclipse.store.demo.dual.storage.invoice; -import static org.eclipse.store.storage.embedded.types.EmbeddedStorage.Foundation; - import java.nio.file.Path; +import org.eclipse.store.storage.embedded.types.EmbeddedStorage; import org.eclipse.store.storage.embedded.types.EmbeddedStorageFoundation; import org.eclipse.store.storage.types.Storage; import org.springframework.context.annotation.Configuration; @@ -22,6 +21,6 @@ public class PersistenceInvoiceConfiguration extends EclipseStoreClientConfigura @Override public EmbeddedStorageFoundation createEmbeddedStorageFoundation() { - return Foundation(Storage.Configuration(Storage.FileProvider(Path.of("storage-invoice")))); + return EmbeddedStorage.Foundation(Storage.Configuration(Storage.FileProvider(Path.of("storage-invoice")))); } } From 7ec280c8999e483f05c65a206d39fb507ff3b8fe Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Thu, 7 Mar 2024 10:59:58 +0100 Subject: [PATCH 29/98] Refactored tests --- .../data/eclipse/store/repository/Lazy.java} | 22 +++---- .../{shared => }/DefaultTestAnnotations.java | 2 +- .../{shared => }/TestConfiguration.java | 4 +- .../isolated/IsolatedTestConfiguration.java | 65 ------------------- .../{shared => }/repositories/Child.java | 2 +- .../repositories/ChildCustomer.java | 2 +- .../repositories/ChildCustomerRepository.java | 2 +- .../{shared => }/repositories/Customer.java | 2 +- .../repositories/CustomerAsRecord.java | 2 +- .../CustomerAsRecordRepository.java | 2 +- .../repositories/CustomerNotCrud.java | 2 +- .../CustomerNotCrudRepository.java | 2 +- .../repositories/CustomerRepository.java | 2 +- .../CustomerRepositoryWithHashSet.java | 2 +- ...CustomerRepositoryWithNonFinalHashSet.java | 2 +- .../CustomerRepositoryWithQuery.java | 2 +- .../repositories/CustomerWithChild.java | 2 +- .../CustomerWithChildRepository.java | 2 +- .../repositories/CustomerWithHashSet.java | 2 +- .../CustomerWithNonFinalHashSet.java | 2 +- .../repositories/CustomerWithQuery.java | 2 +- .../{shared => }/repositories/Node.java | 2 +- .../repositories/NodeRepository.java | 2 +- .../{shared => }/repositories/Owner.java | 2 +- .../repositories/OwnerRepository.java | 2 +- .../repositories/ParentCustomer.java | 2 +- .../ParentCustomerRepository.java | 2 +- .../repositories/SubCustomer.java | 2 +- .../repositories/SubCustomerRepository.java | 2 +- .../repositories/id/CustomerWithIdInt.java | 2 +- .../id/CustomerWithIdIntRepository.java | 2 +- .../id/CustomerWithIdInteger.java | 2 +- .../CustomerWithIdIntegerNoAutoGenerate.java | 2 +- ...WithIdIntegerNoAutoGenerateRepository.java | 2 +- .../id/CustomerWithIdIntegerRepository.java | 2 +- .../repositories/id/CustomerWithIdLong.java | 2 +- .../id/CustomerWithIdLongRepository.java | 2 +- .../repositories/id/CustomerWithIdString.java | 2 +- .../id/CustomerWithIdStringRepository.java | 2 +- .../repositories/id/CustomerWithPurchase.java | 2 +- .../id/CustomerWithPurchaseRepository.java | 2 +- .../repositories/id/Purchase.java | 2 +- .../immutables/CustomerWithFinal.java | 2 +- .../immutables/CustomerWithFinalChild.java | 4 +- .../CustomerWithFinalChildRepository.java | 2 +- .../immutables/CustomerWithFinalId.java | 2 +- .../CustomerWithFinalIdRepository.java | 2 +- .../CustomerWithFinalRepository.java | 2 +- .../repositories/interfaces/CustomerCrud.java | 2 +- .../CustomerEclipseStoreCrudRepository.java | 2 +- ...ustomerEclipseStoreListCrudRepository.java | 2 +- ...seStoreListPagingAndSortingRepository.java | 2 +- ...clipseStorePagingAndSortingRepository.java | 2 +- .../CustomerEclipseStoreRepository.java | 2 +- .../interfaces/CustomerListCrud.java | 2 +- .../CustomerListPagingAndSorting.java | 2 +- .../interfaces/CustomerPagingAndSorting.java | 2 +- .../interfaces/CustomerSimple.java | 2 +- .../real/life/example/Article.java | 2 +- .../real/life/example/ArticleGroup.java | 2 +- .../real/life/example/Invoice.java | 2 +- .../real/life/example/InvoiceRepository.java | 2 +- .../real/life/example/Position.java | 2 +- .../real/life/example/PositionRepository.java | 2 +- .../real/life/example/Warehouse.java | 2 +- .../{shared => }/tests/ChangeRootTests.java | 10 +-- .../{shared => }/tests/ConcurrencyTest.java | 10 +-- .../{shared => }/tests/FinalTest.java | 18 ++--- .../{shared => }/tests/HashSetTest.java | 14 ++-- .../{shared => }/tests/IdTest.java | 32 ++++----- .../{shared => }/tests/InheritanceTest.java | 18 ++--- .../tests/JpaCompatibilityTest.java | 10 +-- .../{shared => }/tests/QueryTest.java | 16 ++--- .../{shared => }/tests/RealLifeTests.java | 22 +++---- .../tests/SimpleMultipleTest.java | 14 ++-- .../{shared => }/tests/SimpleSingleTest.java | 18 ++--- .../tests/SpecificInterfacesTest.java | 26 ++++---- .../{shared => }/tests/StressTest.java | 10 +-- .../{shared => }/tests/WorkingCopyTests.java | 14 ++-- .../tests/keywords/KeywordsTest.java | 10 +-- .../tests/keywords/MinimalDaoObject.java | 2 +- .../tests/keywords/MinimalRepository.java | 2 +- .../special/types/BigDecimalDaoObject.java | 2 +- .../special/types/BigDecimalRepository.java | 2 +- .../special/types/BigIntegerDaoObject.java | 2 +- .../special/types/BigIntegerRepository.java | 2 +- .../special/types/CalendarDaoObject.java | 2 +- .../special/types/CalendarRepository.java | 2 +- .../tests/special/types/ComplexObject.java | 2 +- .../tests/special/types/DateDaoObject.java | 2 +- .../tests/special/types/DateRepository.java | 2 +- .../tests/special/types/EnumMapDaoObject.java | 2 +- .../special/types/EnumMapRepository.java | 2 +- .../tests/special/types/EnumSetDaoObject.java | 2 +- .../special/types/EnumSetRepository.java | 2 +- .../tests/special/types/LazyDaoObject.java | 2 +- .../tests/special/types/LazyRepository.java | 2 +- .../tests/special/types/ListDaoObject.java | 2 +- .../tests/special/types/ListRepository.java | 2 +- .../special/types/LocalDateDaoObject.java | 2 +- .../special/types/LocalDateRepository.java | 2 +- .../special/types/LocalDateTimeDaoObject.java | 2 +- .../types/LocalDateTimeRepository.java | 2 +- .../special/types/LocalTimeDaoObject.java | 2 +- .../special/types/LocalTimeRepository.java | 2 +- .../tests/special/types/MapDaoObject.java | 2 +- .../tests/special/types/MapRepository.java | 2 +- .../special/types/OptionalDaoObject.java | 2 +- .../special/types/OptionalRepository.java | 2 +- .../tests/special/types/SetDaoObject.java | 2 +- .../tests/special/types/SetRepository.java | 2 +- .../tests/special/types/TypesData.java | 2 +- .../tests/special/types/TypesTest.java | 14 ++-- 113 files changed, 235 insertions(+), 302 deletions(-) rename spring-data-eclipse-store/src/{test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java => main/java/software/xdev/spring/data/eclipse/store/repository/Lazy.java} (56%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/DefaultTestAnnotations.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/TestConfiguration.java (94%) delete mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestConfiguration.java rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/Child.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/ChildCustomer.java (92%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/ChildCustomerRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/Customer.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/CustomerAsRecord.java (92%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/CustomerAsRecordRepository.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/CustomerNotCrud.java (94%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/CustomerNotCrudRepository.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/CustomerRepository.java (94%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/CustomerRepositoryWithHashSet.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/CustomerRepositoryWithNonFinalHashSet.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/CustomerRepositoryWithQuery.java (93%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/CustomerWithChild.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/CustomerWithChildRepository.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/CustomerWithHashSet.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/CustomerWithNonFinalHashSet.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/CustomerWithQuery.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/Node.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/NodeRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/Owner.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/OwnerRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/ParentCustomer.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/ParentCustomerRepository.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/SubCustomer.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/SubCustomerRepository.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/id/CustomerWithIdInt.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/id/CustomerWithIdIntRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/id/CustomerWithIdInteger.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/id/CustomerWithIdIntegerRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/id/CustomerWithIdLong.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/id/CustomerWithIdLongRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/id/CustomerWithIdString.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/id/CustomerWithIdStringRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/id/CustomerWithPurchase.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/id/CustomerWithPurchaseRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/id/Purchase.java (94%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/immutables/CustomerWithFinal.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/immutables/CustomerWithFinalChild.java (92%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/immutables/CustomerWithFinalChildRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/immutables/CustomerWithFinalId.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/immutables/CustomerWithFinalIdRepository.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/immutables/CustomerWithFinalRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/interfaces/CustomerCrud.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/interfaces/CustomerEclipseStoreCrudRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/interfaces/CustomerEclipseStoreRepository.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/interfaces/CustomerListCrud.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/interfaces/CustomerListPagingAndSorting.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/interfaces/CustomerPagingAndSorting.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/interfaces/CustomerSimple.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/real/life/example/Article.java (93%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/real/life/example/ArticleGroup.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/real/life/example/Invoice.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/real/life/example/InvoiceRepository.java (88%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/real/life/example/Position.java (93%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/real/life/example/PositionRepository.java (88%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/repositories/real/life/example/Warehouse.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/tests/ChangeRootTests.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/tests/ConcurrencyTest.java (93%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/tests/FinalTest.java (74%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/tests/HashSetTest.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/tests/IdTest.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/tests/InheritanceTest.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/tests/JpaCompatibilityTest.java (86%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/tests/QueryTest.java (94%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/tests/RealLifeTests.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/tests/SimpleMultipleTest.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/tests/SimpleSingleTest.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/tests/SpecificInterfacesTest.java (70%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/tests/StressTest.java (84%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/tests/WorkingCopyTests.java (94%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/keywords/KeywordsTest.java (81%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/keywords/MinimalDaoObject.java (93%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/keywords/MinimalRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/BigDecimalDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/BigDecimalRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/BigIntegerDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/BigIntegerRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/CalendarDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/CalendarRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/ComplexObject.java (94%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/DateDaoObject.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/DateRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/EnumMapDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/EnumMapRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/EnumSetDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/EnumSetRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/LazyDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/LazyRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/ListDaoObject.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/ListRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/LocalDateDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/LocalDateRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/LocalDateTimeDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/LocalDateTimeRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/LocalTimeDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/LocalTimeRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/MapDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/MapRepository.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/OptionalDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/OptionalRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/SetDaoObject.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/SetRepository.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/TypesData.java (99%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{isolated => }/tests/special/types/TypesTest.java (92%) diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/Lazy.java similarity index 56% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java rename to spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/Lazy.java index 223efa00..5052e633 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/Lazy.java @@ -13,26 +13,24 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated; - -import static org.springframework.test.annotation.DirtiesContext.ClassMode.BEFORE_EACH_TEST_METHOD; +package software.xdev.spring.data.eclipse.store.repository; +import java.lang.annotation.Documented; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; -import org.junit.jupiter.api.extension.ExtendWith; -import org.springframework.test.annotation.DirtiesContext; -import org.springframework.test.context.ContextConfiguration; -import org.springframework.test.context.junit.jupiter.SpringExtension; +import org.springframework.data.annotation.QueryAnnotation; +/** + * TODO + */ @Retention(RetentionPolicy.RUNTIME) -@Target(ElementType.TYPE) -@ExtendWith(SpringExtension.class) -@ContextConfiguration(classes = {IsolatedTestConfiguration.class}) -@DirtiesContext(classMode = BEFORE_EACH_TEST_METHOD) -public @interface IsolatedTestAnnotations +@Target({ElementType.FIELD, ElementType.ANNOTATION_TYPE}) +@Documented +@QueryAnnotation +public @interface Lazy { } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/DefaultTestAnnotations.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/DefaultTestAnnotations.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/DefaultTestAnnotations.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/DefaultTestAnnotations.java index a3ebc833..4b47fea7 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/DefaultTestAnnotations.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/DefaultTestAnnotations.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared; +package software.xdev.spring.data.eclipse.store.integration; import static org.springframework.test.annotation.DirtiesContext.ClassMode.BEFORE_EACH_TEST_METHOD; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/TestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/TestConfiguration.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java index 933b0058..fe337930 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/TestConfiguration.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared; +package software.xdev.spring.data.eclipse.store.integration; import static org.eclipse.store.storage.embedded.types.EmbeddedStorage.Foundation; @@ -35,7 +35,7 @@ @Configuration @EnableEclipseStoreRepositories( - value = "software.xdev.spring.data.eclipse.store.integration.shared", + value = "software.xdev.spring.data.eclipse.store.integration", clientConfigurationClass = TestConfiguration.class) public class TestConfiguration extends EclipseStoreClientConfiguration { diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestConfiguration.java deleted file mode 100644 index 443c75a6..00000000 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestConfiguration.java +++ /dev/null @@ -1,65 +0,0 @@ -/* - * Copyright © 2023 XDEV Software (https://xdev.software) - * - * 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. - */ -package software.xdev.spring.data.eclipse.store.integration.isolated; - -import static org.eclipse.store.storage.embedded.types.EmbeddedStorage.Foundation; - -import java.io.IOException; -import java.nio.file.Path; - -import org.eclipse.store.storage.embedded.types.EmbeddedStorageFoundation; -import org.eclipse.store.storage.types.Storage; -import org.springframework.context.annotation.Configuration; -import org.springframework.context.event.ContextClosedEvent; -import org.springframework.context.event.ContextRefreshedEvent; -import org.springframework.context.event.EventListener; -import org.springframework.util.FileSystemUtils; - -import software.xdev.spring.data.eclipse.store.helper.StorageDirectoryNameProvider; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; -import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; - - -@Configuration -@EnableEclipseStoreRepositories( - value = "software.xdev.spring.data.eclipse.store.integration.isolated", - clientConfigurationClass = IsolatedTestConfiguration.class) -public class IsolatedTestConfiguration extends EclipseStoreClientConfiguration -{ - private final String storageDirectory = StorageDirectoryNameProvider.getNewStorageDirectoryPath(); - - @Override - public EmbeddedStorageFoundation createEmbeddedStorageFoundation() - { - return Foundation(Storage.Configuration(Storage.FileProvider(Path.of(this.storageDirectory)))); - } - - @EventListener - public void handleContextRefresh(final ContextRefreshedEvent event) - { - // Init with empty root object - this.getStorageInstance().clearData(); - } - - @EventListener - public void handleContextClosed(final ContextClosedEvent event) throws IOException - { - // End with empty root object - this.getStorageInstance().clearData(); - this.getStorageInstance().stop(); - FileSystemUtils.deleteRecursively(Path.of(this.storageDirectory)); - } -} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Child.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Child.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Child.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Child.java index 549da2db..c0d24c1a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Child.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Child.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomer.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomer.java similarity index 92% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomer.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomer.java index a243bdfe..7af466b3 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomer.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomer.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; public class ChildCustomer extends ParentCustomer { diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomerRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomerRepository.java index 08622099..46979d77 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Customer.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Customer.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Customer.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Customer.java index 2ef2e24d..89e7d4f7 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Customer.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Customer.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecord.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecord.java similarity index 92% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecord.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecord.java index 9c9df6c7..0e082bc9 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecord.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecord.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecordRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecordRepository.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecordRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecordRepository.java index a28803fa..0061c6de 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecordRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecordRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import java.util.Optional; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrud.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrud.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrud.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrud.java index fe960ddd..99140aa9 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrud.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrud.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrudRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrudRepository.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrudRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrudRepository.java index df0ff39e..abf8c087 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrudRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrudRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepository.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepository.java index 7c90c670..cd2a570b 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import java.util.List; import java.util.Optional; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithHashSet.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithHashSet.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithHashSet.java index cf53de00..045d6c17 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithHashSet.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithHashSet.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithNonFinalHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithNonFinalHashSet.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithNonFinalHashSet.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithNonFinalHashSet.java index e459843e..3c729c1b 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithNonFinalHashSet.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithNonFinalHashSet.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithQuery.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithQuery.java similarity index 93% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithQuery.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithQuery.java index f845fed8..69baff3c 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithQuery.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithQuery.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import java.util.List; import java.util.Optional; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChild.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChild.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChild.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChild.java index 272318d8..668e67f2 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChild.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChild.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChildRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChildRepository.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChildRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChildRepository.java index e74bc81b..65a8cf5e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChildRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChildRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import java.util.Optional; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithHashSet.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithHashSet.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithHashSet.java index b46e5b72..e6a2c95c 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithHashSet.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithHashSet.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import java.util.HashSet; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithNonFinalHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithNonFinalHashSet.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithNonFinalHashSet.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithNonFinalHashSet.java index 45009fd3..dc8bbefd 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithNonFinalHashSet.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithNonFinalHashSet.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import java.util.HashSet; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithQuery.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithQuery.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithQuery.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithQuery.java index 43d6d234..a4ad8257 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithQuery.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithQuery.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Node.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Node.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Node.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Node.java index 27764c50..d359f8a4 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Node.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Node.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import java.util.ArrayList; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/NodeRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/NodeRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/NodeRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/NodeRepository.java index efa0d716..53555be9 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/NodeRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/NodeRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Owner.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Owner.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Owner.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Owner.java index 896ed6a2..f49d78f4 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Owner.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Owner.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/OwnerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/OwnerRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/OwnerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/OwnerRepository.java index ce29f850..e3b5b5dc 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/OwnerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/OwnerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomer.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomer.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomer.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomer.java index 2256d706..c897bc62 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomer.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomer.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomerRepository.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomerRepository.java index 29057f43..a76780b6 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import org.springframework.data.repository.CrudRepository; import org.springframework.data.repository.PagingAndSortingRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomer.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomer.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomer.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomer.java index e72316ff..d7cd1a98 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomer.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomer.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; public class SubCustomer extends Customer { diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomerRepository.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomerRepository.java index 321323a2..e95e3785 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories; +package software.xdev.spring.data.eclipse.store.integration.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInt.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInt.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInt.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInt.java index 4b4f4562..ba16d8d4 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInt.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInt.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.repositories.id; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntRepository.java index 888a123d..b000d441 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInteger.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInteger.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInteger.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInteger.java index b0a9e1e8..096d2466 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInteger.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInteger.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.repositories.id; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java index 7618633b..5fa96ed0 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.repositories.id; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java index 7ddc6171..c86528c3 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerRepository.java index f6de36f0..79a534da 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLong.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLong.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLong.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLong.java index 49d3f384..e2c003ce 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLong.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLong.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.repositories.id; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLongRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLongRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLongRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLongRepository.java index e86acdcc..29f340f0 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLongRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLongRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdString.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdString.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdString.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdString.java index eaa32ad8..43045152 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdString.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdString.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.repositories.id; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdStringRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdStringRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdStringRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdStringRepository.java index c40f899e..85e75ec9 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdStringRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdStringRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchase.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchase.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchase.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchase.java index c37d67c5..69e1e80d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchase.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchase.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.repositories.id; import java.util.ArrayList; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchaseRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchaseRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchaseRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchaseRepository.java index 2f986e3a..aa8264e3 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchaseRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchaseRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/Purchase.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/Purchase.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/Purchase.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/Purchase.java index 52de0753..69479540 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/Purchase.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/Purchase.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.repositories.id; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinal.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinal.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinal.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinal.java index d0ddd64d..5eae308e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinal.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinal.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChild.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChild.java similarity index 92% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChild.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChild.java index 1bde2eae..f74c8326 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChild.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChild.java @@ -13,12 +13,12 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; import java.util.List; import java.util.Objects; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Child; +import software.xdev.spring.data.eclipse.store.integration.repositories.Child; public class CustomerWithFinalChild diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChildRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChildRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChildRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChildRepository.java index 22e9d951..0eb44e4a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChildRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChildRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; import org.springframework.data.repository.CrudRepository; import org.springframework.data.repository.PagingAndSortingRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalId.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalId.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalId.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalId.java index c10b2d74..f4cad237 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalId.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalId.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalIdRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalIdRepository.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalIdRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalIdRepository.java index ebb4df9e..7ce5b1fd 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalIdRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalIdRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalRepository.java index 519b3f95..607c3bf3 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; import org.springframework.data.repository.CrudRepository; import org.springframework.data.repository.PagingAndSortingRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerCrud.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerCrud.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerCrud.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerCrud.java index 7d9778f7..9e7d49ce 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerCrud.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerCrud.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreCrudRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreCrudRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreCrudRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreCrudRepository.java index 64ff9274..4c9bd223 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreCrudRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreCrudRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreCrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java index 5fb57f8f..cc4337fa 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreListCrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java index c0d0fb6d..9fbfea7e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreListPagingAndSortingRepositoryRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java index 14b444c2..7d45e15a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStorePagingAndSortingRepositoryRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreRepository.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreRepository.java index 0a476e5f..b3feecb1 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListCrud.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListCrud.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListCrud.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListCrud.java index fe5c0c02..56e2087d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListCrud.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListCrud.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListPagingAndSorting.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListPagingAndSorting.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListPagingAndSorting.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListPagingAndSorting.java index 89ef5b9f..2e848482 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListPagingAndSorting.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListPagingAndSorting.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerPagingAndSorting.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerPagingAndSorting.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerPagingAndSorting.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerPagingAndSorting.java index 4cf9b1c3..06ba144f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerPagingAndSorting.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerPagingAndSorting.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerSimple.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerSimple.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerSimple.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerSimple.java index e5f8404b..775f3198 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerSimple.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerSimple.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Article.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Article.java similarity index 93% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Article.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Article.java index f67cc905..dd418fcb 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Article.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Article.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; import java.util.ArrayList; import java.util.Collections; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/ArticleGroup.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/ArticleGroup.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/ArticleGroup.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/ArticleGroup.java index d8378911..fd6e4bac 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/ArticleGroup.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/ArticleGroup.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; public class ArticleGroup { diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Invoice.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Invoice.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Invoice.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Invoice.java index 498f7492..8af20a95 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Invoice.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Invoice.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/InvoiceRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/InvoiceRepository.java similarity index 88% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/InvoiceRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/InvoiceRepository.java index b86bd835..93c9e286 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/InvoiceRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/InvoiceRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Position.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Position.java similarity index 93% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Position.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Position.java index 85f40363..29b55bc6 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Position.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Position.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; import java.util.List; import java.util.Optional; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/PositionRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/PositionRepository.java similarity index 88% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/PositionRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/PositionRepository.java index 3692bbc5..d7e98068 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/PositionRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/PositionRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Warehouse.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Warehouse.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Warehouse.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Warehouse.java index ce814b84..9f7bd011 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Warehouse.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Warehouse.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; import java.util.HashSet; import java.util.Set; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ChangeRootTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ChangeRootTests.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ChangeRootTests.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ChangeRootTests.java index a229a91b..3ad3bfe5 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ChangeRootTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ChangeRootTests.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.tests; +package software.xdev.spring.data.eclipse.store.integration.tests; import java.util.List; @@ -22,10 +22,10 @@ import org.springframework.beans.factory.annotation.Autowired; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Node; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.NodeRepository; +import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.repositories.Node; +import software.xdev.spring.data.eclipse.store.integration.repositories.NodeRepository; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ConcurrencyTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ConcurrencyTest.java similarity index 93% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ConcurrencyTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ConcurrencyTest.java index 9cf7b0fa..2ebdf4d0 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ConcurrencyTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ConcurrencyTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.tests; +package software.xdev.spring.data.eclipse.store.integration.tests; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; @@ -32,10 +32,10 @@ import org.springframework.beans.factory.annotation.Autowired; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; @SuppressWarnings("OptionalGetWithoutIsPresent") diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/FinalTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/FinalTest.java similarity index 74% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/FinalTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/FinalTest.java index c50022cb..d48bafb6 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/FinalTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/FinalTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.tests; +package software.xdev.spring.data.eclipse.store.integration.tests; import java.util.List; @@ -24,14 +24,14 @@ import software.xdev.spring.data.eclipse.store.exceptions.IdFieldFinalException; import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinal; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinalChild; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinalChildRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinalId; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinalIdRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinalRepository; +import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinal; +import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalChild; +import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalChildRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalId; +import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalIdRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalRepository; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/HashSetTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/HashSetTest.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/HashSetTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/HashSetTest.java index df152e5f..3d42ffe3 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/HashSetTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/HashSetTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.tests; +package software.xdev.spring.data.eclipse.store.integration.tests; import java.util.List; import java.util.Set; @@ -24,12 +24,12 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepositoryWithHashSet; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepositoryWithNonFinalHashSet; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerWithHashSet; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerWithNonFinalHashSet; +import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepositoryWithHashSet; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepositoryWithNonFinalHashSet; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithHashSet; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithNonFinalHashSet; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/IdTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/IdTest.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/IdTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/IdTest.java index 6c100760..1a4e9380 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/IdTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/IdTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.tests; +package software.xdev.spring.data.eclipse.store.integration.tests; import static software.xdev.spring.data.eclipse.store.helper.TestUtil.restartDatastore; @@ -26,21 +26,21 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdInt; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdIntRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdInteger; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdIntegerNoAutoGenerate; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdIntegerNoAutoGenerateRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdIntegerRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdLong; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdLongRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdString; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdStringRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithPurchase; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithPurchaseRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.Purchase; +import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdInt; +import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdIntRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdInteger; +import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdIntegerNoAutoGenerate; +import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdIntegerNoAutoGenerateRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdIntegerRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdLong; +import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdLongRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdString; +import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdStringRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithPurchase; +import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithPurchaseRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.id.Purchase; import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/InheritanceTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/InheritanceTest.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/InheritanceTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/InheritanceTest.java index 3920782f..c99dce81 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/InheritanceTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/InheritanceTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.tests; +package software.xdev.spring.data.eclipse.store.integration.tests; import java.util.List; @@ -23,14 +23,14 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.ChildCustomer; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.ChildCustomerRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.ParentCustomer; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.ParentCustomerRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.SubCustomer; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.SubCustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.repositories.ChildCustomer; +import software.xdev.spring.data.eclipse.store.integration.repositories.ChildCustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.ParentCustomer; +import software.xdev.spring.data.eclipse.store.integration.repositories.ParentCustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.SubCustomer; +import software.xdev.spring.data.eclipse.store.integration.repositories.SubCustomerRepository; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/JpaCompatibilityTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/JpaCompatibilityTest.java similarity index 86% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/JpaCompatibilityTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/JpaCompatibilityTest.java index 73ab0455..b160a6f9 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/JpaCompatibilityTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/JpaCompatibilityTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.tests; +package software.xdev.spring.data.eclipse.store.integration.tests; import java.util.List; import java.util.Optional; @@ -24,10 +24,10 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepositoryWithQuery; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerWithQuery; +import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepositoryWithQuery; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithQuery; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/QueryTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/QueryTest.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/QueryTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/QueryTest.java index a18af6fb..ef6e133e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/QueryTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/QueryTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.tests; +package software.xdev.spring.data.eclipse.store.integration.tests; import java.util.List; import java.util.Optional; @@ -27,13 +27,13 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Child; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerWithChild; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerWithChildRepository; +import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.repositories.Child; +import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithChild; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithChildRepository; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/RealLifeTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/RealLifeTests.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/RealLifeTests.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/RealLifeTests.java index 47d1b1bf..a22819cf 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/RealLifeTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/RealLifeTests.java @@ -13,9 +13,9 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.tests; +package software.xdev.spring.data.eclipse.store.integration.tests; -import static software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.Position.getPositionWithArticleWithName; +import static software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Position.getPositionWithArticleWithName; import java.util.ArrayList; import java.util.Arrays; @@ -27,15 +27,15 @@ import org.springframework.beans.factory.annotation.Autowired; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.Article; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.ArticleGroup; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.Invoice; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.InvoiceRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.Position; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.PositionRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.Warehouse; +import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Article; +import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.ArticleGroup; +import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Invoice; +import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.InvoiceRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Position; +import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.PositionRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Warehouse; @SuppressWarnings("OptionalGetWithoutIsPresent") diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleMultipleTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleMultipleTest.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleMultipleTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleMultipleTest.java index d2d36f00..d19111e7 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleMultipleTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleMultipleTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.tests; +package software.xdev.spring.data.eclipse.store.integration.tests; import java.util.List; @@ -23,12 +23,12 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Owner; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.OwnerRepository; +import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.Owner; +import software.xdev.spring.data.eclipse.store.integration.repositories.OwnerRepository; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleSingleTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleSingleTest.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleSingleTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleSingleTest.java index 4c95363c..5dc76ad0 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleSingleTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleSingleTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.tests; +package software.xdev.spring.data.eclipse.store.integration.tests; import java.util.List; import java.util.Optional; @@ -24,14 +24,14 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerAsRecord; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerAsRecordRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerNotCrud; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerNotCrudRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerAsRecord; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerAsRecordRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerNotCrud; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerNotCrudRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SpecificInterfacesTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SpecificInterfacesTest.java similarity index 70% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SpecificInterfacesTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SpecificInterfacesTest.java index 54256c45..2ebfab8b 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SpecificInterfacesTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SpecificInterfacesTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.tests; +package software.xdev.spring.data.eclipse.store.integration.tests; import java.util.List; @@ -24,18 +24,18 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerCrud; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerEclipseStoreCrudRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerEclipseStoreListCrudRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerEclipseStoreListPagingAndSortingRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerEclipseStorePagingAndSortingRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerEclipseStoreRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerListCrud; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerListPagingAndSorting; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerPagingAndSorting; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerSimple; +import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerCrud; +import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerEclipseStoreCrudRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerEclipseStoreListCrudRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerEclipseStoreListPagingAndSortingRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerEclipseStorePagingAndSortingRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerEclipseStoreRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerListCrud; +import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerListPagingAndSorting; +import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerPagingAndSorting; +import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerSimple; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/StressTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/StressTest.java similarity index 84% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/StressTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/StressTest.java index 7da4d9c1..d8b9e73c 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/StressTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/StressTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.tests; +package software.xdev.spring.data.eclipse.store.integration.tests; import java.util.List; import java.util.stream.IntStream; @@ -24,10 +24,10 @@ import org.springframework.beans.factory.annotation.Autowired; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/WorkingCopyTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/WorkingCopyTests.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/WorkingCopyTests.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/WorkingCopyTests.java index b580ec8a..b87676eb 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/WorkingCopyTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/WorkingCopyTests.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared.tests; +package software.xdev.spring.data.eclipse.store.integration.tests; import java.util.List; import java.util.Optional; @@ -24,12 +24,12 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Node; -import software.xdev.spring.data.eclipse.store.integration.shared.repositories.NodeRepository; +import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.repositories.Node; +import software.xdev.spring.data.eclipse.store.integration.repositories.NodeRepository; @SuppressWarnings("OptionalGetWithoutIsPresent") diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/KeywordsTest.java similarity index 81% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/KeywordsTest.java index 0a8e14db..c075080e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/KeywordsTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.keywords; +package software.xdev.spring.data.eclipse.store.integration.tests.keywords; import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Disabled; @@ -21,8 +21,8 @@ import org.springframework.beans.factory.annotation.Autowired; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; /** @@ -30,11 +30,11 @@ * href="https://docs.spring.io/spring-data/jpa/reference/repositories/query-keywords-reference.html">Repository query * keywords */ -@IsolatedTestAnnotations +@DefaultTestAnnotations class KeywordsTest { @Autowired - private IsolatedTestConfiguration configuration; + private TestConfiguration configuration; @Test @Disabled("For now we don't need 'existsBy'") diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/MinimalDaoObject.java similarity index 93% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/MinimalDaoObject.java index f306c867..97e62cc9 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/MinimalDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.keywords; +package software.xdev.spring.data.eclipse.store.integration.tests.keywords; import jakarta.persistence.GeneratedValue; import jakarta.persistence.GenerationType; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/MinimalRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/MinimalRepository.java index c1db0a3f..dfafcd02 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/MinimalRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.keywords; +package software.xdev.spring.data.eclipse.store.integration.tests.keywords; import org.springframework.data.repository.Repository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigDecimalDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigDecimalDaoObject.java index 52c42c58..2e6eb70f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigDecimalDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import java.math.BigDecimal; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigDecimalRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigDecimalRepository.java index f56eb4a8..92e3940f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigDecimalRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigIntegerDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigIntegerDaoObject.java index 90dc44f1..327b034a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigIntegerDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import java.math.BigInteger; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigIntegerRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigIntegerRepository.java index 74a8d364..235567c9 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigIntegerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/CalendarDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/CalendarDaoObject.java index 3b835475..55888a22 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/CalendarDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import java.util.Calendar; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/CalendarRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/CalendarRepository.java index 187d33fb..2e7c479a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/CalendarRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ComplexObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ComplexObject.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ComplexObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ComplexObject.java index 5561bb6c..8e68b384 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ComplexObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ComplexObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/DateDaoObject.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/DateDaoObject.java index f93dfa12..b32fb86f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/DateDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import java.util.Date; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/DateRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/DateRepository.java index f967c16f..013ca7d6 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/DateRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumMapDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumMapDaoObject.java index cd81c07c..339a3933 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumMapDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import java.util.EnumMap; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumMapRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumMapRepository.java index 4f49be48..ac0d9167 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumMapRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumSetDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumSetDaoObject.java index 31acf389..ebd90363 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumSetDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import java.util.EnumSet; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumSetRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumSetRepository.java index f2f186b8..b16905c2 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumSetRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LazyDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LazyDaoObject.java index 41221a67..2cf1c2d4 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LazyDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import org.eclipse.serializer.reference.Lazy; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LazyRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LazyRepository.java index a3cd5e37..d9a6cb7d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LazyRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ListDaoObject.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ListDaoObject.java index f4cb80e7..4c1dc25c 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ListDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ListRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ListRepository.java index b0351524..ea057c04 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ListRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateDaoObject.java index bf6cf781..e044b976 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import java.time.LocalDate; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateRepository.java index 0aa50229..8d7ea96c 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateTimeDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateTimeDaoObject.java index 169ea937..9a1ef5ed 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateTimeDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import java.time.LocalDateTime; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateTimeRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateTimeRepository.java index 737c6ebf..25fe04ae 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateTimeRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalTimeDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalTimeDaoObject.java index 953aeab5..3ea577bb 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalTimeDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import java.time.LocalTime; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalTimeRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalTimeRepository.java index db1cac67..aafdd07f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalTimeRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/MapDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/MapDaoObject.java index 372ec6b3..a9fc3c98 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/MapDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import java.util.Map; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/MapRepository.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/MapRepository.java index ebbb1d18..15f2a5ba 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/MapRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/OptionalDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/OptionalDaoObject.java index 228abedc..47aca8cb 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/OptionalDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import java.util.Optional; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/OptionalRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/OptionalRepository.java index 7868afc6..aac1f6b9 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/OptionalRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/SetDaoObject.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/SetDaoObject.java index be214b09..8375f22d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/SetDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import java.util.Set; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/SetRepository.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/SetRepository.java index e3ed468b..91ee968e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/SetRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/TypesData.java similarity index 99% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/TypesData.java index 4429ddb6..cfdb604b 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/TypesData.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import java.math.BigDecimal; import java.math.BigInteger; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/TypesTest.java similarity index 92% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/TypesTest.java index 1e1c84e3..e9ac2505 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/TypesTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.tests.special.types; import java.util.Collection; import java.util.Map; @@ -29,23 +29,23 @@ import software.xdev.spring.data.eclipse.store.exceptions.DataTypeNotSupportedException; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; -@IsolatedTestAnnotations +@DefaultTestAnnotations class TypesTest { public static final String TYPES_DATA_SOURCE = - "software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types" + "software.xdev.spring.data.eclipse.store.integration.tests.special.types" + ".TypesData#generateData"; public static final String TYPES_NOT_WORKING_DATA_SOURCE = - "software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types" + "software.xdev.spring.data.eclipse.store.integration.tests.special.types" + ".TypesData#generateNotWorkingData"; @Autowired - private IsolatedTestConfiguration configuration; + private TestConfiguration configuration; @ParameterizedTest @MethodSource(TYPES_DATA_SOURCE) From 06e8b64010a5d7d4b3b9fbaf1c49f2b25c618950 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Thu, 7 Mar 2024 11:12:25 +0100 Subject: [PATCH 30/98] Revert "Refactored tests" This reverts commit 7ec280c8999e483f05c65a206d39fb507ff3b8fe. --- .../isolated/IsolatedTestAnnotations.java} | 22 ++++--- .../isolated/IsolatedTestConfiguration.java | 65 +++++++++++++++++++ .../tests/keywords/KeywordsTest.java | 10 +-- .../tests/keywords/MinimalDaoObject.java | 2 +- .../tests/keywords/MinimalRepository.java | 2 +- .../special/types/BigDecimalDaoObject.java | 2 +- .../special/types/BigDecimalRepository.java | 2 +- .../special/types/BigIntegerDaoObject.java | 2 +- .../special/types/BigIntegerRepository.java | 2 +- .../special/types/CalendarDaoObject.java | 2 +- .../special/types/CalendarRepository.java | 2 +- .../tests/special/types/ComplexObject.java | 2 +- .../tests/special/types/DateDaoObject.java | 2 +- .../tests/special/types/DateRepository.java | 2 +- .../tests/special/types/EnumMapDaoObject.java | 2 +- .../special/types/EnumMapRepository.java | 2 +- .../tests/special/types/EnumSetDaoObject.java | 2 +- .../special/types/EnumSetRepository.java | 2 +- .../tests/special/types/LazyDaoObject.java | 2 +- .../tests/special/types/LazyRepository.java | 2 +- .../tests/special/types/ListDaoObject.java | 2 +- .../tests/special/types/ListRepository.java | 2 +- .../special/types/LocalDateDaoObject.java | 2 +- .../special/types/LocalDateRepository.java | 2 +- .../special/types/LocalDateTimeDaoObject.java | 2 +- .../types/LocalDateTimeRepository.java | 2 +- .../special/types/LocalTimeDaoObject.java | 2 +- .../special/types/LocalTimeRepository.java | 2 +- .../tests/special/types/MapDaoObject.java | 2 +- .../tests/special/types/MapRepository.java | 2 +- .../special/types/OptionalDaoObject.java | 2 +- .../special/types/OptionalRepository.java | 2 +- .../tests/special/types/SetDaoObject.java | 2 +- .../tests/special/types/SetRepository.java | 2 +- .../tests/special/types/TypesData.java | 2 +- .../tests/special/types/TypesTest.java | 14 ++-- .../{ => shared}/DefaultTestAnnotations.java | 2 +- .../{ => shared}/TestConfiguration.java | 4 +- .../{ => shared}/repositories/Child.java | 2 +- .../repositories/ChildCustomer.java | 2 +- .../repositories/ChildCustomerRepository.java | 2 +- .../{ => shared}/repositories/Customer.java | 2 +- .../repositories/CustomerAsRecord.java | 2 +- .../CustomerAsRecordRepository.java | 2 +- .../repositories/CustomerNotCrud.java | 2 +- .../CustomerNotCrudRepository.java | 2 +- .../repositories/CustomerRepository.java | 2 +- .../CustomerRepositoryWithHashSet.java | 2 +- ...CustomerRepositoryWithNonFinalHashSet.java | 2 +- .../CustomerRepositoryWithQuery.java | 2 +- .../repositories/CustomerWithChild.java | 2 +- .../CustomerWithChildRepository.java | 2 +- .../repositories/CustomerWithHashSet.java | 2 +- .../CustomerWithNonFinalHashSet.java | 2 +- .../repositories/CustomerWithQuery.java | 2 +- .../{ => shared}/repositories/Node.java | 2 +- .../repositories/NodeRepository.java | 2 +- .../{ => shared}/repositories/Owner.java | 2 +- .../repositories/OwnerRepository.java | 2 +- .../repositories/ParentCustomer.java | 2 +- .../ParentCustomerRepository.java | 2 +- .../repositories/SubCustomer.java | 2 +- .../repositories/SubCustomerRepository.java | 2 +- .../repositories/id/CustomerWithIdInt.java | 2 +- .../id/CustomerWithIdIntRepository.java | 2 +- .../id/CustomerWithIdInteger.java | 2 +- .../CustomerWithIdIntegerNoAutoGenerate.java | 2 +- ...WithIdIntegerNoAutoGenerateRepository.java | 2 +- .../id/CustomerWithIdIntegerRepository.java | 2 +- .../repositories/id/CustomerWithIdLong.java | 2 +- .../id/CustomerWithIdLongRepository.java | 2 +- .../repositories/id/CustomerWithIdString.java | 2 +- .../id/CustomerWithIdStringRepository.java | 2 +- .../repositories/id/CustomerWithPurchase.java | 2 +- .../id/CustomerWithPurchaseRepository.java | 2 +- .../repositories/id/Purchase.java | 2 +- .../immutables/CustomerWithFinal.java | 2 +- .../immutables/CustomerWithFinalChild.java | 4 +- .../CustomerWithFinalChildRepository.java | 2 +- .../immutables/CustomerWithFinalId.java | 2 +- .../CustomerWithFinalIdRepository.java | 2 +- .../CustomerWithFinalRepository.java | 2 +- .../repositories/interfaces/CustomerCrud.java | 2 +- .../CustomerEclipseStoreCrudRepository.java | 2 +- ...ustomerEclipseStoreListCrudRepository.java | 2 +- ...seStoreListPagingAndSortingRepository.java | 2 +- ...clipseStorePagingAndSortingRepository.java | 2 +- .../CustomerEclipseStoreRepository.java | 2 +- .../interfaces/CustomerListCrud.java | 2 +- .../CustomerListPagingAndSorting.java | 2 +- .../interfaces/CustomerPagingAndSorting.java | 2 +- .../interfaces/CustomerSimple.java | 2 +- .../real/life/example/Article.java | 2 +- .../real/life/example/ArticleGroup.java | 2 +- .../real/life/example/Invoice.java | 2 +- .../real/life/example/InvoiceRepository.java | 2 +- .../real/life/example/Position.java | 2 +- .../real/life/example/PositionRepository.java | 2 +- .../real/life/example/Warehouse.java | 2 +- .../{ => shared}/tests/ChangeRootTests.java | 10 +-- .../{ => shared}/tests/ConcurrencyTest.java | 10 +-- .../{ => shared}/tests/FinalTest.java | 18 ++--- .../{ => shared}/tests/HashSetTest.java | 14 ++-- .../{ => shared}/tests/IdTest.java | 32 ++++----- .../{ => shared}/tests/InheritanceTest.java | 18 ++--- .../tests/JpaCompatibilityTest.java | 10 +-- .../{ => shared}/tests/QueryTest.java | 16 ++--- .../{ => shared}/tests/RealLifeTests.java | 22 +++---- .../tests/SimpleMultipleTest.java | 14 ++-- .../{ => shared}/tests/SimpleSingleTest.java | 18 ++--- .../tests/SpecificInterfacesTest.java | 26 ++++---- .../{ => shared}/tests/StressTest.java | 10 +-- .../{ => shared}/tests/WorkingCopyTests.java | 14 ++-- 113 files changed, 302 insertions(+), 235 deletions(-) rename spring-data-eclipse-store/src/{main/java/software/xdev/spring/data/eclipse/store/repository/Lazy.java => test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java} (56%) create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestConfiguration.java rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/keywords/KeywordsTest.java (81%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/keywords/MinimalDaoObject.java (93%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/keywords/MinimalRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/BigDecimalDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/BigDecimalRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/BigIntegerDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/BigIntegerRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/CalendarDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/CalendarRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/ComplexObject.java (94%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/DateDaoObject.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/DateRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/EnumMapDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/EnumMapRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/EnumSetDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/EnumSetRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/LazyDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/LazyRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/ListDaoObject.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/ListRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/LocalDateDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/LocalDateRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/LocalDateTimeDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/LocalDateTimeRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/LocalTimeDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/LocalTimeRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/MapDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/MapRepository.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/OptionalDaoObject.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/OptionalRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/SetDaoObject.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/SetRepository.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/TypesData.java (99%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => isolated}/tests/special/types/TypesTest.java (92%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/DefaultTestAnnotations.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/TestConfiguration.java (94%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/Child.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/ChildCustomer.java (92%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/ChildCustomerRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/Customer.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerAsRecord.java (92%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerAsRecordRepository.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerNotCrud.java (94%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerNotCrudRepository.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerRepository.java (94%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerRepositoryWithHashSet.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerRepositoryWithNonFinalHashSet.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerRepositoryWithQuery.java (93%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerWithChild.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerWithChildRepository.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerWithHashSet.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerWithNonFinalHashSet.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/CustomerWithQuery.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/Node.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/NodeRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/Owner.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/OwnerRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/ParentCustomer.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/ParentCustomerRepository.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/SubCustomer.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/SubCustomerRepository.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdInt.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdIntRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdInteger.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdIntegerRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdLong.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdLongRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdString.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithIdStringRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithPurchase.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/CustomerWithPurchaseRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/id/Purchase.java (94%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/immutables/CustomerWithFinal.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/immutables/CustomerWithFinalChild.java (92%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/immutables/CustomerWithFinalChildRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/immutables/CustomerWithFinalId.java (96%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/immutables/CustomerWithFinalIdRepository.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/immutables/CustomerWithFinalRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerCrud.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerEclipseStoreCrudRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerEclipseStoreRepository.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerListCrud.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerListPagingAndSorting.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerPagingAndSorting.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/interfaces/CustomerSimple.java (95%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/real/life/example/Article.java (93%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/real/life/example/ArticleGroup.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/real/life/example/Invoice.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/real/life/example/InvoiceRepository.java (88%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/real/life/example/Position.java (93%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/real/life/example/PositionRepository.java (88%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/repositories/real/life/example/Warehouse.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/ChangeRootTests.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/ConcurrencyTest.java (93%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/FinalTest.java (74%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/HashSetTest.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/IdTest.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/InheritanceTest.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/JpaCompatibilityTest.java (86%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/QueryTest.java (94%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/RealLifeTests.java (91%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/SimpleMultipleTest.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/SimpleSingleTest.java (90%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/SpecificInterfacesTest.java (70%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/StressTest.java (84%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{ => shared}/tests/WorkingCopyTests.java (94%) diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/Lazy.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java similarity index 56% rename from spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/Lazy.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java index 5052e633..223efa00 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/Lazy.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java @@ -13,24 +13,26 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.repository; +package software.xdev.spring.data.eclipse.store.integration.isolated; + +import static org.springframework.test.annotation.DirtiesContext.ClassMode.BEFORE_EACH_TEST_METHOD; -import java.lang.annotation.Documented; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; -import org.springframework.data.annotation.QueryAnnotation; +import org.junit.jupiter.api.extension.ExtendWith; +import org.springframework.test.annotation.DirtiesContext; +import org.springframework.test.context.ContextConfiguration; +import org.springframework.test.context.junit.jupiter.SpringExtension; -/** - * TODO - */ @Retention(RetentionPolicy.RUNTIME) -@Target({ElementType.FIELD, ElementType.ANNOTATION_TYPE}) -@Documented -@QueryAnnotation -public @interface Lazy +@Target(ElementType.TYPE) +@ExtendWith(SpringExtension.class) +@ContextConfiguration(classes = {IsolatedTestConfiguration.class}) +@DirtiesContext(classMode = BEFORE_EACH_TEST_METHOD) +public @interface IsolatedTestAnnotations { } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestConfiguration.java new file mode 100644 index 00000000..443c75a6 --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestConfiguration.java @@ -0,0 +1,65 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated; + +import static org.eclipse.store.storage.embedded.types.EmbeddedStorage.Foundation; + +import java.io.IOException; +import java.nio.file.Path; + +import org.eclipse.store.storage.embedded.types.EmbeddedStorageFoundation; +import org.eclipse.store.storage.types.Storage; +import org.springframework.context.annotation.Configuration; +import org.springframework.context.event.ContextClosedEvent; +import org.springframework.context.event.ContextRefreshedEvent; +import org.springframework.context.event.EventListener; +import org.springframework.util.FileSystemUtils; + +import software.xdev.spring.data.eclipse.store.helper.StorageDirectoryNameProvider; +import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; +import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; + + +@Configuration +@EnableEclipseStoreRepositories( + value = "software.xdev.spring.data.eclipse.store.integration.isolated", + clientConfigurationClass = IsolatedTestConfiguration.class) +public class IsolatedTestConfiguration extends EclipseStoreClientConfiguration +{ + private final String storageDirectory = StorageDirectoryNameProvider.getNewStorageDirectoryPath(); + + @Override + public EmbeddedStorageFoundation createEmbeddedStorageFoundation() + { + return Foundation(Storage.Configuration(Storage.FileProvider(Path.of(this.storageDirectory)))); + } + + @EventListener + public void handleContextRefresh(final ContextRefreshedEvent event) + { + // Init with empty root object + this.getStorageInstance().clearData(); + } + + @EventListener + public void handleContextClosed(final ContextClosedEvent event) throws IOException + { + // End with empty root object + this.getStorageInstance().clearData(); + this.getStorageInstance().stop(); + FileSystemUtils.deleteRecursively(Path.of(this.storageDirectory)); + } +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/KeywordsTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java similarity index 81% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/KeywordsTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java index c075080e..0a8e14db 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/KeywordsTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.keywords; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.keywords; import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Disabled; @@ -21,8 +21,8 @@ import org.springframework.beans.factory.annotation.Autowired; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestConfiguration; /** @@ -30,11 +30,11 @@ * href="https://docs.spring.io/spring-data/jpa/reference/repositories/query-keywords-reference.html">Repository query * keywords */ -@DefaultTestAnnotations +@IsolatedTestAnnotations class KeywordsTest { @Autowired - private TestConfiguration configuration; + private IsolatedTestConfiguration configuration; @Test @Disabled("For now we don't need 'existsBy'") diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/MinimalDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalDaoObject.java similarity index 93% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/MinimalDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalDaoObject.java index 97e62cc9..f306c867 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/MinimalDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.keywords; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.keywords; import jakarta.persistence.GeneratedValue; import jakarta.persistence.GenerationType; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/MinimalRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/MinimalRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalRepository.java index dfafcd02..c1db0a3f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/keywords/MinimalRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.keywords; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.keywords; import org.springframework.data.repository.Repository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigDecimalDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigDecimalDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalDaoObject.java index 2e6eb70f..52c42c58 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigDecimalDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import java.math.BigDecimal; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigDecimalRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigDecimalRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalRepository.java index 92e3940f..f56eb4a8 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigDecimalRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigIntegerDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigIntegerDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerDaoObject.java index 327b034a..90dc44f1 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigIntegerDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import java.math.BigInteger; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigIntegerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigIntegerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerRepository.java index 235567c9..74a8d364 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/BigIntegerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/CalendarDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/CalendarDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarDaoObject.java index 55888a22..3b835475 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/CalendarDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import java.util.Calendar; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/CalendarRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/CalendarRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarRepository.java index 2e7c479a..187d33fb 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/CalendarRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ComplexObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ComplexObject.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ComplexObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ComplexObject.java index 8e68b384..5561bb6c 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ComplexObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ComplexObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/DateDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateDaoObject.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/DateDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateDaoObject.java index b32fb86f..f93dfa12 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/DateDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import java.util.Date; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/DateRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/DateRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateRepository.java index 013ca7d6..f967c16f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/DateRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumMapDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumMapDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapDaoObject.java index 339a3933..cd81c07c 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumMapDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import java.util.EnumMap; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumMapRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumMapRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapRepository.java index ac0d9167..4f49be48 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumMapRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumSetDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumSetDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetDaoObject.java index ebd90363..31acf389 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumSetDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import java.util.EnumSet; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumSetRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumSetRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetRepository.java index b16905c2..f2f186b8 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/EnumSetRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LazyDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LazyDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java index 2cf1c2d4..41221a67 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LazyDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import org.eclipse.serializer.reference.Lazy; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LazyRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LazyRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyRepository.java index d9a6cb7d..a3cd5e37 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LazyRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ListDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListDaoObject.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ListDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListDaoObject.java index 4c1dc25c..f4cb80e7 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ListDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ListRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ListRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListRepository.java index ea057c04..b0351524 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/ListRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateDaoObject.java index e044b976..bf6cf781 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import java.time.LocalDate; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateRepository.java index 8d7ea96c..0aa50229 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateTimeDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateTimeDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeDaoObject.java index 9a1ef5ed..169ea937 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateTimeDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import java.time.LocalDateTime; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateTimeRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateTimeRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeRepository.java index 25fe04ae..737c6ebf 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalDateTimeRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalTimeDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalTimeDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeDaoObject.java index 3ea577bb..953aeab5 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalTimeDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import java.time.LocalTime; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalTimeRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalTimeRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeRepository.java index aafdd07f..db1cac67 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/LocalTimeRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/MapDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/MapDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapDaoObject.java index a9fc3c98..372ec6b3 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/MapDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import java.util.Map; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/MapRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapRepository.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/MapRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapRepository.java index 15f2a5ba..ebbb1d18 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/MapRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/OptionalDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalDaoObject.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/OptionalDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalDaoObject.java index 47aca8cb..228abedc 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/OptionalDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import java.util.Optional; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/OptionalRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/OptionalRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalRepository.java index aac1f6b9..7868afc6 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/OptionalRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/SetDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetDaoObject.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/SetDaoObject.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetDaoObject.java index 8375f22d..be214b09 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/SetDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetDaoObject.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import java.util.Set; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/SetRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetRepository.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/SetRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetRepository.java index 91ee968e..e3ed468b 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/SetRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/TypesData.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java similarity index 99% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/TypesData.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java index cfdb604b..4429ddb6 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/TypesData.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import java.math.BigDecimal; import java.math.BigInteger; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/TypesTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java similarity index 92% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/TypesTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java index e9ac2505..1e1c84e3 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/special/types/TypesTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests.special.types; +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; import java.util.Collection; import java.util.Map; @@ -29,23 +29,23 @@ import software.xdev.spring.data.eclipse.store.exceptions.DataTypeNotSupportedException; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestConfiguration; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; -@DefaultTestAnnotations +@IsolatedTestAnnotations class TypesTest { public static final String TYPES_DATA_SOURCE = - "software.xdev.spring.data.eclipse.store.integration.tests.special.types" + "software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types" + ".TypesData#generateData"; public static final String TYPES_NOT_WORKING_DATA_SOURCE = - "software.xdev.spring.data.eclipse.store.integration.tests.special.types" + "software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types" + ".TypesData#generateNotWorkingData"; @Autowired - private TestConfiguration configuration; + private IsolatedTestConfiguration configuration; @ParameterizedTest @MethodSource(TYPES_DATA_SOURCE) diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/DefaultTestAnnotations.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/DefaultTestAnnotations.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/DefaultTestAnnotations.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/DefaultTestAnnotations.java index 4b47fea7..a3ebc833 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/DefaultTestAnnotations.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/DefaultTestAnnotations.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration; +package software.xdev.spring.data.eclipse.store.integration.shared; import static org.springframework.test.annotation.DirtiesContext.ClassMode.BEFORE_EACH_TEST_METHOD; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/TestConfiguration.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/TestConfiguration.java index fe337930..933b0058 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/TestConfiguration.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration; +package software.xdev.spring.data.eclipse.store.integration.shared; import static org.eclipse.store.storage.embedded.types.EmbeddedStorage.Foundation; @@ -35,7 +35,7 @@ @Configuration @EnableEclipseStoreRepositories( - value = "software.xdev.spring.data.eclipse.store.integration", + value = "software.xdev.spring.data.eclipse.store.integration.shared", clientConfigurationClass = TestConfiguration.class) public class TestConfiguration extends EclipseStoreClientConfiguration { diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Child.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Child.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Child.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Child.java index c0d24c1a..549da2db 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Child.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Child.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomer.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomer.java similarity index 92% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomer.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomer.java index 7af466b3..a243bdfe 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomer.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomer.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; public class ChildCustomer extends ParentCustomer { diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomerRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomerRepository.java index 46979d77..08622099 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ChildCustomerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Customer.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Customer.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Customer.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Customer.java index 89e7d4f7..2ef2e24d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Customer.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Customer.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecord.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecord.java similarity index 92% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecord.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecord.java index 0e082bc9..9c9df6c7 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecord.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecord.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecordRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecordRepository.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecordRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecordRepository.java index 0061c6de..a28803fa 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerAsRecordRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecordRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.Optional; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrud.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrud.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrud.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrud.java index 99140aa9..fe960ddd 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrud.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrud.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrudRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrudRepository.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrudRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrudRepository.java index abf8c087..df0ff39e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerNotCrudRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrudRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepository.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepository.java index cd2a570b..7c90c670 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.List; import java.util.Optional; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithHashSet.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithHashSet.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithHashSet.java index 045d6c17..cf53de00 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithHashSet.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithHashSet.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithNonFinalHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithNonFinalHashSet.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithNonFinalHashSet.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithNonFinalHashSet.java index 3c729c1b..e459843e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithNonFinalHashSet.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithNonFinalHashSet.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithQuery.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithQuery.java similarity index 93% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithQuery.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithQuery.java index 69baff3c..f845fed8 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerRepositoryWithQuery.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithQuery.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.List; import java.util.Optional; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChild.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChild.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChild.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChild.java index 668e67f2..272318d8 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChild.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChild.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChildRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChildRepository.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChildRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChildRepository.java index 65a8cf5e..e74bc81b 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithChildRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChildRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.Optional; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithHashSet.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithHashSet.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithHashSet.java index e6a2c95c..b46e5b72 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithHashSet.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithHashSet.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.HashSet; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithNonFinalHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithNonFinalHashSet.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithNonFinalHashSet.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithNonFinalHashSet.java index dc8bbefd..45009fd3 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithNonFinalHashSet.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithNonFinalHashSet.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.HashSet; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithQuery.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithQuery.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithQuery.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithQuery.java index a4ad8257..43d6d234 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/CustomerWithQuery.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithQuery.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Node.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Node.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Node.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Node.java index d359f8a4..27764c50 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Node.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Node.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.ArrayList; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/NodeRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/NodeRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/NodeRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/NodeRepository.java index 53555be9..efa0d716 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/NodeRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/NodeRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Owner.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Owner.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Owner.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Owner.java index f49d78f4..896ed6a2 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/Owner.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Owner.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/OwnerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/OwnerRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/OwnerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/OwnerRepository.java index e3b5b5dc..ce29f850 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/OwnerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/OwnerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomer.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomer.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomer.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomer.java index c897bc62..2256d706 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomer.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomer.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomerRepository.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomerRepository.java index a76780b6..29057f43 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/ParentCustomerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import org.springframework.data.repository.CrudRepository; import org.springframework.data.repository.PagingAndSortingRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomer.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomer.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomer.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomer.java index d7cd1a98..e72316ff 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomer.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomer.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; public class SubCustomer extends Customer { diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomerRepository.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomerRepository.java index e95e3785..321323a2 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/SubCustomerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInt.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInt.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInt.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInt.java index ba16d8d4..4b4f4562 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInt.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInt.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntRepository.java index b000d441..888a123d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInteger.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInteger.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInteger.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInteger.java index 096d2466..b0a9e1e8 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdInteger.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInteger.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java index 5fa96ed0..7618633b 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java index c86528c3..7ddc6171 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerRepository.java index 79a534da..f6de36f0 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdIntegerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLong.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLong.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLong.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLong.java index e2c003ce..49d3f384 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLong.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLong.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLongRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLongRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLongRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLongRepository.java index 29f340f0..e86acdcc 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdLongRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLongRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdString.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdString.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdString.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdString.java index 43045152..eaa32ad8 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdString.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdString.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdStringRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdStringRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdStringRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdStringRepository.java index 85e75ec9..c40f899e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithIdStringRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdStringRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchase.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchase.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchase.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchase.java index 69e1e80d..c37d67c5 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchase.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchase.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import java.util.ArrayList; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchaseRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchaseRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchaseRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchaseRepository.java index aa8264e3..2f986e3a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/CustomerWithPurchaseRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchaseRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/Purchase.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/Purchase.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/Purchase.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/Purchase.java index 69479540..52de0753 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/id/Purchase.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/Purchase.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.id; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.id; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinal.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinal.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinal.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinal.java index 5eae308e..d0ddd64d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinal.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinal.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChild.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChild.java similarity index 92% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChild.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChild.java index f74c8326..1bde2eae 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChild.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChild.java @@ -13,12 +13,12 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; import java.util.List; import java.util.Objects; -import software.xdev.spring.data.eclipse.store.integration.repositories.Child; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Child; public class CustomerWithFinalChild diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChildRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChildRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChildRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChildRepository.java index 0eb44e4a..22e9d951 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalChildRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChildRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; import org.springframework.data.repository.CrudRepository; import org.springframework.data.repository.PagingAndSortingRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalId.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalId.java similarity index 96% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalId.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalId.java index f4cad237..c10b2d74 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalId.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalId.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalIdRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalIdRepository.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalIdRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalIdRepository.java index 7ce5b1fd..ebb4df9e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalIdRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalIdRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalRepository.java index 607c3bf3..519b3f95 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/immutables/CustomerWithFinalRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.immutables; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables; import org.springframework.data.repository.CrudRepository; import org.springframework.data.repository.PagingAndSortingRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerCrud.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerCrud.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerCrud.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerCrud.java index 9e7d49ce..7d9778f7 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerCrud.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerCrud.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreCrudRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreCrudRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreCrudRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreCrudRepository.java index 4c9bd223..64ff9274 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreCrudRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreCrudRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreCrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java index cc4337fa..5fb57f8f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreListCrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java index 9fbfea7e..c0d0fb6d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreListPagingAndSortingRepositoryRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java index 7d45e15a..14b444c2 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStorePagingAndSortingRepositoryRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreRepository.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreRepository.java index b3feecb1..0a476e5f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerEclipseStoreRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListCrud.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListCrud.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListCrud.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListCrud.java index 56e2087d..fe5c0c02 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListCrud.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListCrud.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListPagingAndSorting.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListPagingAndSorting.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListPagingAndSorting.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListPagingAndSorting.java index 2e848482..89ef5b9f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerListPagingAndSorting.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListPagingAndSorting.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerPagingAndSorting.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerPagingAndSorting.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerPagingAndSorting.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerPagingAndSorting.java index 06ba144f..4cf9b1c3 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerPagingAndSorting.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerPagingAndSorting.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerSimple.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerSimple.java similarity index 95% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerSimple.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerSimple.java index 775f3198..e5f8404b 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/interfaces/CustomerSimple.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerSimple.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.interfaces; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces; import java.util.List; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Article.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Article.java similarity index 93% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Article.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Article.java index dd418fcb..f67cc905 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Article.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Article.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; import java.util.ArrayList; import java.util.Collections; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/ArticleGroup.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/ArticleGroup.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/ArticleGroup.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/ArticleGroup.java index fd6e4bac..d8378911 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/ArticleGroup.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/ArticleGroup.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; public class ArticleGroup { diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Invoice.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Invoice.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Invoice.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Invoice.java index 8af20a95..498f7492 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Invoice.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Invoice.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; import java.util.List; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/InvoiceRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/InvoiceRepository.java similarity index 88% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/InvoiceRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/InvoiceRepository.java index 93c9e286..b86bd835 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/InvoiceRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/InvoiceRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Position.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Position.java similarity index 93% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Position.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Position.java index 29b55bc6..85f40363 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Position.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Position.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; import java.util.List; import java.util.Optional; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/PositionRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/PositionRepository.java similarity index 88% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/PositionRepository.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/PositionRepository.java index d7e98068..3692bbc5 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/PositionRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/PositionRepository.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; import org.springframework.data.repository.CrudRepository; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Warehouse.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Warehouse.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Warehouse.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Warehouse.java index 9f7bd011..ce814b84 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/repositories/real/life/example/Warehouse.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Warehouse.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example; +package software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example; import java.util.HashSet; import java.util.Set; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ChangeRootTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ChangeRootTests.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ChangeRootTests.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ChangeRootTests.java index 3ad3bfe5..a229a91b 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ChangeRootTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ChangeRootTests.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; @@ -22,10 +22,10 @@ import org.springframework.beans.factory.annotation.Autowired; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.repositories.Node; -import software.xdev.spring.data.eclipse.store.integration.repositories.NodeRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Node; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.NodeRepository; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ConcurrencyTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ConcurrencyTest.java similarity index 93% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ConcurrencyTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ConcurrencyTest.java index 2ebdf4d0..9cf7b0fa 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/ConcurrencyTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ConcurrencyTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; @@ -32,10 +32,10 @@ import org.springframework.beans.factory.annotation.Autowired; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; @SuppressWarnings("OptionalGetWithoutIsPresent") diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/FinalTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/FinalTest.java similarity index 74% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/FinalTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/FinalTest.java index d48bafb6..c50022cb 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/FinalTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/FinalTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; @@ -24,14 +24,14 @@ import software.xdev.spring.data.eclipse.store.exceptions.IdFieldFinalException; import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinal; -import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalChild; -import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalChildRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalId; -import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalIdRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.immutables.CustomerWithFinalRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinal; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinalChild; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinalChildRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinalId; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinalIdRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinalRepository; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/HashSetTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/HashSetTest.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/HashSetTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/HashSetTest.java index 3d42ffe3..df152e5f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/HashSetTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/HashSetTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; import java.util.Set; @@ -24,12 +24,12 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepositoryWithHashSet; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepositoryWithNonFinalHashSet; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithHashSet; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithNonFinalHashSet; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepositoryWithHashSet; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepositoryWithNonFinalHashSet; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerWithHashSet; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerWithNonFinalHashSet; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/IdTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/IdTest.java similarity index 89% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/IdTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/IdTest.java index 1a4e9380..6c100760 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/IdTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/IdTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import static software.xdev.spring.data.eclipse.store.helper.TestUtil.restartDatastore; @@ -26,21 +26,21 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdInt; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdIntRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdInteger; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdIntegerNoAutoGenerate; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdIntegerNoAutoGenerateRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdIntegerRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdLong; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdLongRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdString; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithIdStringRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithPurchase; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.CustomerWithPurchaseRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.id.Purchase; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdInt; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdIntRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdInteger; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdIntegerNoAutoGenerate; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdIntegerNoAutoGenerateRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdIntegerRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdLong; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdLongRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdString; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdStringRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithPurchase; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithPurchaseRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.Purchase; import software.xdev.spring.data.eclipse.store.repository.EclipseStoreStorage; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/InheritanceTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/InheritanceTest.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/InheritanceTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/InheritanceTest.java index c99dce81..3920782f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/InheritanceTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/InheritanceTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; @@ -23,14 +23,14 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.repositories.ChildCustomer; -import software.xdev.spring.data.eclipse.store.integration.repositories.ChildCustomerRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.ParentCustomer; -import software.xdev.spring.data.eclipse.store.integration.repositories.ParentCustomerRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.SubCustomer; -import software.xdev.spring.data.eclipse.store.integration.repositories.SubCustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.ChildCustomer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.ChildCustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.ParentCustomer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.ParentCustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.SubCustomer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.SubCustomerRepository; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/JpaCompatibilityTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/JpaCompatibilityTest.java similarity index 86% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/JpaCompatibilityTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/JpaCompatibilityTest.java index b160a6f9..73ab0455 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/JpaCompatibilityTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/JpaCompatibilityTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; import java.util.Optional; @@ -24,10 +24,10 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepositoryWithQuery; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithQuery; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepositoryWithQuery; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerWithQuery; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/QueryTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/QueryTest.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/QueryTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/QueryTest.java index ef6e133e..a18af6fb 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/QueryTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/QueryTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; import java.util.Optional; @@ -27,13 +27,13 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.repositories.Child; -import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithChild; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerWithChildRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Child; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerWithChild; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerWithChildRepository; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/RealLifeTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/RealLifeTests.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/RealLifeTests.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/RealLifeTests.java index a22819cf..47d1b1bf 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/RealLifeTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/RealLifeTests.java @@ -13,9 +13,9 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; -import static software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Position.getPositionWithArticleWithName; +import static software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.Position.getPositionWithArticleWithName; import java.util.ArrayList; import java.util.Arrays; @@ -27,15 +27,15 @@ import org.springframework.beans.factory.annotation.Autowired; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Article; -import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.ArticleGroup; -import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Invoice; -import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.InvoiceRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Position; -import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.PositionRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.real.life.example.Warehouse; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.Article; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.ArticleGroup; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.Invoice; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.InvoiceRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.Position; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.PositionRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.Warehouse; @SuppressWarnings("OptionalGetWithoutIsPresent") diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleMultipleTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleMultipleTest.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleMultipleTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleMultipleTest.java index d19111e7..d2d36f00 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleMultipleTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleMultipleTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; @@ -23,12 +23,12 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.Owner; -import software.xdev.spring.data.eclipse.store.integration.repositories.OwnerRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Owner; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.OwnerRepository; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleSingleTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleSingleTest.java similarity index 90% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleSingleTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleSingleTest.java index 5dc76ad0..4c95363c 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SimpleSingleTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleSingleTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; import java.util.Optional; @@ -24,14 +24,14 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerAsRecord; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerAsRecordRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerNotCrud; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerNotCrudRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerAsRecord; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerAsRecordRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerNotCrud; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerNotCrudRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SpecificInterfacesTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SpecificInterfacesTest.java similarity index 70% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SpecificInterfacesTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SpecificInterfacesTest.java index 2ebfab8b..54256c45 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/SpecificInterfacesTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SpecificInterfacesTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; @@ -24,18 +24,18 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerCrud; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerEclipseStoreCrudRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerEclipseStoreListCrudRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerEclipseStoreListPagingAndSortingRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerEclipseStorePagingAndSortingRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerEclipseStoreRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerListCrud; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerListPagingAndSorting; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerPagingAndSorting; -import software.xdev.spring.data.eclipse.store.integration.repositories.interfaces.CustomerSimple; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerCrud; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerEclipseStoreCrudRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerEclipseStoreListCrudRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerEclipseStoreListPagingAndSortingRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerEclipseStorePagingAndSortingRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerEclipseStoreRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerListCrud; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerListPagingAndSorting; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerPagingAndSorting; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerSimple; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/StressTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/StressTest.java similarity index 84% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/StressTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/StressTest.java index d8b9e73c..7da4d9c1 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/StressTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/StressTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; import java.util.stream.IntStream; @@ -24,10 +24,10 @@ import org.springframework.beans.factory.annotation.Autowired; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; @DefaultTestAnnotations diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/WorkingCopyTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/WorkingCopyTests.java similarity index 94% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/WorkingCopyTests.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/WorkingCopyTests.java index b87676eb..b580ec8a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/tests/WorkingCopyTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/WorkingCopyTests.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.tests; +package software.xdev.spring.data.eclipse.store.integration.shared.tests; import java.util.List; import java.util.Optional; @@ -24,12 +24,12 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; -import software.xdev.spring.data.eclipse.store.integration.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; -import software.xdev.spring.data.eclipse.store.integration.repositories.Customer; -import software.xdev.spring.data.eclipse.store.integration.repositories.CustomerRepository; -import software.xdev.spring.data.eclipse.store.integration.repositories.Node; -import software.xdev.spring.data.eclipse.store.integration.repositories.NodeRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; +import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Node; +import software.xdev.spring.data.eclipse.store.integration.shared.repositories.NodeRepository; @SuppressWarnings("OptionalGetWithoutIsPresent") From 98cc37c00dc840a476de26590495f183fbe5597b Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Thu, 7 Mar 2024 11:33:01 +0100 Subject: [PATCH 31/98] Refactored tests --- .../{shared => }/TestConfiguration.java | 6 +- .../isolated/IsolatedTestAnnotations.java | 2 - .../isolated/IsolatedTestConfiguration.java | 65 ------------------- .../integration/isolated/package-info.java | 6 ++ .../isolated/tests/keywords/KeywordsTest.java | 5 +- .../keywords/KeywordsTestConfiguration.java | 28 ++++++++ .../types/SpecialTypesTestConfiguration.java | 28 ++++++++ .../tests/special/types/TypesTest.java | 5 +- .../shared/DefaultTestAnnotations.java | 2 +- .../shared/SharedTestConfiguration.java | 30 +++++++++ .../integration/shared/package-info.java | 4 ++ .../shared/tests/ChangeRootTests.java | 4 +- .../shared/tests/ConcurrencyTest.java | 4 +- .../integration/shared/tests/FinalTest.java | 4 +- .../integration/shared/tests/HashSetTest.java | 4 +- .../integration/shared/tests/IdTest.java | 4 +- .../shared/tests/InheritanceTest.java | 4 +- .../shared/tests/JpaCompatibilityTest.java | 4 +- .../integration/shared/tests/QueryTest.java | 4 +- .../shared/tests/RealLifeTests.java | 4 +- .../shared/tests/SimpleMultipleTest.java | 4 +- .../shared/tests/SimpleSingleTest.java | 4 +- .../shared/tests/SpecificInterfacesTest.java | 4 +- .../integration/shared/tests/StressTest.java | 4 +- .../shared/tests/WorkingCopyTests.java | 4 +- 25 files changed, 132 insertions(+), 105 deletions(-) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/{shared => }/TestConfiguration.java (87%) delete mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestConfiguration.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/package-info.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTestConfiguration.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SpecialTypesTestConfiguration.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/SharedTestConfiguration.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/package-info.java diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/TestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java similarity index 87% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/TestConfiguration.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java index 933b0058..855f7e5e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/TestConfiguration.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.integration.shared; +package software.xdev.spring.data.eclipse.store.integration; import static org.eclipse.store.storage.embedded.types.EmbeddedStorage.Foundation; @@ -30,13 +30,9 @@ import software.xdev.spring.data.eclipse.store.helper.StorageDirectoryNameProvider; import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; -import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; @Configuration -@EnableEclipseStoreRepositories( - value = "software.xdev.spring.data.eclipse.store.integration.shared", - clientConfigurationClass = TestConfiguration.class) public class TestConfiguration extends EclipseStoreClientConfiguration { private final String storageDirectory = StorageDirectoryNameProvider.getNewStorageDirectoryPath(); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java index 223efa00..0fddcacf 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java @@ -24,14 +24,12 @@ import org.junit.jupiter.api.extension.ExtendWith; import org.springframework.test.annotation.DirtiesContext; -import org.springframework.test.context.ContextConfiguration; import org.springframework.test.context.junit.jupiter.SpringExtension; @Retention(RetentionPolicy.RUNTIME) @Target(ElementType.TYPE) @ExtendWith(SpringExtension.class) -@ContextConfiguration(classes = {IsolatedTestConfiguration.class}) @DirtiesContext(classMode = BEFORE_EACH_TEST_METHOD) public @interface IsolatedTestAnnotations { diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestConfiguration.java deleted file mode 100644 index 443c75a6..00000000 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestConfiguration.java +++ /dev/null @@ -1,65 +0,0 @@ -/* - * Copyright © 2023 XDEV Software (https://xdev.software) - * - * 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. - */ -package software.xdev.spring.data.eclipse.store.integration.isolated; - -import static org.eclipse.store.storage.embedded.types.EmbeddedStorage.Foundation; - -import java.io.IOException; -import java.nio.file.Path; - -import org.eclipse.store.storage.embedded.types.EmbeddedStorageFoundation; -import org.eclipse.store.storage.types.Storage; -import org.springframework.context.annotation.Configuration; -import org.springframework.context.event.ContextClosedEvent; -import org.springframework.context.event.ContextRefreshedEvent; -import org.springframework.context.event.EventListener; -import org.springframework.util.FileSystemUtils; - -import software.xdev.spring.data.eclipse.store.helper.StorageDirectoryNameProvider; -import software.xdev.spring.data.eclipse.store.repository.config.EclipseStoreClientConfiguration; -import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; - - -@Configuration -@EnableEclipseStoreRepositories( - value = "software.xdev.spring.data.eclipse.store.integration.isolated", - clientConfigurationClass = IsolatedTestConfiguration.class) -public class IsolatedTestConfiguration extends EclipseStoreClientConfiguration -{ - private final String storageDirectory = StorageDirectoryNameProvider.getNewStorageDirectoryPath(); - - @Override - public EmbeddedStorageFoundation createEmbeddedStorageFoundation() - { - return Foundation(Storage.Configuration(Storage.FileProvider(Path.of(this.storageDirectory)))); - } - - @EventListener - public void handleContextRefresh(final ContextRefreshedEvent event) - { - // Init with empty root object - this.getStorageInstance().clearData(); - } - - @EventListener - public void handleContextClosed(final ContextClosedEvent event) throws IOException - { - // End with empty root object - this.getStorageInstance().clearData(); - this.getStorageInstance().stop(); - FileSystemUtils.deleteRecursively(Path.of(this.storageDirectory)); - } -} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/package-info.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/package-info.java new file mode 100644 index 00000000..f5465f61 --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/package-info.java @@ -0,0 +1,6 @@ +/** + * The repositories of these tests are seperated from each other. That means that e.g. the + * {@link software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types.TypesTest} can't access the + * {@link software.xdev.spring.data.eclipse.store.integration.isolated.tests.keywords.MinimalRepository}. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java index 0a8e14db..348d8980 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java @@ -19,10 +19,10 @@ import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Test; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.test.context.ContextConfiguration; import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestConfiguration; /** @@ -31,10 +31,11 @@ * keywords */ @IsolatedTestAnnotations +@ContextConfiguration(classes = {KeywordsTestConfiguration.class}) class KeywordsTest { @Autowired - private IsolatedTestConfiguration configuration; + private KeywordsTestConfiguration configuration; @Test @Disabled("For now we don't need 'existsBy'") diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTestConfiguration.java new file mode 100644 index 00000000..241d778d --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTestConfiguration.java @@ -0,0 +1,28 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.keywords; + +import org.springframework.context.annotation.Configuration; + +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; + + +@Configuration +@EnableEclipseStoreRepositories(clientConfigurationClass = KeywordsTestConfiguration.class) +public class KeywordsTestConfiguration extends TestConfiguration +{ +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SpecialTypesTestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SpecialTypesTestConfiguration.java new file mode 100644 index 00000000..1dfe164e --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SpecialTypesTestConfiguration.java @@ -0,0 +1,28 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; + +import org.springframework.context.annotation.Configuration; + +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; + + +@Configuration +@EnableEclipseStoreRepositories(clientConfigurationClass = SpecialTypesTestConfiguration.class) +public class SpecialTypesTestConfiguration extends TestConfiguration +{ +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java index 1e1c84e3..d7278d7a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java @@ -26,15 +26,16 @@ import org.junit.jupiter.params.provider.MethodSource; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.context.ApplicationContext; +import org.springframework.test.context.ContextConfiguration; import software.xdev.spring.data.eclipse.store.exceptions.DataTypeNotSupportedException; import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestConfiguration; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; @IsolatedTestAnnotations +@ContextConfiguration(classes = {SpecialTypesTestConfiguration.class}) class TypesTest { public static final String TYPES_DATA_SOURCE = @@ -45,7 +46,7 @@ class TypesTest + ".TypesData#generateNotWorkingData"; @Autowired - private IsolatedTestConfiguration configuration; + private SpecialTypesTestConfiguration configuration; @ParameterizedTest @MethodSource(TYPES_DATA_SOURCE) diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/DefaultTestAnnotations.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/DefaultTestAnnotations.java index a3ebc833..41a134d6 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/DefaultTestAnnotations.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/DefaultTestAnnotations.java @@ -31,7 +31,7 @@ @Retention(RetentionPolicy.RUNTIME) @Target(ElementType.TYPE) @ExtendWith(SpringExtension.class) -@ContextConfiguration(classes = {TestConfiguration.class}) +@ContextConfiguration(classes = {SharedTestConfiguration.class}) @DirtiesContext(classMode = BEFORE_EACH_TEST_METHOD) public @interface DefaultTestAnnotations { diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/SharedTestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/SharedTestConfiguration.java new file mode 100644 index 00000000..d4b6a582 --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/SharedTestConfiguration.java @@ -0,0 +1,30 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.shared; + +import org.springframework.context.annotation.Configuration; + +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; + + +@Configuration +@EnableEclipseStoreRepositories( + value = "software.xdev.spring.data.eclipse.store.integration.shared", + clientConfigurationClass = SharedTestConfiguration.class) +public class SharedTestConfiguration extends TestConfiguration +{ +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/package-info.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/package-info.java new file mode 100644 index 00000000..be4503c9 --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/package-info.java @@ -0,0 +1,4 @@ +/** + * These tests SHARE their repositories. That's not ideal and should be changed in the future. + */ +package software.xdev.spring.data.eclipse.store.integration.shared; diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ChangeRootTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ChangeRootTests.java index a229a91b..055c6078 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ChangeRootTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ChangeRootTests.java @@ -23,7 +23,7 @@ import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.SharedTestConfiguration; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Node; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.NodeRepository; @@ -39,7 +39,7 @@ public class ChangeRootTests @Autowired private NodeRepository repository; @Autowired - private TestConfiguration configuration; + private SharedTestConfiguration configuration; //@formatter:off /** diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ConcurrencyTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ConcurrencyTest.java index 9cf7b0fa..4e1ae8d8 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ConcurrencyTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ConcurrencyTest.java @@ -33,7 +33,7 @@ import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.SharedTestConfiguration; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; @@ -47,7 +47,7 @@ class ConcurrencyTest private CustomerRepository repository; @Autowired - private TestConfiguration configuration; + private SharedTestConfiguration configuration; private final List testCustomers = IntStream.range(1, 100).mapToObj((i) -> new Customer(CUSTOMER_NO + i, "")).toList(); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/FinalTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/FinalTest.java index c50022cb..74e48fb3 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/FinalTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/FinalTest.java @@ -25,7 +25,7 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.SharedTestConfiguration; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinal; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinalChild; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.immutables.CustomerWithFinalChildRepository; @@ -45,7 +45,7 @@ class FinalTest CustomerWithFinalIdRepository withFinalIdRepository; @Autowired - TestConfiguration configuration; + SharedTestConfiguration configuration; @Test void testSaveAndFindSingle() diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/HashSetTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/HashSetTest.java index df152e5f..29d451c0 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/HashSetTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/HashSetTest.java @@ -25,7 +25,7 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.SharedTestConfiguration; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepositoryWithHashSet; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepositoryWithNonFinalHashSet; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerWithHashSet; @@ -41,7 +41,7 @@ class HashSetTest private CustomerRepositoryWithNonFinalHashSet nonFinalRepository; @Autowired - private TestConfiguration configuration; + private SharedTestConfiguration configuration; @Test void testSaveAndFindAll() diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/IdTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/IdTest.java index 6c100760..5833c0e4 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/IdTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/IdTest.java @@ -27,7 +27,7 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.SharedTestConfiguration; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdInt; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdIntRepository; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.id.CustomerWithIdInteger; @@ -49,7 +49,7 @@ class IdTest { @Autowired - private TestConfiguration configuration; + private SharedTestConfiguration configuration; @Test void testCreateSingleWithAutoIdInteger(@Autowired final CustomerWithIdIntegerRepository customerRepository) diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/InheritanceTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/InheritanceTest.java index 3920782f..6cd03676 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/InheritanceTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/InheritanceTest.java @@ -24,7 +24,7 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.SharedTestConfiguration; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.ChildCustomer; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.ChildCustomerRepository; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.ParentCustomer; @@ -43,7 +43,7 @@ class InheritanceTest @Autowired private SubCustomerRepository subCustomerRepository; @Autowired - private TestConfiguration configuration; + private SharedTestConfiguration configuration; @Test void testSaveChildFindParent() diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/JpaCompatibilityTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/JpaCompatibilityTest.java index 73ab0455..ec626212 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/JpaCompatibilityTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/JpaCompatibilityTest.java @@ -25,7 +25,7 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.SharedTestConfiguration; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepositoryWithQuery; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerWithQuery; @@ -37,7 +37,7 @@ class JpaCompatibilityTest private CustomerRepositoryWithQuery customerRepository; @Autowired - private TestConfiguration configuration; + private SharedTestConfiguration configuration; @Test void testUseQueryAnnotationFindAll() diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/QueryTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/QueryTest.java index a18af6fb..1bbd8778 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/QueryTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/QueryTest.java @@ -28,7 +28,7 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.SharedTestConfiguration; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Child; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; @@ -45,7 +45,7 @@ class QueryTest private CustomerWithChildRepository customerWithChildRepository; @Autowired - private TestConfiguration configuration; + private SharedTestConfiguration configuration; @Test void testBasicFindAllByLastNameTwoResults() diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/RealLifeTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/RealLifeTests.java index 47d1b1bf..bae2ea7c 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/RealLifeTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/RealLifeTests.java @@ -28,7 +28,7 @@ import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.SharedTestConfiguration; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.Article; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.ArticleGroup; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.real.life.example.Invoice; @@ -54,7 +54,7 @@ public class RealLifeTests @Autowired PositionRepository positionRepository; @Autowired - private TestConfiguration configuration; + private SharedTestConfiguration configuration; private Invoice buildDefaultModel() { diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleMultipleTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleMultipleTest.java index d2d36f00..26855070 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleMultipleTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleMultipleTest.java @@ -24,7 +24,7 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.SharedTestConfiguration; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Owner; @@ -39,7 +39,7 @@ class SimpleMultipleTest @Autowired private OwnerRepository ownerRepository; @Autowired - private TestConfiguration configuration; + private SharedTestConfiguration configuration; @Test void testBasicSaveAndFindAll() diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleSingleTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleSingleTest.java index 4c95363c..49a8c87e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleSingleTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleSingleTest.java @@ -25,7 +25,7 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.SharedTestConfiguration; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerAsRecord; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerAsRecordRepository; @@ -43,7 +43,7 @@ class SimpleSingleTest private CustomerAsRecordRepository recordRepository; @Autowired - private TestConfiguration configuration; + private SharedTestConfiguration configuration; @Test void testNullFindAll() diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SpecificInterfacesTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SpecificInterfacesTest.java index 54256c45..07126440 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SpecificInterfacesTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SpecificInterfacesTest.java @@ -25,7 +25,7 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.SharedTestConfiguration; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerCrud; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerEclipseStoreCrudRepository; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.interfaces.CustomerEclipseStoreListCrudRepository; @@ -53,7 +53,7 @@ class SpecificInterfacesTest private CustomerEclipseStoreListPagingAndSortingRepository listPagingAndSortingRepository; @Autowired - private TestConfiguration configuration; + private SharedTestConfiguration configuration; @Test void testSimple() diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/StressTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/StressTest.java index 7da4d9c1..0916f46e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/StressTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/StressTest.java @@ -25,7 +25,7 @@ import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.SharedTestConfiguration; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; @@ -37,7 +37,7 @@ class StressTest private CustomerRepository repository; @Autowired - private TestConfiguration configuration; + private SharedTestConfiguration configuration; /** * @param customerCount beyond 5_000 takes quite a long time. That's why 5_000 is the biggest number for single diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/WorkingCopyTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/WorkingCopyTests.java index b580ec8a..41c5311d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/WorkingCopyTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/WorkingCopyTests.java @@ -25,7 +25,7 @@ import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.shared.DefaultTestAnnotations; -import software.xdev.spring.data.eclipse.store.integration.shared.TestConfiguration; +import software.xdev.spring.data.eclipse.store.integration.shared.SharedTestConfiguration; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Customer; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.CustomerRepository; import software.xdev.spring.data.eclipse.store.integration.shared.repositories.Node; @@ -44,7 +44,7 @@ public class WorkingCopyTests @Autowired NodeRepository nodeRepository; @Autowired - private TestConfiguration configuration; + private SharedTestConfiguration configuration; @Test void testBasicChangeOnlyAfterSave() From 89665190b27165933f796b57a2325a5efc0c1690 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Thu, 7 Mar 2024 14:14:03 +0100 Subject: [PATCH 32/98] Created test environment for lazy --- .../isolated/tests/lazy/LazyTest.java | 56 +++++++++++++++++++ .../tests/lazy/LazyTestConfiguration.java | 28 ++++++++++ .../tests/lazy/ObjectWithLazyHashMap.java | 34 +++++++++++ .../lazy/ObjectWithLazyHashMapRepository.java | 23 ++++++++ .../tests/lazy/ObjectWithLazyHashSet.java | 34 +++++++++++ .../lazy/ObjectWithLazyHashSetRepository.java | 23 ++++++++ .../tests/lazy/ObjectWithLazyList.java | 34 +++++++++++ .../lazy/ObjectWithLazyListRepository.java | 23 ++++++++ .../lazy/ObjectWithLazySimpleObject.java | 31 ++++++++++ .../ObjectWithLazySimpleObjectRepository.java | 23 ++++++++ .../isolated/tests/lazy/SimpleObject.java | 5 ++ 11 files changed, 314 insertions(+) create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTestConfiguration.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashMap.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashMapRepository.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashSet.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashSetRepository.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyList.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyListRepository.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazySimpleObject.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazySimpleObjectRepository.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/SimpleObject.java diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java new file mode 100644 index 00000000..ee4832e8 --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java @@ -0,0 +1,56 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.lazy; + +import org.eclipse.serializer.collections.lazy.LazyArrayList; +import org.eclipse.serializer.collections.lazy.LazyList; +import org.junit.jupiter.api.Assertions; +import org.junit.jupiter.api.Test; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.test.context.ContextConfiguration; + +import software.xdev.spring.data.eclipse.store.helper.TestUtil; +import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestAnnotations; + + +@IsolatedTestAnnotations +@ContextConfiguration(classes = {LazyTestConfiguration.class}) +class LazyTest +{ + @Autowired + private LazyTestConfiguration configuration; + + @Test + void lazyListStore(final ObjectWithLazyListRepository repository) + { + final ObjectWithLazyList newList = new ObjectWithLazyList(); + final SimpleObject objectToStore = new SimpleObject("Test"); + final LazyArrayList lazyArrayList = new LazyArrayList(); + lazyArrayList.add(objectToStore); + newList.setLazyList(lazyArrayList); + repository.save(newList); + + TestUtil.doBeforeAndAfterRestartOfDatastore( + this.configuration, + () -> { + Assertions.assertEquals(1, repository.findAll().size()); + final LazyList loadedLazyList = repository.findAll().getFirst().getLazyList(); + Assertions.assertEquals(1, loadedLazyList.size()); + Assertions.assertEquals(objectToStore, loadedLazyList.getFirst()); + } + ); + } +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTestConfiguration.java new file mode 100644 index 00000000..625c98da --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTestConfiguration.java @@ -0,0 +1,28 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.lazy; + +import org.springframework.context.annotation.Configuration; + +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; + + +@Configuration +@EnableEclipseStoreRepositories(clientConfigurationClass = LazyTestConfiguration.class) +public class LazyTestConfiguration extends TestConfiguration +{ +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashMap.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashMap.java new file mode 100644 index 00000000..3ea0d2fd --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashMap.java @@ -0,0 +1,34 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.lazy; + +import org.eclipse.serializer.collections.lazy.LazyHashMap; + + +public class ObjectWithLazyHashMap +{ + private LazyHashMap lazyHashMap; + + public LazyHashMap getLazyHashMap() + { + return this.lazyHashMap; + } + + public void setLazyHashMap(final LazyHashMap lazyHashMap) + { + this.lazyHashMap = lazyHashMap; + } +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashMapRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashMapRepository.java new file mode 100644 index 00000000..7389aebb --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashMapRepository.java @@ -0,0 +1,23 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.lazy; + +import org.springframework.data.repository.ListCrudRepository; + + +public interface ObjectWithLazyHashMapRepository extends ListCrudRepository +{ +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashSet.java new file mode 100644 index 00000000..7a366f72 --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashSet.java @@ -0,0 +1,34 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.lazy; + +import org.eclipse.serializer.collections.lazy.LazyHashSet; + + +public class ObjectWithLazyHashSet +{ + private LazyHashSet lazyHashSet; + + public LazyHashSet getLazyHashSet() + { + return this.lazyHashSet; + } + + public void setLazyHashSet(final LazyHashSet lazyHashSet) + { + this.lazyHashSet = lazyHashSet; + } +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashSetRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashSetRepository.java new file mode 100644 index 00000000..cffb92aa --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashSetRepository.java @@ -0,0 +1,23 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.lazy; + +import org.springframework.data.repository.ListCrudRepository; + + +public interface ObjectWithLazyHashSetRepository extends ListCrudRepository +{ +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyList.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyList.java new file mode 100644 index 00000000..dc608f8e --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyList.java @@ -0,0 +1,34 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.lazy; + +import org.eclipse.serializer.collections.lazy.LazyList; + + +public class ObjectWithLazyList +{ + private LazyList lazyList; + + public LazyList getLazyList() + { + return this.lazyList; + } + + public void setLazyList(final LazyList lazyList) + { + this.lazyList = lazyList; + } +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyListRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyListRepository.java new file mode 100644 index 00000000..964f6117 --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyListRepository.java @@ -0,0 +1,23 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.lazy; + +import org.springframework.data.repository.ListCrudRepository; + + +public interface ObjectWithLazyListRepository extends ListCrudRepository +{ +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazySimpleObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazySimpleObject.java new file mode 100644 index 00000000..3ae4c2b8 --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazySimpleObject.java @@ -0,0 +1,31 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.lazy; + +public class ObjectWithLazySimpleObject +{ + private SimpleObject lazySimpleObject; + + public SimpleObject getLazySimpleObject() + { + return this.lazySimpleObject; + } + + public void setLazySimpleObject(final SimpleObject lazySimpleObject) + { + this.lazySimpleObject = lazySimpleObject; + } +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazySimpleObjectRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazySimpleObjectRepository.java new file mode 100644 index 00000000..9d413d7f --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazySimpleObjectRepository.java @@ -0,0 +1,23 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.lazy; + +import org.springframework.data.repository.ListCrudRepository; + + +public interface ObjectWithLazySimpleObjectRepository extends ListCrudRepository +{ +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/SimpleObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/SimpleObject.java new file mode 100644 index 00000000..abbd79d3 --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/SimpleObject.java @@ -0,0 +1,5 @@ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.lazy; + +public record SimpleObject(String value) +{ +} From f202ee21d0554a880a9163e27265aed65767d0f6 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Fri, 8 Mar 2024 14:51:17 +0100 Subject: [PATCH 33/98] Implemented Proxy creator for Lazies --- .../store/repository/SupportedChecker.java | 6 - .../repository/lazy/LazyInterceptor.java | 22 +++ .../repository/lazy/LazyProxyGenerator.java | 28 +++ .../lazy/SuperLazyBinaryHandler.java | 169 ++++++++++++++++++ .../support/copier/DataTypeUtil.java | 7 + .../copier/AbstractRegisteringCopier.java | 80 +++++++++ .../EclipseSerializerRegisteringCopier.java | 71 ++------ .../RegisteringObjectCopier.java | 9 +- ...RegisteringStorageToWorkingCopyCopier.java | 49 +++++ .../RegisteringWorkingCopyAndOriginal.java | 7 + ...RegisteringWorkingCopyToStorageCopier.java | 48 +++++ .../working/RecursiveWorkingCopier.java | 98 ++++++++-- .../integration/isolated/package-info.java | 15 ++ .../isolated/tests/lazy/LazyTest.java | 4 +- .../isolated/tests/lazy/SimpleObject.java | 15 ++ .../tests/special/types/LazyDaoObject.java | 19 ++ .../tests/special/types/TypesData.java | 99 ++++++++-- .../integration/shared/package-info.java | 15 ++ ...teringStorageToWorkingCopyCopierTest.java} | 34 ++-- 19 files changed, 683 insertions(+), 112 deletions(-) create mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyInterceptor.java create mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyProxyGenerator.java create mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SuperLazyBinaryHandler.java create mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java rename spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/{object => copier}/EclipseSerializerRegisteringCopier.java (66%) rename spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/{object => copier}/RegisteringObjectCopier.java (80%) create mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java create mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyAndOriginal.java create mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/{object/EclipseStoreRegisteringCopierTest.java => copier/RegisteringStorageToWorkingCopyCopierTest.java} (72%) diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/SupportedChecker.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/SupportedChecker.java index 9d9cfc7b..832ad604 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/SupportedChecker.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/SupportedChecker.java @@ -41,18 +41,12 @@ public interface SupportedChecker *

* Some classes are not supported, because Eclipse Store doesn't support them. *

- *

- * {@link Lazy} is not supported, because a lot of hidden stuff must be done to keep Lazy-References really Lazy - * when creating a working copy. - *

*/ boolean isSupported(Class clazz); class Implementation implements SupportedChecker { private static final List> UNSUPPORTED_DATA_TYPES = List.of( - // Is difficult to handle when creating working copies - Lazy.class, // Here EclipseStore has problems: https://github.com/microstream-one/microstream/issues/173 Calendar.class, WeakHashMap.class, diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyInterceptor.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyInterceptor.java new file mode 100644 index 00000000..9ab1a39e --- /dev/null +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyInterceptor.java @@ -0,0 +1,22 @@ +package software.xdev.spring.data.eclipse.store.repository.lazy; + +import org.aopalliance.intercept.ConstructorInterceptor; +import org.aopalliance.intercept.ConstructorInvocation; +import org.eclipse.serializer.reference.Lazy; + + +public class LazyInterceptor implements ConstructorInterceptor +{ + private final Lazy originalLazy; + + public LazyInterceptor(final Lazy originalLazy) + { + this.originalLazy = originalLazy; + } + + @Override + public Lazy construct(final ConstructorInvocation invocation) + { + return Lazy.Reference(this.originalLazy.get()); + } +} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyProxyGenerator.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyProxyGenerator.java new file mode 100644 index 00000000..b9d0b36b --- /dev/null +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyProxyGenerator.java @@ -0,0 +1,28 @@ +package software.xdev.spring.data.eclipse.store.repository.lazy; + +import org.eclipse.serializer.reference.Lazy; +import org.springframework.aop.framework.ProxyFactory; + + +public final class LazyProxyGenerator +{ + private LazyProxyGenerator() + { + } + + public static , T> L generateLazyProxy(final L lazy, final Class clazz) + { + final ProxyFactory f = new ProxyFactory(clazz, new LazyInterceptor<>(lazy)); + return (L)f.getProxy(); + } + + public static Lazy generateLazyProxy(final Lazy lazy) + { + return generateLazyProxy(lazy, Lazy.class); + } + + public static Lazy.Default generateLazyDefaultProxy(final Lazy.Default lazy) + { + return generateLazyProxy(lazy, Lazy.Default.class); + } +} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SuperLazyBinaryHandler.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SuperLazyBinaryHandler.java new file mode 100644 index 00000000..2577588c --- /dev/null +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SuperLazyBinaryHandler.java @@ -0,0 +1,169 @@ +package software.xdev.spring.data.eclipse.store.repository.lazy; + +import java.lang.reflect.Constructor; + +import org.eclipse.serializer.persistence.binary.types.AbstractBinaryHandlerCustom; +import org.eclipse.serializer.persistence.binary.types.Binary; +import org.eclipse.serializer.persistence.types.PersistenceLoadHandler; +import org.eclipse.serializer.persistence.types.PersistenceReferenceLoader; +import org.eclipse.serializer.persistence.types.PersistenceStoreHandler; +import org.eclipse.serializer.reference.Lazy; +import org.eclipse.serializer.reference.ObjectSwizzling; +import org.eclipse.serializer.reflect.XReflect; + + +/** + * Copied from + * {@link org.eclipse.serializer.persistence.binary.org.eclipse.serializer.reference.BinaryHandlerLazyDefault}. + */ +public class SuperLazyBinaryHandler extends AbstractBinaryHandlerCustom> +{ + /////////////////////////////////////////////////////////////////////////// + // static methods // + /////////////////// + + public static SuperLazyBinaryHandler New() + { + return new SuperLazyBinaryHandler(); + } + + @SuppressWarnings("rawtypes") + static final Constructor CONSTRUCTOR = XReflect.setAccessible( + XReflect.getDeclaredConstructor(Lazy.Default.class, Object.class, long.class, ObjectSwizzling.class) + ); + + /////////////////////////////////////////////////////////////////////////// + // constructors // + ///////////////// + + private SuperLazyBinaryHandler() + { + super( + Lazy.Default.genericType(), + CustomFields( + CustomField(Object.class, "subject") + ) + ); + } + + /////////////////////////////////////////////////////////////////////////// + // methods // + //////////// + + @Override + public final void store( + final Binary data, + final Lazy.Default instance, + final long objectId, + final PersistenceStoreHandler handler + ) + { + /* (29.09.2015 TM)NOTE: There are several cases that have to be handled here correctly: + * + * 1) objectId == 0, referent == null + * "Empty" lazy reference that must be stored as such + * + * 2.) objectId == 0, referent != null + * Newly created lazy reference with a referent. The referent has to be handled and the lazy reference has + * to be stored with the referent's OID + * + * 3.) objectId != null, referent == null + * The lazy reference represents a non-null referent that is currently simply not loaded. The lazy reference + * must be stored nonetheless, pointing to its known referent objectId + * + * 4.) objectId != null, referent != null + * The lazy reference represents a non-null referent that is currently loaded. The refernt must be handled, + * the lazy reference must be stored, pointing to its known referent objectId. + */ + + final Object referent = instance.peek(); + final long referenceOid; + + if(referent == null) + { + referenceOid = instance.objectId(); + } + else + { + // OID validation or updating is done by linking logic + referenceOid = handler.apply(referent); + } + + // link to object supplier (internal logic can either update, discard or throw exception on mismatch) + // instance.$link(referenceOid, handler.getObjectRetriever()); + + // lazy reference instance must be stored in any case + data.storeEntityHeader(Binary.referenceBinaryLength(1), this.typeId(), objectId); + data.store_long(referenceOid); + } + + @SuppressWarnings("unchecked") + @Override + public final Lazy.Default create(final Binary data, final PersistenceLoadHandler handler) + { + /* (27.04.2016 TM)NOTE: registering a Lazy instance with a reference manager + * without having the object supplier set yet might cause an inconsistency if the + * LRM iterates lazy references before the update added the supplier reference. + * ON the other hand: the lazy reference instance is not yet completed and whatever + * logic iterates over the LRM's entries shouldn't rely on anything. + */ + final long objectId = data.read_long(0); + + final Lazy.Default newLazy = Lazy.register( + XReflect.invoke(CONSTRUCTOR, null, objectId, null) + ); + return LazyProxyGenerator.generateLazyProxy(newLazy); + } + + @Override + public final void updateState( + final Binary data, + final Lazy.Default instance, + final PersistenceLoadHandler handler + ) + { + /* + * Intentionally no subject lookup here as premature strong referencing + * might defeat the purpose of memory freeing lazy referencing if no + * other strong reference to the subject is present at the moment. + */ + instance.$setLoader(handler.getObjectRetriever()); + } + + @Override + public final void complete( + final Binary data, + final Lazy.Default instance, + final PersistenceLoadHandler handler + ) + { + // no-op for normal implementation (see non-reference-hashing collections for other examples) + } + + @Override + public final boolean hasPersistedReferences() + { + return true; + } + + @Override + public final boolean hasPersistedVariableLength() + { + return false; + } + + @Override + public final boolean hasVaryingPersistedLengthInstances() + { + return false; + } + + @Override + public final void iterateLoadableReferences( + final Binary offset, + final PersistenceReferenceLoader iterator + ) + { + // the lazy reference is not naturally loadable, but special-handled by this handler + } +} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/DataTypeUtil.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/DataTypeUtil.java index 0e6fc2de..254fa092 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/DataTypeUtil.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/DataTypeUtil.java @@ -20,6 +20,8 @@ import jakarta.annotation.Nonnull; +import org.eclipse.serializer.reference.Lazy; + public final class DataTypeUtil { @@ -45,6 +47,11 @@ public static boolean isObjectArray(final Object obj) return obj instanceof Object[]; } + public static boolean isLazy(final Object obj) + { + return obj instanceof Lazy; + } + public static boolean isPrimitiveArray(final Object obj) { return obj instanceof boolean[] diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java new file mode 100644 index 00000000..219a1cc0 --- /dev/null +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java @@ -0,0 +1,80 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; + +import org.eclipse.serializer.Serializer; +import org.eclipse.serializer.SerializerFoundation; +import org.eclipse.serializer.persistence.binary.jdk17.java.util.BinaryHandlerImmutableCollectionsList12; +import org.eclipse.serializer.persistence.binary.jdk17.java.util.BinaryHandlerImmutableCollectionsSet12; +import org.eclipse.serializer.persistence.binary.types.Binary; +import org.eclipse.serializer.persistence.types.PersistenceManager; +import org.eclipse.serializer.reference.Reference; +import org.eclipse.serializer.util.X; + +import software.xdev.spring.data.eclipse.store.repository.SupportedChecker; + + +/** + * This class registers storage instances and copy them for working copies. Utilizes + * {@link EclipseSerializerRegisteringCopier}. + */ +public abstract class AbstractRegisteringCopier implements RegisteringObjectCopier +{ + private final EclipseSerializerRegisteringCopier actualCopier; + + public AbstractRegisteringCopier( + final SupportedChecker supportedChecker, + final RegisteringWorkingCopyAndOriginal register) + { + this.actualCopier = new EclipseSerializerRegisteringCopier( + supportedChecker, + register, + this.createPersistenceManager() + ); + } + + protected abstract PersistenceManager createPersistenceManager(); + + protected SerializerFoundation createSerializerFoundation() + { + final SerializerFoundation newFoundation = SerializerFoundation.New(); + newFoundation.registerCustomTypeHandler(BinaryHandlerImmutableCollectionsSet12.New()); + newFoundation.registerCustomTypeHandler(BinaryHandlerImmutableCollectionsList12.New()); + + final Reference buffer = X.Reference(null); + final Serializer.Source source = () -> X.Constant(buffer.get()); + final Serializer.Target target = buffer::set; + return newFoundation + .setPersistenceSource(source) + .setPersistenceTarget(target) + // Make every type persistable. + // This is quite dangerous! + // But if this is not set we get problems e.g. with HashMap$Node + .setTypeEvaluatorPersistable(a -> true); + } + + @Override + public synchronized T copy(final T source) + { + return this.actualCopier.copy(source); + } + + @Override + public synchronized void close() + { + this.actualCopier.close(); + } +} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/object/EclipseSerializerRegisteringCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/EclipseSerializerRegisteringCopier.java similarity index 66% rename from spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/object/EclipseSerializerRegisteringCopier.java rename to spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/EclipseSerializerRegisteringCopier.java index 00f6f8e5..4420a5a4 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/object/EclipseSerializerRegisteringCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/EclipseSerializerRegisteringCopier.java @@ -13,28 +13,21 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.repository.support.copier.object; +package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; import java.util.HashMap; import java.util.Map; -import org.eclipse.serializer.Serializer; -import org.eclipse.serializer.SerializerFoundation; -import org.eclipse.serializer.persistence.binary.jdk17.java.util.BinaryHandlerImmutableCollectionsList12; -import org.eclipse.serializer.persistence.binary.jdk17.java.util.BinaryHandlerImmutableCollectionsSet12; import org.eclipse.serializer.persistence.binary.types.Binary; import org.eclipse.serializer.persistence.binary.types.BinaryStorer; import org.eclipse.serializer.persistence.types.PersistenceLoader; import org.eclipse.serializer.persistence.types.PersistenceManager; import org.eclipse.serializer.persistence.types.PersistenceStorer; -import org.eclipse.serializer.reference.Reference; -import org.eclipse.serializer.util.X; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import software.xdev.spring.data.eclipse.store.exceptions.DataTypeNotSupportedException; import software.xdev.spring.data.eclipse.store.repository.SupportedChecker; -import software.xdev.spring.data.eclipse.store.repository.WorkingCopyRegistry; import software.xdev.spring.data.eclipse.store.repository.support.copier.DataTypeUtil; @@ -42,32 +35,23 @@ * This class utilizes EclipseStore-Serialization and copies objects by serializing and deserializing objects in * memory. */ -public class EclipseSerializerRegisteringCopier implements RegisteringObjectCopier +public class EclipseSerializerRegisteringCopier implements AutoCloseable { private static final Logger LOG = LoggerFactory.getLogger(EclipseSerializerRegisteringCopier.class); - private final SerializerFoundation foundation; private PersistenceManager persistenceManager; private final SupportedChecker supportedChecker; - - private final WorkingCopyRegistry registry; + private final RegisteringWorkingCopyAndOriginal register; public EclipseSerializerRegisteringCopier( - final WorkingCopyRegistry registry, - final SupportedChecker supportedChecker) + final SupportedChecker supportedChecker, + final RegisteringWorkingCopyAndOriginal register, + final PersistenceManager persistenceManager) { - final SerializerFoundation newFoundation = SerializerFoundation.New(); - newFoundation.registerCustomTypeHandler(BinaryHandlerImmutableCollectionsSet12.New()); - newFoundation.registerCustomTypeHandler(BinaryHandlerImmutableCollectionsList12.New()); - this.foundation = newFoundation; - this.registry = registry; this.supportedChecker = supportedChecker; + this.register = register; + this.persistenceManager = persistenceManager; } - - @Override - public synchronized T copy(final T source) - { - return this.copy(source, false); - } + @Override public synchronized void close() @@ -80,28 +64,6 @@ public synchronized void close() } } - private void lazyInit() - { - if(this.persistenceManager == null) - { - final Reference buffer = X.Reference(null); - final Serializer.Source source = () -> X.Constant(buffer.get()); - final Serializer.Target target = buffer::set; - this.persistenceManager = - (((SerializerFoundation)this.foundation.setPersistenceSource(source)) - .setPersistenceTarget(target)) - // Make every type persistable. - // This is quite dangerous! - // But if this is not set we get problems e.g. with HashMap$Node - .setTypeEvaluatorPersistable(a -> true) - .createPersistenceManager(); - } - else - { - this.persistenceManager.objectRegistry().truncateAll(); - } - } - /** * Here lies a lot of knowledge about EclipseStore internals. *

@@ -116,11 +78,9 @@ private void lazyInit() * EclipseStore-ObjectId. *

*/ - @SuppressWarnings("unchecked") - @Override - public synchronized T copy(final T source, final boolean invertRegistering) + public synchronized T copy(final T source) { - this.lazyInit(); + this.persistenceManager.objectRegistry().truncateAll(); final BinaryStorer.Default storer = (BinaryStorer.Default)this.persistenceManager.createStorer(); // Loader erstellen final PersistenceLoader loader = this.persistenceManager.createLoader(); @@ -153,14 +113,7 @@ public synchronized T copy(final T source, final boolean invertRegistering) if(originalObject != null) { summarizer.incrementRegisteredObjectsCount(); - if(invertRegistering) - { - this.registry.invertRegister(copiedObject, originalObject); - } - else - { - this.registry.register(copiedObject, originalObject); - } + this.register.register(copiedObject, originalObject); } } ); diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/object/RegisteringObjectCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringObjectCopier.java similarity index 80% rename from spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/object/RegisteringObjectCopier.java rename to spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringObjectCopier.java index 4e659c08..e111941e 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/object/RegisteringObjectCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringObjectCopier.java @@ -13,12 +13,9 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.repository.support.copier.object; +package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; -import org.eclipse.serializer.ObjectCopier; - - -public interface RegisteringObjectCopier extends ObjectCopier +public interface RegisteringObjectCopier extends AutoCloseable { - T copy(T t, boolean invertRegistering); + T copy(T t); } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java new file mode 100644 index 00000000..283b7b04 --- /dev/null +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java @@ -0,0 +1,49 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; + +import org.eclipse.serializer.persistence.binary.types.Binary; +import org.eclipse.serializer.persistence.types.PersistenceManager; + +import software.xdev.spring.data.eclipse.store.repository.SupportedChecker; +import software.xdev.spring.data.eclipse.store.repository.WorkingCopyRegistry; +import software.xdev.spring.data.eclipse.store.repository.lazy.SuperLazyBinaryHandler; + + +/** + * This class registers storage instances and copy them for working copies. Utilizes + * {@link EclipseSerializerRegisteringCopier}. + */ +public class RegisteringStorageToWorkingCopyCopier extends AbstractRegisteringCopier +{ + public RegisteringStorageToWorkingCopyCopier( + final WorkingCopyRegistry registry, + final SupportedChecker supportedChecker) + { + super( + supportedChecker, + (workingCopy, objectToStore) -> registry.register(workingCopy, objectToStore) + ); + } + + @Override + protected PersistenceManager createPersistenceManager() + { + return this.createSerializerFoundation() + .registerCustomTypeHandlers(SuperLazyBinaryHandler.New()) + .createPersistenceManager(); + } +} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyAndOriginal.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyAndOriginal.java new file mode 100644 index 00000000..1438d835 --- /dev/null +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyAndOriginal.java @@ -0,0 +1,7 @@ +package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; + +@FunctionalInterface +public interface RegisteringWorkingCopyAndOriginal +{ + boolean register(final Object workingCopy, final Object objectToStore); +} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java new file mode 100644 index 00000000..39708b45 --- /dev/null +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java @@ -0,0 +1,48 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; + +import org.eclipse.serializer.persistence.binary.types.Binary; +import org.eclipse.serializer.persistence.types.PersistenceManager; + +import software.xdev.spring.data.eclipse.store.repository.SupportedChecker; +import software.xdev.spring.data.eclipse.store.repository.WorkingCopyRegistry; + + +/** + * This class registers working copy instances and copy them for the storage. Utilizes + * {@link EclipseSerializerRegisteringCopier}. + */ +public class RegisteringWorkingCopyToStorageCopier extends AbstractRegisteringCopier +{ + + public RegisteringWorkingCopyToStorageCopier( + final WorkingCopyRegistry registry, + final SupportedChecker supportedChecker) + { + super( + supportedChecker, + (workingCopy, objectToStore) -> registry.invertRegister(workingCopy, objectToStore) + ); + } + + @Override + protected PersistenceManager createPersistenceManager() + { + return this.createSerializerFoundation() + .createPersistenceManager(); + } +} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java index a781da27..76906a2e 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java @@ -27,6 +27,7 @@ import java.util.TreeMap; import java.util.TreeSet; +import org.eclipse.serializer.reference.Lazy; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -37,9 +38,11 @@ import software.xdev.spring.data.eclipse.store.repository.WorkingCopyRegistry; import software.xdev.spring.data.eclipse.store.repository.access.AccessHelper; import software.xdev.spring.data.eclipse.store.repository.access.modifier.FieldAccessModifier; +import software.xdev.spring.data.eclipse.store.repository.lazy.LazyProxyGenerator; import software.xdev.spring.data.eclipse.store.repository.support.copier.DataTypeUtil; -import software.xdev.spring.data.eclipse.store.repository.support.copier.object.EclipseSerializerRegisteringCopier; -import software.xdev.spring.data.eclipse.store.repository.support.copier.object.RegisteringObjectCopier; +import software.xdev.spring.data.eclipse.store.repository.support.copier.copier.RegisteringObjectCopier; +import software.xdev.spring.data.eclipse.store.repository.support.copier.copier.RegisteringStorageToWorkingCopyCopier; +import software.xdev.spring.data.eclipse.store.repository.support.copier.copier.RegisteringWorkingCopyToStorageCopier; /** @@ -47,8 +50,14 @@ */ public class RecursiveWorkingCopier implements WorkingCopier { + public enum MergingDirection + { + STORAGE_TO_WORKING_COPY, + WORKING_COPY_TO_STORAGE + } private static final Logger LOG = LoggerFactory.getLogger(RecursiveWorkingCopier.class); - private final RegisteringObjectCopier objectCopier; + private final RegisteringObjectCopier workingCopyToStorageCopier; + private final RegisteringObjectCopier storageToWorkingCopyCopier; private final WorkingCopyRegistry registry; private final IdSetterProvider idSetterProvider; private final Class domainClass; @@ -63,7 +72,8 @@ public RecursiveWorkingCopier( { this.domainClass = domainClass; this.registry = registry; - this.objectCopier = new EclipseSerializerRegisteringCopier(registry, supportedChecker); + this.workingCopyToStorageCopier = new RegisteringWorkingCopyToStorageCopier(registry, supportedChecker); + this.storageToWorkingCopyCopier = new RegisteringStorageToWorkingCopyCopier(registry, supportedChecker); this.idSetterProvider = idSetterProvider; this.persistableChecker = persistableChecker; } @@ -110,7 +120,8 @@ public WorkingCopierResult mergeBack(final T workingCopy) workingCopy, true, new HashSetMergedTargetsCollector(), - changedObjectCollector); + changedObjectCollector, + MergingDirection.WORKING_COPY_TO_STORAGE); if(LOG.isTraceEnabled()) { LOG.trace("Merging back the working copy object of class {}", workingCopy.getClass().getSimpleName()); @@ -123,7 +134,8 @@ public E getOrCreateObjectForDatastore( final E workingCopy, final boolean mergeValues, final MergedTargetsCollector alreadyMergedTargets, - final ChangedObjectCollector changedCollector) + final ChangedObjectCollector changedCollector, + final MergingDirection mergingDirection) { if(workingCopy == null) { @@ -135,7 +147,8 @@ public E getOrCreateObjectForDatastore( { if(mergeValues) { - this.mergeValues(workingCopy, originalObject, alreadyMergedTargets, changedCollector); + this.mergeValues(workingCopy, originalObject, alreadyMergedTargets, changedCollector, + mergingDirection); } changedCollector.collectChangedObject(originalObject); return originalObject; @@ -146,7 +159,7 @@ public E getOrCreateObjectForDatastore( final E objectForDatastore = this.genericCopy(workingCopy, true); // "Why merging values of an identical object?" you might ask. // Well, because some sub-objects might already be in the datastore. - this.mergeValues(workingCopy, objectForDatastore, alreadyMergedTargets, changedCollector); + this.mergeValues(workingCopy, objectForDatastore, alreadyMergedTargets, changedCollector, mergingDirection); changedCollector.collectChangedObject(objectForDatastore); return objectForDatastore; } @@ -161,7 +174,9 @@ private void mergeValues( final E sourceObject, final E targetObject, final MergedTargetsCollector alreadyMergedTargets, - final ChangedObjectCollector changedCollector) + final ChangedObjectCollector changedCollector, + final MergingDirection mergingDirection + ) { if(sourceObject == targetObject || alreadyMergedTargets.isAlreadyMerged(targetObject) || targetObject == null) { @@ -179,7 +194,13 @@ private void mergeValues( } AccessHelper.getInheritedPrivateFieldsByName(sourceObject.getClass()).values().forEach( field -> - this.mergeValueOfField(sourceObject, targetObject, field, alreadyMergedTargets, changedCollector) + this.mergeValueOfField( + sourceObject, + targetObject, + field, + alreadyMergedTargets, + changedCollector, + mergingDirection) ); } catch(final Exception e) @@ -193,7 +214,8 @@ private void mergeValueOfField( final E targetObject, final Field field, final MergedTargetsCollector alreadyMergedTargets, - final ChangedObjectCollector changedCollector) + final ChangedObjectCollector changedCollector, + final MergingDirection mergingDirection) { try { @@ -239,10 +261,16 @@ else if(DataTypeUtil.isObjectArray(valueOfSourceObject)) valueOfSourceObject.getClass().getComponentType(), (Object[])valueOfSourceObject, alreadyMergedTargets, - changedCollector + changedCollector, + mergingDirection ); fam.writeValueOfField(targetObject, newArray, !targetObjectIsPartOfJavaPackage); } + else if(DataTypeUtil.isLazy(valueOfSourceObject)) + { + final Lazy newLazy = this.createNewLazy((Lazy)valueOfSourceObject, mergingDirection); + fam.writeValueOfField(targetObject, newLazy, true); + } else { // "Simple" object @@ -252,7 +280,8 @@ else if(DataTypeUtil.isObjectArray(valueOfSourceObject)) valueOfSourceObject, false, alreadyMergedTargets, - changedCollector); + changedCollector, + mergingDirection); if(valueOfTargetObject != originalValueObjectOfSource) { // If the reference is new, it must be set @@ -276,7 +305,8 @@ else if(DataTypeUtil.isObjectArray(valueOfSourceObject)) valueOfSourceObject, originalValueObjectOfSource, alreadyMergedTargets, - changedCollector); + changedCollector, + mergingDirection); } } } @@ -288,6 +318,34 @@ else if(DataTypeUtil.isObjectArray(valueOfSourceObject)) } } + private Lazy createNewLazy( + final Lazy valueOfSourceObject, + final MergingDirection mergingDirection + ) + { + final Lazy oldLazy = valueOfSourceObject; + final Lazy newLazy; + if(mergingDirection.equals(MergingDirection.STORAGE_TO_WORKING_COPY)) + { + // If this object is generated for a working copy we need a proxy that only loads the actual + // stored lazy if needed and not before. + newLazy = LazyProxyGenerator.generateLazyProxy(oldLazy); + } + else + { + // TODO + if(oldLazy.isLoaded()) + { + newLazy = Lazy.Reference(oldLazy.get()); + } + else + { + throw new RuntimeException(""); + } + } + return newLazy; + } + /** * Super special case for HashMap or similar java-classes which can't be merged nicely. Thus, we make a simple copy * of the whole object. @@ -311,7 +369,8 @@ private E[] createGenericObjectArray( final Class clazz, final Object[] valueOfSourceObjectArray, final MergedTargetsCollector alreadyMergedTargets, - final ChangedObjectCollector changedCollector) + final ChangedObjectCollector changedCollector, + final MergingDirection mergingDirection) { // Create new Array with original objects with merged data final E[] newArray = (E[])Array.newInstance(clazz, valueOfSourceObjectArray.length); @@ -321,14 +380,19 @@ private E[] createGenericObjectArray( (E)valueOfSourceObjectArray[i], true, alreadyMergedTargets, - changedCollector); + changedCollector, + mergingDirection); } return newArray; } private E onlyCreateCopy(final E objectToCopy, final boolean invertRegistry) { - return this.objectCopier.copy(objectToCopy, invertRegistry); + if(invertRegistry) + { + return this.workingCopyToStorageCopier.copy(objectToCopy); + } + return this.storageToWorkingCopyCopier.copy(objectToCopy); } @Override diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/package-info.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/package-info.java index f5465f61..a5d558eb 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/package-info.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/package-info.java @@ -1,3 +1,18 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ /** * The repositories of these tests are seperated from each other. That means that e.g. the * {@link software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types.TypesTest} can't access the diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java index ee4832e8..d05c7b64 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java @@ -47,9 +47,9 @@ void lazyListStore(final ObjectWithLazyListRepository repository) this.configuration, () -> { Assertions.assertEquals(1, repository.findAll().size()); - final LazyList loadedLazyList = repository.findAll().getFirst().getLazyList(); + final LazyList loadedLazyList = repository.findAll().get(0).getLazyList(); Assertions.assertEquals(1, loadedLazyList.size()); - Assertions.assertEquals(objectToStore, loadedLazyList.getFirst()); + Assertions.assertEquals(objectToStore, loadedLazyList.get(0)); } ); } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/SimpleObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/SimpleObject.java index abbd79d3..96d53b3e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/SimpleObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/SimpleObject.java @@ -1,3 +1,18 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ package software.xdev.spring.data.eclipse.store.integration.isolated.tests.lazy; public record SimpleObject(String value) diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java index 41221a67..641d8531 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java @@ -15,6 +15,8 @@ */ package software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types; +import java.util.Objects; + import org.eclipse.serializer.reference.Lazy; @@ -24,4 +26,21 @@ public LazyDaoObject(final Integer id, final Lazy value) { super(id, value); } + + @Override + public boolean equals(final Object o) + { + if(this == o) + { + return true; + } + if(o == null || this.getClass() != o.getClass()) + { + return false; + } + final ComplexObject> that = (ComplexObject>)o; + return Objects.equals(this.getId(), that.getId()) && Objects.equals( + this.getValue().get(), + that.getValue().get()); + } } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java index 4429ddb6..b4968828 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java @@ -44,6 +44,9 @@ import java.util.function.Function; import java.util.stream.Stream; +import org.eclipse.serializer.collections.lazy.LazyArrayList; +import org.eclipse.serializer.collections.lazy.LazyHashMap; +import org.eclipse.serializer.collections.lazy.LazyHashSet; import org.eclipse.serializer.reference.Lazy; import org.junit.jupiter.params.provider.Arguments; @@ -108,6 +111,32 @@ public static Stream generateData() id -> new SetDaoObject(id, new HashSet<>(List.of("1", "2"))), set -> set.getValue().add("3") ), + new TestArguments<>( + SetRepository.class, + id -> new SetDaoObject(id, new LazyHashSet<>()), + set -> set.getValue().add("1") + ), + new TestArguments<>( + SetRepository.class, + id -> + { + final LazyHashSet set = new LazyHashSet<>(); + set.add("1"); + return new SetDaoObject(id, set); + }, + set -> set.getValue().add("2") + ), + new TestArguments<>( + SetRepository.class, + id -> + { + final LazyHashSet set = new LazyHashSet<>(); + set.add("1"); + set.add("2"); + return new SetDaoObject(id, set); + }, + set -> set.getValue().add("3") + ), new TestArguments<>( SetRepository.class, id -> new SetDaoObject(id, new TreeSet<>()), @@ -244,6 +273,32 @@ public static Stream generateData() }, object -> object.getValue().add("3") ), + new TestArguments<>( + ListRepository.class, + id -> new ListDaoObject(id, new LazyArrayList<>()), + object -> object.getValue().add("1") + ), + new TestArguments<>( + ListRepository.class, + id -> + { + final LazyArrayList list = new LazyArrayList<>(); + list.add("1"); + return new ListDaoObject(id, list); + }, + object -> object.getValue().add("2") + ), + new TestArguments<>( + ListRepository.class, + id -> + { + final LazyArrayList list = new LazyArrayList<>(); + list.add("1"); + list.add("2"); + return new ListDaoObject(id, list); + }, + object -> object.getValue().add("3") + ), new TestArguments<>( ListRepository.class, id -> new ListDaoObject(id, new ArrayList<>(Set.of("1"))), @@ -378,6 +433,40 @@ public static Stream generateData() OptionalRepository.class, id -> new OptionalDaoObject(id, null), set -> set.setValue(Optional.of("1")) + ), + new TestArguments<>( + LazyRepository.class, + id -> new LazyDaoObject(id, Lazy.Reference("1")), + object -> object.setValue(Lazy.Reference("2")) + ), + new TestArguments<>( + LazyRepository.class, + id -> new LazyDaoObject(id, Lazy.Reference("1")), + object -> object.getValue().clear() + ), + new TestArguments<>( + MapRepository.class, + id -> new MapDaoObject(id, new LazyHashMap<>()), + set -> set.getValue().put("1", "1") + ), + new TestArguments<>( + MapRepository.class, + id -> { + final LazyHashMap lazyHashMap = new LazyHashMap<>(); + lazyHashMap.put("1", "1"); + return new MapDaoObject(id, lazyHashMap); + }, + set -> set.getValue().put("2", "2") + ), + new TestArguments<>( + MapRepository.class, + id -> { + final LazyHashMap lazyHashMap = new LazyHashMap<>(); + lazyHashMap.put("1", "1"); + lazyHashMap.put("2", "2"); + return new MapDaoObject(id, lazyHashMap); + }, + set -> set.getValue().put("3", "3") ) ) ).toArguments(); @@ -392,16 +481,6 @@ public static Stream generateNotWorkingData() { return new ListOfTestArguments( List.of( - new TestArguments<>( - LazyRepository.class, - id -> new LazyDaoObject(id, Lazy.Reference("1")), - object -> object.setValue(Lazy.Reference("2")) - ), - new TestArguments<>( - LazyRepository.class, - id -> new LazyDaoObject(id, Lazy.Reference("1")), - object -> object.getValue().clear() - ), new TestArguments<>( EnumMapRepository.class, id -> new EnumMapDaoObject(id, new EnumMap<>(EnumMapDaoObject.Album.class)), diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/package-info.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/package-info.java index be4503c9..77b2d9f2 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/package-info.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/package-info.java @@ -1,3 +1,18 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ /** * These tests SHARE their repositories. That's not ideal and should be changed in the future. */ diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/object/EclipseStoreRegisteringCopierTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopierTest.java similarity index 72% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/object/EclipseStoreRegisteringCopierTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopierTest.java index 51ad01bf..f870a9b4 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/object/EclipseStoreRegisteringCopierTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopierTest.java @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.repository.support.copier.object; +package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; import java.util.List; import java.util.stream.IntStream; @@ -25,7 +25,7 @@ import software.xdev.spring.data.eclipse.store.repository.WorkingCopyRegistry; -class EclipseStoreRegisteringCopierTest +class RegisteringStorageToWorkingCopyCopierTest { private record DummyData(String data, int number) { @@ -34,8 +34,10 @@ private record DummyData(String data, int number) @Test void testCopyManyCopiesSingle() { - try(final EclipseSerializerRegisteringCopier copier = - new EclipseSerializerRegisteringCopier(new WorkingCopyRegistry(), new SupportedChecker.Implementation())) + try(final RegisteringStorageToWorkingCopyCopier copier = + new RegisteringStorageToWorkingCopyCopier( + new WorkingCopyRegistry(), + new SupportedChecker.Implementation())) { final List originalObjects = IntStream.range(0, 1_000).mapToObj( i -> new DummyData("Data" + i, i) @@ -50,8 +52,10 @@ void testCopyManyCopiesSingle() @Test void testCopyAgainSameObject() { - try(final EclipseSerializerRegisteringCopier copier = - new EclipseSerializerRegisteringCopier(new WorkingCopyRegistry(), new SupportedChecker.Implementation())) + try(final RegisteringStorageToWorkingCopyCopier copier = + new RegisteringStorageToWorkingCopyCopier( + new WorkingCopyRegistry(), + new SupportedChecker.Implementation())) { final DummyData originalObject = new DummyData("Test", 1); @@ -65,8 +69,10 @@ void testCopyAgainSameObject() @Test void testCopyAgainTheCopy() { - try(final EclipseSerializerRegisteringCopier copier = - new EclipseSerializerRegisteringCopier(new WorkingCopyRegistry(), new SupportedChecker.Implementation())) + try(final RegisteringStorageToWorkingCopyCopier copier = + new RegisteringStorageToWorkingCopyCopier( + new WorkingCopyRegistry(), + new SupportedChecker.Implementation())) { final DummyData originalObject = new DummyData("Test", 1); @@ -82,8 +88,10 @@ void testCopyAgainTheCopy() @Test void testCopyManyCopiesBulk() { - try(final EclipseSerializerRegisteringCopier copier = - new EclipseSerializerRegisteringCopier(new WorkingCopyRegistry(), new SupportedChecker.Implementation())) + try(final RegisteringStorageToWorkingCopyCopier copier = + new RegisteringStorageToWorkingCopyCopier( + new WorkingCopyRegistry(), + new SupportedChecker.Implementation())) { final List originalObjects = IntStream.range(0, 100_000).mapToObj( i -> new DummyData("Data" + i, i) @@ -98,8 +106,10 @@ void testCopyManyCopiesBulk() @Test void testCopyEmpty() { - try(final EclipseSerializerRegisteringCopier copier = - new EclipseSerializerRegisteringCopier(new WorkingCopyRegistry(), new SupportedChecker.Implementation())) + try(final RegisteringStorageToWorkingCopyCopier copier = + new RegisteringStorageToWorkingCopyCopier( + new WorkingCopyRegistry(), + new SupportedChecker.Implementation())) { Assertions.assertThrows(NullPointerException.class, () -> copier.copy(null)); } From c095b80f9ef38416871add8d9ce0d3756f97aaf4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 11 Mar 2024 01:21:13 +0000 Subject: [PATCH 34/98] Bump org.apache.maven.plugins:maven-assembly-plugin from 3.6.0 to 3.7.0 Bumps [org.apache.maven.plugins:maven-assembly-plugin](https://github.com/apache/maven-assembly-plugin) from 3.6.0 to 3.7.0. - [Commits](https://github.com/apache/maven-assembly-plugin/compare/maven-assembly-plugin-3.6.0...maven-assembly-plugin-3.7.0) --- updated-dependencies: - dependency-name: org.apache.maven.plugins:maven-assembly-plugin dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- standard-maven-template-demo/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/standard-maven-template-demo/pom.xml b/standard-maven-template-demo/pom.xml index 2b80c696..6a7ffcb1 100644 --- a/standard-maven-template-demo/pom.xml +++ b/standard-maven-template-demo/pom.xml @@ -52,7 +52,7 @@ org.apache.maven.plugins maven-assembly-plugin - 3.6.0 + 3.7.0 From 0a08f049cbab2677d4a3da39e2886d19282b1d86 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 12 Mar 2024 00:35:14 +0000 Subject: [PATCH 35/98] Bump com.puppycrawl.tools:checkstyle from 10.14.0 to 10.14.1 Bumps [com.puppycrawl.tools:checkstyle](https://github.com/checkstyle/checkstyle) from 10.14.0 to 10.14.1. - [Release notes](https://github.com/checkstyle/checkstyle/releases) - [Commits](https://github.com/checkstyle/checkstyle/compare/checkstyle-10.14.0...checkstyle-10.14.1) --- updated-dependencies: - dependency-name: com.puppycrawl.tools:checkstyle dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- spring-data-eclipse-store-benchmark/pom.xml | 2 +- spring-data-eclipse-store-demo/pom.xml | 2 +- spring-data-eclipse-store-jpa/pom.xml | 2 +- spring-data-eclipse-store/pom.xml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/spring-data-eclipse-store-benchmark/pom.xml b/spring-data-eclipse-store-benchmark/pom.xml index e2f3612f..513e6e02 100644 --- a/spring-data-eclipse-store-benchmark/pom.xml +++ b/spring-data-eclipse-store-benchmark/pom.xml @@ -96,7 +96,7 @@ com.puppycrawl.tools checkstyle - 10.14.0 + 10.14.1 diff --git a/spring-data-eclipse-store-demo/pom.xml b/spring-data-eclipse-store-demo/pom.xml index 29d21bef..72ff96d7 100644 --- a/spring-data-eclipse-store-demo/pom.xml +++ b/spring-data-eclipse-store-demo/pom.xml @@ -103,7 +103,7 @@ com.puppycrawl.tools checkstyle - 10.14.0 + 10.14.1 diff --git a/spring-data-eclipse-store-jpa/pom.xml b/spring-data-eclipse-store-jpa/pom.xml index 8af9104d..89fef290 100644 --- a/spring-data-eclipse-store-jpa/pom.xml +++ b/spring-data-eclipse-store-jpa/pom.xml @@ -123,7 +123,7 @@ com.puppycrawl.tools checkstyle - 10.14.0 + 10.14.1 diff --git a/spring-data-eclipse-store/pom.xml b/spring-data-eclipse-store/pom.xml index 6e5cf6e6..186235a3 100644 --- a/spring-data-eclipse-store/pom.xml +++ b/spring-data-eclipse-store/pom.xml @@ -339,7 +339,7 @@ com.puppycrawl.tools checkstyle - 10.14.0 + 10.14.1 From 9dab1f11cf7d52d1265606c27b9472759443f9e9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 12 Mar 2024 00:35:17 +0000 Subject: [PATCH 36/98] Bump org.apache.maven.plugins:maven-gpg-plugin from 3.1.0 to 3.2.0 Bumps [org.apache.maven.plugins:maven-gpg-plugin](https://github.com/apache/maven-gpg-plugin) from 3.1.0 to 3.2.0. - [Release notes](https://github.com/apache/maven-gpg-plugin/releases) - [Commits](https://github.com/apache/maven-gpg-plugin/compare/maven-gpg-plugin-3.1.0...maven-gpg-plugin-3.2.0) --- updated-dependencies: - dependency-name: org.apache.maven.plugins:maven-gpg-plugin dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- spring-data-eclipse-store/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spring-data-eclipse-store/pom.xml b/spring-data-eclipse-store/pom.xml index 6e5cf6e6..13476af9 100644 --- a/spring-data-eclipse-store/pom.xml +++ b/spring-data-eclipse-store/pom.xml @@ -291,7 +291,7 @@ org.apache.maven.plugins maven-gpg-plugin - 3.1.0 + 3.2.0 sign-artifacts From 822b62cbbae7bdf65b4bb7b3c40c58a036e87f4f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 12 Mar 2024 00:36:26 +0000 Subject: [PATCH 37/98] Bump com.puppycrawl.tools:checkstyle from 10.14.0 to 10.14.1 Bumps [com.puppycrawl.tools:checkstyle](https://github.com/checkstyle/checkstyle) from 10.14.0 to 10.14.1. - [Release notes](https://github.com/checkstyle/checkstyle/releases) - [Commits](https://github.com/checkstyle/checkstyle/compare/checkstyle-10.14.0...checkstyle-10.14.1) --- updated-dependencies: - dependency-name: com.puppycrawl.tools:checkstyle dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- standard-maven-template-demo/pom.xml | 2 +- standard-maven-template/pom.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/standard-maven-template-demo/pom.xml b/standard-maven-template-demo/pom.xml index 2b80c696..9621682a 100644 --- a/standard-maven-template-demo/pom.xml +++ b/standard-maven-template-demo/pom.xml @@ -92,7 +92,7 @@ com.puppycrawl.tools checkstyle - 10.14.0 + 10.14.1 diff --git a/standard-maven-template/pom.xml b/standard-maven-template/pom.xml index b8a7cc2f..c043d0de 100644 --- a/standard-maven-template/pom.xml +++ b/standard-maven-template/pom.xml @@ -216,7 +216,7 @@ com.puppycrawl.tools checkstyle - 10.14.0 + 10.14.1 From 765ada2af6bda80843e2541426134d7b65d342c4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 12 Mar 2024 00:36:30 +0000 Subject: [PATCH 38/98] Bump org.apache.maven.plugins:maven-gpg-plugin from 3.1.0 to 3.2.0 Bumps [org.apache.maven.plugins:maven-gpg-plugin](https://github.com/apache/maven-gpg-plugin) from 3.1.0 to 3.2.0. - [Release notes](https://github.com/apache/maven-gpg-plugin/releases) - [Commits](https://github.com/apache/maven-gpg-plugin/compare/maven-gpg-plugin-3.1.0...maven-gpg-plugin-3.2.0) --- updated-dependencies: - dependency-name: org.apache.maven.plugins:maven-gpg-plugin dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- standard-maven-template/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/standard-maven-template/pom.xml b/standard-maven-template/pom.xml index b8a7cc2f..aea39f74 100644 --- a/standard-maven-template/pom.xml +++ b/standard-maven-template/pom.xml @@ -168,7 +168,7 @@ org.apache.maven.plugins maven-gpg-plugin - 3.1.0 + 3.2.0 sign-artifacts From 35beb2918dd0f41e954495782f6d5f4cc6e788fd Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 12 Mar 2024 09:13:06 +0100 Subject: [PATCH 39/98] Lazy storing working for simplest test --- .../BinaryHandlerOnlyForCopyingException.java | 11 ++ .../importer/EclipseStoreDataImporter.java | 7 +- .../store/repository/EclipseStoreStorage.java | 10 +- .../repository/lazy/LazyProxyGenerator.java | 14 +- .../lazy/SpringDataEclipseStoreLazy.java | 129 +++++++++++++ ...ringDataEclipseStoreLazyBinaryHandler.java | 117 ++++++++++++ .../lazy/SuperLazyBinaryHandler.java | 169 ------------------ .../EclipseStoreRepositoryFactory.java | 3 +- .../support/copier/DataTypeUtil.java | 6 +- .../copier/AbstractRegisteringCopier.java | 8 +- .../copier/PersistenceManagerProvider.java | 12 ++ ...RegisteringStorageToWorkingCopyCopier.java | 19 +- ...RegisteringWorkingCopyToStorageCopier.java | 17 +- .../working/RecursiveWorkingCopier.java | 92 ++++------ .../tests/special/types/TypesData.java | 8 +- ...steringStorageToWorkingCopyCopierTest.java | 15 +- 16 files changed, 370 insertions(+), 267 deletions(-) create mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/BinaryHandlerOnlyForCopyingException.java create mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java create mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java delete mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SuperLazyBinaryHandler.java create mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/PersistenceManagerProvider.java diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/BinaryHandlerOnlyForCopyingException.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/BinaryHandlerOnlyForCopyingException.java new file mode 100644 index 00000000..96ab9ca3 --- /dev/null +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/BinaryHandlerOnlyForCopyingException.java @@ -0,0 +1,11 @@ +package software.xdev.spring.data.eclipse.store.exceptions; + +public class BinaryHandlerOnlyForCopyingException extends RuntimeException +{ + public BinaryHandlerOnlyForCopyingException() + { + super( + "This handler should only be used for copying objects one time. It shouldn't be used for anything else, " + + "yet it looks like you are using it for something else."); + } +} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporter.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporter.java index 18adb2d0..b21fc73c 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporter.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporter.java @@ -205,8 +205,11 @@ private void createRepositoryForType( storageInstance.getRegistry(), storageInstance, storageInstance, - new SupportedChecker.Implementation()), - domainClass); + new SupportedChecker.Implementation(), + storageInstance + ), + domainClass + ); } private record EntityManagerFactoryRepositoryListPair( diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java index 32800225..07b06e8a 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java @@ -26,6 +26,7 @@ import org.eclipse.serializer.persistence.binary.jdk17.java.util.BinaryHandlerImmutableCollectionsList12; import org.eclipse.serializer.persistence.binary.jdk17.java.util.BinaryHandlerImmutableCollectionsSet12; import org.eclipse.serializer.persistence.types.Storer; +import org.eclipse.serializer.reference.ObjectSwizzling; import org.eclipse.store.storage.embedded.types.EmbeddedStorageFoundation; import org.eclipse.store.storage.types.StorageManager; import org.slf4j.Logger; @@ -40,7 +41,7 @@ import software.xdev.spring.data.eclipse.store.repository.support.reposyncer.SimpleRepositorySynchronizer; public class EclipseStoreStorage - implements EntityListProvider, IdSetterProvider, PersistableChecker + implements EntityListProvider, IdSetterProvider, PersistableChecker, ObjectSwizzling { private static final Logger LOG = LoggerFactory.getLogger(EclipseStoreStorage.class); private final Map, String> entityClassToRepositoryName = new HashMap<>(); @@ -311,4 +312,11 @@ public boolean isPersistable(final Class clazz) this.ensureEntitiesInRoot(); return this.persistenceChecker.isPersistable(clazz); } + + @Override + public Object getObject(final long objectId) + { + this.ensureEntitiesInRoot(); + return this.storageManager.getObject(objectId); + } } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyProxyGenerator.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyProxyGenerator.java index b9d0b36b..f9650a98 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyProxyGenerator.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyProxyGenerator.java @@ -10,19 +10,9 @@ private LazyProxyGenerator() { } - public static , T> L generateLazyProxy(final L lazy, final Class clazz) - { - final ProxyFactory f = new ProxyFactory(clazz, new LazyInterceptor<>(lazy)); - return (L)f.getProxy(); - } - public static Lazy generateLazyProxy(final Lazy lazy) { - return generateLazyProxy(lazy, Lazy.class); - } - - public static Lazy.Default generateLazyDefaultProxy(final Lazy.Default lazy) - { - return generateLazyProxy(lazy, Lazy.Default.class); + final ProxyFactory f = new ProxyFactory(Lazy.class, new LazyInterceptor<>(lazy)); + return (Lazy)f.getProxy(); } } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java new file mode 100644 index 00000000..cf9c2487 --- /dev/null +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java @@ -0,0 +1,129 @@ +package software.xdev.spring.data.eclipse.store.repository.lazy; + +import java.util.Objects; + +import org.eclipse.serializer.reference.Lazy; +import org.eclipse.serializer.reference.ObjectSwizzling; + + +public interface SpringDataEclipseStoreLazy extends Lazy +{ + static SpringDataEclipseStoreLazy.Default build(final T objectToWrapInLazy) + { + return new Default<>(objectToWrapInLazy); + } + + static SpringDataEclipseStoreLazy.Default buildFromStorage(final long objectId, final ObjectSwizzling loader) + { + return new Default<>(objectId, loader); + } + + static SpringDataEclipseStoreLazy.Default buildOnlyForStorage(final long objectId) + { + return new Default<>(objectId); + } + + long objectId(); + + class Default implements SpringDataEclipseStoreLazy + { + private Lazy wrappedLazy; + private long objectId; + private ObjectSwizzling loader; + + private Default(final T wrappedObject) + { + this.wrappedLazy = Lazy.Reference(wrappedObject); + } + + private Default(final long objectId, final ObjectSwizzling loader) + { + this.objectId = objectId; + this.loader = loader; + } + + private Default(final long objectId) + { + this.objectId = objectId; + } + + private Lazy ensureLazy() + { + if(this.wrappedLazy == null) + { + Objects.requireNonNull(this.loader); + Objects.requireNonNull(this.objectId); + this.wrappedLazy = Lazy.Reference((T)this.loader.getObject(this.objectId)); + } + return this.wrappedLazy; + } + + @SuppressWarnings("all") + public static final Class> genericType() + { + // no idea how to get ".class" to work otherwise in conjunction with generics. + return (Class)SpringDataEclipseStoreLazy.Default.class; + } + + @Override + public T get() + { + return this.ensureLazy().get(); + } + + @Override + public T peek() + { + return this.ensureLazy().peek(); + } + + @Override + public T clear() + { + this.wrappedLazy = null; + return null; + } + + @Override + public boolean isStored() + { + return this.ensureLazy().isStored(); + } + + @Override + public boolean isLoaded() + { + if(this.wrappedLazy == null) + { + return false; + } + return this.ensureLazy().isLoaded(); + } + + @Override + public long lastTouched() + { + return this.ensureLazy().lastTouched(); + } + + @Override + public boolean clear(final ClearingEvaluator clearingEvaluator) + { + if(this.wrappedLazy != null) + { + return this.wrappedLazy.clear(clearingEvaluator); + } + return true; + } + + @Override + public long objectId() + { + if(this.wrappedLazy != null && this.wrappedLazy instanceof Lazy.Default) + { + return ((Lazy.Default)this.wrappedLazy).objectId(); + } + return this.objectId; + } + } +} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java new file mode 100644 index 00000000..fc04264a --- /dev/null +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java @@ -0,0 +1,117 @@ +package software.xdev.spring.data.eclipse.store.repository.lazy; + +import java.lang.reflect.Constructor; +import java.util.Objects; + +import org.eclipse.serializer.persistence.binary.types.AbstractBinaryHandlerCustom; +import org.eclipse.serializer.persistence.binary.types.Binary; +import org.eclipse.serializer.persistence.types.PersistenceLoadHandler; +import org.eclipse.serializer.persistence.types.PersistenceReferenceLoader; +import org.eclipse.serializer.persistence.types.PersistenceStoreHandler; +import org.eclipse.serializer.reference.Lazy; +import org.eclipse.serializer.reference.ObjectSwizzling; +import org.eclipse.serializer.reflect.XReflect; + +import software.xdev.spring.data.eclipse.store.exceptions.BinaryHandlerOnlyForCopyingException; + + +/** + * Copied from + * {@link org.eclipse.serializer.persistence.binary.org.eclipse.serializer.reference.BinaryHandlerLazyDefault}. + */ +public final class SpringDataEclipseStoreLazyBinaryHandler + extends AbstractBinaryHandlerCustom> +{ + @SuppressWarnings("rawtypes") + static final Constructor CONSTRUCTOR = XReflect.setAccessible( + XReflect.getDeclaredConstructor( + SpringDataEclipseStoreLazy.Default.class, + long.class, + ObjectSwizzling.class + ) + ); + + private final ObjectSwizzling objectSwizzling; + + public SpringDataEclipseStoreLazyBinaryHandler(final ObjectSwizzling objectSwizzling) + { + super( + SpringDataEclipseStoreLazy.Default.genericType(), + CustomFields( + CustomField(Object.class, "subject") + ) + ); + this.objectSwizzling = Objects.requireNonNull(objectSwizzling); + } + + @Override + public final void store( + final Binary data, + final SpringDataEclipseStoreLazy.Default instance, + final long objectId, + final PersistenceStoreHandler handler + ) + { + final long referenceOid = instance.objectId(); + data.storeEntityHeader(Binary.referenceBinaryLength(1), this.typeId(), objectId); + data.store_long(referenceOid); + } + + @SuppressWarnings("unchecked") + @Override + public final SpringDataEclipseStoreLazy.Default create(final Binary data, final PersistenceLoadHandler handler) + { + final long objectId = data.read_long(0); + + return Lazy.register( + XReflect.invoke(CONSTRUCTOR, objectId, this.objectSwizzling) + ); + } + + @Override + public final void updateState( + final Binary data, + final SpringDataEclipseStoreLazy.Default instance, + final PersistenceLoadHandler handler + ) + { + throw new BinaryHandlerOnlyForCopyingException(); + } + + @Override + public final void complete( + final Binary data, + final SpringDataEclipseStoreLazy.Default instance, + final PersistenceLoadHandler handler + ) + { + // no-op for normal implementation (see non-reference-hashing collections for other examples) + } + + @Override + public final boolean hasPersistedReferences() + { + return true; + } + + @Override + public final boolean hasPersistedVariableLength() + { + return false; + } + + @Override + public final boolean hasVaryingPersistedLengthInstances() + { + return false; + } + + @Override + public final void iterateLoadableReferences( + final Binary offset, + final PersistenceReferenceLoader iterator + ) + { + // the lazy reference is not naturally loadable, but special-handled by this handler + } +} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SuperLazyBinaryHandler.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SuperLazyBinaryHandler.java deleted file mode 100644 index 2577588c..00000000 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SuperLazyBinaryHandler.java +++ /dev/null @@ -1,169 +0,0 @@ -package software.xdev.spring.data.eclipse.store.repository.lazy; - -import java.lang.reflect.Constructor; - -import org.eclipse.serializer.persistence.binary.types.AbstractBinaryHandlerCustom; -import org.eclipse.serializer.persistence.binary.types.Binary; -import org.eclipse.serializer.persistence.types.PersistenceLoadHandler; -import org.eclipse.serializer.persistence.types.PersistenceReferenceLoader; -import org.eclipse.serializer.persistence.types.PersistenceStoreHandler; -import org.eclipse.serializer.reference.Lazy; -import org.eclipse.serializer.reference.ObjectSwizzling; -import org.eclipse.serializer.reflect.XReflect; - - -/** - * Copied from - * {@link org.eclipse.serializer.persistence.binary.org.eclipse.serializer.reference.BinaryHandlerLazyDefault}. - */ -public class SuperLazyBinaryHandler extends AbstractBinaryHandlerCustom> -{ - /////////////////////////////////////////////////////////////////////////// - // static methods // - /////////////////// - - public static SuperLazyBinaryHandler New() - { - return new SuperLazyBinaryHandler(); - } - - @SuppressWarnings("rawtypes") - static final Constructor CONSTRUCTOR = XReflect.setAccessible( - XReflect.getDeclaredConstructor(Lazy.Default.class, Object.class, long.class, ObjectSwizzling.class) - ); - - /////////////////////////////////////////////////////////////////////////// - // constructors // - ///////////////// - - private SuperLazyBinaryHandler() - { - super( - Lazy.Default.genericType(), - CustomFields( - CustomField(Object.class, "subject") - ) - ); - } - - /////////////////////////////////////////////////////////////////////////// - // methods // - //////////// - - @Override - public final void store( - final Binary data, - final Lazy.Default instance, - final long objectId, - final PersistenceStoreHandler handler - ) - { - /* (29.09.2015 TM)NOTE: There are several cases that have to be handled here correctly: - * - * 1) objectId == 0, referent == null - * "Empty" lazy reference that must be stored as such - * - * 2.) objectId == 0, referent != null - * Newly created lazy reference with a referent. The referent has to be handled and the lazy reference has - * to be stored with the referent's OID - * - * 3.) objectId != null, referent == null - * The lazy reference represents a non-null referent that is currently simply not loaded. The lazy reference - * must be stored nonetheless, pointing to its known referent objectId - * - * 4.) objectId != null, referent != null - * The lazy reference represents a non-null referent that is currently loaded. The refernt must be handled, - * the lazy reference must be stored, pointing to its known referent objectId. - */ - - final Object referent = instance.peek(); - final long referenceOid; - - if(referent == null) - { - referenceOid = instance.objectId(); - } - else - { - // OID validation or updating is done by linking logic - referenceOid = handler.apply(referent); - } - - // link to object supplier (internal logic can either update, discard or throw exception on mismatch) - // instance.$link(referenceOid, handler.getObjectRetriever()); - - // lazy reference instance must be stored in any case - data.storeEntityHeader(Binary.referenceBinaryLength(1), this.typeId(), objectId); - data.store_long(referenceOid); - } - - @SuppressWarnings("unchecked") - @Override - public final Lazy.Default create(final Binary data, final PersistenceLoadHandler handler) - { - /* (27.04.2016 TM)NOTE: registering a Lazy instance with a reference manager - * without having the object supplier set yet might cause an inconsistency if the - * LRM iterates lazy references before the update added the supplier reference. - * ON the other hand: the lazy reference instance is not yet completed and whatever - * logic iterates over the LRM's entries shouldn't rely on anything. - */ - final long objectId = data.read_long(0); - - final Lazy.Default newLazy = Lazy.register( - XReflect.invoke(CONSTRUCTOR, null, objectId, null) - ); - return LazyProxyGenerator.generateLazyProxy(newLazy); - } - - @Override - public final void updateState( - final Binary data, - final Lazy.Default instance, - final PersistenceLoadHandler handler - ) - { - /* - * Intentionally no subject lookup here as premature strong referencing - * might defeat the purpose of memory freeing lazy referencing if no - * other strong reference to the subject is present at the moment. - */ - instance.$setLoader(handler.getObjectRetriever()); - } - - @Override - public final void complete( - final Binary data, - final Lazy.Default instance, - final PersistenceLoadHandler handler - ) - { - // no-op for normal implementation (see non-reference-hashing collections for other examples) - } - - @Override - public final boolean hasPersistedReferences() - { - return true; - } - - @Override - public final boolean hasPersistedVariableLength() - { - return false; - } - - @Override - public final boolean hasVaryingPersistedLengthInstances() - { - return false; - } - - @Override - public final void iterateLoadableReferences( - final Binary offset, - final PersistenceReferenceLoader iterator - ) - { - // the lazy reference is not naturally loadable, but special-handled by this handler - } -} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreRepositoryFactory.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreRepositoryFactory.java index 2f42894f..970a1ea2 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreRepositoryFactory.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreRepositoryFactory.java @@ -86,7 +86,8 @@ private WorkingCopier createWorkingCopier( storage.getRegistry(), storage, storage, - new SupportedChecker.Implementation() + new SupportedChecker.Implementation(), + storage ); } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/DataTypeUtil.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/DataTypeUtil.java index 254fa092..1c56d322 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/DataTypeUtil.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/DataTypeUtil.java @@ -20,7 +20,7 @@ import jakarta.annotation.Nonnull; -import org.eclipse.serializer.reference.Lazy; +import software.xdev.spring.data.eclipse.store.repository.lazy.SpringDataEclipseStoreLazy; public final class DataTypeUtil @@ -47,9 +47,9 @@ public static boolean isObjectArray(final Object obj) return obj instanceof Object[]; } - public static boolean isLazy(final Object obj) + public static boolean isSpringDataEclipseStoreLazy(final Object obj) { - return obj instanceof Lazy; + return obj instanceof SpringDataEclipseStoreLazy; } public static boolean isPrimitiveArray(final Object obj) diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java index 219a1cc0..79acb4c7 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java @@ -20,7 +20,6 @@ import org.eclipse.serializer.persistence.binary.jdk17.java.util.BinaryHandlerImmutableCollectionsList12; import org.eclipse.serializer.persistence.binary.jdk17.java.util.BinaryHandlerImmutableCollectionsSet12; import org.eclipse.serializer.persistence.binary.types.Binary; -import org.eclipse.serializer.persistence.types.PersistenceManager; import org.eclipse.serializer.reference.Reference; import org.eclipse.serializer.util.X; @@ -37,17 +36,16 @@ public abstract class AbstractRegisteringCopier implements RegisteringObjectCopi public AbstractRegisteringCopier( final SupportedChecker supportedChecker, - final RegisteringWorkingCopyAndOriginal register) + final RegisteringWorkingCopyAndOriginal register, + final PersistenceManagerProvider persistenceManagerProvider) { this.actualCopier = new EclipseSerializerRegisteringCopier( supportedChecker, register, - this.createPersistenceManager() + persistenceManagerProvider.createPersistenceManager(this.createSerializerFoundation()) ); } - protected abstract PersistenceManager createPersistenceManager(); - protected SerializerFoundation createSerializerFoundation() { final SerializerFoundation newFoundation = SerializerFoundation.New(); diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/PersistenceManagerProvider.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/PersistenceManagerProvider.java new file mode 100644 index 00000000..3728da3c --- /dev/null +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/PersistenceManagerProvider.java @@ -0,0 +1,12 @@ +package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; + +import org.eclipse.serializer.SerializerFoundation; +import org.eclipse.serializer.persistence.binary.types.Binary; +import org.eclipse.serializer.persistence.types.PersistenceManager; + + +@FunctionalInterface +public interface PersistenceManagerProvider +{ + PersistenceManager createPersistenceManager(SerializerFoundation serializerFoundation); +} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java index 283b7b04..78bc13e1 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java @@ -15,12 +15,14 @@ */ package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; +import org.eclipse.serializer.SerializerFoundation; import org.eclipse.serializer.persistence.binary.types.Binary; import org.eclipse.serializer.persistence.types.PersistenceManager; +import org.eclipse.serializer.reference.ObjectSwizzling; import software.xdev.spring.data.eclipse.store.repository.SupportedChecker; import software.xdev.spring.data.eclipse.store.repository.WorkingCopyRegistry; -import software.xdev.spring.data.eclipse.store.repository.lazy.SuperLazyBinaryHandler; +import software.xdev.spring.data.eclipse.store.repository.lazy.SpringDataEclipseStoreLazyBinaryHandler; /** @@ -31,19 +33,22 @@ public class RegisteringStorageToWorkingCopyCopier extends AbstractRegisteringCo { public RegisteringStorageToWorkingCopyCopier( final WorkingCopyRegistry registry, - final SupportedChecker supportedChecker) + final SupportedChecker supportedChecker, + final ObjectSwizzling objectSwizzling) { super( supportedChecker, - (workingCopy, objectToStore) -> registry.register(workingCopy, objectToStore) + (workingCopy, objectToStore) -> registry.register(workingCopy, objectToStore), + (serializerFoundation) -> createPersistenceManager(serializerFoundation, objectSwizzling) ); } - @Override - protected PersistenceManager createPersistenceManager() + private static PersistenceManager createPersistenceManager( + final SerializerFoundation serializerFoundation, + final ObjectSwizzling objectSwizzling) { - return this.createSerializerFoundation() - .registerCustomTypeHandlers(SuperLazyBinaryHandler.New()) + return serializerFoundation + .registerCustomTypeHandlers(new SpringDataEclipseStoreLazyBinaryHandler(objectSwizzling)) .createPersistenceManager(); } } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java index 39708b45..428c2a81 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java @@ -15,11 +15,14 @@ */ package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; +import org.eclipse.serializer.SerializerFoundation; import org.eclipse.serializer.persistence.binary.types.Binary; import org.eclipse.serializer.persistence.types.PersistenceManager; +import org.eclipse.serializer.reference.ObjectSwizzling; import software.xdev.spring.data.eclipse.store.repository.SupportedChecker; import software.xdev.spring.data.eclipse.store.repository.WorkingCopyRegistry; +import software.xdev.spring.data.eclipse.store.repository.lazy.SpringDataEclipseStoreLazyBinaryHandler; /** @@ -31,18 +34,22 @@ public class RegisteringWorkingCopyToStorageCopier extends AbstractRegisteringCo public RegisteringWorkingCopyToStorageCopier( final WorkingCopyRegistry registry, - final SupportedChecker supportedChecker) + final SupportedChecker supportedChecker, + final ObjectSwizzling objectSwizzling) { super( supportedChecker, - (workingCopy, objectToStore) -> registry.invertRegister(workingCopy, objectToStore) + (workingCopy, objectToStore) -> registry.invertRegister(workingCopy, objectToStore), + (serializerFoundation) -> createPersistenceManager(serializerFoundation, objectSwizzling) ); } - @Override - protected PersistenceManager createPersistenceManager() + private static PersistenceManager createPersistenceManager( + final SerializerFoundation serializerFoundation, + final ObjectSwizzling objectSwizzling) { - return this.createSerializerFoundation() + return serializerFoundation + .registerCustomTypeHandlers(new SpringDataEclipseStoreLazyBinaryHandler(objectSwizzling)) .createPersistenceManager(); } } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java index 76906a2e..49be55e8 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java @@ -27,7 +27,7 @@ import java.util.TreeMap; import java.util.TreeSet; -import org.eclipse.serializer.reference.Lazy; +import org.eclipse.serializer.reference.ObjectSwizzling; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -38,7 +38,7 @@ import software.xdev.spring.data.eclipse.store.repository.WorkingCopyRegistry; import software.xdev.spring.data.eclipse.store.repository.access.AccessHelper; import software.xdev.spring.data.eclipse.store.repository.access.modifier.FieldAccessModifier; -import software.xdev.spring.data.eclipse.store.repository.lazy.LazyProxyGenerator; +import software.xdev.spring.data.eclipse.store.repository.lazy.SpringDataEclipseStoreLazy; import software.xdev.spring.data.eclipse.store.repository.support.copier.DataTypeUtil; import software.xdev.spring.data.eclipse.store.repository.support.copier.copier.RegisteringObjectCopier; import software.xdev.spring.data.eclipse.store.repository.support.copier.copier.RegisteringStorageToWorkingCopyCopier; @@ -50,11 +50,6 @@ */ public class RecursiveWorkingCopier implements WorkingCopier { - public enum MergingDirection - { - STORAGE_TO_WORKING_COPY, - WORKING_COPY_TO_STORAGE - } private static final Logger LOG = LoggerFactory.getLogger(RecursiveWorkingCopier.class); private final RegisteringObjectCopier workingCopyToStorageCopier; private final RegisteringObjectCopier storageToWorkingCopyCopier; @@ -68,12 +63,15 @@ public RecursiveWorkingCopier( final WorkingCopyRegistry registry, final IdSetterProvider idSetterProvider, final PersistableChecker persistableChecker, - final SupportedChecker supportedChecker) + final SupportedChecker supportedChecker, + final ObjectSwizzling objectSwizzling) { this.domainClass = domainClass; this.registry = registry; - this.workingCopyToStorageCopier = new RegisteringWorkingCopyToStorageCopier(registry, supportedChecker); - this.storageToWorkingCopyCopier = new RegisteringStorageToWorkingCopyCopier(registry, supportedChecker); + this.workingCopyToStorageCopier = + new RegisteringWorkingCopyToStorageCopier(registry, supportedChecker, objectSwizzling); + this.storageToWorkingCopyCopier = + new RegisteringStorageToWorkingCopyCopier(registry, supportedChecker, objectSwizzling); this.idSetterProvider = idSetterProvider; this.persistableChecker = persistableChecker; } @@ -120,8 +118,7 @@ public WorkingCopierResult mergeBack(final T workingCopy) workingCopy, true, new HashSetMergedTargetsCollector(), - changedObjectCollector, - MergingDirection.WORKING_COPY_TO_STORAGE); + changedObjectCollector); if(LOG.isTraceEnabled()) { LOG.trace("Merging back the working copy object of class {}", workingCopy.getClass().getSimpleName()); @@ -134,8 +131,7 @@ public E getOrCreateObjectForDatastore( final E workingCopy, final boolean mergeValues, final MergedTargetsCollector alreadyMergedTargets, - final ChangedObjectCollector changedCollector, - final MergingDirection mergingDirection) + final ChangedObjectCollector changedCollector) { if(workingCopy == null) { @@ -147,8 +143,7 @@ public E getOrCreateObjectForDatastore( { if(mergeValues) { - this.mergeValues(workingCopy, originalObject, alreadyMergedTargets, changedCollector, - mergingDirection); + this.mergeValues(workingCopy, originalObject, alreadyMergedTargets, changedCollector); } changedCollector.collectChangedObject(originalObject); return originalObject; @@ -159,7 +154,7 @@ public E getOrCreateObjectForDatastore( final E objectForDatastore = this.genericCopy(workingCopy, true); // "Why merging values of an identical object?" you might ask. // Well, because some sub-objects might already be in the datastore. - this.mergeValues(workingCopy, objectForDatastore, alreadyMergedTargets, changedCollector, mergingDirection); + this.mergeValues(workingCopy, objectForDatastore, alreadyMergedTargets, changedCollector); changedCollector.collectChangedObject(objectForDatastore); return objectForDatastore; } @@ -174,8 +169,7 @@ private void mergeValues( final E sourceObject, final E targetObject, final MergedTargetsCollector alreadyMergedTargets, - final ChangedObjectCollector changedCollector, - final MergingDirection mergingDirection + final ChangedObjectCollector changedCollector ) { if(sourceObject == targetObject || alreadyMergedTargets.isAlreadyMerged(targetObject) || targetObject == null) @@ -199,8 +193,7 @@ private void mergeValues( targetObject, field, alreadyMergedTargets, - changedCollector, - mergingDirection) + changedCollector) ); } catch(final Exception e) @@ -214,8 +207,7 @@ private void mergeValueOfField( final E targetObject, final Field field, final MergedTargetsCollector alreadyMergedTargets, - final ChangedObjectCollector changedCollector, - final MergingDirection mergingDirection) + final ChangedObjectCollector changedCollector) { try { @@ -261,14 +253,17 @@ else if(DataTypeUtil.isObjectArray(valueOfSourceObject)) valueOfSourceObject.getClass().getComponentType(), (Object[])valueOfSourceObject, alreadyMergedTargets, - changedCollector, - mergingDirection + changedCollector ); fam.writeValueOfField(targetObject, newArray, !targetObjectIsPartOfJavaPackage); } - else if(DataTypeUtil.isLazy(valueOfSourceObject)) + else if(DataTypeUtil.isSpringDataEclipseStoreLazy(valueOfSourceObject)) { - final Lazy newLazy = this.createNewLazy((Lazy)valueOfSourceObject, mergingDirection); + final SpringDataEclipseStoreLazy newLazy = + this.createNewLazy( + (SpringDataEclipseStoreLazy)valueOfSourceObject, + alreadyMergedTargets, + changedCollector); fam.writeValueOfField(targetObject, newLazy, true); } else @@ -280,8 +275,7 @@ else if(DataTypeUtil.isLazy(valueOfSourceObject)) valueOfSourceObject, false, alreadyMergedTargets, - changedCollector, - mergingDirection); + changedCollector); if(valueOfTargetObject != originalValueObjectOfSource) { // If the reference is new, it must be set @@ -305,8 +299,7 @@ else if(DataTypeUtil.isLazy(valueOfSourceObject)) valueOfSourceObject, originalValueObjectOfSource, alreadyMergedTargets, - changedCollector, - mergingDirection); + changedCollector); } } } @@ -318,32 +311,27 @@ else if(DataTypeUtil.isLazy(valueOfSourceObject)) } } - private Lazy createNewLazy( - final Lazy valueOfSourceObject, - final MergingDirection mergingDirection + private SpringDataEclipseStoreLazy createNewLazy( + final SpringDataEclipseStoreLazy oldLazy, + final MergedTargetsCollector alreadyMergedTargets, + final ChangedObjectCollector changedCollector ) { - final Lazy oldLazy = valueOfSourceObject; - final Lazy newLazy; - if(mergingDirection.equals(MergingDirection.STORAGE_TO_WORKING_COPY)) - { - // If this object is generated for a working copy we need a proxy that only loads the actual - // stored lazy if needed and not before. - newLazy = LazyProxyGenerator.generateLazyProxy(oldLazy); - } - else - { - // TODO if(oldLazy.isLoaded()) { - newLazy = Lazy.Reference(oldLazy.get()); + final E copyOfWrappedObject = this.getOrCreateObjectForDatastore( + oldLazy.get(), + true, + alreadyMergedTargets, + changedCollector); + return SpringDataEclipseStoreLazy.build(copyOfWrappedObject); } else { - throw new RuntimeException(""); + // This lazy should never be used again! + // It is though of as a temporary copy to merge back into the original-storage-data. + return (SpringDataEclipseStoreLazy)SpringDataEclipseStoreLazy.buildOnlyForStorage(oldLazy.objectId()); } - } - return newLazy; } /** @@ -369,8 +357,7 @@ private E[] createGenericObjectArray( final Class clazz, final Object[] valueOfSourceObjectArray, final MergedTargetsCollector alreadyMergedTargets, - final ChangedObjectCollector changedCollector, - final MergingDirection mergingDirection) + final ChangedObjectCollector changedCollector) { // Create new Array with original objects with merged data final E[] newArray = (E[])Array.newInstance(clazz, valueOfSourceObjectArray.length); @@ -380,8 +367,7 @@ private E[] createGenericObjectArray( (E)valueOfSourceObjectArray[i], true, alreadyMergedTargets, - changedCollector, - mergingDirection); + changedCollector); } return newArray; } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java index b4968828..6c3bed83 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java @@ -47,10 +47,10 @@ import org.eclipse.serializer.collections.lazy.LazyArrayList; import org.eclipse.serializer.collections.lazy.LazyHashMap; import org.eclipse.serializer.collections.lazy.LazyHashSet; -import org.eclipse.serializer.reference.Lazy; import org.junit.jupiter.params.provider.Arguments; import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreRepository; +import software.xdev.spring.data.eclipse.store.repository.lazy.SpringDataEclipseStoreLazy; final class TypesData @@ -436,12 +436,12 @@ public static Stream generateData() ), new TestArguments<>( LazyRepository.class, - id -> new LazyDaoObject(id, Lazy.Reference("1")), - object -> object.setValue(Lazy.Reference("2")) + id -> new LazyDaoObject(id, SpringDataEclipseStoreLazy.build("1")), + object -> object.setValue(SpringDataEclipseStoreLazy.build("2")) ), new TestArguments<>( LazyRepository.class, - id -> new LazyDaoObject(id, Lazy.Reference("1")), + id -> new LazyDaoObject(id, SpringDataEclipseStoreLazy.build("1")), object -> object.getValue().clear() ), new TestArguments<>( diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopierTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopierTest.java index f870a9b4..a7f44591 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopierTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopierTest.java @@ -37,7 +37,8 @@ void testCopyManyCopiesSingle() try(final RegisteringStorageToWorkingCopyCopier copier = new RegisteringStorageToWorkingCopyCopier( new WorkingCopyRegistry(), - new SupportedChecker.Implementation())) + new SupportedChecker.Implementation(), + o -> null)) { final List originalObjects = IntStream.range(0, 1_000).mapToObj( i -> new DummyData("Data" + i, i) @@ -55,7 +56,8 @@ void testCopyAgainSameObject() try(final RegisteringStorageToWorkingCopyCopier copier = new RegisteringStorageToWorkingCopyCopier( new WorkingCopyRegistry(), - new SupportedChecker.Implementation())) + new SupportedChecker.Implementation(), + o -> null)) { final DummyData originalObject = new DummyData("Test", 1); @@ -72,7 +74,8 @@ void testCopyAgainTheCopy() try(final RegisteringStorageToWorkingCopyCopier copier = new RegisteringStorageToWorkingCopyCopier( new WorkingCopyRegistry(), - new SupportedChecker.Implementation())) + new SupportedChecker.Implementation(), + o -> null)) { final DummyData originalObject = new DummyData("Test", 1); @@ -91,7 +94,8 @@ void testCopyManyCopiesBulk() try(final RegisteringStorageToWorkingCopyCopier copier = new RegisteringStorageToWorkingCopyCopier( new WorkingCopyRegistry(), - new SupportedChecker.Implementation())) + new SupportedChecker.Implementation(), + o -> null)) { final List originalObjects = IntStream.range(0, 100_000).mapToObj( i -> new DummyData("Data" + i, i) @@ -109,7 +113,8 @@ void testCopyEmpty() try(final RegisteringStorageToWorkingCopyCopier copier = new RegisteringStorageToWorkingCopyCopier( new WorkingCopyRegistry(), - new SupportedChecker.Implementation())) + new SupportedChecker.Implementation(), + o -> null)) { Assertions.assertThrows(NullPointerException.class, () -> copier.copy(null)); } From d566f307d50b5ea81404b09d4f0d61209326aa81 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 12 Mar 2024 09:15:20 +0100 Subject: [PATCH 40/98] Adjustments in docs for new url --- docs/antora-playbook.yml | 2 +- docs/modules/ROOT/pages/index.adoc | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/antora-playbook.yml b/docs/antora-playbook.yml index 1c388c23..15845af5 100644 --- a/docs/antora-playbook.yml +++ b/docs/antora-playbook.yml @@ -1,6 +1,6 @@ site: title: Spring-Data-Eclipse-Store - url: https://xdev-software.github.io/spring-data-eclipse-store/ + url: https://spring-eclipsestore.xdev.software/ robots: allow # see https://docs.antora.org/antora/2.3/playbook/configure-runtime/ diff --git a/docs/modules/ROOT/pages/index.adoc b/docs/modules/ROOT/pages/index.adoc index 58fc8243..dcab5756 100644 --- a/docs/modules/ROOT/pages/index.adoc +++ b/docs/modules/ROOT/pages/index.adoc @@ -1,8 +1,8 @@ -= Overview += {product-name} image::Logo.svg[Logo XDEV Spring-Data-Eclipse-Store,200] -== About {product-name} +== About A Open-Source library to simplify using https://eclipsestore.io/[EclipseStore] in a https://spring.io/projects/spring-data/[Spring environment]. From 24b3a630c9f4d84d6cf6de45ae12271eb3400e74 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 12 Mar 2024 09:16:55 +0100 Subject: [PATCH 41/98] Added copyright --- .../store/integration/isolated/package-info.java | 15 +++++++++++++++ .../store/integration/shared/package-info.java | 15 +++++++++++++++ 2 files changed, 30 insertions(+) diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/package-info.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/package-info.java index f5465f61..a5d558eb 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/package-info.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/package-info.java @@ -1,3 +1,18 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ /** * The repositories of these tests are seperated from each other. That means that e.g. the * {@link software.xdev.spring.data.eclipse.store.integration.isolated.tests.special.types.TypesTest} can't access the diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/package-info.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/package-info.java index be4503c9..77b2d9f2 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/package-info.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/package-info.java @@ -1,3 +1,18 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ /** * These tests SHARE their repositories. That's not ideal and should be changed in the future. */ From a8f408ff95b967270227e59a619426ed516c9881 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 12 Mar 2024 11:39:56 +0100 Subject: [PATCH 42/98] Simple Lazy working --- .../BinaryHandlerOnlyForCopyingException.java | 11 -- .../lazy/SpringDataEclipseStoreLazy.java | 24 ++-- ...ringDataEclipseStoreLazyBinaryHandler.java | 5 +- .../data/eclipse/store/helper/TestData.java | 3 + .../isolated/tests/lazy/LazyTest.java | 126 +++++++++++++++++- .../isolated/tests/lazy/ObjectWithLazy.java | 34 +++++ .../tests/lazy/ObjectWithLazyRepository.java | 23 ++++ .../tests/special/types/TypesData.java | 5 - 8 files changed, 202 insertions(+), 29 deletions(-) delete mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/BinaryHandlerOnlyForCopyingException.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazy.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyRepository.java diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/BinaryHandlerOnlyForCopyingException.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/BinaryHandlerOnlyForCopyingException.java deleted file mode 100644 index 96ab9ca3..00000000 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/BinaryHandlerOnlyForCopyingException.java +++ /dev/null @@ -1,11 +0,0 @@ -package software.xdev.spring.data.eclipse.store.exceptions; - -public class BinaryHandlerOnlyForCopyingException extends RuntimeException -{ - public BinaryHandlerOnlyForCopyingException() - { - super( - "This handler should only be used for copying objects one time. It shouldn't be used for anything else, " - + "yet it looks like you are using it for something else."); - } -} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java index cf9c2487..c033d650 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java @@ -4,6 +4,7 @@ import org.eclipse.serializer.reference.Lazy; import org.eclipse.serializer.reference.ObjectSwizzling; +import org.eclipse.serializer.reference.Swizzling; public interface SpringDataEclipseStoreLazy extends Lazy @@ -13,11 +14,6 @@ static SpringDataEclipseStoreLazy.Default build(final T objectToWrapInLaz return new Default<>(objectToWrapInLazy); } - static SpringDataEclipseStoreLazy.Default buildFromStorage(final long objectId, final ObjectSwizzling loader) - { - return new Default<>(objectId, loader); - } - static SpringDataEclipseStoreLazy.Default buildOnlyForStorage(final long objectId) { return new Default<>(objectId); @@ -28,8 +24,9 @@ static SpringDataEclipseStoreLazy.Default buildOnlyForStorage(final long obje class Default implements SpringDataEclipseStoreLazy { private Lazy wrappedLazy; - private long objectId; - private ObjectSwizzling loader; + private long objectId = Swizzling.notFoundId(); + private transient ObjectSwizzling loader; + private transient boolean isStored = false; private Default(final T wrappedObject) { @@ -80,6 +77,12 @@ public T peek() @Override public T clear() { + if(!this.isStored()) + { + throw new IllegalStateException("Cannot clear an unstored lazy reference."); + } + // Make sure to save the correct objectId. + this.objectId = this.objectId(); this.wrappedLazy = null; return null; } @@ -87,7 +90,12 @@ public T clear() @Override public boolean isStored() { - return this.ensureLazy().isStored(); + return this.isStored; + } + + void setStored() + { + this.isStored = true; } @Override diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java index fc04264a..b4bb38cf 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java @@ -12,8 +12,6 @@ import org.eclipse.serializer.reference.ObjectSwizzling; import org.eclipse.serializer.reflect.XReflect; -import software.xdev.spring.data.eclipse.store.exceptions.BinaryHandlerOnlyForCopyingException; - /** * Copied from @@ -55,6 +53,7 @@ public final void store( final long referenceOid = instance.objectId(); data.storeEntityHeader(Binary.referenceBinaryLength(1), this.typeId(), objectId); data.store_long(referenceOid); + instance.setStored(); } @SuppressWarnings("unchecked") @@ -75,7 +74,7 @@ public final void updateState( final PersistenceLoadHandler handler ) { - throw new BinaryHandlerOnlyForCopyingException(); + // no-op } @Override diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/TestData.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/TestData.java index e5482b6d..7ab5dddd 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/TestData.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/TestData.java @@ -22,6 +22,9 @@ public final class TestData public static final String LAST_NAME_ALTERNATIVE = "Nicks"; public static final String FIRST_NAME_ALTERNATIVE = "Stevie"; + public static final String DUMMY_STRING = "-- skldfoöüä+#+!(/%&/%($§\"=)()nxjkß? _:.. ,-.;"; + public static final String DUMMY_STRING_ALTERNATIVE = " abc "; + private TestData() { } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java index d05c7b64..b3d15d35 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java @@ -15,15 +15,20 @@ */ package software.xdev.spring.data.eclipse.store.integration.isolated.tests.lazy; +import static software.xdev.spring.data.eclipse.store.helper.TestUtil.restartDatastore; + import org.eclipse.serializer.collections.lazy.LazyArrayList; import org.eclipse.serializer.collections.lazy.LazyList; +import org.eclipse.serializer.reference.Lazy; import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.test.context.ContextConfiguration; +import software.xdev.spring.data.eclipse.store.helper.TestData; import software.xdev.spring.data.eclipse.store.helper.TestUtil; import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestAnnotations; +import software.xdev.spring.data.eclipse.store.repository.lazy.SpringDataEclipseStoreLazy; @IsolatedTestAnnotations @@ -34,10 +39,10 @@ class LazyTest private LazyTestConfiguration configuration; @Test - void lazyListStore(final ObjectWithLazyListRepository repository) + void lazyListStore(@Autowired final ObjectWithLazyListRepository repository) { final ObjectWithLazyList newList = new ObjectWithLazyList(); - final SimpleObject objectToStore = new SimpleObject("Test"); + final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); final LazyArrayList lazyArrayList = new LazyArrayList(); lazyArrayList.add(objectToStore); newList.setLazyList(lazyArrayList); @@ -53,4 +58,121 @@ void lazyListStore(final ObjectWithLazyListRepository repository) } ); } + + @Test + void lazyStore(@Autowired final ObjectWithLazyRepository repository) + { + final ObjectWithLazy newLazy = new ObjectWithLazy(); + final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); + repository.save(newLazy); + + TestUtil.doBeforeAndAfterRestartOfDatastore( + this.configuration, + () -> { + Assertions.assertEquals(1, repository.findAll().size()); + final Lazy lazy = repository.findAll().get(0).getLazy(); + Assertions.assertEquals(objectToStore, lazy.get()); + } + ); + } + + @Test + void lazyClearBeforeSave(@Autowired final ObjectWithLazyRepository repository) + { + final ObjectWithLazy newLazy = new ObjectWithLazy(); + final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); + Assertions.assertThrows(IllegalStateException.class, () -> newLazy.getLazy().clear()); + } + + @Test + void lazyClearAfterSave(@Autowired final ObjectWithLazyRepository repository) + { + final ObjectWithLazy newLazy = new ObjectWithLazy(); + final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); + repository.save(newLazy); + newLazy.getLazy().clear(); + + TestUtil.doBeforeAndAfterRestartOfDatastore( + this.configuration, + () -> { + Assertions.assertEquals(1, repository.findAll().size()); + final Lazy lazy = repository.findAll().get(0).getLazy(); + Assertions.assertEquals(objectToStore, lazy.get()); + } + ); + } + + @Test + void lazyChangeAfterSave(@Autowired final ObjectWithLazyRepository repository) + { + final ObjectWithLazy newLazy = new ObjectWithLazy(); + final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); + repository.save(newLazy); + + final SimpleObject objectToStore2 = new SimpleObject(TestData.DUMMY_STRING_ALTERNATIVE); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore2)); + repository.save(newLazy); + + TestUtil.doBeforeAndAfterRestartOfDatastore( + this.configuration, + () -> { + Assertions.assertEquals(1, repository.findAll().size()); + final Lazy lazy = repository.findAll().get(0).getLazy(); + Assertions.assertEquals(objectToStore2, lazy.get()); + } + ); + } + + @Test + void lazyChangeBeforeSave(@Autowired final ObjectWithLazyRepository repository) + { + final ObjectWithLazy newLazy = new ObjectWithLazy(); + final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); + + final SimpleObject objectToStore2 = new SimpleObject(TestData.DUMMY_STRING_ALTERNATIVE); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore2)); + repository.save(newLazy); + + TestUtil.doBeforeAndAfterRestartOfDatastore( + this.configuration, + () -> { + Assertions.assertEquals(1, repository.findAll().size()); + final Lazy lazy = repository.findAll().get(0).getLazy(); + Assertions.assertEquals(objectToStore2, lazy.get()); + } + ); + } + + @Test + void lazyChangeAfterRestart(@Autowired final ObjectWithLazyRepository repository) + { + final ObjectWithLazy newLazy = new ObjectWithLazy(); + final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); + repository.save(newLazy); + + restartDatastore(this.configuration); + + Assertions.assertEquals(1, repository.findAll().size()); + final ObjectWithLazy reloadedObjectWithLazy = repository.findAll().get(0); + Assertions.assertEquals(objectToStore, reloadedObjectWithLazy.getLazy().get()); + + final SimpleObject objectToStore2 = new SimpleObject(TestData.DUMMY_STRING_ALTERNATIVE); + reloadedObjectWithLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore2)); + repository.save(reloadedObjectWithLazy); + + TestUtil.doBeforeAndAfterRestartOfDatastore( + this.configuration, + () -> { + Assertions.assertEquals(1, repository.findAll().size()); + final Lazy lazy = repository.findAll().get(0).getLazy(); + Assertions.assertEquals(objectToStore2, lazy.get()); + } + ); + } } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazy.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazy.java new file mode 100644 index 00000000..8f414c44 --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazy.java @@ -0,0 +1,34 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.lazy; + +import org.eclipse.serializer.reference.Lazy; + + +public class ObjectWithLazy +{ + private Lazy lazy; + + public Lazy getLazy() + { + return this.lazy; + } + + public void setLazy(final Lazy lazy) + { + this.lazy = lazy; + } +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyRepository.java new file mode 100644 index 00000000..02bcdd93 --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyRepository.java @@ -0,0 +1,23 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.lazy; + +import org.springframework.data.repository.ListCrudRepository; + + +public interface ObjectWithLazyRepository extends ListCrudRepository +{ +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java index 6c3bed83..cc895af2 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java @@ -439,11 +439,6 @@ public static Stream generateData() id -> new LazyDaoObject(id, SpringDataEclipseStoreLazy.build("1")), object -> object.setValue(SpringDataEclipseStoreLazy.build("2")) ), - new TestArguments<>( - LazyRepository.class, - id -> new LazyDaoObject(id, SpringDataEclipseStoreLazy.build("1")), - object -> object.getValue().clear() - ), new TestArguments<>( MapRepository.class, id -> new MapDaoObject(id, new LazyHashMap<>()), From 93f5e0317489a655f201fcf1253f1601b475bfa0 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 12 Mar 2024 13:49:37 +0100 Subject: [PATCH 43/98] Cleanup Lazy --- .../repository/lazy/LazyInterceptor.java | 22 --------------- .../repository/lazy/LazyProxyGenerator.java | 18 ------------ .../copier/AbstractRegisteringCopier.java | 28 ++++++++++++++----- .../copier/PersistenceManagerProvider.java | 12 -------- ...RegisteringStorageToWorkingCopyCopier.java | 15 +--------- ...RegisteringWorkingCopyToStorageCopier.java | 15 +--------- .../isolated/tests/lazy/LazyTest.java | 12 ++++++++ 7 files changed, 35 insertions(+), 87 deletions(-) delete mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyInterceptor.java delete mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyProxyGenerator.java delete mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/PersistenceManagerProvider.java diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyInterceptor.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyInterceptor.java deleted file mode 100644 index 9ab1a39e..00000000 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyInterceptor.java +++ /dev/null @@ -1,22 +0,0 @@ -package software.xdev.spring.data.eclipse.store.repository.lazy; - -import org.aopalliance.intercept.ConstructorInterceptor; -import org.aopalliance.intercept.ConstructorInvocation; -import org.eclipse.serializer.reference.Lazy; - - -public class LazyInterceptor implements ConstructorInterceptor -{ - private final Lazy originalLazy; - - public LazyInterceptor(final Lazy originalLazy) - { - this.originalLazy = originalLazy; - } - - @Override - public Lazy construct(final ConstructorInvocation invocation) - { - return Lazy.Reference(this.originalLazy.get()); - } -} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyProxyGenerator.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyProxyGenerator.java deleted file mode 100644 index f9650a98..00000000 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/LazyProxyGenerator.java +++ /dev/null @@ -1,18 +0,0 @@ -package software.xdev.spring.data.eclipse.store.repository.lazy; - -import org.eclipse.serializer.reference.Lazy; -import org.springframework.aop.framework.ProxyFactory; - - -public final class LazyProxyGenerator -{ - private LazyProxyGenerator() - { - } - - public static Lazy generateLazyProxy(final Lazy lazy) - { - final ProxyFactory f = new ProxyFactory(Lazy.class, new LazyInterceptor<>(lazy)); - return (Lazy)f.getProxy(); - } -} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java index 79acb4c7..65147ba3 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java @@ -20,10 +20,13 @@ import org.eclipse.serializer.persistence.binary.jdk17.java.util.BinaryHandlerImmutableCollectionsList12; import org.eclipse.serializer.persistence.binary.jdk17.java.util.BinaryHandlerImmutableCollectionsSet12; import org.eclipse.serializer.persistence.binary.types.Binary; +import org.eclipse.serializer.persistence.types.PersistenceManager; +import org.eclipse.serializer.reference.ObjectSwizzling; import org.eclipse.serializer.reference.Reference; import org.eclipse.serializer.util.X; import software.xdev.spring.data.eclipse.store.repository.SupportedChecker; +import software.xdev.spring.data.eclipse.store.repository.lazy.SpringDataEclipseStoreLazyBinaryHandler; /** @@ -37,25 +40,36 @@ public abstract class AbstractRegisteringCopier implements RegisteringObjectCopi public AbstractRegisteringCopier( final SupportedChecker supportedChecker, final RegisteringWorkingCopyAndOriginal register, - final PersistenceManagerProvider persistenceManagerProvider) + final ObjectSwizzling objectSwizzling) { this.actualCopier = new EclipseSerializerRegisteringCopier( supportedChecker, register, - persistenceManagerProvider.createPersistenceManager(this.createSerializerFoundation()) + this.createPersistenceManager( + this.createSerializerFoundation(), + objectSwizzling + ) ); } + private PersistenceManager createPersistenceManager( + final SerializerFoundation serializerFoundation, + final ObjectSwizzling objectSwizzling) + { + return serializerFoundation + .registerCustomTypeHandler(BinaryHandlerImmutableCollectionsSet12.New()) + .registerCustomTypeHandler(BinaryHandlerImmutableCollectionsList12.New()) + .registerCustomTypeHandlers(new SpringDataEclipseStoreLazyBinaryHandler(objectSwizzling)) + .createPersistenceManager(); + } + protected SerializerFoundation createSerializerFoundation() { - final SerializerFoundation newFoundation = SerializerFoundation.New(); - newFoundation.registerCustomTypeHandler(BinaryHandlerImmutableCollectionsSet12.New()); - newFoundation.registerCustomTypeHandler(BinaryHandlerImmutableCollectionsList12.New()); - final Reference buffer = X.Reference(null); final Serializer.Source source = () -> X.Constant(buffer.get()); final Serializer.Target target = buffer::set; - return newFoundation + + return SerializerFoundation.New() .setPersistenceSource(source) .setPersistenceTarget(target) // Make every type persistable. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/PersistenceManagerProvider.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/PersistenceManagerProvider.java deleted file mode 100644 index 3728da3c..00000000 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/PersistenceManagerProvider.java +++ /dev/null @@ -1,12 +0,0 @@ -package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; - -import org.eclipse.serializer.SerializerFoundation; -import org.eclipse.serializer.persistence.binary.types.Binary; -import org.eclipse.serializer.persistence.types.PersistenceManager; - - -@FunctionalInterface -public interface PersistenceManagerProvider -{ - PersistenceManager createPersistenceManager(SerializerFoundation serializerFoundation); -} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java index 78bc13e1..49a55b86 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java @@ -15,14 +15,10 @@ */ package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; -import org.eclipse.serializer.SerializerFoundation; -import org.eclipse.serializer.persistence.binary.types.Binary; -import org.eclipse.serializer.persistence.types.PersistenceManager; import org.eclipse.serializer.reference.ObjectSwizzling; import software.xdev.spring.data.eclipse.store.repository.SupportedChecker; import software.xdev.spring.data.eclipse.store.repository.WorkingCopyRegistry; -import software.xdev.spring.data.eclipse.store.repository.lazy.SpringDataEclipseStoreLazyBinaryHandler; /** @@ -39,16 +35,7 @@ public RegisteringStorageToWorkingCopyCopier( super( supportedChecker, (workingCopy, objectToStore) -> registry.register(workingCopy, objectToStore), - (serializerFoundation) -> createPersistenceManager(serializerFoundation, objectSwizzling) + objectSwizzling ); } - - private static PersistenceManager createPersistenceManager( - final SerializerFoundation serializerFoundation, - final ObjectSwizzling objectSwizzling) - { - return serializerFoundation - .registerCustomTypeHandlers(new SpringDataEclipseStoreLazyBinaryHandler(objectSwizzling)) - .createPersistenceManager(); - } } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java index 428c2a81..fd5f8d5b 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java @@ -15,14 +15,10 @@ */ package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; -import org.eclipse.serializer.SerializerFoundation; -import org.eclipse.serializer.persistence.binary.types.Binary; -import org.eclipse.serializer.persistence.types.PersistenceManager; import org.eclipse.serializer.reference.ObjectSwizzling; import software.xdev.spring.data.eclipse.store.repository.SupportedChecker; import software.xdev.spring.data.eclipse.store.repository.WorkingCopyRegistry; -import software.xdev.spring.data.eclipse.store.repository.lazy.SpringDataEclipseStoreLazyBinaryHandler; /** @@ -40,16 +36,7 @@ public RegisteringWorkingCopyToStorageCopier( super( supportedChecker, (workingCopy, objectToStore) -> registry.invertRegister(workingCopy, objectToStore), - (serializerFoundation) -> createPersistenceManager(serializerFoundation, objectSwizzling) + objectSwizzling ); } - - private static PersistenceManager createPersistenceManager( - final SerializerFoundation serializerFoundation, - final ObjectSwizzling objectSwizzling) - { - return serializerFoundation - .registerCustomTypeHandlers(new SpringDataEclipseStoreLazyBinaryHandler(objectSwizzling)) - .createPersistenceManager(); - } } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java index b3d15d35..a4db2dd7 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java @@ -21,6 +21,7 @@ import org.eclipse.serializer.collections.lazy.LazyList; import org.eclipse.serializer.reference.Lazy; import org.junit.jupiter.api.Assertions; +import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Test; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.test.context.ContextConfiguration; @@ -39,6 +40,7 @@ class LazyTest private LazyTestConfiguration configuration; @Test + @Disabled("This should work at some point. At least a warning should be displayed.") void lazyListStore(@Autowired final ObjectWithLazyListRepository repository) { final ObjectWithLazyList newList = new ObjectWithLazyList(); @@ -86,6 +88,16 @@ void lazyClearBeforeSave(@Autowired final ObjectWithLazyRepository repository) Assertions.assertThrows(IllegalStateException.class, () -> newLazy.getLazy().clear()); } + @Test + @Disabled("This should work at some point. At least a warning should be displayed.") + void lazyUseEclipseStoreLazy(@Autowired final ObjectWithLazyRepository repository) + { + final ObjectWithLazy newLazy = new ObjectWithLazy(); + final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); + newLazy.setLazy(Lazy.Reference(objectToStore)); + Assertions.assertThrows(Exception.class, () -> repository.save(newLazy)); + } + @Test void lazyClearAfterSave(@Autowired final ObjectWithLazyRepository repository) { From 2e1b83946637393f782abc6045ecd260af560817 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 12 Mar 2024 14:20:49 +0100 Subject: [PATCH 44/98] Added Copyrights --- .../lazy/SpringDataEclipseStoreLazy.java | 15 +++++++++++++++ .../SpringDataEclipseStoreLazyBinaryHandler.java | 15 +++++++++++++++ .../copier/RegisteringWorkingCopyAndOriginal.java | 15 +++++++++++++++ 3 files changed, 45 insertions(+) diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java index c033d650..a3664867 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java @@ -1,3 +1,18 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ package software.xdev.spring.data.eclipse.store.repository.lazy; import java.util.Objects; diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java index b4bb38cf..ccabf0d6 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java @@ -1,3 +1,18 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ package software.xdev.spring.data.eclipse.store.repository.lazy; import java.lang.reflect.Constructor; diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyAndOriginal.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyAndOriginal.java index 1438d835..b1153bae 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyAndOriginal.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyAndOriginal.java @@ -1,3 +1,18 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; @FunctionalInterface From d7a1a0e97781bdb554d2ae9abe8729b85989d27e Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Thu, 14 Mar 2024 09:15:02 +0100 Subject: [PATCH 45/98] Simple Lazy working quite well. More complex lazies are not implemented yet. --- .../lazy/SpringDataEclipseStoreLazy.java | 52 ++++-- ...ringDataEclipseStoreLazyBinaryHandler.java | 95 ++++++++--- .../working/RecursiveWorkingCopier.java | 2 +- .../tests/lazy/ComplexLazyObject.java | 55 +++++++ .../isolated/tests/lazy/LazyTest.java | 69 ++++++-- .../isolated/tests/lazy/ObjectWithLazy.java | 8 +- .../tests/lazy/ObjectWithLazyRepository.java | 2 +- .../tests/special/types/TypesData.java | 152 +++++++++--------- 8 files changed, 307 insertions(+), 128 deletions(-) create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ComplexLazyObject.java diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java index a3664867..efc67f56 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java @@ -22,6 +22,12 @@ import org.eclipse.serializer.reference.Swizzling; +/** + * This is the Lazy-Wrapper a user of the Spring-Data-Eclipse-Store-Library should use. Please do not use the + * {@link Lazy}-Wrapper! Because SDES is making working copies of the stored data, the {@link Lazy} does not work as + * expected. Instead, use this Wrapper. It brings the same functionality as the native {@link Lazy}-Wrapper but works + * with working copies. + */ public interface SpringDataEclipseStoreLazy extends Lazy { static SpringDataEclipseStoreLazy.Default build(final T objectToWrapInLazy) @@ -29,15 +35,19 @@ static SpringDataEclipseStoreLazy.Default build(final T objectToWrapInLaz return new Default<>(objectToWrapInLazy); } - static SpringDataEclipseStoreLazy.Default buildOnlyForStorage(final long objectId) - { - return new Default<>(objectId); - } + SpringDataEclipseStoreLazy copy(); long objectId(); + /** + * This class is very complex and its various membervariables all have their reason to exist. This code is very + * difficult to read due to its the functionality explained in the {@link SpringDataEclipseStoreLazyBinaryHandler}. + * + * @param + */ class Default implements SpringDataEclipseStoreLazy { + private T objectToBeWrapped; private Lazy wrappedLazy; private long objectId = Swizzling.notFoundId(); private transient ObjectSwizzling loader; @@ -45,7 +55,7 @@ class Default implements SpringDataEclipseStoreLazy private Default(final T wrappedObject) { - this.wrappedLazy = Lazy.Reference(wrappedObject); + this.objectToBeWrapped = wrappedObject; } private Default(final long objectId, final ObjectSwizzling loader) @@ -54,11 +64,6 @@ private Default(final long objectId, final ObjectSwizzling loader) this.loader = loader; } - private Default(final long objectId) - { - this.objectId = objectId; - } - private Lazy ensureLazy() { if(this.wrappedLazy == null) @@ -80,6 +85,10 @@ public static final Class> genericType() @Override public T get() { + if(this.objectToBeWrapped != null) + { + return this.objectToBeWrapped; + } return this.ensureLazy().get(); } @@ -116,6 +125,10 @@ void setStored() @Override public boolean isLoaded() { + if(this.objectToBeWrapped != null) + { + return true; + } if(this.wrappedLazy == null) { return false; @@ -148,5 +161,24 @@ public long objectId() } return this.objectId; } + + void setWrappedLazy(final Lazy wrappedLazy) + { + this.wrappedLazy = wrappedLazy; + } + + public T getObjectToBeWrapped() + { + return this.objectToBeWrapped; + } + + @Override + public SpringDataEclipseStoreLazy copy() + { + return new SpringDataEclipseStoreLazy.Default( + this.objectId, + this.loader + ); + } } } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java index ccabf0d6..7d061f44 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java @@ -18,8 +18,10 @@ import java.lang.reflect.Constructor; import java.util.Objects; +import org.eclipse.serializer.memory.XMemory; import org.eclipse.serializer.persistence.binary.types.AbstractBinaryHandlerCustom; import org.eclipse.serializer.persistence.binary.types.Binary; +import org.eclipse.serializer.persistence.binary.types.BinaryTypeHandler; import org.eclipse.serializer.persistence.types.PersistenceLoadHandler; import org.eclipse.serializer.persistence.types.PersistenceReferenceLoader; import org.eclipse.serializer.persistence.types.PersistenceStoreHandler; @@ -29,14 +31,30 @@ /** - * Copied from - * {@link org.eclipse.serializer.persistence.binary.org.eclipse.serializer.reference.BinaryHandlerLazyDefault}. + * This is a complicated one. First off: this handler should only be used for WorkingCopies (see + * {@link software.xdev.spring.data.eclipse.store.repository.support.copier.copier.EclipseSerializerRegisteringCopier})! + *

+ * First case:
+ * The user creates a {@link SpringDataEclipseStoreLazy} and puts a object in it. + * This object is stored as with a default {@link BinaryTypeHandler}. But when it gets loaded, + * it does not load as the stored object, but it gets wrapped in a {@link Lazy#Reference(Object)}. + *

+ *

+ * Second case:
+ * The actual lazy object gets loaded from the actual storage. In this case the {@link ObjectSwizzling} is + * important! It's the actual {@link ObjectSwizzling} from the storage (not from the + * {@link software.xdev.spring.data.eclipse.store.repository.support.copier.copier.EclipseSerializerRegisteringCopier}). + * This means, the {@link SpringDataEclipseStoreLazy} holds the objectId of the original lazy in the original + * storage. + * Therefore if {@link SpringDataEclipseStoreLazy#get()} is called a new working copy of the lazy from the + * storage is loaded. + *

*/ public final class SpringDataEclipseStoreLazyBinaryHandler extends AbstractBinaryHandlerCustom> { @SuppressWarnings("rawtypes") - static final Constructor CONSTRUCTOR = XReflect.setAccessible( + static final Constructor CONSTRUCTOR_SURROGATE_LAZY = XReflect.setAccessible( XReflect.getDeclaredConstructor( SpringDataEclipseStoreLazy.Default.class, long.class, @@ -44,52 +62,84 @@ public final class SpringDataEclipseStoreLazyBinaryHandler ) ); - private final ObjectSwizzling objectSwizzling; + public static final int OFFSET_UNWRAPPED_OBJECT = 8; + public static final int OFFSET_LAZY = 0; - public SpringDataEclipseStoreLazyBinaryHandler(final ObjectSwizzling objectSwizzling) + private final ObjectSwizzling originalStoreLoader; + + public SpringDataEclipseStoreLazyBinaryHandler(final ObjectSwizzling originalStoreLoader) { super( SpringDataEclipseStoreLazy.Default.genericType(), CustomFields( - CustomField(Object.class, "subject") + CustomField(Object.class, "lazySubject"), + CustomField(Object.class, "unwrappedSubject") ) ); - this.objectSwizzling = Objects.requireNonNull(objectSwizzling); + this.originalStoreLoader = Objects.requireNonNull(originalStoreLoader); } @Override - public final void store( + public void store( final Binary data, final SpringDataEclipseStoreLazy.Default instance, final long objectId, final PersistenceStoreHandler handler ) { - final long referenceOid = instance.objectId(); - data.storeEntityHeader(Binary.referenceBinaryLength(1), this.typeId(), objectId); - data.store_long(referenceOid); + data.storeEntityHeader(Binary.referenceBinaryLength(2), this.typeId(), objectId); + if(instance.getObjectToBeWrapped() != null) + { + // Store unwrapped Object + final long newObjectId = handler.applyEager(instance.getObjectToBeWrapped()); + data.store_long(OFFSET_UNWRAPPED_OBJECT, newObjectId); + } + else + { + // Store only reference to lazy + data.store_long(OFFSET_LAZY, instance.objectId()); + } instance.setStored(); } @SuppressWarnings("unchecked") @Override - public final SpringDataEclipseStoreLazy.Default create(final Binary data, final PersistenceLoadHandler handler) + public SpringDataEclipseStoreLazy.Default create(final Binary data, final PersistenceLoadHandler handler) { - final long objectId = data.read_long(0); + final long objectIdOfLazy = data.read_long(OFFSET_LAZY); + final long objectIdOfUnwrappedObject = data.read_long(OFFSET_UNWRAPPED_OBJECT); - return Lazy.register( - XReflect.invoke(CONSTRUCTOR, objectId, this.objectSwizzling) - ); + if(objectIdOfUnwrappedObject == 0) + { + return Lazy.register( + XReflect.invoke(CONSTRUCTOR_SURROGATE_LAZY, objectIdOfLazy, this.originalStoreLoader) + ); + } + return XMemory.instantiateBlank(SpringDataEclipseStoreLazy.Default.class); } @Override - public final void updateState( + public void updateState( final Binary data, final SpringDataEclipseStoreLazy.Default instance, final PersistenceLoadHandler handler ) { - // no-op + this.updateStateT(data, instance, handler); + } + + private void updateStateT( + final Binary data, + final SpringDataEclipseStoreLazy.Default instance, + final PersistenceLoadHandler handler + ) + { + final long objectIdOfUnwrappedObject = data.read_long(OFFSET_UNWRAPPED_OBJECT); + + if(objectIdOfUnwrappedObject != 0) + { + instance.setWrappedLazy(Lazy.Reference((T)handler.lookupObject(objectIdOfUnwrappedObject))); + } } @Override @@ -122,10 +172,15 @@ public final boolean hasVaryingPersistedLengthInstances() @Override public final void iterateLoadableReferences( - final Binary offset, + final Binary data, final PersistenceReferenceLoader iterator ) { - // the lazy reference is not naturally loadable, but special-handled by this handler + final long objectIdOfUnwrappedObject = data.read_long(OFFSET_UNWRAPPED_OBJECT); + + if(objectIdOfUnwrappedObject != 0) + { + iterator.acceptObjectId(objectIdOfUnwrappedObject); + } } } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java index 49be55e8..3120009e 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java @@ -330,7 +330,7 @@ private SpringDataEclipseStoreLazy createNewLazy( { // This lazy should never be used again! // It is though of as a temporary copy to merge back into the original-storage-data. - return (SpringDataEclipseStoreLazy)SpringDataEclipseStoreLazy.buildOnlyForStorage(oldLazy.objectId()); + return oldLazy.copy(); } } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ComplexLazyObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ComplexLazyObject.java new file mode 100644 index 00000000..07b57b68 --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ComplexLazyObject.java @@ -0,0 +1,55 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.lazy; + +import java.util.List; + +import org.eclipse.serializer.reference.Lazy; + + +public class ComplexLazyObject +{ + private Lazy simpleObject; + private List>> listOfLazyListOfString; + + public ComplexLazyObject( + final Lazy simpleObject, + final List>> listOfLazyListOfString) + { + this.simpleObject = simpleObject; + this.listOfLazyListOfString = listOfLazyListOfString; + } + + public Lazy getSimpleObject() + { + return this.simpleObject; + } + + public void setSimpleObject(final Lazy simpleObject) + { + this.simpleObject = simpleObject; + } + + public List>> getListOfLazyListOfString() + { + return this.listOfLazyListOfString; + } + + public void setListOfLazyListOfString(final List>> listOfLazyListOfString) + { + this.listOfLazyListOfString = listOfLazyListOfString; + } +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java index a4db2dd7..a088bedb 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java @@ -17,6 +17,9 @@ import static software.xdev.spring.data.eclipse.store.helper.TestUtil.restartDatastore; +import java.util.ArrayList; +import java.util.Arrays; + import org.eclipse.serializer.collections.lazy.LazyArrayList; import org.eclipse.serializer.collections.lazy.LazyList; import org.eclipse.serializer.reference.Lazy; @@ -45,7 +48,7 @@ void lazyListStore(@Autowired final ObjectWithLazyListRepository repository) { final ObjectWithLazyList newList = new ObjectWithLazyList(); final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); - final LazyArrayList lazyArrayList = new LazyArrayList(); + final LazyArrayList lazyArrayList = new LazyArrayList<>(); lazyArrayList.add(objectToStore); newList.setLazyList(lazyArrayList); repository.save(newList); @@ -62,9 +65,9 @@ void lazyListStore(@Autowired final ObjectWithLazyListRepository repository) } @Test - void lazyStore(@Autowired final ObjectWithLazyRepository repository) + void lazyStore(@Autowired final ObjectWithLazyRepository repository) { - final ObjectWithLazy newLazy = new ObjectWithLazy(); + final ObjectWithLazy newLazy = new ObjectWithLazy<>(); final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); repository.save(newLazy); @@ -80,9 +83,43 @@ void lazyStore(@Autowired final ObjectWithLazyRepository repository) } @Test - void lazyClearBeforeSave(@Autowired final ObjectWithLazyRepository repository) + void lazyStoreComplexObject(@Autowired final ObjectWithLazyRepository repository) + { + final ObjectWithLazy newLazy = new ObjectWithLazy<>(); + final ComplexLazyObject objectToStore = new ComplexLazyObject( + SpringDataEclipseStoreLazy.build(new SimpleObject(TestData.DUMMY_STRING)), + new ArrayList<>(Arrays.asList( + SpringDataEclipseStoreLazy.build(new ArrayList<>(Arrays.asList(TestData.DUMMY_STRING))), + SpringDataEclipseStoreLazy.build(new ArrayList<>(Arrays.asList(TestData.DUMMY_STRING_ALTERNATIVE))) + )) + ); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); + repository.save(newLazy); + + TestUtil.doBeforeAndAfterRestartOfDatastore( + this.configuration, + () -> { + Assertions.assertEquals(1, repository.findAll().size()); + final Lazy lazy = repository.findAll().get(0).getLazy(); + Assertions.assertNotNull(lazy.get()); + Assertions.assertEquals(objectToStore.getSimpleObject().get(), lazy.get().getSimpleObject().get()); + Assertions.assertEquals( + objectToStore.getListOfLazyListOfString().size(), + lazy.get().getListOfLazyListOfString().size()); + Assertions.assertEquals( + objectToStore.getListOfLazyListOfString().get(0).get(), + lazy.get().getListOfLazyListOfString().get(0).get()); + Assertions.assertEquals( + objectToStore.getListOfLazyListOfString().get(1).get(), + lazy.get().getListOfLazyListOfString().get(1).get()); + } + ); + } + + @Test + void lazyClearBeforeSave() { - final ObjectWithLazy newLazy = new ObjectWithLazy(); + final ObjectWithLazy newLazy = new ObjectWithLazy<>(); final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); Assertions.assertThrows(IllegalStateException.class, () -> newLazy.getLazy().clear()); @@ -90,18 +127,18 @@ void lazyClearBeforeSave(@Autowired final ObjectWithLazyRepository repository) @Test @Disabled("This should work at some point. At least a warning should be displayed.") - void lazyUseEclipseStoreLazy(@Autowired final ObjectWithLazyRepository repository) + void lazyUseEclipseStoreLazy(@Autowired final ObjectWithLazyRepository repository) { - final ObjectWithLazy newLazy = new ObjectWithLazy(); + final ObjectWithLazy newLazy = new ObjectWithLazy<>(); final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); newLazy.setLazy(Lazy.Reference(objectToStore)); Assertions.assertThrows(Exception.class, () -> repository.save(newLazy)); } @Test - void lazyClearAfterSave(@Autowired final ObjectWithLazyRepository repository) + void lazyClearAfterSave(@Autowired final ObjectWithLazyRepository repository) { - final ObjectWithLazy newLazy = new ObjectWithLazy(); + final ObjectWithLazy newLazy = new ObjectWithLazy<>(); final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); repository.save(newLazy); @@ -118,9 +155,9 @@ void lazyClearAfterSave(@Autowired final ObjectWithLazyRepository repository) } @Test - void lazyChangeAfterSave(@Autowired final ObjectWithLazyRepository repository) + void lazyChangeAfterSave(@Autowired final ObjectWithLazyRepository repository) { - final ObjectWithLazy newLazy = new ObjectWithLazy(); + final ObjectWithLazy newLazy = new ObjectWithLazy<>(); final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); repository.save(newLazy); @@ -140,9 +177,9 @@ void lazyChangeAfterSave(@Autowired final ObjectWithLazyRepository repository) } @Test - void lazyChangeBeforeSave(@Autowired final ObjectWithLazyRepository repository) + void lazyChangeBeforeSave(@Autowired final ObjectWithLazyRepository repository) { - final ObjectWithLazy newLazy = new ObjectWithLazy(); + final ObjectWithLazy newLazy = new ObjectWithLazy<>(); final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); @@ -161,9 +198,9 @@ void lazyChangeBeforeSave(@Autowired final ObjectWithLazyRepository repository) } @Test - void lazyChangeAfterRestart(@Autowired final ObjectWithLazyRepository repository) + void lazyChangeAfterRestart(@Autowired final ObjectWithLazyRepository repository) { - final ObjectWithLazy newLazy = new ObjectWithLazy(); + final ObjectWithLazy newLazy = new ObjectWithLazy<>(); final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); repository.save(newLazy); @@ -171,7 +208,7 @@ void lazyChangeAfterRestart(@Autowired final ObjectWithLazyRepository repository restartDatastore(this.configuration); Assertions.assertEquals(1, repository.findAll().size()); - final ObjectWithLazy reloadedObjectWithLazy = repository.findAll().get(0); + final ObjectWithLazy reloadedObjectWithLazy = repository.findAll().get(0); Assertions.assertEquals(objectToStore, reloadedObjectWithLazy.getLazy().get()); final SimpleObject objectToStore2 = new SimpleObject(TestData.DUMMY_STRING_ALTERNATIVE); diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazy.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazy.java index 8f414c44..88a8eeb8 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazy.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazy.java @@ -18,16 +18,16 @@ import org.eclipse.serializer.reference.Lazy; -public class ObjectWithLazy +public class ObjectWithLazy { - private Lazy lazy; + private Lazy lazy; - public Lazy getLazy() + public Lazy getLazy() { return this.lazy; } - public void setLazy(final Lazy lazy) + public void setLazy(final Lazy lazy) { this.lazy = lazy; } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyRepository.java index 02bcdd93..aab0c595 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyRepository.java @@ -18,6 +18,6 @@ import org.springframework.data.repository.ListCrudRepository; -public interface ObjectWithLazyRepository extends ListCrudRepository +public interface ObjectWithLazyRepository extends ListCrudRepository, Integer> { } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java index cc895af2..91241667 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java @@ -111,32 +111,6 @@ public static Stream generateData() id -> new SetDaoObject(id, new HashSet<>(List.of("1", "2"))), set -> set.getValue().add("3") ), - new TestArguments<>( - SetRepository.class, - id -> new SetDaoObject(id, new LazyHashSet<>()), - set -> set.getValue().add("1") - ), - new TestArguments<>( - SetRepository.class, - id -> - { - final LazyHashSet set = new LazyHashSet<>(); - set.add("1"); - return new SetDaoObject(id, set); - }, - set -> set.getValue().add("2") - ), - new TestArguments<>( - SetRepository.class, - id -> - { - final LazyHashSet set = new LazyHashSet<>(); - set.add("1"); - set.add("2"); - return new SetDaoObject(id, set); - }, - set -> set.getValue().add("3") - ), new TestArguments<>( SetRepository.class, id -> new SetDaoObject(id, new TreeSet<>()), @@ -273,32 +247,6 @@ public static Stream generateData() }, object -> object.getValue().add("3") ), - new TestArguments<>( - ListRepository.class, - id -> new ListDaoObject(id, new LazyArrayList<>()), - object -> object.getValue().add("1") - ), - new TestArguments<>( - ListRepository.class, - id -> - { - final LazyArrayList list = new LazyArrayList<>(); - list.add("1"); - return new ListDaoObject(id, list); - }, - object -> object.getValue().add("2") - ), - new TestArguments<>( - ListRepository.class, - id -> - { - final LazyArrayList list = new LazyArrayList<>(); - list.add("1"); - list.add("2"); - return new ListDaoObject(id, list); - }, - object -> object.getValue().add("3") - ), new TestArguments<>( ListRepository.class, id -> new ListDaoObject(id, new ArrayList<>(Set.of("1"))), @@ -438,30 +386,6 @@ public static Stream generateData() LazyRepository.class, id -> new LazyDaoObject(id, SpringDataEclipseStoreLazy.build("1")), object -> object.setValue(SpringDataEclipseStoreLazy.build("2")) - ), - new TestArguments<>( - MapRepository.class, - id -> new MapDaoObject(id, new LazyHashMap<>()), - set -> set.getValue().put("1", "1") - ), - new TestArguments<>( - MapRepository.class, - id -> { - final LazyHashMap lazyHashMap = new LazyHashMap<>(); - lazyHashMap.put("1", "1"); - return new MapDaoObject(id, lazyHashMap); - }, - set -> set.getValue().put("2", "2") - ), - new TestArguments<>( - MapRepository.class, - id -> { - final LazyHashMap lazyHashMap = new LazyHashMap<>(); - lazyHashMap.put("1", "1"); - lazyHashMap.put("2", "2"); - return new MapDaoObject(id, lazyHashMap); - }, - set -> set.getValue().put("3", "3") ) ) ).toArguments(); @@ -510,6 +434,82 @@ public static Stream generateNotWorkingData() CalendarRepository.class, id -> new CalendarDaoObject(id, Calendar.getInstance()), object -> object.getValue().add(Calendar.DAY_OF_MONTH, 1) + ), + new TestArguments<>( + MapRepository.class, + id -> { + final LazyHashMap lazyHashMap = new LazyHashMap<>(); + lazyHashMap.put("1", "1"); + return new MapDaoObject(id, lazyHashMap); + }, + set -> set.getValue().put("2", "2") + ), + new TestArguments<>( + MapRepository.class, + id -> { + final LazyHashMap lazyHashMap = new LazyHashMap<>(); + lazyHashMap.put("1", "1"); + lazyHashMap.put("2", "2"); + return new MapDaoObject(id, lazyHashMap); + }, + set -> set.getValue().put("3", "3") + ), + new TestArguments<>( + SetRepository.class, + id -> new SetDaoObject(id, new LazyHashSet<>()), + set -> set.getValue().add("1") + ), + new TestArguments<>( + SetRepository.class, + id -> + { + final LazyHashSet set = new LazyHashSet<>(); + set.add("1"); + return new SetDaoObject(id, set); + }, + set -> set.getValue().add("2") + ), + new TestArguments<>( + SetRepository.class, + id -> + { + final LazyHashSet set = new LazyHashSet<>(); + set.add("1"); + set.add("2"); + return new SetDaoObject(id, set); + }, + set -> set.getValue().add("3") + ), + new TestArguments<>( + ListRepository.class, + id -> new ListDaoObject(id, new LazyArrayList<>()), + object -> object.getValue().add("1") + ), + new TestArguments<>( + ListRepository.class, + id -> + { + final LazyArrayList list = new LazyArrayList<>(); + list.add("1"); + return new ListDaoObject(id, list); + }, + object -> object.getValue().add("2") + ), + new TestArguments<>( + ListRepository.class, + id -> + { + final LazyArrayList list = new LazyArrayList<>(); + list.add("1"); + list.add("2"); + return new ListDaoObject(id, list); + }, + object -> object.getValue().add("3") + ), + new TestArguments<>( + MapRepository.class, + id -> new MapDaoObject(id, new LazyHashMap<>()), + set -> set.getValue().put("1", "1") ) ) ).toArguments(); From fa54897bad74da04c4e6cc6952d9df4a545cf509 Mon Sep 17 00:00:00 2001 From: AB Date: Thu, 14 Mar 2024 16:16:03 +0100 Subject: [PATCH 46/98] Add and use maven wrapper --- .github/workflows/checkBuild.yml | 6 +- .github/workflows/release.yml | 12 +- .github/workflows/sonar.yml | 2 +- .github/workflows/test-deploy.yml | 2 +- .mvn/wrapper/maven-wrapper.properties | 18 ++ CONTRIBUTING.md | 2 +- mvnw | 308 ++++++++++++++++++++++++++ mvnw.cmd | 205 +++++++++++++++++ 8 files changed, 543 insertions(+), 12 deletions(-) create mode 100644 .mvn/wrapper/maven-wrapper.properties create mode 100644 mvnw create mode 100644 mvnw.cmd diff --git a/.github/workflows/checkBuild.yml b/.github/workflows/checkBuild.yml index da4fbd43..d3993c29 100644 --- a/.github/workflows/checkBuild.yml +++ b/.github/workflows/checkBuild.yml @@ -43,7 +43,7 @@ jobs: cache: 'maven' - name: Build with Maven - run: mvn -B clean package + run: ./mvnw -B clean package - name: Check for uncommited changes run: | @@ -59,7 +59,7 @@ jobs: echo ---------------------------------------- echo Troubleshooting echo ---------------------------------------- - echo "::error::Unstaged changes detected. Locally try running: git clean -ffdx && mvn -B clean package" + echo "::error::Unstaged changes detected. Locally try running: git clean -ffdx && ./mvnw -B clean package" exit 1 fi @@ -89,4 +89,4 @@ jobs: cache: 'maven' - name: Run Checkstyle - run: mvn -B checkstyle:check -P checkstyle -T2C + run: ./mvnw -B checkstyle:check -P checkstyle -T2C diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 534759b2..a7e212ab 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -25,7 +25,7 @@ jobs: cache: 'maven' - name: Build with Maven - run: mvn -B clean package + run: ./mvnw -B clean package - name: Check for uncommited changes run: | @@ -41,7 +41,7 @@ jobs: echo ---------------------------------------- echo Troubleshooting echo ---------------------------------------- - echo "::error::Unstaged changes detected. Locally try running: git clean -ffdx && mvn -B clean package" + echo "::error::Unstaged changes detected. Locally try running: git clean -ffdx && ./mvnw -B clean package" exit 1 fi @@ -65,13 +65,13 @@ jobs: for i in "${modules[@]}" do echo "Processing $i/pom.xml" - (cd "$i" && mvn -B versions:set -DremoveSnapshot -DgenerateBackupPoms=false) + (cd "$i" && ../mvnw -B versions:set -DremoveSnapshot -DgenerateBackupPoms=false) done - name: Get version id: version run: | - version=$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout) + version=$(../mvnw help:evaluate -Dexpression=project.version -q -DforceStdout) echo "release=$version" >> $GITHUB_OUTPUT echo "releasenumber=${version//[!0-9]/}" >> $GITHUB_OUTPUT working-directory: ${{ env.PRIMARY_MAVEN_MODULE }} @@ -129,7 +129,7 @@ jobs: gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} - name: Publish to Apache Maven Central - run: mvn -B deploy -Possrh + run: ../mvnw -B deploy -Possrh env: MAVEN_CENTRAL_USERNAME: ${{ secrets.S01_OSS_SONATYPE_MAVEN_USERNAME }} MAVEN_CENTRAL_TOKEN: ${{ secrets.S01_OSS_SONATYPE_MAVEN_TOKEN }} @@ -210,7 +210,7 @@ jobs: for i in "${modules[@]}" do echo "Processing $i/pom.xml" - (cd "$i" && mvn -B build-helper:parse-version versions:set -DnewVersion=\${parsedVersion.majorVersion}.\${parsedVersion.minorVersion}.\${parsedVersion.nextIncrementalVersion} -DgenerateBackupPoms=false -DnextSnapshot=true) + (cd "$i" && ../mvnw -B build-helper:parse-version versions:set -DnewVersion=\${parsedVersion.majorVersion}.\${parsedVersion.minorVersion}.\${parsedVersion.nextIncrementalVersion} -DgenerateBackupPoms=false -DnextSnapshot=true) done - name: Git Commit and Push diff --git a/.github/workflows/sonar.yml b/.github/workflows/sonar.yml index 39335e05..db10f678 100644 --- a/.github/workflows/sonar.yml +++ b/.github/workflows/sonar.yml @@ -56,7 +56,7 @@ jobs: - name: Build with Maven run: | - mvn -B verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar \ + ./mvnw -B verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar \ -DskipTests \ -Dsonar.projectKey=${{ env.SONARCLOUD_ORG }}_${{ github.event.repository.name }} \ -Dsonar.organization=${{ env.SONARCLOUD_ORG }} \ diff --git a/.github/workflows/test-deploy.yml b/.github/workflows/test-deploy.yml index 4e883f82..cdd96cc1 100644 --- a/.github/workflows/test-deploy.yml +++ b/.github/workflows/test-deploy.yml @@ -24,7 +24,7 @@ jobs: gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} - name: Publish to OSSRH - run: mvn -B deploy -Possrh + run: ../mvnw -B deploy -Possrh working-directory: ${{ env.PRIMARY_MAVEN_MODULE }} env: MAVEN_CENTRAL_USERNAME: ${{ secrets.S01_OSS_SONATYPE_MAVEN_USERNAME }} diff --git a/.mvn/wrapper/maven-wrapper.properties b/.mvn/wrapper/maven-wrapper.properties new file mode 100644 index 00000000..eacdc9ed --- /dev/null +++ b/.mvn/wrapper/maven-wrapper.properties @@ -0,0 +1,18 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.5/apache-maven-3.9.5-bin.zip +wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 2f8dd900..cbb31c6b 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -20,7 +20,7 @@ We also encourage you to read the [contribution instructions by GitHub](https:// You should have the following things installed: * Git * Java 21 - should be as unmodified as possible (Recommended: [Eclipse Adoptium](https://adoptium.net/temurin/releases/)) -* Maven +* Maven (Note that the [Maven Wrapper](https://maven.apache.org/wrapper/) is shipped with the repo) ### Recommended setup * Install ``IntelliJ`` (Community Edition is sufficient) diff --git a/mvnw b/mvnw new file mode 100644 index 00000000..8d937f4c --- /dev/null +++ b/mvnw @@ -0,0 +1,308 @@ +#!/bin/sh +# ---------------------------------------------------------------------------- +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you 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. +# ---------------------------------------------------------------------------- + +# ---------------------------------------------------------------------------- +# Apache Maven Wrapper startup batch script, version 3.2.0 +# +# Required ENV vars: +# ------------------ +# JAVA_HOME - location of a JDK home dir +# +# Optional ENV vars +# ----------------- +# MAVEN_OPTS - parameters passed to the Java VM when running Maven +# e.g. to debug Maven itself, use +# set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000 +# MAVEN_SKIP_RC - flag to disable loading of mavenrc files +# ---------------------------------------------------------------------------- + +if [ -z "$MAVEN_SKIP_RC" ] ; then + + if [ -f /usr/local/etc/mavenrc ] ; then + . /usr/local/etc/mavenrc + fi + + if [ -f /etc/mavenrc ] ; then + . /etc/mavenrc + fi + + if [ -f "$HOME/.mavenrc" ] ; then + . "$HOME/.mavenrc" + fi + +fi + +# OS specific support. $var _must_ be set to either true or false. +cygwin=false; +darwin=false; +mingw=false +case "$(uname)" in + CYGWIN*) cygwin=true ;; + MINGW*) mingw=true;; + Darwin*) darwin=true + # Use /usr/libexec/java_home if available, otherwise fall back to /Library/Java/Home + # See https://developer.apple.com/library/mac/qa/qa1170/_index.html + if [ -z "$JAVA_HOME" ]; then + if [ -x "/usr/libexec/java_home" ]; then + JAVA_HOME="$(/usr/libexec/java_home)"; export JAVA_HOME + else + JAVA_HOME="/Library/Java/Home"; export JAVA_HOME + fi + fi + ;; +esac + +if [ -z "$JAVA_HOME" ] ; then + if [ -r /etc/gentoo-release ] ; then + JAVA_HOME=$(java-config --jre-home) + fi +fi + +# For Cygwin, ensure paths are in UNIX format before anything is touched +if $cygwin ; then + [ -n "$JAVA_HOME" ] && + JAVA_HOME=$(cygpath --unix "$JAVA_HOME") + [ -n "$CLASSPATH" ] && + CLASSPATH=$(cygpath --path --unix "$CLASSPATH") +fi + +# For Mingw, ensure paths are in UNIX format before anything is touched +if $mingw ; then + [ -n "$JAVA_HOME" ] && [ -d "$JAVA_HOME" ] && + JAVA_HOME="$(cd "$JAVA_HOME" || (echo "cannot cd into $JAVA_HOME."; exit 1); pwd)" +fi + +if [ -z "$JAVA_HOME" ]; then + javaExecutable="$(which javac)" + if [ -n "$javaExecutable" ] && ! [ "$(expr "\"$javaExecutable\"" : '\([^ ]*\)')" = "no" ]; then + # readlink(1) is not available as standard on Solaris 10. + readLink=$(which readlink) + if [ ! "$(expr "$readLink" : '\([^ ]*\)')" = "no" ]; then + if $darwin ; then + javaHome="$(dirname "\"$javaExecutable\"")" + javaExecutable="$(cd "\"$javaHome\"" && pwd -P)/javac" + else + javaExecutable="$(readlink -f "\"$javaExecutable\"")" + fi + javaHome="$(dirname "\"$javaExecutable\"")" + javaHome=$(expr "$javaHome" : '\(.*\)/bin') + JAVA_HOME="$javaHome" + export JAVA_HOME + fi + fi +fi + +if [ -z "$JAVACMD" ] ; then + if [ -n "$JAVA_HOME" ] ; then + if [ -x "$JAVA_HOME/jre/sh/java" ] ; then + # IBM's JDK on AIX uses strange locations for the executables + JAVACMD="$JAVA_HOME/jre/sh/java" + else + JAVACMD="$JAVA_HOME/bin/java" + fi + else + JAVACMD="$(\unset -f command 2>/dev/null; \command -v java)" + fi +fi + +if [ ! -x "$JAVACMD" ] ; then + echo "Error: JAVA_HOME is not defined correctly." >&2 + echo " We cannot execute $JAVACMD" >&2 + exit 1 +fi + +if [ -z "$JAVA_HOME" ] ; then + echo "Warning: JAVA_HOME environment variable is not set." +fi + +# traverses directory structure from process work directory to filesystem root +# first directory with .mvn subdirectory is considered project base directory +find_maven_basedir() { + if [ -z "$1" ] + then + echo "Path not specified to find_maven_basedir" + return 1 + fi + + basedir="$1" + wdir="$1" + while [ "$wdir" != '/' ] ; do + if [ -d "$wdir"/.mvn ] ; then + basedir=$wdir + break + fi + # workaround for JBEAP-8937 (on Solaris 10/Sparc) + if [ -d "${wdir}" ]; then + wdir=$(cd "$wdir/.." || exit 1; pwd) + fi + # end of workaround + done + printf '%s' "$(cd "$basedir" || exit 1; pwd)" +} + +# concatenates all lines of a file +concat_lines() { + if [ -f "$1" ]; then + # Remove \r in case we run on Windows within Git Bash + # and check out the repository with auto CRLF management + # enabled. Otherwise, we may read lines that are delimited with + # \r\n and produce $'-Xarg\r' rather than -Xarg due to word + # splitting rules. + tr -s '\r\n' ' ' < "$1" + fi +} + +log() { + if [ "$MVNW_VERBOSE" = true ]; then + printf '%s\n' "$1" + fi +} + +BASE_DIR=$(find_maven_basedir "$(dirname "$0")") +if [ -z "$BASE_DIR" ]; then + exit 1; +fi + +MAVEN_PROJECTBASEDIR=${MAVEN_BASEDIR:-"$BASE_DIR"}; export MAVEN_PROJECTBASEDIR +log "$MAVEN_PROJECTBASEDIR" + +########################################################################################## +# Extension to allow automatically downloading the maven-wrapper.jar from Maven-central +# This allows using the maven wrapper in projects that prohibit checking in binary data. +########################################################################################## +wrapperJarPath="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.jar" +if [ -r "$wrapperJarPath" ]; then + log "Found $wrapperJarPath" +else + log "Couldn't find $wrapperJarPath, downloading it ..." + + if [ -n "$MVNW_REPOURL" ]; then + wrapperUrl="$MVNW_REPOURL/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar" + else + wrapperUrl="https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar" + fi + while IFS="=" read -r key value; do + # Remove '\r' from value to allow usage on windows as IFS does not consider '\r' as a separator ( considers space, tab, new line ('\n'), and custom '=' ) + safeValue=$(echo "$value" | tr -d '\r') + case "$key" in (wrapperUrl) wrapperUrl="$safeValue"; break ;; + esac + done < "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.properties" + log "Downloading from: $wrapperUrl" + + if $cygwin; then + wrapperJarPath=$(cygpath --path --windows "$wrapperJarPath") + fi + + if command -v wget > /dev/null; then + log "Found wget ... using wget" + [ "$MVNW_VERBOSE" = true ] && QUIET="" || QUIET="--quiet" + if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then + wget $QUIET "$wrapperUrl" -O "$wrapperJarPath" || rm -f "$wrapperJarPath" + else + wget $QUIET --http-user="$MVNW_USERNAME" --http-password="$MVNW_PASSWORD" "$wrapperUrl" -O "$wrapperJarPath" || rm -f "$wrapperJarPath" + fi + elif command -v curl > /dev/null; then + log "Found curl ... using curl" + [ "$MVNW_VERBOSE" = true ] && QUIET="" || QUIET="--silent" + if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then + curl $QUIET -o "$wrapperJarPath" "$wrapperUrl" -f -L || rm -f "$wrapperJarPath" + else + curl $QUIET --user "$MVNW_USERNAME:$MVNW_PASSWORD" -o "$wrapperJarPath" "$wrapperUrl" -f -L || rm -f "$wrapperJarPath" + fi + else + log "Falling back to using Java to download" + javaSource="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/MavenWrapperDownloader.java" + javaClass="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/MavenWrapperDownloader.class" + # For Cygwin, switch paths to Windows format before running javac + if $cygwin; then + javaSource=$(cygpath --path --windows "$javaSource") + javaClass=$(cygpath --path --windows "$javaClass") + fi + if [ -e "$javaSource" ]; then + if [ ! -e "$javaClass" ]; then + log " - Compiling MavenWrapperDownloader.java ..." + ("$JAVA_HOME/bin/javac" "$javaSource") + fi + if [ -e "$javaClass" ]; then + log " - Running MavenWrapperDownloader.java ..." + ("$JAVA_HOME/bin/java" -cp .mvn/wrapper MavenWrapperDownloader "$wrapperUrl" "$wrapperJarPath") || rm -f "$wrapperJarPath" + fi + fi + fi +fi +########################################################################################## +# End of extension +########################################################################################## + +# If specified, validate the SHA-256 sum of the Maven wrapper jar file +wrapperSha256Sum="" +while IFS="=" read -r key value; do + case "$key" in (wrapperSha256Sum) wrapperSha256Sum=$value; break ;; + esac +done < "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.properties" +if [ -n "$wrapperSha256Sum" ]; then + wrapperSha256Result=false + if command -v sha256sum > /dev/null; then + if echo "$wrapperSha256Sum $wrapperJarPath" | sha256sum -c > /dev/null 2>&1; then + wrapperSha256Result=true + fi + elif command -v shasum > /dev/null; then + if echo "$wrapperSha256Sum $wrapperJarPath" | shasum -a 256 -c > /dev/null 2>&1; then + wrapperSha256Result=true + fi + else + echo "Checksum validation was requested but neither 'sha256sum' or 'shasum' are available." + echo "Please install either command, or disable validation by removing 'wrapperSha256Sum' from your maven-wrapper.properties." + exit 1 + fi + if [ $wrapperSha256Result = false ]; then + echo "Error: Failed to validate Maven wrapper SHA-256, your Maven wrapper might be compromised." >&2 + echo "Investigate or delete $wrapperJarPath to attempt a clean download." >&2 + echo "If you updated your Maven version, you need to update the specified wrapperSha256Sum property." >&2 + exit 1 + fi +fi + +MAVEN_OPTS="$(concat_lines "$MAVEN_PROJECTBASEDIR/.mvn/jvm.config") $MAVEN_OPTS" + +# For Cygwin, switch paths to Windows format before running java +if $cygwin; then + [ -n "$JAVA_HOME" ] && + JAVA_HOME=$(cygpath --path --windows "$JAVA_HOME") + [ -n "$CLASSPATH" ] && + CLASSPATH=$(cygpath --path --windows "$CLASSPATH") + [ -n "$MAVEN_PROJECTBASEDIR" ] && + MAVEN_PROJECTBASEDIR=$(cygpath --path --windows "$MAVEN_PROJECTBASEDIR") +fi + +# Provide a "standardized" way to retrieve the CLI args that will +# work with both Windows and non-Windows executions. +MAVEN_CMD_LINE_ARGS="$MAVEN_CONFIG $*" +export MAVEN_CMD_LINE_ARGS + +WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain + +# shellcheck disable=SC2086 # safe args +exec "$JAVACMD" \ + $MAVEN_OPTS \ + $MAVEN_DEBUG_OPTS \ + -classpath "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.jar" \ + "-Dmaven.multiModuleProjectDirectory=${MAVEN_PROJECTBASEDIR}" \ + ${WRAPPER_LAUNCHER} $MAVEN_CONFIG "$@" diff --git a/mvnw.cmd b/mvnw.cmd new file mode 100644 index 00000000..c4586b56 --- /dev/null +++ b/mvnw.cmd @@ -0,0 +1,205 @@ +@REM ---------------------------------------------------------------------------- +@REM Licensed to the Apache Software Foundation (ASF) under one +@REM or more contributor license agreements. See the NOTICE file +@REM distributed with this work for additional information +@REM regarding copyright ownership. The ASF licenses this file +@REM to you under the Apache License, Version 2.0 (the +@REM "License"); you may not use this file except in compliance +@REM with the License. You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, +@REM software distributed under the License is distributed on an +@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +@REM KIND, either express or implied. See the License for the +@REM specific language governing permissions and limitations +@REM under the License. +@REM ---------------------------------------------------------------------------- + +@REM ---------------------------------------------------------------------------- +@REM Apache Maven Wrapper startup batch script, version 3.2.0 +@REM +@REM Required ENV vars: +@REM JAVA_HOME - location of a JDK home dir +@REM +@REM Optional ENV vars +@REM MAVEN_BATCH_ECHO - set to 'on' to enable the echoing of the batch commands +@REM MAVEN_BATCH_PAUSE - set to 'on' to wait for a keystroke before ending +@REM MAVEN_OPTS - parameters passed to the Java VM when running Maven +@REM e.g. to debug Maven itself, use +@REM set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000 +@REM MAVEN_SKIP_RC - flag to disable loading of mavenrc files +@REM ---------------------------------------------------------------------------- + +@REM Begin all REM lines with '@' in case MAVEN_BATCH_ECHO is 'on' +@echo off +@REM set title of command window +title %0 +@REM enable echoing by setting MAVEN_BATCH_ECHO to 'on' +@if "%MAVEN_BATCH_ECHO%" == "on" echo %MAVEN_BATCH_ECHO% + +@REM set %HOME% to equivalent of $HOME +if "%HOME%" == "" (set "HOME=%HOMEDRIVE%%HOMEPATH%") + +@REM Execute a user defined script before this one +if not "%MAVEN_SKIP_RC%" == "" goto skipRcPre +@REM check for pre script, once with legacy .bat ending and once with .cmd ending +if exist "%USERPROFILE%\mavenrc_pre.bat" call "%USERPROFILE%\mavenrc_pre.bat" %* +if exist "%USERPROFILE%\mavenrc_pre.cmd" call "%USERPROFILE%\mavenrc_pre.cmd" %* +:skipRcPre + +@setlocal + +set ERROR_CODE=0 + +@REM To isolate internal variables from possible post scripts, we use another setlocal +@setlocal + +@REM ==== START VALIDATION ==== +if not "%JAVA_HOME%" == "" goto OkJHome + +echo. +echo Error: JAVA_HOME not found in your environment. >&2 +echo Please set the JAVA_HOME variable in your environment to match the >&2 +echo location of your Java installation. >&2 +echo. +goto error + +:OkJHome +if exist "%JAVA_HOME%\bin\java.exe" goto init + +echo. +echo Error: JAVA_HOME is set to an invalid directory. >&2 +echo JAVA_HOME = "%JAVA_HOME%" >&2 +echo Please set the JAVA_HOME variable in your environment to match the >&2 +echo location of your Java installation. >&2 +echo. +goto error + +@REM ==== END VALIDATION ==== + +:init + +@REM Find the project base dir, i.e. the directory that contains the folder ".mvn". +@REM Fallback to current working directory if not found. + +set MAVEN_PROJECTBASEDIR=%MAVEN_BASEDIR% +IF NOT "%MAVEN_PROJECTBASEDIR%"=="" goto endDetectBaseDir + +set EXEC_DIR=%CD% +set WDIR=%EXEC_DIR% +:findBaseDir +IF EXIST "%WDIR%"\.mvn goto baseDirFound +cd .. +IF "%WDIR%"=="%CD%" goto baseDirNotFound +set WDIR=%CD% +goto findBaseDir + +:baseDirFound +set MAVEN_PROJECTBASEDIR=%WDIR% +cd "%EXEC_DIR%" +goto endDetectBaseDir + +:baseDirNotFound +set MAVEN_PROJECTBASEDIR=%EXEC_DIR% +cd "%EXEC_DIR%" + +:endDetectBaseDir + +IF NOT EXIST "%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config" goto endReadAdditionalConfig + +@setlocal EnableExtensions EnableDelayedExpansion +for /F "usebackq delims=" %%a in ("%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config") do set JVM_CONFIG_MAVEN_PROPS=!JVM_CONFIG_MAVEN_PROPS! %%a +@endlocal & set JVM_CONFIG_MAVEN_PROPS=%JVM_CONFIG_MAVEN_PROPS% + +:endReadAdditionalConfig + +SET MAVEN_JAVA_EXE="%JAVA_HOME%\bin\java.exe" +set WRAPPER_JAR="%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.jar" +set WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain + +set WRAPPER_URL="https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar" + +FOR /F "usebackq tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO ( + IF "%%A"=="wrapperUrl" SET WRAPPER_URL=%%B +) + +@REM Extension to allow automatically downloading the maven-wrapper.jar from Maven-central +@REM This allows using the maven wrapper in projects that prohibit checking in binary data. +if exist %WRAPPER_JAR% ( + if "%MVNW_VERBOSE%" == "true" ( + echo Found %WRAPPER_JAR% + ) +) else ( + if not "%MVNW_REPOURL%" == "" ( + SET WRAPPER_URL="%MVNW_REPOURL%/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar" + ) + if "%MVNW_VERBOSE%" == "true" ( + echo Couldn't find %WRAPPER_JAR%, downloading it ... + echo Downloading from: %WRAPPER_URL% + ) + + powershell -Command "&{"^ + "$webclient = new-object System.Net.WebClient;"^ + "if (-not ([string]::IsNullOrEmpty('%MVNW_USERNAME%') -and [string]::IsNullOrEmpty('%MVNW_PASSWORD%'))) {"^ + "$webclient.Credentials = new-object System.Net.NetworkCredential('%MVNW_USERNAME%', '%MVNW_PASSWORD%');"^ + "}"^ + "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; $webclient.DownloadFile('%WRAPPER_URL%', '%WRAPPER_JAR%')"^ + "}" + if "%MVNW_VERBOSE%" == "true" ( + echo Finished downloading %WRAPPER_JAR% + ) +) +@REM End of extension + +@REM If specified, validate the SHA-256 sum of the Maven wrapper jar file +SET WRAPPER_SHA_256_SUM="" +FOR /F "usebackq tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO ( + IF "%%A"=="wrapperSha256Sum" SET WRAPPER_SHA_256_SUM=%%B +) +IF NOT %WRAPPER_SHA_256_SUM%=="" ( + powershell -Command "&{"^ + "$hash = (Get-FileHash \"%WRAPPER_JAR%\" -Algorithm SHA256).Hash.ToLower();"^ + "If('%WRAPPER_SHA_256_SUM%' -ne $hash){"^ + " Write-Output 'Error: Failed to validate Maven wrapper SHA-256, your Maven wrapper might be compromised.';"^ + " Write-Output 'Investigate or delete %WRAPPER_JAR% to attempt a clean download.';"^ + " Write-Output 'If you updated your Maven version, you need to update the specified wrapperSha256Sum property.';"^ + " exit 1;"^ + "}"^ + "}" + if ERRORLEVEL 1 goto error +) + +@REM Provide a "standardized" way to retrieve the CLI args that will +@REM work with both Windows and non-Windows executions. +set MAVEN_CMD_LINE_ARGS=%* + +%MAVEN_JAVA_EXE% ^ + %JVM_CONFIG_MAVEN_PROPS% ^ + %MAVEN_OPTS% ^ + %MAVEN_DEBUG_OPTS% ^ + -classpath %WRAPPER_JAR% ^ + "-Dmaven.multiModuleProjectDirectory=%MAVEN_PROJECTBASEDIR%" ^ + %WRAPPER_LAUNCHER% %MAVEN_CONFIG% %* +if ERRORLEVEL 1 goto error +goto end + +:error +set ERROR_CODE=1 + +:end +@endlocal & set ERROR_CODE=%ERROR_CODE% + +if not "%MAVEN_SKIP_RC%"=="" goto skipRcPost +@REM check for post script, once with legacy .bat ending and once with .cmd ending +if exist "%USERPROFILE%\mavenrc_post.bat" call "%USERPROFILE%\mavenrc_post.bat" +if exist "%USERPROFILE%\mavenrc_post.cmd" call "%USERPROFILE%\mavenrc_post.cmd" +:skipRcPost + +@REM pause the script if MAVEN_BATCH_PAUSE is set to 'on' +if "%MAVEN_BATCH_PAUSE%"=="on" pause + +if "%MAVEN_TERMINATE_CMD%"=="on" exit %ERROR_CODE% + +cmd /C exit /B %ERROR_CODE% From ee0882ac9f1c701df587da82d9f09d585ccd6c52 Mon Sep 17 00:00:00 2001 From: AB Date: Thu, 14 Mar 2024 16:18:06 +0100 Subject: [PATCH 47/98] Make mvnw executable --- mvnw | 0 1 file changed, 0 insertions(+), 0 deletions(-) mode change 100644 => 100755 mvnw diff --git a/mvnw b/mvnw old mode 100644 new mode 100755 From fd163abe5c447a8c839540448389229e9c41fc9c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 18 Mar 2024 00:53:50 +0000 Subject: [PATCH 48/98] Bump com.puppycrawl.tools:checkstyle from 10.14.1 to 10.14.2 Bumps [com.puppycrawl.tools:checkstyle](https://github.com/checkstyle/checkstyle) from 10.14.1 to 10.14.2. - [Release notes](https://github.com/checkstyle/checkstyle/releases) - [Commits](https://github.com/checkstyle/checkstyle/compare/checkstyle-10.14.1...checkstyle-10.14.2) --- updated-dependencies: - dependency-name: com.puppycrawl.tools:checkstyle dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- standard-maven-template-demo/pom.xml | 2 +- standard-maven-template/pom.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/standard-maven-template-demo/pom.xml b/standard-maven-template-demo/pom.xml index b6bb7ce6..0219b22f 100644 --- a/standard-maven-template-demo/pom.xml +++ b/standard-maven-template-demo/pom.xml @@ -92,7 +92,7 @@ com.puppycrawl.tools checkstyle - 10.14.1 + 10.14.2 diff --git a/standard-maven-template/pom.xml b/standard-maven-template/pom.xml index e8e6a249..a7273ed0 100644 --- a/standard-maven-template/pom.xml +++ b/standard-maven-template/pom.xml @@ -216,7 +216,7 @@ com.puppycrawl.tools checkstyle - 10.14.1 + 10.14.2 From 8129ef16d31beef03d82b832f761864b07c11235 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 18 Mar 2024 01:03:44 +0000 Subject: [PATCH 49/98] Bump com.puppycrawl.tools:checkstyle from 10.14.1 to 10.14.2 Bumps [com.puppycrawl.tools:checkstyle](https://github.com/checkstyle/checkstyle) from 10.14.1 to 10.14.2. - [Release notes](https://github.com/checkstyle/checkstyle/releases) - [Commits](https://github.com/checkstyle/checkstyle/compare/checkstyle-10.14.1...checkstyle-10.14.2) --- updated-dependencies: - dependency-name: com.puppycrawl.tools:checkstyle dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- spring-data-eclipse-store-benchmark/pom.xml | 2 +- spring-data-eclipse-store-demo/pom.xml | 2 +- spring-data-eclipse-store-jpa/pom.xml | 2 +- spring-data-eclipse-store/pom.xml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/spring-data-eclipse-store-benchmark/pom.xml b/spring-data-eclipse-store-benchmark/pom.xml index 513e6e02..5d153d06 100644 --- a/spring-data-eclipse-store-benchmark/pom.xml +++ b/spring-data-eclipse-store-benchmark/pom.xml @@ -96,7 +96,7 @@ com.puppycrawl.tools checkstyle - 10.14.1 + 10.14.2 diff --git a/spring-data-eclipse-store-demo/pom.xml b/spring-data-eclipse-store-demo/pom.xml index 72ff96d7..e5142dcf 100644 --- a/spring-data-eclipse-store-demo/pom.xml +++ b/spring-data-eclipse-store-demo/pom.xml @@ -103,7 +103,7 @@ com.puppycrawl.tools checkstyle - 10.14.1 + 10.14.2 diff --git a/spring-data-eclipse-store-jpa/pom.xml b/spring-data-eclipse-store-jpa/pom.xml index 89fef290..4e5fac89 100644 --- a/spring-data-eclipse-store-jpa/pom.xml +++ b/spring-data-eclipse-store-jpa/pom.xml @@ -123,7 +123,7 @@ com.puppycrawl.tools checkstyle - 10.14.1 + 10.14.2 diff --git a/spring-data-eclipse-store/pom.xml b/spring-data-eclipse-store/pom.xml index 56e25a1b..ca084889 100644 --- a/spring-data-eclipse-store/pom.xml +++ b/spring-data-eclipse-store/pom.xml @@ -339,7 +339,7 @@ com.puppycrawl.tools checkstyle - 10.14.1 + 10.14.2 From 3798841f3e5cdb52178c3f47dbfbf0622094b439 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Mar 2024 00:30:15 +0000 Subject: [PATCH 50/98] Bump org.apache.maven.plugins:maven-compiler-plugin Bumps [org.apache.maven.plugins:maven-compiler-plugin](https://github.com/apache/maven-compiler-plugin) from 3.12.1 to 3.13.0. - [Release notes](https://github.com/apache/maven-compiler-plugin/releases) - [Commits](https://github.com/apache/maven-compiler-plugin/compare/maven-compiler-plugin-3.12.1...maven-compiler-plugin-3.13.0) --- updated-dependencies: - dependency-name: org.apache.maven.plugins:maven-compiler-plugin dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- standard-maven-template-demo/pom.xml | 2 +- standard-maven-template/pom.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/standard-maven-template-demo/pom.xml b/standard-maven-template-demo/pom.xml index b6bb7ce6..b4b091bb 100644 --- a/standard-maven-template-demo/pom.xml +++ b/standard-maven-template-demo/pom.xml @@ -41,7 +41,7 @@ org.apache.maven.plugins maven-compiler-plugin - 3.12.1 + 3.13.0 ${maven.compiler.release} diff --git a/standard-maven-template/pom.xml b/standard-maven-template/pom.xml index e8e6a249..da79080d 100644 --- a/standard-maven-template/pom.xml +++ b/standard-maven-template/pom.xml @@ -118,7 +118,7 @@ org.apache.maven.plugins maven-compiler-plugin - 3.12.1 + 3.13.0 ${maven.compiler.release} From 9f760aa301dea0e29c4891ebc0c9daf47712904a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Mar 2024 00:30:19 +0000 Subject: [PATCH 51/98] Bump org.apache.maven.plugins:maven-gpg-plugin from 3.2.0 to 3.2.1 Bumps [org.apache.maven.plugins:maven-gpg-plugin](https://github.com/apache/maven-gpg-plugin) from 3.2.0 to 3.2.1. - [Release notes](https://github.com/apache/maven-gpg-plugin/releases) - [Commits](https://github.com/apache/maven-gpg-plugin/compare/maven-gpg-plugin-3.2.0...maven-gpg-plugin-3.2.1) --- updated-dependencies: - dependency-name: org.apache.maven.plugins:maven-gpg-plugin dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- standard-maven-template/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/standard-maven-template/pom.xml b/standard-maven-template/pom.xml index e8e6a249..8543eb9b 100644 --- a/standard-maven-template/pom.xml +++ b/standard-maven-template/pom.xml @@ -168,7 +168,7 @@ org.apache.maven.plugins maven-gpg-plugin - 3.2.0 + 3.2.1 sign-artifacts From 2bc07f70c33a1a5e4b329459fae379dd1e123728 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Mar 2024 00:30:23 +0000 Subject: [PATCH 52/98] Bump org.apache.maven.plugins:maven-assembly-plugin from 3.7.0 to 3.7.1 Bumps [org.apache.maven.plugins:maven-assembly-plugin](https://github.com/apache/maven-assembly-plugin) from 3.7.0 to 3.7.1. - [Release notes](https://github.com/apache/maven-assembly-plugin/releases) - [Commits](https://github.com/apache/maven-assembly-plugin/compare/maven-assembly-plugin-3.7.0...maven-assembly-plugin-3.7.1) --- updated-dependencies: - dependency-name: org.apache.maven.plugins:maven-assembly-plugin dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- standard-maven-template-demo/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/standard-maven-template-demo/pom.xml b/standard-maven-template-demo/pom.xml index b6bb7ce6..e8af754c 100644 --- a/standard-maven-template-demo/pom.xml +++ b/standard-maven-template-demo/pom.xml @@ -52,7 +52,7 @@ org.apache.maven.plugins maven-assembly-plugin - 3.7.0 + 3.7.1 From 46f3e686491e282753bb3d712ca20ccf3c274527 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Mar 2024 01:02:14 +0000 Subject: [PATCH 53/98] Bump org.apache.maven.plugins:maven-gpg-plugin from 3.2.0 to 3.2.1 Bumps [org.apache.maven.plugins:maven-gpg-plugin](https://github.com/apache/maven-gpg-plugin) from 3.2.0 to 3.2.1. - [Release notes](https://github.com/apache/maven-gpg-plugin/releases) - [Commits](https://github.com/apache/maven-gpg-plugin/compare/maven-gpg-plugin-3.2.0...maven-gpg-plugin-3.2.1) --- updated-dependencies: - dependency-name: org.apache.maven.plugins:maven-gpg-plugin dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- spring-data-eclipse-store/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spring-data-eclipse-store/pom.xml b/spring-data-eclipse-store/pom.xml index 56e25a1b..23a81511 100644 --- a/spring-data-eclipse-store/pom.xml +++ b/spring-data-eclipse-store/pom.xml @@ -291,7 +291,7 @@ org.apache.maven.plugins maven-gpg-plugin - 3.2.0 + 3.2.1 sign-artifacts From 83470f4d8d70e924099e9db5c77a2ce920c4322f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Mar 2024 01:02:18 +0000 Subject: [PATCH 54/98] Bump org.apache.maven.plugins:maven-compiler-plugin Bumps [org.apache.maven.plugins:maven-compiler-plugin](https://github.com/apache/maven-compiler-plugin) from 3.12.1 to 3.13.0. - [Release notes](https://github.com/apache/maven-compiler-plugin/releases) - [Commits](https://github.com/apache/maven-compiler-plugin/compare/maven-compiler-plugin-3.12.1...maven-compiler-plugin-3.13.0) --- updated-dependencies: - dependency-name: org.apache.maven.plugins:maven-compiler-plugin dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- spring-data-eclipse-store-benchmark/pom.xml | 2 +- spring-data-eclipse-store-demo/pom.xml | 2 +- spring-data-eclipse-store-jpa/pom.xml | 2 +- spring-data-eclipse-store/pom.xml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/spring-data-eclipse-store-benchmark/pom.xml b/spring-data-eclipse-store-benchmark/pom.xml index 513e6e02..c8c2f76e 100644 --- a/spring-data-eclipse-store-benchmark/pom.xml +++ b/spring-data-eclipse-store-benchmark/pom.xml @@ -69,7 +69,7 @@ org.apache.maven.plugins maven-compiler-plugin - 3.12.1 + 3.13.0 ${maven.compiler.release} diff --git a/spring-data-eclipse-store-demo/pom.xml b/spring-data-eclipse-store-demo/pom.xml index 72ff96d7..0453ad56 100644 --- a/spring-data-eclipse-store-demo/pom.xml +++ b/spring-data-eclipse-store-demo/pom.xml @@ -68,7 +68,7 @@ org.apache.maven.plugins maven-compiler-plugin - 3.12.1 + 3.13.0 ${maven.compiler.release} diff --git a/spring-data-eclipse-store-jpa/pom.xml b/spring-data-eclipse-store-jpa/pom.xml index 89fef290..8d35715d 100644 --- a/spring-data-eclipse-store-jpa/pom.xml +++ b/spring-data-eclipse-store-jpa/pom.xml @@ -88,7 +88,7 @@ org.apache.maven.plugins maven-compiler-plugin - 3.12.1 + 3.13.0 ${maven.compiler.release} diff --git a/spring-data-eclipse-store/pom.xml b/spring-data-eclipse-store/pom.xml index 56e25a1b..a5d80b47 100644 --- a/spring-data-eclipse-store/pom.xml +++ b/spring-data-eclipse-store/pom.xml @@ -225,7 +225,7 @@ org.apache.maven.plugins maven-compiler-plugin - 3.12.1 + 3.13.0 ${maven.compiler.release} From 6e1c20ab2e0a262f2d8e7c33f3ddc57837e3c055 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Tue, 19 Mar 2024 10:21:17 +0100 Subject: [PATCH 55/98] Fixed lazy tests --- .../data/eclipse/store/repository/SupportedChecker.java | 8 +++++++- .../isolated/tests/special/types/LazyDaoObject.java | 4 +++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/SupportedChecker.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/SupportedChecker.java index 832ad604..9f143ab3 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/SupportedChecker.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/SupportedChecker.java @@ -20,6 +20,9 @@ import java.util.List; import java.util.WeakHashMap; +import org.eclipse.serializer.collections.lazy.LazyArrayList; +import org.eclipse.serializer.collections.lazy.LazyHashMap; +import org.eclipse.serializer.collections.lazy.LazyHashSet; import org.eclipse.serializer.reference.Lazy; @@ -51,7 +54,10 @@ class Implementation implements SupportedChecker Calendar.class, WeakHashMap.class, // Here EclipseStore has problems too: https://github.com/microstream-one/microstream/issues/204 - EnumMap.class + EnumMap.class, + LazyHashMap.class, + LazyArrayList.class, + LazyHashSet.class ); @Override diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java index 641d8531..ad8f6f8d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java @@ -39,7 +39,9 @@ public boolean equals(final Object o) return false; } final ComplexObject> that = (ComplexObject>)o; - return Objects.equals(this.getId(), that.getId()) && Objects.equals( + return Objects.equals(this.getId(), that.getId()) && + (this.getValue() == null && that.getValue() == null) || + Objects.equals( this.getValue().get(), that.getValue().get()); } From 10f29b844db57ee81e6c815678bec6d16975cc5d Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Wed, 20 Mar 2024 14:05:32 +0100 Subject: [PATCH 56/98] Added tests for lazy handling --- .../LazyNotUnlinkableException.java | 24 +++ .../store/repository/access/AccessHelper.java | 2 +- .../access/modifier/FieldAccessModifier.java | 2 +- .../lazy/SpringDataEclipseStoreLazy.java | 83 ++++++++- ...ringDataEclipseStoreLazyBinaryHandler.java | 4 +- .../support/SimpleEclipseStoreRepository.java | 6 +- .../support/copier/id/SimpleIdSetter.java | 2 +- .../working/RecursiveWorkingCopier.java | 54 ++++-- .../isolated/tests/lazy/LazyTest.java | 165 ++++++++++++++++++ 9 files changed, 311 insertions(+), 31 deletions(-) create mode 100644 spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/LazyNotUnlinkableException.java diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/LazyNotUnlinkableException.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/LazyNotUnlinkableException.java new file mode 100644 index 00000000..8c89e5cc --- /dev/null +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/LazyNotUnlinkableException.java @@ -0,0 +1,24 @@ +/* + * Copyright © 2023 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.exceptions; + +public class LazyNotUnlinkableException extends RuntimeException +{ + public LazyNotUnlinkableException(final String message, final Throwable e) + { + super(message, e); + } +} diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/AccessHelper.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/AccessHelper.java index 29039059..e77ef59f 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/AccessHelper.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/AccessHelper.java @@ -99,7 +99,7 @@ public static Field getInheritedPrivateField(final Class clazz, final String */ public static Object readFieldVariable(final Field field, final T sourceObject) { - try(final FieldAccessModifier fieldAccessModifier = FieldAccessModifier.makeFieldReadable( + try(final FieldAccessModifier fieldAccessModifier = FieldAccessModifier.prepareForField( Objects.requireNonNull(field), Objects.requireNonNull(sourceObject))) { diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/modifier/FieldAccessModifier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/modifier/FieldAccessModifier.java index f6a9b382..bd56de35 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/modifier/FieldAccessModifier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/modifier/FieldAccessModifier.java @@ -24,7 +24,7 @@ */ public interface FieldAccessModifier extends AutoCloseable { - static FieldAccessModifier makeFieldReadable(final Field field, final T sourceObject) + static FieldAccessModifier prepareForField(final Field field, final T sourceObject) { return new FieldAccessibleMaker<>(Objects.requireNonNull(field), Objects.requireNonNull(sourceObject)); } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java index efc67f56..0a246fa3 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java @@ -15,12 +15,16 @@ */ package software.xdev.spring.data.eclipse.store.repository.lazy; +import java.lang.reflect.Field; import java.util.Objects; import org.eclipse.serializer.reference.Lazy; import org.eclipse.serializer.reference.ObjectSwizzling; import org.eclipse.serializer.reference.Swizzling; +import software.xdev.spring.data.eclipse.store.exceptions.LazyNotUnlinkableException; +import software.xdev.spring.data.eclipse.store.repository.access.modifier.FieldAccessModifier; + /** * This is the Lazy-Wrapper a user of the Spring-Data-Eclipse-Store-Library should use. Please do not use the @@ -35,10 +39,22 @@ static SpringDataEclipseStoreLazy.Default build(final T objectToWrapInLaz return new Default<>(objectToWrapInLazy); } - SpringDataEclipseStoreLazy copy(); + SpringDataEclipseStoreLazy copyOnlyWithReference(); + + void unlink(); long objectId(); + boolean isOriginalObject(); + + interface Internals + { + static SpringDataEclipseStoreLazy.Default build(final Lazy lazySubject) + { + return new Default<>(lazySubject); + } + } + /** * This class is very complex and its various membervariables all have their reason to exist. This code is very * difficult to read due to its the functionality explained in the {@link SpringDataEclipseStoreLazyBinaryHandler}. @@ -53,28 +69,44 @@ class Default implements SpringDataEclipseStoreLazy private transient ObjectSwizzling loader; private transient boolean isStored = false; - private Default(final T wrappedObject) + private Default(final Lazy lazySubject) { - this.objectToBeWrapped = wrappedObject; + this.setWrappedLazy(lazySubject); + } + + private Default(final T objectToBeWrapped) + { + this.objectToBeWrapped = objectToBeWrapped; } private Default(final long objectId, final ObjectSwizzling loader) { this.objectId = objectId; this.loader = loader; + // This object is already stored in the real storage. So it can get cleared. + this.setStored(); } private Lazy ensureLazy() { - if(this.wrappedLazy == null) + if(this.wrappedLazy == null || !this.wrappedLazy.isLoaded()) { - Objects.requireNonNull(this.loader); - Objects.requireNonNull(this.objectId); - this.wrappedLazy = Lazy.Reference((T)this.loader.getObject(this.objectId)); + this.wrappedLazy = this.createNewDefaultLazyWithClearableReference(); } return this.wrappedLazy; } + private Lazy createNewDefaultLazyWithClearableReference() + { + Objects.requireNonNull(this.loader); + Objects.requireNonNull(this.objectId); + return Lazy.New( + (T)this.loader.getObject(this.objectId), + Swizzling.nullId(), + this.loader + ); + } + @SuppressWarnings("all") public static final Class> genericType() { @@ -165,6 +197,8 @@ public long objectId() void setWrappedLazy(final Lazy wrappedLazy) { this.wrappedLazy = wrappedLazy; + // This object is already stored in the real storage. So it can get cleared. + this.setStored(); } public T getObjectToBeWrapped() @@ -173,12 +207,43 @@ public T getObjectToBeWrapped() } @Override - public SpringDataEclipseStoreLazy copy() + public SpringDataEclipseStoreLazy copyOnlyWithReference() { return new SpringDataEclipseStoreLazy.Default( - this.objectId, + this.objectId(), this.loader ); } + + // TODO is this necessary? + @Override + public void unlink() + { + try + { + if(this.wrappedLazy != null) + { + final Lazy.Default wrappedDefaultLazy = (Lazy.Default)this.wrappedLazy; + wrappedDefaultLazy.$unlink(); + final Field objectIdField = Lazy.Default.class.getDeclaredField("objectId"); + try(final FieldAccessModifier fam = FieldAccessModifier.prepareForField( + objectIdField, + wrappedDefaultLazy)) + { + fam.writeValueOfField(wrappedDefaultLazy, Swizzling.nullId(), true); + } + } + } + catch(final Exception e) + { + throw new LazyNotUnlinkableException("Could not unlink lazy " + this.wrappedLazy, e); + } + } + + @Override + public boolean isOriginalObject() + { + return this.objectToBeWrapped != null; + } } } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java index 7d061f44..163dd1bd 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java @@ -88,7 +88,7 @@ public void store( ) { data.storeEntityHeader(Binary.referenceBinaryLength(2), this.typeId(), objectId); - if(instance.getObjectToBeWrapped() != null) + if(instance.isOriginalObject()) { // Store unwrapped Object final long newObjectId = handler.applyEager(instance.getObjectToBeWrapped()); @@ -139,6 +139,8 @@ private void updateStateT( if(objectIdOfUnwrappedObject != 0) { instance.setWrappedLazy(Lazy.Reference((T)handler.lookupObject(objectIdOfUnwrappedObject))); + // Is already stored in the main storage. + instance.setStored(); } } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/SimpleEclipseStoreRepository.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/SimpleEclipseStoreRepository.java index b366c873..2672f9d9 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/SimpleEclipseStoreRepository.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/SimpleEclipseStoreRepository.java @@ -151,7 +151,7 @@ public Optional findById(@Nonnull final ID id) { for(final T entity : this.storage.getEntityList(this.domainClass)) { - try(final FieldAccessModifier fam = FieldAccessModifier.makeFieldReadable(this.getIdField(), entity)) + try(final FieldAccessModifier fam = FieldAccessModifier.prepareForField(this.getIdField(), entity)) { if(id.equals(fam.getValueOfField(entity))) { @@ -173,7 +173,7 @@ public boolean existsById(@Nonnull final ID id) { for(final T entity : this.storage.getEntityList(this.domainClass)) { - try(final FieldAccessModifier fam = FieldAccessModifier.makeFieldReadable(this.getIdField(), entity)) + try(final FieldAccessModifier fam = FieldAccessModifier.prepareForField(this.getIdField(), entity)) { if(id.equals(fam.getValueOfField(entity))) { @@ -204,7 +204,7 @@ public List findAllById(@Nonnull final Iterable ids) final List foundEntities = new ArrayList<>(); for(final T entity : this.storage.getEntityList(this.domainClass)) { - try(final FieldAccessModifier fam = FieldAccessModifier.makeFieldReadable(this.getIdField(), entity)) + try(final FieldAccessModifier fam = FieldAccessModifier.prepareForField(this.getIdField(), entity)) { for(final ID id : ids) { diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/SimpleIdSetter.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/SimpleIdSetter.java index 5c7a5975..4be7128d 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/SimpleIdSetter.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/SimpleIdSetter.java @@ -53,7 +53,7 @@ private void checkIfIdFieldIsFinal() @Override public void ensureId(final T objectToSetIdIn) { - try(final FieldAccessModifier fam = FieldAccessModifier.makeFieldReadable( + try(final FieldAccessModifier fam = FieldAccessModifier.prepareForField( this.idField, objectToSetIdIn)) { diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java index 3120009e..8bc48a43 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java @@ -27,6 +27,7 @@ import java.util.TreeMap; import java.util.TreeSet; +import org.eclipse.serializer.reference.Lazy; import org.eclipse.serializer.reference.ObjectSwizzling; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -152,7 +153,7 @@ public E getOrCreateObjectForDatastore( // The object to merge back is not a working copy, but a originalObject. // Therefore, we create a copy to persist this in the storage. final E objectForDatastore = this.genericCopy(workingCopy, true); - // "Why merging values of an identical object?" you might ask. + // "Why merge values of an identical object?" you might ask. // Well, because some sub-objects might already be in the datastore. this.mergeValues(workingCopy, objectForDatastore, alreadyMergedTargets, changedCollector); changedCollector.collectChangedObject(objectForDatastore); @@ -217,7 +218,7 @@ private void mergeValueOfField( return; } - try(final FieldAccessModifier fam = FieldAccessModifier.makeFieldReadable( + try(final FieldAccessModifier fam = FieldAccessModifier.prepareForField( field, sourceObject)) { @@ -262,6 +263,7 @@ else if(DataTypeUtil.isSpringDataEclipseStoreLazy(valueOfSourceObject)) final SpringDataEclipseStoreLazy newLazy = this.createNewLazy( (SpringDataEclipseStoreLazy)valueOfSourceObject, + (SpringDataEclipseStoreLazy)valueOfTargetObject, alreadyMergedTargets, changedCollector); fam.writeValueOfField(targetObject, newLazy, true); @@ -313,25 +315,47 @@ else if(DataTypeUtil.isSpringDataEclipseStoreLazy(valueOfSourceObject)) private SpringDataEclipseStoreLazy createNewLazy( final SpringDataEclipseStoreLazy oldLazy, + final SpringDataEclipseStoreLazy newLazy, final MergedTargetsCollector alreadyMergedTargets, final ChangedObjectCollector changedCollector ) { - if(oldLazy.isLoaded()) - { - final E copyOfWrappedObject = this.getOrCreateObjectForDatastore( - oldLazy.get(), - true, - alreadyMergedTargets, - changedCollector); - return SpringDataEclipseStoreLazy.build(copyOfWrappedObject); - } - else + if(oldLazy.isLoaded()) + { + if(oldLazy.isOriginalObject()) { - // This lazy should never be used again! - // It is though of as a temporary copy to merge back into the original-storage-data. - return oldLazy.copy(); + // This object is new and in this case it is merged into the storage. + if(!newLazy.isStored()) + { + // The EclipseSerializerRegisteringCopier already creates the perfect lazy object. + // No change necessary. + return (SpringDataEclipseStoreLazy)newLazy; + } + else + { + final Lazy newLazyForBuilding = Lazy.Reference(oldLazy.get()); + oldLazy.unlink(); + newLazy.unlink(); + // This object is already stored but the new version must get overwritten. + return SpringDataEclipseStoreLazy.Internals.build(newLazyForBuilding); + } } + final E copyOfWrappedObject = this.getOrCreateObjectForDatastore( + oldLazy.get(), + true, + alreadyMergedTargets, + changedCollector); + oldLazy.unlink(); + newLazy.unlink(); + return SpringDataEclipseStoreLazy.build(copyOfWrappedObject); + } + else + { + oldLazy.unlink(); + // This lazy should never be used again! + // It is though of as a temporary copy to merge back into the original-storage-data. + return (SpringDataEclipseStoreLazy)newLazy.copyOnlyWithReference(); + } } /** diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java index a088bedb..2b36e26e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java @@ -19,10 +19,12 @@ import java.util.ArrayList; import java.util.Arrays; +import java.util.List; import org.eclipse.serializer.collections.lazy.LazyArrayList; import org.eclipse.serializer.collections.lazy.LazyList; import org.eclipse.serializer.reference.Lazy; +import org.eclipse.serializer.reference.LazyReferenceManager; import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Test; @@ -82,6 +84,107 @@ void lazyStore(@Autowired final ObjectWithLazyRepository repositor ); } + @Test + void lazyGetsCleared(@Autowired final ObjectWithLazyRepository repository) + { + final ObjectWithLazy newLazy = new ObjectWithLazy<>(); + final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); + repository.save(newLazy); + + restartDatastore(this.configuration); + + final List> loadedObjects = repository.findAll(); + Assertions.assertEquals(1, loadedObjects.size()); + Assertions.assertFalse(loadedObjects.get(0).getLazy().isLoaded()); + Assertions.assertNotNull(loadedObjects.get(0).getLazy().get()); + Assertions.assertTrue(loadedObjects.get(0).getLazy().isLoaded()); + + LazyReferenceManager.get().clear(); + Assertions.assertFalse(repository.findAll().get(0).getLazy().isLoaded()); + } + + @Test + void lazyWorkingCopyIsCreated(@Autowired final ObjectWithLazyRepository repository) + { + final ObjectWithLazy newLazy = new ObjectWithLazy<>(); + final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); + repository.save(newLazy); + + TestUtil.doBeforeAndAfterRestartOfDatastore( + this.configuration, + () -> { + final SimpleObject storedObject = newLazy.getLazy().get(); + final SimpleObject loadedObject = repository.findAll().get(0).getLazy().get(); + Assertions.assertNotSame(storedObject, loadedObject); + Assertions.assertEquals(storedObject, loadedObject); + } + ); + } + + @Test + void lazyDifferentWorkingCopiesAreCreated(@Autowired final ObjectWithLazyRepository repository) + { + final ObjectWithLazy newLazy = new ObjectWithLazy<>(); + final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); + repository.save(newLazy); + + TestUtil.doBeforeAndAfterRestartOfDatastore( + this.configuration, + () -> { + final ObjectWithLazy workingCopy1 = repository.findAll().get(0); + final ObjectWithLazy workingCopy2 = repository.findAll().get(0); + Assertions.assertNotSame(workingCopy1.getLazy(), workingCopy2.getLazy()); + Assertions.assertNotSame(workingCopy1.getLazy().get(), workingCopy2.getLazy().get()); + Assertions.assertEquals(workingCopy1.getLazy().get(), workingCopy2.getLazy().get()); + } + ); + } + + @Test + void lazyWorkingCopyChange(@Autowired final ObjectWithLazyRepository repository) + { + final ObjectWithLazy newLazy = new ObjectWithLazy<>(); + final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); + repository.save(newLazy); + + final SimpleObject changedObjectToStore = new SimpleObject(TestData.DUMMY_STRING_ALTERNATIVE); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(changedObjectToStore)); + + TestUtil.doBeforeAndAfterRestartOfDatastore( + this.configuration, + () -> { + Assertions.assertNotEquals(newLazy.getLazy().get(), repository.findAll().get(0).getLazy().get()); + } + ); + } + + @Test + void lazyWorkingCopyChangeAfterRestart(@Autowired final ObjectWithLazyRepository repository) + { + final ObjectWithLazy newLazy = new ObjectWithLazy<>(); + final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); + repository.save(newLazy); + + restartDatastore(this.configuration); + + final SimpleObject changedObjectToStore = new SimpleObject(TestData.DUMMY_STRING_ALTERNATIVE); + final ObjectWithLazy objectToChange = repository.findAll().get(0); + objectToChange.setLazy(SpringDataEclipseStoreLazy.build(changedObjectToStore)); + + Assertions.assertNotEquals(objectToChange.getLazy().get(), repository.findAll().get(0).getLazy().get()); + + repository.save(objectToChange); + + final ObjectWithLazy workingCopy1 = repository.findAll().get(0); + final ObjectWithLazy workingCopy2 = repository.findAll().get(0); + Assertions.assertEquals(workingCopy1.getLazy().get(), workingCopy2.getLazy().get()); + } + @Test void lazyStoreComplexObject(@Autowired final ObjectWithLazyRepository repository) { @@ -116,6 +219,55 @@ void lazyStoreComplexObject(@Autowired final ObjectWithLazyRepository repository) + { + final ObjectWithLazy newLazy = new ObjectWithLazy<>(); + final ComplexLazyObject objectToStore = new ComplexLazyObject( + SpringDataEclipseStoreLazy.build(new SimpleObject(TestData.DUMMY_STRING)), + new ArrayList<>(Arrays.asList( + SpringDataEclipseStoreLazy.build(new ArrayList<>(Arrays.asList(TestData.DUMMY_STRING))), + SpringDataEclipseStoreLazy.build(new ArrayList<>(Arrays.asList(TestData.DUMMY_STRING_ALTERNATIVE))) + )) + ); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); + repository.save(newLazy); + + restartDatastore(this.configuration); + + final ObjectWithLazy loadedObjectToChange = repository.findAll().get(0); + loadedObjectToChange + .getLazy() + .get() + .getListOfLazyListOfString() + .add(SpringDataEclipseStoreLazy.build(List.of(TestData.DUMMY_STRING_ALTERNATIVE))); + repository.save(loadedObjectToChange); + + TestUtil.doBeforeAndAfterRestartOfDatastore( + this.configuration, + () -> { + final ObjectWithLazy loadedObject = repository.findAll().get(0); + Assertions.assertNotSame(loadedObjectToChange, loadedObject); + Assertions.assertNotSame( + loadedObjectToChange.getLazy().get(), + loadedObject.getLazy().get() + ); + Assertions.assertEquals( + loadedObjectToChange.getLazy().get().getListOfLazyListOfString().size(), + loadedObject.getLazy().get().getListOfLazyListOfString().size() + ); + Assertions.assertEquals( + loadedObjectToChange.getLazy().get().getListOfLazyListOfString().get(0).get().size(), + loadedObject.getLazy().get().getListOfLazyListOfString().get(0).get().size() + ); + Assertions.assertEquals( + loadedObjectToChange.getLazy().get().getListOfLazyListOfString().get(0).get().get(0), + loadedObject.getLazy().get().getListOfLazyListOfString().get(0).get().get(0) + ); + } + ); + } + @Test void lazyClearBeforeSave() { @@ -154,6 +306,19 @@ void lazyClearAfterSave(@Autowired final ObjectWithLazyRepository ); } + @Test + void lazyClearAfterRestart(@Autowired final ObjectWithLazyRepository repository) + { + final ObjectWithLazy newLazy = new ObjectWithLazy<>(); + final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); + repository.save(newLazy); + + restartDatastore(this.configuration); + + Assertions.assertDoesNotThrow(() -> newLazy.getLazy().clear()); + } + @Test void lazyChangeAfterSave(@Autowired final ObjectWithLazyRepository repository) { From 9b5b2f77ea937b4cff23dc9ae48fab60223c198d Mon Sep 17 00:00:00 2001 From: AB Date: Mon, 25 Mar 2024 08:53:52 +0100 Subject: [PATCH 57/98] Fix mvnw location --- .github/workflows/release.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index a7e212ab..9971f284 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -60,12 +60,13 @@ jobs: - name: Un-SNAP run: | + mvnwPath=$(readlink -f ./mvnw) modules=("") # root modules+=($(grep -ozP '(?<=module>)[^<]+' 'pom.xml' | tr -d '\0')) for i in "${modules[@]}" do echo "Processing $i/pom.xml" - (cd "$i" && ../mvnw -B versions:set -DremoveSnapshot -DgenerateBackupPoms=false) + (cd "$i" && $mvnwPath -B versions:set -DremoveSnapshot -DgenerateBackupPoms=false) done - name: Get version @@ -205,12 +206,13 @@ jobs: - name: Inc Version and SNAP run: | + mvnwPath=$(readlink -f ./mvnw) modules=("") # root modules+=($(grep -ozP '(?<=module>)[^<]+' 'pom.xml' | tr -d '\0')) for i in "${modules[@]}" do echo "Processing $i/pom.xml" - (cd "$i" && ../mvnw -B build-helper:parse-version versions:set -DnewVersion=\${parsedVersion.majorVersion}.\${parsedVersion.minorVersion}.\${parsedVersion.nextIncrementalVersion} -DgenerateBackupPoms=false -DnextSnapshot=true) + (cd "$i" && $mvnwPath -B build-helper:parse-version versions:set -DnewVersion=\${parsedVersion.majorVersion}.\${parsedVersion.minorVersion}.\${parsedVersion.nextIncrementalVersion} -DgenerateBackupPoms=false -DnextSnapshot=true) done - name: Git Commit and Push From c1adfaf8851bf5b956110ff2bcee60f4f90b935b Mon Sep 17 00:00:00 2001 From: AB Date: Tue, 26 Mar 2024 09:26:15 +0100 Subject: [PATCH 58/98] Correct SCM connection info --- standard-maven-template/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/standard-maven-template/pom.xml b/standard-maven-template/pom.xml index c5ce7340..790b6449 100644 --- a/standard-maven-template/pom.xml +++ b/standard-maven-template/pom.xml @@ -15,7 +15,7 @@ https://github.com/xdev-software/standard-maven-template - https://github.com/xdev-software/standard-maven-template.git + scm:git:https://github.com/xdev-software/standard-maven-template.git 2023 From 4e2aa3b725cd987a0855cb8e0e7f53ee82a9d5d1 Mon Sep 17 00:00:00 2001 From: AB Date: Tue, 26 Mar 2024 11:33:22 +0100 Subject: [PATCH 59/98] Improve pages representation * Use newer maven site plugin * Simplify release workflow * Use mvnw * Correct link --- .github/workflows/release.yml | 32 +++----------------------------- README.md | 2 +- standard-maven-template/pom.xml | 14 ++++++++++++++ 3 files changed, 18 insertions(+), 30 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 9971f284..46873c73 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -138,7 +138,6 @@ jobs: working-directory: ${{ env.PRIMARY_MAVEN_MODULE }} publish-pages: - name: Publish dependencies and licenses to github pages runs-on: ubuntu-latest needs: [prepare_release] steps: @@ -157,40 +156,15 @@ jobs: distribution: 'temurin' cache: 'maven' - - name: Build dependencies/licenses files - run: mvn -B project-info-reports:dependencies + - name: Build site + run: ../mvnw -B site working-directory: ${{ env.PRIMARY_MAVEN_MODULE }} - - name: Upload licenses - Upload Artifact - uses: actions/upload-artifact@v4 - with: - name: dependencies-licenses - path: ${{ env.PRIMARY_MAVEN_MODULE }}/target/site - - - name: Generate docs/dependencies dir - run: mkdir -p docs/dependencies - - - name: Move built files into docs/dependencies - run: mv ${{ env.PRIMARY_MAVEN_MODULE }}/target/site/* docs/dependencies - - - name: Rename dependencies.html to index.html - working-directory: docs/dependencies - run: mv dependencies.html index.html - - - name: Copy Readme into docs (as index.md) - run: cp README.md docs/index.md - - - name: Configure Pages - working-directory: docs - run: |- - echo "theme: jekyll-theme-tactile" > _config.yml - - name: Deploy to Github pages uses: peaceiris/actions-gh-pages@v3 with: github_token: ${{ secrets.GITHUB_TOKEN }} - publish_dir: ./docs - enable_jekyll: true + publish_dir: ./${{ env.PRIMARY_MAVEN_MODULE }}/target/site after_release: runs-on: ubuntu-latest diff --git a/README.md b/README.md index b90c3ebd..db9412b5 100644 --- a/README.md +++ b/README.md @@ -16,4 +16,4 @@ If you need support as soon as possible and you can't wait for any pull request, See the [contributing guide](./CONTRIBUTING.md) for detailed instructions on how to get started with our project. ## Dependencies and Licenses -View the [license of the current project](LICENSE) or the [summary including all dependencies](https://xdev-software.github.io/standard-maven-template/dependencies/) +View the [license of the current project](LICENSE) or the [summary including all dependencies](https://xdev-software.github.io/standard-maven-template/dependencies) diff --git a/standard-maven-template/pom.xml b/standard-maven-template/pom.xml index 790b6449..1cd4ae64 100644 --- a/standard-maven-template/pom.xml +++ b/standard-maven-template/pom.xml @@ -85,6 +85,20 @@ + + + + org.apache.maven.plugins + maven-site-plugin + 4.0.0-M13 + + + org.apache.maven.plugins + maven-project-info-reports-plugin + 3.5.0 + + + com.mycila From 913db08a9455977137e232c05f8a3d839bf632cd Mon Sep 17 00:00:00 2001 From: Alex B <45384811+AB-xdev@users.noreply.github.com> Date: Tue, 26 Mar 2024 11:34:24 +0100 Subject: [PATCH 60/98] Update checkstyle-idea.xml Plugin saves file without linebreak at end -> Remove so that no git changes are detected --- .idea/checkstyle-idea.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.idea/checkstyle-idea.xml b/.idea/checkstyle-idea.xml index 9a5d4ffe..5c1e5281 100644 --- a/.idea/checkstyle-idea.xml +++ b/.idea/checkstyle-idea.xml @@ -1,7 +1,7 @@ - 10.12.5 + 10.14.0 JavaOnlyWithTests true true @@ -17,4 +17,4 @@ - + \ No newline at end of file From bc0cd3a944beef72e402f31a29d18f960bdaf887 Mon Sep 17 00:00:00 2001 From: AB Date: Tue, 26 Mar 2024 11:47:10 +0100 Subject: [PATCH 61/98] Update maven-gpg-plugin --- standard-maven-template/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/standard-maven-template/pom.xml b/standard-maven-template/pom.xml index 1cd4ae64..e84ddff8 100644 --- a/standard-maven-template/pom.xml +++ b/standard-maven-template/pom.xml @@ -182,7 +182,7 @@ org.apache.maven.plugins maven-gpg-plugin - 3.2.1 + 3.2.2 sign-artifacts From b2a23b191ccad41f0621dc197503591274e30494 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 2 Apr 2024 00:21:42 +0000 Subject: [PATCH 62/98] Bump com.puppycrawl.tools:checkstyle from 10.14.2 to 10.15.0 Bumps [com.puppycrawl.tools:checkstyle](https://github.com/checkstyle/checkstyle) from 10.14.2 to 10.15.0. - [Release notes](https://github.com/checkstyle/checkstyle/releases) - [Commits](https://github.com/checkstyle/checkstyle/compare/checkstyle-10.14.2...checkstyle-10.15.0) --- updated-dependencies: - dependency-name: com.puppycrawl.tools:checkstyle dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- standard-maven-template-demo/pom.xml | 2 +- standard-maven-template/pom.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/standard-maven-template-demo/pom.xml b/standard-maven-template-demo/pom.xml index 2e466d4a..0a4432db 100644 --- a/standard-maven-template-demo/pom.xml +++ b/standard-maven-template-demo/pom.xml @@ -92,7 +92,7 @@ com.puppycrawl.tools checkstyle - 10.14.2 + 10.15.0 diff --git a/standard-maven-template/pom.xml b/standard-maven-template/pom.xml index e84ddff8..b7b0fc34 100644 --- a/standard-maven-template/pom.xml +++ b/standard-maven-template/pom.xml @@ -230,7 +230,7 @@ com.puppycrawl.tools checkstyle - 10.14.2 + 10.15.0 From 0af9590c417fb708ffe83f838f5308c9652143d3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 5 Apr 2024 00:42:48 +0000 Subject: [PATCH 63/98] Bump org.apache.maven.plugins:maven-source-plugin from 3.3.0 to 3.3.1 Bumps [org.apache.maven.plugins:maven-source-plugin](https://github.com/apache/maven-source-plugin) from 3.3.0 to 3.3.1. - [Commits](https://github.com/apache/maven-source-plugin/compare/maven-source-plugin-3.3.0...maven-source-plugin-3.3.1) --- updated-dependencies: - dependency-name: org.apache.maven.plugins:maven-source-plugin dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- standard-maven-template/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/standard-maven-template/pom.xml b/standard-maven-template/pom.xml index b7b0fc34..f25578ad 100644 --- a/standard-maven-template/pom.xml +++ b/standard-maven-template/pom.xml @@ -161,7 +161,7 @@ org.apache.maven.plugins maven-source-plugin - 3.3.0 + 3.3.1 attach-sources From 8f204f5650eebdde102beb935053fac8be9a4105 Mon Sep 17 00:00:00 2001 From: AB Date: Wed, 10 Apr 2024 13:11:40 +0200 Subject: [PATCH 64/98] Introduce Renovate --- .github/dependabot.yml | 22 ---------------------- renovate.json5 | 4 ++++ 2 files changed, 4 insertions(+), 22 deletions(-) delete mode 100644 .github/dependabot.yml create mode 100644 renovate.json5 diff --git a/.github/dependabot.yml b/.github/dependabot.yml deleted file mode 100644 index 28d6d7b3..00000000 --- a/.github/dependabot.yml +++ /dev/null @@ -1,22 +0,0 @@ -version: 2 -updates: -- package-ecosystem: github-actions - directory: "/" - schedule: - interval: daily - # Run it at a specific time so that we don't get emails all day long - time: "00:00" - open-pull-requests-limit: 10 - ignore: - - dependency-name: "*" - # GitHub actions are using git tags (v1 = v1.2 = v1.2.3) which should be compatible until a major change is performed - update-types: - - "version-update:semver-minor" - - "version-update:semver-patch" -- package-ecosystem: maven - directory: "/" - schedule: - interval: daily - # Run it at a specific time so that we don't get emails all day long - time: "00:00" - open-pull-requests-limit: 10 diff --git a/renovate.json5 b/renovate.json5 new file mode 100644 index 00000000..11a77b2a --- /dev/null +++ b/renovate.json5 @@ -0,0 +1,4 @@ +{ + "$schema": "https://docs.renovatebot.com/renovate-schema.json", + "rebaseWhen": "behind-base-branch" +} From 84e5c3875da79de06f79ce1bbbf58c6d31ec6010 Mon Sep 17 00:00:00 2001 From: XDEV Renovate Bot Date: Wed, 10 Apr 2024 11:18:26 +0000 Subject: [PATCH 65/98] Update dependency maven to v3.9.6 --- .mvn/wrapper/maven-wrapper.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.mvn/wrapper/maven-wrapper.properties b/.mvn/wrapper/maven-wrapper.properties index eacdc9ed..346d645f 100644 --- a/.mvn/wrapper/maven-wrapper.properties +++ b/.mvn/wrapper/maven-wrapper.properties @@ -14,5 +14,5 @@ # KIND, either express or implied. See the License for the # specific language governing permissions and limitations # under the License. -distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.5/apache-maven-3.9.5-bin.zip +distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.6/apache-maven-3.9.6-bin.zip wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar From a27c4efe8b86e58a5eb28e49e0192aec6a13a714 Mon Sep 17 00:00:00 2001 From: XDEV Renovate Bot Date: Wed, 10 Apr 2024 11:18:27 +0000 Subject: [PATCH 66/98] Update peaceiris/actions-gh-pages action to v4 --- .github/workflows/release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 46873c73..4ad042f4 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -161,7 +161,7 @@ jobs: working-directory: ${{ env.PRIMARY_MAVEN_MODULE }} - name: Deploy to Github pages - uses: peaceiris/actions-gh-pages@v3 + uses: peaceiris/actions-gh-pages@v4 with: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./${{ env.PRIMARY_MAVEN_MODULE }}/target/site From 4865729466fda65da0fcc02386fa8b987c36d451 Mon Sep 17 00:00:00 2001 From: AB Date: Wed, 10 Apr 2024 13:22:12 +0200 Subject: [PATCH 67/98] Modify workflows for renovate --- .github/workflows/checkBuild.yml | 1 + .github/workflows/sonar.yml | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/checkBuild.yml b/.github/workflows/checkBuild.yml index d3993c29..fa9b7f5d 100644 --- a/.github/workflows/checkBuild.yml +++ b/.github/workflows/checkBuild.yml @@ -72,6 +72,7 @@ jobs: code-style: runs-on: ubuntu-latest + if: ${{ github.event_name != 'pull_request' || !startsWith(github.head_ref, 'renovate/') }} strategy: matrix: diff --git a/.github/workflows/sonar.yml b/.github/workflows/sonar.yml index db10f678..1c9b0f8d 100644 --- a/.github/workflows/sonar.yml +++ b/.github/workflows/sonar.yml @@ -27,8 +27,7 @@ jobs: sonar: name: SonarCloud Scan runs-on: ubuntu-latest - # Dependabot PRs have no access to secrets (SONAR_TOKEN) -> Ignore them - if: ${{ github.event_name != 'pull_request' || !startsWith(github.head_ref, 'dependabot/') }} + if: ${{ github.event_name != 'pull_request' || !startsWith(github.head_ref, 'renovate/') }} steps: - uses: actions/checkout@v4 with: From d21aae6a70a926740e6448eda93e894efa2b2712 Mon Sep 17 00:00:00 2001 From: XDEV Renovate Bot Date: Thu, 11 Apr 2024 07:27:55 +0000 Subject: [PATCH 68/98] Update dependency org.apache.maven.plugins:maven-gpg-plugin to v3.2.3 --- standard-maven-template/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/standard-maven-template/pom.xml b/standard-maven-template/pom.xml index f25578ad..5ee52759 100644 --- a/standard-maven-template/pom.xml +++ b/standard-maven-template/pom.xml @@ -182,7 +182,7 @@ org.apache.maven.plugins maven-gpg-plugin - 3.2.2 + 3.2.3 sign-artifacts From b0ba58a976cf3bfffd9cfee7f8bdf1dee22df941 Mon Sep 17 00:00:00 2001 From: XDEV Renovate Bot Date: Thu, 11 Apr 2024 07:35:37 +0000 Subject: [PATCH 69/98] Update dependency com.puppycrawl.tools:checkstyle to v10.15.0 --- spring-data-eclipse-store-benchmark/pom.xml | 2 +- spring-data-eclipse-store-jpa/pom.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/spring-data-eclipse-store-benchmark/pom.xml b/spring-data-eclipse-store-benchmark/pom.xml index 14e39783..f9de8f91 100644 --- a/spring-data-eclipse-store-benchmark/pom.xml +++ b/spring-data-eclipse-store-benchmark/pom.xml @@ -96,7 +96,7 @@ com.puppycrawl.tools checkstyle - 10.14.2 + 10.15.0 diff --git a/spring-data-eclipse-store-jpa/pom.xml b/spring-data-eclipse-store-jpa/pom.xml index e658a530..7a935836 100644 --- a/spring-data-eclipse-store-jpa/pom.xml +++ b/spring-data-eclipse-store-jpa/pom.xml @@ -123,7 +123,7 @@ com.puppycrawl.tools checkstyle - 10.14.2 + 10.15.0 From d1748a5779236e34017842ac8c2c759448261cad Mon Sep 17 00:00:00 2001 From: Alex B <45384811+AB-xdev@users.noreply.github.com> Date: Tue, 16 Apr 2024 08:43:54 +0200 Subject: [PATCH 70/98] Update pom.xml Remove unused inception year in demo --- standard-maven-template-demo/pom.xml | 2 -- 1 file changed, 2 deletions(-) diff --git a/standard-maven-template-demo/pom.xml b/standard-maven-template-demo/pom.xml index 0a4432db..a401ade8 100644 --- a/standard-maven-template-demo/pom.xml +++ b/standard-maven-template-demo/pom.xml @@ -9,8 +9,6 @@ 1.0.0-SNAPSHOT jar - 2022 - XDEV Software https://xdev.software From 6b8f038eaba707d872ae88ac5cbcf9d11a9fb5f7 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Wed, 17 Apr 2024 12:53:24 +0200 Subject: [PATCH 71/98] Most tests for lazy working --- .../store/repository/WorkingCopyRegistry.java | 3 +++ .../repository/lazy/SpringDataEclipseStoreLazy.java | 11 ++++++++--- .../SpringDataEclipseStoreLazyBinaryHandler.java | 13 ++++++++++--- .../copier/copier/AbstractRegisteringCopier.java | 2 +- 4 files changed, 22 insertions(+), 7 deletions(-) diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/WorkingCopyRegistry.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/WorkingCopyRegistry.java index 6f2b0b56..9674fdb7 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/WorkingCopyRegistry.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/WorkingCopyRegistry.java @@ -27,6 +27,9 @@ public class WorkingCopyRegistry { private static final Logger LOG = LoggerFactory.getLogger(WorkingCopyRegistry.class); + /** + * Map with Working Copies (key) with the corresponding original object (value). + */ private Map currentWorkingCopies = new IdentityHashMap<>(); /** diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java index 0a246fa3..37f04934 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java @@ -24,6 +24,7 @@ import software.xdev.spring.data.eclipse.store.exceptions.LazyNotUnlinkableException; import software.xdev.spring.data.eclipse.store.repository.access.modifier.FieldAccessModifier; +import software.xdev.spring.data.eclipse.store.repository.support.copier.copier.RegisteringObjectCopier; /** @@ -67,6 +68,7 @@ class Default implements SpringDataEclipseStoreLazy private Lazy wrappedLazy; private long objectId = Swizzling.notFoundId(); private transient ObjectSwizzling loader; + private transient RegisteringObjectCopier copier; private transient boolean isStored = false; private Default(final Lazy lazySubject) @@ -79,10 +81,11 @@ private Default(final T objectToBeWrapped) this.objectToBeWrapped = objectToBeWrapped; } - private Default(final long objectId, final ObjectSwizzling loader) + private Default(final long objectId, final ObjectSwizzling loader, final RegisteringObjectCopier copier) { this.objectId = objectId; this.loader = loader; + this.copier = copier; // This object is already stored in the real storage. So it can get cleared. this.setStored(); } @@ -100,8 +103,9 @@ private Lazy createNewDefaultLazyWithClearableReference() { Objects.requireNonNull(this.loader); Objects.requireNonNull(this.objectId); + Objects.requireNonNull(this.copier); return Lazy.New( - (T)this.loader.getObject(this.objectId), + (T)this.copier.copy(this.loader.getObject(this.objectId)), Swizzling.nullId(), this.loader ); @@ -211,7 +215,8 @@ public SpringDataEclipseStoreLazy copyOnlyWithReference() { return new SpringDataEclipseStoreLazy.Default( this.objectId(), - this.loader + this.loader, + this.copier ); } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java index 163dd1bd..d591e5dc 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java @@ -29,6 +29,8 @@ import org.eclipse.serializer.reference.ObjectSwizzling; import org.eclipse.serializer.reflect.XReflect; +import software.xdev.spring.data.eclipse.store.repository.support.copier.copier.RegisteringObjectCopier; + /** * This is a complicated one. First off: this handler should only be used for WorkingCopies (see @@ -58,7 +60,8 @@ public final class SpringDataEclipseStoreLazyBinaryHandler XReflect.getDeclaredConstructor( SpringDataEclipseStoreLazy.Default.class, long.class, - ObjectSwizzling.class + ObjectSwizzling.class, + RegisteringObjectCopier.class ) ); @@ -66,8 +69,11 @@ public final class SpringDataEclipseStoreLazyBinaryHandler public static final int OFFSET_LAZY = 0; private final ObjectSwizzling originalStoreLoader; + private final RegisteringObjectCopier copier; - public SpringDataEclipseStoreLazyBinaryHandler(final ObjectSwizzling originalStoreLoader) + public SpringDataEclipseStoreLazyBinaryHandler( + final ObjectSwizzling originalStoreLoader, + final RegisteringObjectCopier copier) { super( SpringDataEclipseStoreLazy.Default.genericType(), @@ -77,6 +83,7 @@ public SpringDataEclipseStoreLazyBinaryHandler(final ObjectSwizzling originalSto ) ); this.originalStoreLoader = Objects.requireNonNull(originalStoreLoader); + this.copier = copier; } @Override @@ -112,7 +119,7 @@ public SpringDataEclipseStoreLazy.Default create(final Binary data, final Per if(objectIdOfUnwrappedObject == 0) { return Lazy.register( - XReflect.invoke(CONSTRUCTOR_SURROGATE_LAZY, objectIdOfLazy, this.originalStoreLoader) + XReflect.invoke(CONSTRUCTOR_SURROGATE_LAZY, objectIdOfLazy, this.originalStoreLoader, this.copier) ); } return XMemory.instantiateBlank(SpringDataEclipseStoreLazy.Default.class); diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java index 65147ba3..945ef8e6 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java @@ -59,7 +59,7 @@ private PersistenceManager createPersistenceManager( return serializerFoundation .registerCustomTypeHandler(BinaryHandlerImmutableCollectionsSet12.New()) .registerCustomTypeHandler(BinaryHandlerImmutableCollectionsList12.New()) - .registerCustomTypeHandlers(new SpringDataEclipseStoreLazyBinaryHandler(objectSwizzling)) + .registerCustomTypeHandlers(new SpringDataEclipseStoreLazyBinaryHandler(objectSwizzling, this)) .createPersistenceManager(); } From 66507b7722dc48907273ff6dce848e0d3482dd97 Mon Sep 17 00:00:00 2001 From: Alex B <45384811+AB-xdev@users.noreply.github.com> Date: Thu, 18 Apr 2024 09:37:24 +0200 Subject: [PATCH 72/98] Remove invalid space --- LICENSE | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/LICENSE b/LICENSE index 864bb41e..ccaa2b3a 100644 --- a/LICENSE +++ b/LICENSE @@ -186,7 +186,7 @@ same "printed page" as the copyright notice for easier identification within third-party archives. - Copyright 2024 XDEV Software + Copyright 2024 XDEV Software Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. From 5335fac88c90bd54eff58ef21af10f48abe02933 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Thu, 18 Apr 2024 15:06:06 +0200 Subject: [PATCH 73/98] Lazy working with tests --- .../store/repository/EclipseStoreStorage.java | 2 + .../lazy/SpringDataEclipseStoreLazy.java | 24 ++++++---- ...ringDataEclipseStoreLazyBinaryHandler.java | 8 ++-- .../copier/AbstractRegisteringCopier.java | 12 +++-- ...RegisteringStorageToWorkingCopyCopier.java | 7 ++- ...RegisteringWorkingCopyToStorageCopier.java | 7 ++- .../working/RecursiveWorkingCopier.java | 27 ++++++++---- .../support/copier/working/WorkingCopier.java | 2 + .../store/helper/DummyWorkingCopier.java | 6 +++ .../isolated/tests/lazy/LazyTest.java | 44 +++++++++++++++++++ ...steringStorageToWorkingCopyCopierTest.java | 15 ++++--- 11 files changed, 120 insertions(+), 34 deletions(-) diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java index 07b06e8a..b4d8145f 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java @@ -26,6 +26,7 @@ import org.eclipse.serializer.persistence.binary.jdk17.java.util.BinaryHandlerImmutableCollectionsList12; import org.eclipse.serializer.persistence.binary.jdk17.java.util.BinaryHandlerImmutableCollectionsSet12; import org.eclipse.serializer.persistence.types.Storer; +import org.eclipse.serializer.reference.LazyReferenceManager; import org.eclipse.serializer.reference.ObjectSwizzling; import org.eclipse.store.storage.embedded.types.EmbeddedStorageFoundation; import org.eclipse.store.storage.types.StorageManager; @@ -273,6 +274,7 @@ public synchronized void stop() this.registry.reset(); this.entityClassToIdSetter.clear(); LOG.info("Stopped storage."); + LazyReferenceManager.get().stop(); } else { diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java index 37f04934..fef25ac7 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java @@ -24,7 +24,7 @@ import software.xdev.spring.data.eclipse.store.exceptions.LazyNotUnlinkableException; import software.xdev.spring.data.eclipse.store.repository.access.modifier.FieldAccessModifier; -import software.xdev.spring.data.eclipse.store.repository.support.copier.copier.RegisteringObjectCopier; +import software.xdev.spring.data.eclipse.store.repository.support.copier.working.WorkingCopier; /** @@ -40,7 +40,7 @@ static SpringDataEclipseStoreLazy.Default build(final T objectToWrapInLaz return new Default<>(objectToWrapInLazy); } - SpringDataEclipseStoreLazy copyOnlyWithReference(); + SpringDataEclipseStoreLazy copyWithReference(); void unlink(); @@ -50,7 +50,7 @@ static SpringDataEclipseStoreLazy.Default build(final T objectToWrapInLaz interface Internals { - static SpringDataEclipseStoreLazy.Default build(final Lazy lazySubject) + static SpringDataEclipseStoreLazy.Default buildWithLazy(final Lazy lazySubject) { return new Default<>(lazySubject); } @@ -68,7 +68,7 @@ class Default implements SpringDataEclipseStoreLazy private Lazy wrappedLazy; private long objectId = Swizzling.notFoundId(); private transient ObjectSwizzling loader; - private transient RegisteringObjectCopier copier; + private transient WorkingCopier copier; private transient boolean isStored = false; private Default(final Lazy lazySubject) @@ -81,7 +81,7 @@ private Default(final T objectToBeWrapped) this.objectToBeWrapped = objectToBeWrapped; } - private Default(final long objectId, final ObjectSwizzling loader, final RegisteringObjectCopier copier) + private Default(final long objectId, final ObjectSwizzling loader, final WorkingCopier copier) { this.objectId = objectId; this.loader = loader; @@ -104,8 +104,12 @@ private Lazy createNewDefaultLazyWithClearableReference() Objects.requireNonNull(this.loader); Objects.requireNonNull(this.objectId); Objects.requireNonNull(this.copier); + + final T originalInstance = (T)this.loader.getObject(this.objectId); + final T copiedInstance = this.copier.onlyCreateCopy(originalInstance, false); + return Lazy.New( - (T)this.copier.copy(this.loader.getObject(this.objectId)), + copiedInstance, Swizzling.nullId(), this.loader ); @@ -211,13 +215,15 @@ public T getObjectToBeWrapped() } @Override - public SpringDataEclipseStoreLazy copyOnlyWithReference() + public SpringDataEclipseStoreLazy copyWithReference() { - return new SpringDataEclipseStoreLazy.Default( + final SpringDataEclipseStoreLazy.Default newLazy = new SpringDataEclipseStoreLazy.Default( this.objectId(), this.loader, this.copier ); + newLazy.wrappedLazy = this.wrappedLazy; + return newLazy; } // TODO is this necessary? @@ -235,6 +241,8 @@ public void unlink() objectIdField, wrappedDefaultLazy)) { + // The lazy object should be seen as "stored" by the LazyManager. + // Therefore, we must set the objectId to Swizzling.nullId(). fam.writeValueOfField(wrappedDefaultLazy, Swizzling.nullId(), true); } } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java index d591e5dc..13324385 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java @@ -29,7 +29,7 @@ import org.eclipse.serializer.reference.ObjectSwizzling; import org.eclipse.serializer.reflect.XReflect; -import software.xdev.spring.data.eclipse.store.repository.support.copier.copier.RegisteringObjectCopier; +import software.xdev.spring.data.eclipse.store.repository.support.copier.working.WorkingCopier; /** @@ -61,7 +61,7 @@ public final class SpringDataEclipseStoreLazyBinaryHandler SpringDataEclipseStoreLazy.Default.class, long.class, ObjectSwizzling.class, - RegisteringObjectCopier.class + WorkingCopier.class ) ); @@ -69,11 +69,11 @@ public final class SpringDataEclipseStoreLazyBinaryHandler public static final int OFFSET_LAZY = 0; private final ObjectSwizzling originalStoreLoader; - private final RegisteringObjectCopier copier; + private final WorkingCopier copier; public SpringDataEclipseStoreLazyBinaryHandler( final ObjectSwizzling originalStoreLoader, - final RegisteringObjectCopier copier) + final WorkingCopier copier) { super( SpringDataEclipseStoreLazy.Default.genericType(), diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java index 945ef8e6..51ef272e 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java @@ -27,6 +27,7 @@ import software.xdev.spring.data.eclipse.store.repository.SupportedChecker; import software.xdev.spring.data.eclipse.store.repository.lazy.SpringDataEclipseStoreLazyBinaryHandler; +import software.xdev.spring.data.eclipse.store.repository.support.copier.working.WorkingCopier; /** @@ -40,26 +41,29 @@ public abstract class AbstractRegisteringCopier implements RegisteringObjectCopi public AbstractRegisteringCopier( final SupportedChecker supportedChecker, final RegisteringWorkingCopyAndOriginal register, - final ObjectSwizzling objectSwizzling) + final ObjectSwizzling objectSwizzling, + final WorkingCopier copier) { this.actualCopier = new EclipseSerializerRegisteringCopier( supportedChecker, register, this.createPersistenceManager( this.createSerializerFoundation(), - objectSwizzling + objectSwizzling, + copier ) ); } private PersistenceManager createPersistenceManager( final SerializerFoundation serializerFoundation, - final ObjectSwizzling objectSwizzling) + final ObjectSwizzling objectSwizzling, + final WorkingCopier copier) { return serializerFoundation .registerCustomTypeHandler(BinaryHandlerImmutableCollectionsSet12.New()) .registerCustomTypeHandler(BinaryHandlerImmutableCollectionsList12.New()) - .registerCustomTypeHandlers(new SpringDataEclipseStoreLazyBinaryHandler(objectSwizzling, this)) + .registerCustomTypeHandlers(new SpringDataEclipseStoreLazyBinaryHandler(objectSwizzling, copier)) .createPersistenceManager(); } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java index 49a55b86..11084ac4 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java @@ -19,6 +19,7 @@ import software.xdev.spring.data.eclipse.store.repository.SupportedChecker; import software.xdev.spring.data.eclipse.store.repository.WorkingCopyRegistry; +import software.xdev.spring.data.eclipse.store.repository.support.copier.working.WorkingCopier; /** @@ -30,12 +31,14 @@ public class RegisteringStorageToWorkingCopyCopier extends AbstractRegisteringCo public RegisteringStorageToWorkingCopyCopier( final WorkingCopyRegistry registry, final SupportedChecker supportedChecker, - final ObjectSwizzling objectSwizzling) + final ObjectSwizzling objectSwizzling, + final WorkingCopier copier) { super( supportedChecker, (workingCopy, objectToStore) -> registry.register(workingCopy, objectToStore), - objectSwizzling + objectSwizzling, + copier ); } } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java index fd5f8d5b..e137ff5c 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java @@ -19,6 +19,7 @@ import software.xdev.spring.data.eclipse.store.repository.SupportedChecker; import software.xdev.spring.data.eclipse.store.repository.WorkingCopyRegistry; +import software.xdev.spring.data.eclipse.store.repository.support.copier.working.WorkingCopier; /** @@ -31,12 +32,14 @@ public class RegisteringWorkingCopyToStorageCopier extends AbstractRegisteringCo public RegisteringWorkingCopyToStorageCopier( final WorkingCopyRegistry registry, final SupportedChecker supportedChecker, - final ObjectSwizzling objectSwizzling) + final ObjectSwizzling objectSwizzling, + final WorkingCopier copier) { super( supportedChecker, (workingCopy, objectToStore) -> registry.invertRegister(workingCopy, objectToStore), - objectSwizzling + objectSwizzling, + copier ); } } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java index 8bc48a43..25279520 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java @@ -70,9 +70,9 @@ public RecursiveWorkingCopier( this.domainClass = domainClass; this.registry = registry; this.workingCopyToStorageCopier = - new RegisteringWorkingCopyToStorageCopier(registry, supportedChecker, objectSwizzling); + new RegisteringWorkingCopyToStorageCopier(registry, supportedChecker, objectSwizzling, this); this.storageToWorkingCopyCopier = - new RegisteringStorageToWorkingCopyCopier(registry, supportedChecker, objectSwizzling); + new RegisteringStorageToWorkingCopyCopier(registry, supportedChecker, objectSwizzling, this); this.idSetterProvider = idSetterProvider; this.persistableChecker = persistableChecker; } @@ -182,12 +182,14 @@ private void mergeValues( { alreadyMergedTargets.collectMergedTarget(targetObject); - if(sourceObject instanceof String) + if(sourceObject instanceof String || sourceObject instanceof SpringDataEclipseStoreLazy) { // no merge needed and no merge possible return; } - AccessHelper.getInheritedPrivateFieldsByName(sourceObject.getClass()).values().forEach( + final Collection valuesToMerge = + AccessHelper.getInheritedPrivateFieldsByName(sourceObject.getClass()).values(); + valuesToMerge.forEach( field -> this.mergeValueOfField( sourceObject, @@ -333,11 +335,17 @@ private SpringDataEclipseStoreLazy createNewLazy( } else { - final Lazy newLazyForBuilding = Lazy.Reference(oldLazy.get()); + // This object is already stored but the new version must get overwritten. + // The oldLazy Object can contain all kinds of objects (including more lazies) + final E copyOfWrappedObject = this.getOrCreateObjectForDatastore( + oldLazy.get(), + true, + alreadyMergedTargets, + changedCollector); oldLazy.unlink(); newLazy.unlink(); - // This object is already stored but the new version must get overwritten. - return SpringDataEclipseStoreLazy.Internals.build(newLazyForBuilding); + + return SpringDataEclipseStoreLazy.Internals.buildWithLazy(Lazy.Reference(copyOfWrappedObject)); } } final E copyOfWrappedObject = this.getOrCreateObjectForDatastore( @@ -354,7 +362,7 @@ private SpringDataEclipseStoreLazy createNewLazy( oldLazy.unlink(); // This lazy should never be used again! // It is though of as a temporary copy to merge back into the original-storage-data. - return (SpringDataEclipseStoreLazy)newLazy.copyOnlyWithReference(); + return (SpringDataEclipseStoreLazy)newLazy.copyWithReference(); } } @@ -396,7 +404,8 @@ private E[] createGenericObjectArray( return newArray; } - private E onlyCreateCopy(final E objectToCopy, final boolean invertRegistry) + @Override + public E onlyCreateCopy(final E objectToCopy, final boolean invertRegistry) { if(invertRegistry) { diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/WorkingCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/WorkingCopier.java index c2c60f23..43a8f928 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/WorkingCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/WorkingCopier.java @@ -50,6 +50,8 @@ public interface WorkingCopier */ WorkingCopierResult mergeBack(T workingCopy); + E onlyCreateCopy(final E objectToCopy, final boolean invertRegistry); + /** * @return the original entity that corresponds to the given working copy object. */ diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/DummyWorkingCopier.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/DummyWorkingCopier.java index e92deeb6..2875144c 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/DummyWorkingCopier.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/DummyWorkingCopier.java @@ -41,6 +41,12 @@ public WorkingCopierResult mergeBack(final T workingCopy) return null; } + @Override + public E onlyCreateCopy(final E objectToCopy, final boolean invertRegistry) + { + return objectToCopy; + } + @Override public T getOriginal(final T workingCopy) { diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java index 2b36e26e..dd1ce194 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java @@ -268,6 +268,50 @@ void lazyChangeComplexObject(@Autowired final ObjectWithLazyRepository repository) + { + final ObjectWithLazy newLazy = new ObjectWithLazy<>(); + final ComplexLazyObject objectToStore = new ComplexLazyObject( + SpringDataEclipseStoreLazy.build(new SimpleObject(TestData.DUMMY_STRING)), + new ArrayList<>(Arrays.asList( + SpringDataEclipseStoreLazy.build(new ArrayList<>(Arrays.asList(TestData.DUMMY_STRING))), + SpringDataEclipseStoreLazy.build(new ArrayList<>(Arrays.asList(TestData.DUMMY_STRING_ALTERNATIVE))) + )) + ); + newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); + repository.save(newLazy); + + restartDatastore(this.configuration); + + final ObjectWithLazy loadedObjectToChange = repository.findAll().get(0); + repository.save(loadedObjectToChange); + + TestUtil.doBeforeAndAfterRestartOfDatastore( + this.configuration, + () -> { + final ObjectWithLazy loadedObject = repository.findAll().get(0); + Assertions.assertNotSame(loadedObjectToChange, loadedObject); + Assertions.assertNotSame( + loadedObjectToChange.getLazy().get(), + loadedObject.getLazy().get() + ); + Assertions.assertEquals( + loadedObjectToChange.getLazy().get().getListOfLazyListOfString().size(), + loadedObject.getLazy().get().getListOfLazyListOfString().size() + ); + Assertions.assertEquals( + loadedObjectToChange.getLazy().get().getListOfLazyListOfString().get(0).get().size(), + loadedObject.getLazy().get().getListOfLazyListOfString().get(0).get().size() + ); + Assertions.assertEquals( + loadedObjectToChange.getLazy().get().getListOfLazyListOfString().get(0).get().get(0), + loadedObject.getLazy().get().getListOfLazyListOfString().get(0).get().get(0) + ); + } + ); + } + @Test void lazyClearBeforeSave() { diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopierTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopierTest.java index a7f44591..d0e3a72f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopierTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopierTest.java @@ -38,7 +38,8 @@ void testCopyManyCopiesSingle() new RegisteringStorageToWorkingCopyCopier( new WorkingCopyRegistry(), new SupportedChecker.Implementation(), - o -> null)) + o -> null, + null)) { final List originalObjects = IntStream.range(0, 1_000).mapToObj( i -> new DummyData("Data" + i, i) @@ -57,7 +58,8 @@ void testCopyAgainSameObject() new RegisteringStorageToWorkingCopyCopier( new WorkingCopyRegistry(), new SupportedChecker.Implementation(), - o -> null)) + o -> null, + null)) { final DummyData originalObject = new DummyData("Test", 1); @@ -75,7 +77,8 @@ void testCopyAgainTheCopy() new RegisteringStorageToWorkingCopyCopier( new WorkingCopyRegistry(), new SupportedChecker.Implementation(), - o -> null)) + o -> null, + null)) { final DummyData originalObject = new DummyData("Test", 1); @@ -95,7 +98,8 @@ void testCopyManyCopiesBulk() new RegisteringStorageToWorkingCopyCopier( new WorkingCopyRegistry(), new SupportedChecker.Implementation(), - o -> null)) + o -> null, + null)) { final List originalObjects = IntStream.range(0, 100_000).mapToObj( i -> new DummyData("Data" + i, i) @@ -114,7 +118,8 @@ void testCopyEmpty() new RegisteringStorageToWorkingCopyCopier( new WorkingCopyRegistry(), new SupportedChecker.Implementation(), - o -> null)) + o -> null, + null)) { Assertions.assertThrows(NullPointerException.class, () -> copier.copy(null)); } From fd9656a52e736915f5867868bfb7e2bec09968db Mon Sep 17 00:00:00 2001 From: XDEV Renovate Bot Date: Sat, 20 Apr 2024 02:15:22 +0000 Subject: [PATCH 74/98] Update dependency org.apache.maven.plugins:maven-gpg-plugin to v3.2.4 --- standard-maven-template/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/standard-maven-template/pom.xml b/standard-maven-template/pom.xml index 5ee52759..f8facd65 100644 --- a/standard-maven-template/pom.xml +++ b/standard-maven-template/pom.xml @@ -182,7 +182,7 @@ org.apache.maven.plugins maven-gpg-plugin - 3.2.3 + 3.2.4 sign-artifacts From 34acb7c46c304632c0a5dede676c5857d12a76f5 Mon Sep 17 00:00:00 2001 From: XDEV Renovate Bot Date: Sun, 21 Apr 2024 02:19:24 +0000 Subject: [PATCH 75/98] Update dependency maven-wrapper to v3.3.0 --- .mvn/wrapper/maven-wrapper.properties | 1 - mvnw | 428 +++++++++++--------------- mvnw.cmd | 301 ++++++++---------- 3 files changed, 306 insertions(+), 424 deletions(-) diff --git a/.mvn/wrapper/maven-wrapper.properties b/.mvn/wrapper/maven-wrapper.properties index 346d645f..7f156212 100644 --- a/.mvn/wrapper/maven-wrapper.properties +++ b/.mvn/wrapper/maven-wrapper.properties @@ -15,4 +15,3 @@ # specific language governing permissions and limitations # under the License. distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.6/apache-maven-3.9.6-bin.zip -wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar diff --git a/mvnw b/mvnw index 8d937f4c..08303327 100755 --- a/mvnw +++ b/mvnw @@ -19,290 +19,232 @@ # ---------------------------------------------------------------------------- # ---------------------------------------------------------------------------- -# Apache Maven Wrapper startup batch script, version 3.2.0 -# -# Required ENV vars: -# ------------------ -# JAVA_HOME - location of a JDK home dir +# Apache Maven Wrapper startup batch script, version 3.3.0 # # Optional ENV vars # ----------------- -# MAVEN_OPTS - parameters passed to the Java VM when running Maven -# e.g. to debug Maven itself, use -# set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000 -# MAVEN_SKIP_RC - flag to disable loading of mavenrc files +# JAVA_HOME - location of a JDK home dir, required when download maven via java source +# MVNW_REPOURL - repo url base for downloading maven distribution +# MVNW_USERNAME/MVNW_PASSWORD - user and password for downloading maven +# MVNW_VERBOSE - true: enable verbose log; debug: trace the mvnw script; others: silence the output # ---------------------------------------------------------------------------- -if [ -z "$MAVEN_SKIP_RC" ] ; then - - if [ -f /usr/local/etc/mavenrc ] ; then - . /usr/local/etc/mavenrc - fi - - if [ -f /etc/mavenrc ] ; then - . /etc/mavenrc - fi - - if [ -f "$HOME/.mavenrc" ] ; then - . "$HOME/.mavenrc" - fi - -fi +set -euf +[ "${MVNW_VERBOSE-}" != debug ] || set -x -# OS specific support. $var _must_ be set to either true or false. -cygwin=false; -darwin=false; -mingw=false +# OS specific support. +native_path() { printf %s\\n "$1"; } case "$(uname)" in - CYGWIN*) cygwin=true ;; - MINGW*) mingw=true;; - Darwin*) darwin=true - # Use /usr/libexec/java_home if available, otherwise fall back to /Library/Java/Home - # See https://developer.apple.com/library/mac/qa/qa1170/_index.html - if [ -z "$JAVA_HOME" ]; then - if [ -x "/usr/libexec/java_home" ]; then - JAVA_HOME="$(/usr/libexec/java_home)"; export JAVA_HOME - else - JAVA_HOME="/Library/Java/Home"; export JAVA_HOME - fi - fi - ;; +CYGWIN* | MINGW*) + [ -z "${JAVA_HOME-}" ] || JAVA_HOME="$(cygpath --unix "$JAVA_HOME")" + native_path() { cygpath --path --windows "$1"; } + ;; esac -if [ -z "$JAVA_HOME" ] ; then - if [ -r /etc/gentoo-release ] ; then - JAVA_HOME=$(java-config --jre-home) - fi -fi - -# For Cygwin, ensure paths are in UNIX format before anything is touched -if $cygwin ; then - [ -n "$JAVA_HOME" ] && - JAVA_HOME=$(cygpath --unix "$JAVA_HOME") - [ -n "$CLASSPATH" ] && - CLASSPATH=$(cygpath --path --unix "$CLASSPATH") -fi - -# For Mingw, ensure paths are in UNIX format before anything is touched -if $mingw ; then - [ -n "$JAVA_HOME" ] && [ -d "$JAVA_HOME" ] && - JAVA_HOME="$(cd "$JAVA_HOME" || (echo "cannot cd into $JAVA_HOME."; exit 1); pwd)" -fi - -if [ -z "$JAVA_HOME" ]; then - javaExecutable="$(which javac)" - if [ -n "$javaExecutable" ] && ! [ "$(expr "\"$javaExecutable\"" : '\([^ ]*\)')" = "no" ]; then - # readlink(1) is not available as standard on Solaris 10. - readLink=$(which readlink) - if [ ! "$(expr "$readLink" : '\([^ ]*\)')" = "no" ]; then - if $darwin ; then - javaHome="$(dirname "\"$javaExecutable\"")" - javaExecutable="$(cd "\"$javaHome\"" && pwd -P)/javac" - else - javaExecutable="$(readlink -f "\"$javaExecutable\"")" - fi - javaHome="$(dirname "\"$javaExecutable\"")" - javaHome=$(expr "$javaHome" : '\(.*\)/bin') - JAVA_HOME="$javaHome" - export JAVA_HOME - fi - fi -fi - -if [ -z "$JAVACMD" ] ; then - if [ -n "$JAVA_HOME" ] ; then - if [ -x "$JAVA_HOME/jre/sh/java" ] ; then +# set JAVACMD and JAVACCMD +set_java_home() { + # For Cygwin and MinGW, ensure paths are in Unix format before anything is touched + if [ -n "${JAVA_HOME-}" ]; then + if [ -x "$JAVA_HOME/jre/sh/java" ]; then # IBM's JDK on AIX uses strange locations for the executables JAVACMD="$JAVA_HOME/jre/sh/java" + JAVACCMD="$JAVA_HOME/jre/sh/javac" else JAVACMD="$JAVA_HOME/bin/java" + JAVACCMD="$JAVA_HOME/bin/javac" + + if [ ! -x "$JAVACMD" ] || [ ! -x "$JAVACCMD" ]; then + echo "The JAVA_HOME environment variable is not defined correctly, so mvnw cannot run." >&2 + echo "JAVA_HOME is set to \"$JAVA_HOME\", but \"\$JAVA_HOME/bin/java\" or \"\$JAVA_HOME/bin/javac\" does not exist." >&2 + return 1 + fi fi else - JAVACMD="$(\unset -f command 2>/dev/null; \command -v java)" - fi -fi - -if [ ! -x "$JAVACMD" ] ; then - echo "Error: JAVA_HOME is not defined correctly." >&2 - echo " We cannot execute $JAVACMD" >&2 - exit 1 -fi - -if [ -z "$JAVA_HOME" ] ; then - echo "Warning: JAVA_HOME environment variable is not set." -fi - -# traverses directory structure from process work directory to filesystem root -# first directory with .mvn subdirectory is considered project base directory -find_maven_basedir() { - if [ -z "$1" ] - then - echo "Path not specified to find_maven_basedir" - return 1 + JAVACMD="$( + 'set' +e + 'unset' -f command 2>/dev/null + 'command' -v java + )" || : + JAVACCMD="$( + 'set' +e + 'unset' -f command 2>/dev/null + 'command' -v javac + )" || : + + if [ ! -x "${JAVACMD-}" ] || [ ! -x "${JAVACCMD-}" ]; then + echo "The java/javac command does not exist in PATH nor is JAVA_HOME set, so mvnw cannot run." >&2 + return 1 + fi fi +} - basedir="$1" - wdir="$1" - while [ "$wdir" != '/' ] ; do - if [ -d "$wdir"/.mvn ] ; then - basedir=$wdir - break - fi - # workaround for JBEAP-8937 (on Solaris 10/Sparc) - if [ -d "${wdir}" ]; then - wdir=$(cd "$wdir/.." || exit 1; pwd) - fi - # end of workaround +# hash string like Java String::hashCode +hash_string() { + str="${1:-}" h=0 + while [ -n "$str" ]; do + char="${str%"${str#?}"}" + h=$(((h * 31 + $(LC_CTYPE=C printf %d "'$char")) % 4294967296)) + str="${str#?}" done - printf '%s' "$(cd "$basedir" || exit 1; pwd)" + printf %x\\n $h } -# concatenates all lines of a file -concat_lines() { - if [ -f "$1" ]; then - # Remove \r in case we run on Windows within Git Bash - # and check out the repository with auto CRLF management - # enabled. Otherwise, we may read lines that are delimited with - # \r\n and produce $'-Xarg\r' rather than -Xarg due to word - # splitting rules. - tr -s '\r\n' ' ' < "$1" - fi +verbose() { :; } +[ "${MVNW_VERBOSE-}" != true ] || verbose() { printf %s\\n "${1-}"; } + +die() { + printf %s\\n "$1" >&2 + exit 1 } -log() { - if [ "$MVNW_VERBOSE" = true ]; then - printf '%s\n' "$1" - fi +# parse distributionUrl and optional distributionSha256Sum, requires .mvn/wrapper/maven-wrapper.properties +while IFS="=" read -r key value; do + case "${key-}" in + distributionUrl) distributionUrl="${value-}" ;; + distributionSha256Sum) distributionSha256Sum="${value-}" ;; + esac +done <"${0%/*}/.mvn/wrapper/maven-wrapper.properties" +[ -n "${distributionUrl-}" ] || die "cannot read distributionUrl property in ${0%/*}/.mvn/wrapper/maven-wrapper.properties" + +case "${distributionUrl##*/}" in +maven-mvnd-*bin.*) + MVN_CMD=mvnd.sh _MVNW_REPO_PATTERN=/maven/mvnd/ + case "${PROCESSOR_ARCHITECTURE-}${PROCESSOR_ARCHITEW6432-}:$(uname -a)" in + *AMD64:CYGWIN* | *AMD64:MINGW*) distributionPlatform=windows-amd64 ;; + :Darwin*x86_64) distributionPlatform=darwin-amd64 ;; + :Darwin*arm64) distributionPlatform=darwin-aarch64 ;; + :Linux*x86_64*) distributionPlatform=linux-amd64 ;; + *) + echo "Cannot detect native platform for mvnd on $(uname)-$(uname -m), use pure java version" >&2 + distributionPlatform=linux-amd64 + ;; + esac + distributionUrl="${distributionUrl%-bin.*}-$distributionPlatform.zip" + ;; +maven-mvnd-*) MVN_CMD=mvnd.sh _MVNW_REPO_PATTERN=/maven/mvnd/ ;; +*) MVN_CMD="mvn${0##*/mvnw}" _MVNW_REPO_PATTERN=/org/apache/maven/ ;; +esac + +# apply MVNW_REPOURL and calculate MAVEN_HOME +# maven home pattern: ~/.m2/wrapper/dists/{apache-maven-,maven-mvnd--}/ +[ -z "${MVNW_REPOURL-}" ] || distributionUrl="$MVNW_REPOURL$_MVNW_REPO_PATTERN${distributionUrl#*"$_MVNW_REPO_PATTERN"}" +distributionUrlName="${distributionUrl##*/}" +distributionUrlNameMain="${distributionUrlName%.*}" +distributionUrlNameMain="${distributionUrlNameMain%-bin}" +MAVEN_HOME="$HOME/.m2/wrapper/dists/${distributionUrlNameMain-}/$(hash_string "$distributionUrl")" + +exec_maven() { + unset MVNW_VERBOSE MVNW_USERNAME MVNW_PASSWORD MVNW_REPOURL || : + exec "$MAVEN_HOME/bin/$MVN_CMD" "$@" || die "cannot exec $MAVEN_HOME/bin/$MVN_CMD" } -BASE_DIR=$(find_maven_basedir "$(dirname "$0")") -if [ -z "$BASE_DIR" ]; then - exit 1; +if [ -d "$MAVEN_HOME" ]; then + verbose "found existing MAVEN_HOME at $MAVEN_HOME" + exec_maven "$@" fi -MAVEN_PROJECTBASEDIR=${MAVEN_BASEDIR:-"$BASE_DIR"}; export MAVEN_PROJECTBASEDIR -log "$MAVEN_PROJECTBASEDIR" +case "${distributionUrl-}" in +*?-bin.zip | *?maven-mvnd-?*-?*.zip) ;; +*) die "distributionUrl is not valid, must match *-bin.zip or maven-mvnd-*.zip, but found '${distributionUrl-}'" ;; +esac -########################################################################################## -# Extension to allow automatically downloading the maven-wrapper.jar from Maven-central -# This allows using the maven wrapper in projects that prohibit checking in binary data. -########################################################################################## -wrapperJarPath="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.jar" -if [ -r "$wrapperJarPath" ]; then - log "Found $wrapperJarPath" +# prepare tmp dir +if TMP_DOWNLOAD_DIR="$(mktemp -d)" && [ -d "$TMP_DOWNLOAD_DIR" ]; then + clean() { rm -rf -- "$TMP_DOWNLOAD_DIR"; } + trap clean HUP INT TERM EXIT else - log "Couldn't find $wrapperJarPath, downloading it ..." + die "cannot create temp dir" +fi - if [ -n "$MVNW_REPOURL" ]; then - wrapperUrl="$MVNW_REPOURL/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar" - else - wrapperUrl="https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar" - fi - while IFS="=" read -r key value; do - # Remove '\r' from value to allow usage on windows as IFS does not consider '\r' as a separator ( considers space, tab, new line ('\n'), and custom '=' ) - safeValue=$(echo "$value" | tr -d '\r') - case "$key" in (wrapperUrl) wrapperUrl="$safeValue"; break ;; - esac - done < "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.properties" - log "Downloading from: $wrapperUrl" +mkdir -p -- "${MAVEN_HOME%/*}" - if $cygwin; then - wrapperJarPath=$(cygpath --path --windows "$wrapperJarPath") - fi +# Download and Install Apache Maven +verbose "Couldn't find MAVEN_HOME, downloading and installing it ..." +verbose "Downloading from: $distributionUrl" +verbose "Downloading to: $TMP_DOWNLOAD_DIR/$distributionUrlName" - if command -v wget > /dev/null; then - log "Found wget ... using wget" - [ "$MVNW_VERBOSE" = true ] && QUIET="" || QUIET="--quiet" - if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then - wget $QUIET "$wrapperUrl" -O "$wrapperJarPath" || rm -f "$wrapperJarPath" - else - wget $QUIET --http-user="$MVNW_USERNAME" --http-password="$MVNW_PASSWORD" "$wrapperUrl" -O "$wrapperJarPath" || rm -f "$wrapperJarPath" - fi - elif command -v curl > /dev/null; then - log "Found curl ... using curl" - [ "$MVNW_VERBOSE" = true ] && QUIET="" || QUIET="--silent" - if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then - curl $QUIET -o "$wrapperJarPath" "$wrapperUrl" -f -L || rm -f "$wrapperJarPath" - else - curl $QUIET --user "$MVNW_USERNAME:$MVNW_PASSWORD" -o "$wrapperJarPath" "$wrapperUrl" -f -L || rm -f "$wrapperJarPath" - fi - else - log "Falling back to using Java to download" - javaSource="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/MavenWrapperDownloader.java" - javaClass="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/MavenWrapperDownloader.class" - # For Cygwin, switch paths to Windows format before running javac - if $cygwin; then - javaSource=$(cygpath --path --windows "$javaSource") - javaClass=$(cygpath --path --windows "$javaClass") - fi - if [ -e "$javaSource" ]; then - if [ ! -e "$javaClass" ]; then - log " - Compiling MavenWrapperDownloader.java ..." - ("$JAVA_HOME/bin/javac" "$javaSource") - fi - if [ -e "$javaClass" ]; then - log " - Running MavenWrapperDownloader.java ..." - ("$JAVA_HOME/bin/java" -cp .mvn/wrapper MavenWrapperDownloader "$wrapperUrl" "$wrapperJarPath") || rm -f "$wrapperJarPath" - fi - fi - fi +# select .zip or .tar.gz +if ! command -v unzip >/dev/null; then + distributionUrl="${distributionUrl%.zip}.tar.gz" + distributionUrlName="${distributionUrl##*/}" fi -########################################################################################## -# End of extension -########################################################################################## -# If specified, validate the SHA-256 sum of the Maven wrapper jar file -wrapperSha256Sum="" -while IFS="=" read -r key value; do - case "$key" in (wrapperSha256Sum) wrapperSha256Sum=$value; break ;; - esac -done < "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.properties" -if [ -n "$wrapperSha256Sum" ]; then - wrapperSha256Result=false - if command -v sha256sum > /dev/null; then - if echo "$wrapperSha256Sum $wrapperJarPath" | sha256sum -c > /dev/null 2>&1; then - wrapperSha256Result=true +# verbose opt +__MVNW_QUIET_WGET=--quiet __MVNW_QUIET_CURL=--silent __MVNW_QUIET_UNZIP=-q __MVNW_QUIET_TAR='' +[ "${MVNW_VERBOSE-}" != true ] || __MVNW_QUIET_WGET='' __MVNW_QUIET_CURL='' __MVNW_QUIET_UNZIP='' __MVNW_QUIET_TAR=v + +# normalize http auth +case "${MVNW_PASSWORD:+has-password}" in +'') MVNW_USERNAME='' MVNW_PASSWORD='' ;; +has-password) [ -n "${MVNW_USERNAME-}" ] || MVNW_USERNAME='' MVNW_PASSWORD='' ;; +esac + +if [ -z "${MVNW_USERNAME-}" ] && command -v wget >/dev/null; then + verbose "Found wget ... using wget" + wget ${__MVNW_QUIET_WGET:+"$__MVNW_QUIET_WGET"} "$distributionUrl" -O "$TMP_DOWNLOAD_DIR/$distributionUrlName" || die "wget: Failed to fetch $distributionUrl" +elif [ -z "${MVNW_USERNAME-}" ] && command -v curl >/dev/null; then + verbose "Found curl ... using curl" + curl ${__MVNW_QUIET_CURL:+"$__MVNW_QUIET_CURL"} -f -L -o "$TMP_DOWNLOAD_DIR/$distributionUrlName" "$distributionUrl" || die "curl: Failed to fetch $distributionUrl" +elif set_java_home; then + verbose "Falling back to use Java to download" + javaSource="$TMP_DOWNLOAD_DIR/Downloader.java" + targetZip="$TMP_DOWNLOAD_DIR/$distributionUrlName" + cat >"$javaSource" <<-END + public class Downloader extends java.net.Authenticator + { + protected java.net.PasswordAuthentication getPasswordAuthentication() + { + return new java.net.PasswordAuthentication( System.getenv( "MVNW_USERNAME" ), System.getenv( "MVNW_PASSWORD" ).toCharArray() ); + } + public static void main( String[] args ) throws Exception + { + setDefault( new Downloader() ); + java.nio.file.Files.copy( new java.net.URL( args[0] ).openStream(), java.nio.file.Paths.get( args[1] ).toAbsolutePath().normalize() ); + } + } + END + # For Cygwin/MinGW, switch paths to Windows format before running javac and java + verbose " - Compiling Downloader.java ..." + "$(native_path "$JAVACCMD")" "$(native_path "$javaSource")" || die "Failed to compile Downloader.java" + verbose " - Running Downloader.java ..." + "$(native_path "$JAVACMD")" -cp "$(native_path "$TMP_DOWNLOAD_DIR")" Downloader "$distributionUrl" "$(native_path "$targetZip")" +fi + +# If specified, validate the SHA-256 sum of the Maven distribution zip file +if [ -n "${distributionSha256Sum-}" ]; then + distributionSha256Result=false + if [ "$MVN_CMD" = mvnd.sh ]; then + echo "Checksum validation is not supported for maven-mvnd." >&2 + echo "Please disable validation by removing 'distributionSha256Sum' from your maven-wrapper.properties." >&2 + exit 1 + elif command -v sha256sum >/dev/null; then + if echo "$distributionSha256Sum $TMP_DOWNLOAD_DIR/$distributionUrlName" | sha256sum -c >/dev/null 2>&1; then + distributionSha256Result=true fi - elif command -v shasum > /dev/null; then - if echo "$wrapperSha256Sum $wrapperJarPath" | shasum -a 256 -c > /dev/null 2>&1; then - wrapperSha256Result=true + elif command -v shasum >/dev/null; then + if echo "$distributionSha256Sum $TMP_DOWNLOAD_DIR/$distributionUrlName" | shasum -a 256 -c >/dev/null 2>&1; then + distributionSha256Result=true fi else - echo "Checksum validation was requested but neither 'sha256sum' or 'shasum' are available." - echo "Please install either command, or disable validation by removing 'wrapperSha256Sum' from your maven-wrapper.properties." + echo "Checksum validation was requested but neither 'sha256sum' or 'shasum' are available." >&2 + echo "Please install either command, or disable validation by removing 'distributionSha256Sum' from your maven-wrapper.properties." >&2 exit 1 fi - if [ $wrapperSha256Result = false ]; then - echo "Error: Failed to validate Maven wrapper SHA-256, your Maven wrapper might be compromised." >&2 - echo "Investigate or delete $wrapperJarPath to attempt a clean download." >&2 - echo "If you updated your Maven version, you need to update the specified wrapperSha256Sum property." >&2 + if [ $distributionSha256Result = false ]; then + echo "Error: Failed to validate Maven distribution SHA-256, your Maven distribution might be compromised." >&2 + echo "If you updated your Maven version, you need to update the specified distributionSha256Sum property." >&2 exit 1 fi fi -MAVEN_OPTS="$(concat_lines "$MAVEN_PROJECTBASEDIR/.mvn/jvm.config") $MAVEN_OPTS" - -# For Cygwin, switch paths to Windows format before running java -if $cygwin; then - [ -n "$JAVA_HOME" ] && - JAVA_HOME=$(cygpath --path --windows "$JAVA_HOME") - [ -n "$CLASSPATH" ] && - CLASSPATH=$(cygpath --path --windows "$CLASSPATH") - [ -n "$MAVEN_PROJECTBASEDIR" ] && - MAVEN_PROJECTBASEDIR=$(cygpath --path --windows "$MAVEN_PROJECTBASEDIR") +# unzip and move +if command -v unzip >/dev/null; then + unzip ${__MVNW_QUIET_UNZIP:+"$__MVNW_QUIET_UNZIP"} "$TMP_DOWNLOAD_DIR/$distributionUrlName" -d "$TMP_DOWNLOAD_DIR" || die "failed to unzip" +else + tar xzf${__MVNW_QUIET_TAR:+"$__MVNW_QUIET_TAR"} "$TMP_DOWNLOAD_DIR/$distributionUrlName" -C "$TMP_DOWNLOAD_DIR" || die "failed to untar" fi +printf %s\\n "$distributionUrl" >"$TMP_DOWNLOAD_DIR/$distributionUrlNameMain/mvnw.url" +mv -- "$TMP_DOWNLOAD_DIR/$distributionUrlNameMain" "$MAVEN_HOME" || [ -d "$MAVEN_HOME" ] || die "fail to move MAVEN_HOME" -# Provide a "standardized" way to retrieve the CLI args that will -# work with both Windows and non-Windows executions. -MAVEN_CMD_LINE_ARGS="$MAVEN_CONFIG $*" -export MAVEN_CMD_LINE_ARGS - -WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain - -# shellcheck disable=SC2086 # safe args -exec "$JAVACMD" \ - $MAVEN_OPTS \ - $MAVEN_DEBUG_OPTS \ - -classpath "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.jar" \ - "-Dmaven.multiModuleProjectDirectory=${MAVEN_PROJECTBASEDIR}" \ - ${WRAPPER_LAUNCHER} $MAVEN_CONFIG "$@" +clean || : +exec_maven "$@" diff --git a/mvnw.cmd b/mvnw.cmd index c4586b56..136e686a 100644 --- a/mvnw.cmd +++ b/mvnw.cmd @@ -1,3 +1,4 @@ +<# : batch portion @REM ---------------------------------------------------------------------------- @REM Licensed to the Apache Software Foundation (ASF) under one @REM or more contributor license agreements. See the NOTICE file @@ -18,188 +19,128 @@ @REM ---------------------------------------------------------------------------- @REM ---------------------------------------------------------------------------- -@REM Apache Maven Wrapper startup batch script, version 3.2.0 -@REM -@REM Required ENV vars: -@REM JAVA_HOME - location of a JDK home dir +@REM Apache Maven Wrapper startup batch script, version 3.3.0 @REM @REM Optional ENV vars -@REM MAVEN_BATCH_ECHO - set to 'on' to enable the echoing of the batch commands -@REM MAVEN_BATCH_PAUSE - set to 'on' to wait for a keystroke before ending -@REM MAVEN_OPTS - parameters passed to the Java VM when running Maven -@REM e.g. to debug Maven itself, use -@REM set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000 -@REM MAVEN_SKIP_RC - flag to disable loading of mavenrc files +@REM MVNW_REPOURL - repo url base for downloading maven distribution +@REM MVNW_USERNAME/MVNW_PASSWORD - user and password for downloading maven +@REM MVNW_VERBOSE - true: enable verbose log; others: silence the output @REM ---------------------------------------------------------------------------- -@REM Begin all REM lines with '@' in case MAVEN_BATCH_ECHO is 'on' -@echo off -@REM set title of command window -title %0 -@REM enable echoing by setting MAVEN_BATCH_ECHO to 'on' -@if "%MAVEN_BATCH_ECHO%" == "on" echo %MAVEN_BATCH_ECHO% - -@REM set %HOME% to equivalent of $HOME -if "%HOME%" == "" (set "HOME=%HOMEDRIVE%%HOMEPATH%") - -@REM Execute a user defined script before this one -if not "%MAVEN_SKIP_RC%" == "" goto skipRcPre -@REM check for pre script, once with legacy .bat ending and once with .cmd ending -if exist "%USERPROFILE%\mavenrc_pre.bat" call "%USERPROFILE%\mavenrc_pre.bat" %* -if exist "%USERPROFILE%\mavenrc_pre.cmd" call "%USERPROFILE%\mavenrc_pre.cmd" %* -:skipRcPre - -@setlocal - -set ERROR_CODE=0 - -@REM To isolate internal variables from possible post scripts, we use another setlocal -@setlocal - -@REM ==== START VALIDATION ==== -if not "%JAVA_HOME%" == "" goto OkJHome - -echo. -echo Error: JAVA_HOME not found in your environment. >&2 -echo Please set the JAVA_HOME variable in your environment to match the >&2 -echo location of your Java installation. >&2 -echo. -goto error - -:OkJHome -if exist "%JAVA_HOME%\bin\java.exe" goto init - -echo. -echo Error: JAVA_HOME is set to an invalid directory. >&2 -echo JAVA_HOME = "%JAVA_HOME%" >&2 -echo Please set the JAVA_HOME variable in your environment to match the >&2 -echo location of your Java installation. >&2 -echo. -goto error - -@REM ==== END VALIDATION ==== - -:init - -@REM Find the project base dir, i.e. the directory that contains the folder ".mvn". -@REM Fallback to current working directory if not found. - -set MAVEN_PROJECTBASEDIR=%MAVEN_BASEDIR% -IF NOT "%MAVEN_PROJECTBASEDIR%"=="" goto endDetectBaseDir - -set EXEC_DIR=%CD% -set WDIR=%EXEC_DIR% -:findBaseDir -IF EXIST "%WDIR%"\.mvn goto baseDirFound -cd .. -IF "%WDIR%"=="%CD%" goto baseDirNotFound -set WDIR=%CD% -goto findBaseDir - -:baseDirFound -set MAVEN_PROJECTBASEDIR=%WDIR% -cd "%EXEC_DIR%" -goto endDetectBaseDir - -:baseDirNotFound -set MAVEN_PROJECTBASEDIR=%EXEC_DIR% -cd "%EXEC_DIR%" - -:endDetectBaseDir - -IF NOT EXIST "%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config" goto endReadAdditionalConfig - -@setlocal EnableExtensions EnableDelayedExpansion -for /F "usebackq delims=" %%a in ("%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config") do set JVM_CONFIG_MAVEN_PROPS=!JVM_CONFIG_MAVEN_PROPS! %%a -@endlocal & set JVM_CONFIG_MAVEN_PROPS=%JVM_CONFIG_MAVEN_PROPS% - -:endReadAdditionalConfig - -SET MAVEN_JAVA_EXE="%JAVA_HOME%\bin\java.exe" -set WRAPPER_JAR="%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.jar" -set WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain - -set WRAPPER_URL="https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar" - -FOR /F "usebackq tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO ( - IF "%%A"=="wrapperUrl" SET WRAPPER_URL=%%B -) - -@REM Extension to allow automatically downloading the maven-wrapper.jar from Maven-central -@REM This allows using the maven wrapper in projects that prohibit checking in binary data. -if exist %WRAPPER_JAR% ( - if "%MVNW_VERBOSE%" == "true" ( - echo Found %WRAPPER_JAR% - ) -) else ( - if not "%MVNW_REPOURL%" == "" ( - SET WRAPPER_URL="%MVNW_REPOURL%/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar" - ) - if "%MVNW_VERBOSE%" == "true" ( - echo Couldn't find %WRAPPER_JAR%, downloading it ... - echo Downloading from: %WRAPPER_URL% - ) - - powershell -Command "&{"^ - "$webclient = new-object System.Net.WebClient;"^ - "if (-not ([string]::IsNullOrEmpty('%MVNW_USERNAME%') -and [string]::IsNullOrEmpty('%MVNW_PASSWORD%'))) {"^ - "$webclient.Credentials = new-object System.Net.NetworkCredential('%MVNW_USERNAME%', '%MVNW_PASSWORD%');"^ - "}"^ - "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; $webclient.DownloadFile('%WRAPPER_URL%', '%WRAPPER_JAR%')"^ - "}" - if "%MVNW_VERBOSE%" == "true" ( - echo Finished downloading %WRAPPER_JAR% - ) -) -@REM End of extension - -@REM If specified, validate the SHA-256 sum of the Maven wrapper jar file -SET WRAPPER_SHA_256_SUM="" -FOR /F "usebackq tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO ( - IF "%%A"=="wrapperSha256Sum" SET WRAPPER_SHA_256_SUM=%%B +@IF "%__MVNW_ARG0_NAME__%"=="" (SET __MVNW_ARG0_NAME__=%~nx0) +@SET __MVNW_CMD__= +@SET __MVNW_ERROR__= +@SET __MVNW_PSMODULEP_SAVE=%PSModulePath% +@SET PSModulePath= +@FOR /F "usebackq tokens=1* delims==" %%A IN (`powershell -noprofile "& {$scriptDir='%~dp0'; $script='%__MVNW_ARG0_NAME__%'; icm -ScriptBlock ([Scriptblock]::Create((Get-Content -Raw '%~f0'))) -NoNewScope}"`) DO @( + IF "%%A"=="MVN_CMD" (set __MVNW_CMD__=%%B) ELSE IF "%%B"=="" (echo %%A) ELSE (echo %%A=%%B) ) -IF NOT %WRAPPER_SHA_256_SUM%=="" ( - powershell -Command "&{"^ - "$hash = (Get-FileHash \"%WRAPPER_JAR%\" -Algorithm SHA256).Hash.ToLower();"^ - "If('%WRAPPER_SHA_256_SUM%' -ne $hash){"^ - " Write-Output 'Error: Failed to validate Maven wrapper SHA-256, your Maven wrapper might be compromised.';"^ - " Write-Output 'Investigate or delete %WRAPPER_JAR% to attempt a clean download.';"^ - " Write-Output 'If you updated your Maven version, you need to update the specified wrapperSha256Sum property.';"^ - " exit 1;"^ - "}"^ - "}" - if ERRORLEVEL 1 goto error -) - -@REM Provide a "standardized" way to retrieve the CLI args that will -@REM work with both Windows and non-Windows executions. -set MAVEN_CMD_LINE_ARGS=%* - -%MAVEN_JAVA_EXE% ^ - %JVM_CONFIG_MAVEN_PROPS% ^ - %MAVEN_OPTS% ^ - %MAVEN_DEBUG_OPTS% ^ - -classpath %WRAPPER_JAR% ^ - "-Dmaven.multiModuleProjectDirectory=%MAVEN_PROJECTBASEDIR%" ^ - %WRAPPER_LAUNCHER% %MAVEN_CONFIG% %* -if ERRORLEVEL 1 goto error -goto end - -:error -set ERROR_CODE=1 - -:end -@endlocal & set ERROR_CODE=%ERROR_CODE% - -if not "%MAVEN_SKIP_RC%"=="" goto skipRcPost -@REM check for post script, once with legacy .bat ending and once with .cmd ending -if exist "%USERPROFILE%\mavenrc_post.bat" call "%USERPROFILE%\mavenrc_post.bat" -if exist "%USERPROFILE%\mavenrc_post.cmd" call "%USERPROFILE%\mavenrc_post.cmd" -:skipRcPost - -@REM pause the script if MAVEN_BATCH_PAUSE is set to 'on' -if "%MAVEN_BATCH_PAUSE%"=="on" pause - -if "%MAVEN_TERMINATE_CMD%"=="on" exit %ERROR_CODE% - -cmd /C exit /B %ERROR_CODE% +@SET PSModulePath=%__MVNW_PSMODULEP_SAVE% +@SET __MVNW_PSMODULEP_SAVE= +@SET __MVNW_ARG0_NAME__= +@SET MVNW_USERNAME= +@SET MVNW_PASSWORD= +@IF NOT "%__MVNW_CMD__%"=="" (%__MVNW_CMD__% %*) +@echo Cannot start maven from wrapper >&2 && exit /b 1 +@GOTO :EOF +: end batch / begin powershell #> + +$ErrorActionPreference = "Stop" +if ($env:MVNW_VERBOSE -eq "true") { + $VerbosePreference = "Continue" +} + +# calculate distributionUrl, requires .mvn/wrapper/maven-wrapper.properties +$distributionUrl = (Get-Content -Raw "$scriptDir/.mvn/wrapper/maven-wrapper.properties" | ConvertFrom-StringData).distributionUrl +if (!$distributionUrl) { + Write-Error "cannot read distributionUrl property in $scriptDir/.mvn/wrapper/maven-wrapper.properties" +} + +switch -wildcard -casesensitive ( $($distributionUrl -replace '^.*/','') ) { + "maven-mvnd-*" { + $USE_MVND = $true + $distributionUrl = $distributionUrl -replace '-bin\.[^.]*$',"-windows-amd64.zip" + $MVN_CMD = "mvnd.cmd" + break + } + default { + $USE_MVND = $false + $MVN_CMD = $script -replace '^mvnw','mvn' + break + } +} + +# apply MVNW_REPOURL and calculate MAVEN_HOME +# maven home pattern: ~/.m2/wrapper/dists/{apache-maven-,maven-mvnd--}/ +if ($env:MVNW_REPOURL) { + $MVNW_REPO_PATTERN = if ($USE_MVND) { "/org/apache/maven/" } else { "/maven/mvnd/" } + $distributionUrl = "$env:MVNW_REPOURL$MVNW_REPO_PATTERN$($distributionUrl -replace '^.*'+$MVNW_REPO_PATTERN,'')" +} +$distributionUrlName = $distributionUrl -replace '^.*/','' +$distributionUrlNameMain = $distributionUrlName -replace '\.[^.]*$','' -replace '-bin$','' +$MAVEN_HOME_PARENT = "$HOME/.m2/wrapper/dists/$distributionUrlNameMain" +$MAVEN_HOME_NAME = ([System.Security.Cryptography.MD5]::Create().ComputeHash([byte[]][char[]]$distributionUrl) | ForEach-Object {$_.ToString("x2")}) -join '' +$MAVEN_HOME = "$MAVEN_HOME_PARENT/$MAVEN_HOME_NAME" + +if (Test-Path -Path "$MAVEN_HOME" -PathType Container) { + Write-Verbose "found existing MAVEN_HOME at $MAVEN_HOME" + Write-Output "MVN_CMD=$MAVEN_HOME/bin/$MVN_CMD" + exit $? +} + +if (! $distributionUrlNameMain -or ($distributionUrlName -eq $distributionUrlNameMain)) { + Write-Error "distributionUrl is not valid, must end with *-bin.zip, but found $distributionUrl" +} + +# prepare tmp dir +$TMP_DOWNLOAD_DIR_HOLDER = New-TemporaryFile +$TMP_DOWNLOAD_DIR = New-Item -Itemtype Directory -Path "$TMP_DOWNLOAD_DIR_HOLDER.dir" +$TMP_DOWNLOAD_DIR_HOLDER.Delete() | Out-Null +trap { + if ($TMP_DOWNLOAD_DIR.Exists) { + try { Remove-Item $TMP_DOWNLOAD_DIR -Recurse -Force | Out-Null } + catch { Write-Warning "Cannot remove $TMP_DOWNLOAD_DIR" } + } +} + +New-Item -Itemtype Directory -Path "$MAVEN_HOME_PARENT" -Force | Out-Null + +# Download and Install Apache Maven +Write-Verbose "Couldn't find MAVEN_HOME, downloading and installing it ..." +Write-Verbose "Downloading from: $distributionUrl" +Write-Verbose "Downloading to: $TMP_DOWNLOAD_DIR/$distributionUrlName" + +$webclient = New-Object System.Net.WebClient +if ($env:MVNW_USERNAME -and $env:MVNW_PASSWORD) { + $webclient.Credentials = New-Object System.Net.NetworkCredential($env:MVNW_USERNAME, $env:MVNW_PASSWORD) +} +[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 +$webclient.DownloadFile($distributionUrl, "$TMP_DOWNLOAD_DIR/$distributionUrlName") | Out-Null + +# If specified, validate the SHA-256 sum of the Maven distribution zip file +$distributionSha256Sum = (Get-Content -Raw "$scriptDir/.mvn/wrapper/maven-wrapper.properties" | ConvertFrom-StringData).distributionSha256Sum +if ($distributionSha256Sum) { + if ($USE_MVND) { + Write-Error "Checksum validation is not supported for maven-mvnd. `nPlease disable validation by removing 'distributionSha256Sum' from your maven-wrapper.properties." + } + Import-Module $PSHOME\Modules\Microsoft.PowerShell.Utility -Function Get-FileHash + if ((Get-FileHash "$TMP_DOWNLOAD_DIR/$distributionUrlName" -Algorithm SHA256).Hash.ToLower() -ne $distributionSha256Sum) { + Write-Error "Error: Failed to validate Maven distribution SHA-256, your Maven distribution might be compromised. If you updated your Maven version, you need to update the specified distributionSha256Sum property." + } +} + +# unzip and move +Expand-Archive "$TMP_DOWNLOAD_DIR/$distributionUrlName" -DestinationPath "$TMP_DOWNLOAD_DIR" | Out-Null +Rename-Item -Path "$TMP_DOWNLOAD_DIR/$distributionUrlNameMain" -NewName $MAVEN_HOME_NAME | Out-Null +try { + Move-Item -Path "$TMP_DOWNLOAD_DIR/$MAVEN_HOME_NAME" -Destination $MAVEN_HOME_PARENT | Out-Null +} catch { + if (! (Test-Path -Path "$MAVEN_HOME" -PathType Container)) { + Write-Error "fail to move MAVEN_HOME" + } +} finally { + try { Remove-Item $TMP_DOWNLOAD_DIR -Recurse -Force | Out-Null } + catch { Write-Warning "Cannot remove $TMP_DOWNLOAD_DIR" } +} + +Write-Output "MVN_CMD=$MAVEN_HOME/bin/$MVN_CMD" From 6f9f53cf0d4fd605a051729ea0d6f24266c43061 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Mon, 22 Apr 2024 09:07:59 +0200 Subject: [PATCH 76/98] Added docs and demos for lazy --- CHANGELOG.md | 1 + docs/modules/ROOT/nav.adoc | 1 + docs/modules/ROOT/pages/known-issues.adoc | 8 ---- docs/modules/ROOT/pages/lazies.adoc | 40 +++++++++++++++++++ .../demo/complex/ComplexDemoApplication.java | 11 +++++ .../store/demo/complex/owner/Owner.java | 11 ++++- .../demo/complex/owner/OwnerRepository.java | 4 ++ .../lazy/SpringDataEclipseStoreLazy.java | 29 ++++++-------- ...ringDataEclipseStoreLazyBinaryHandler.java | 2 +- 9 files changed, 79 insertions(+), 28 deletions(-) create mode 100644 docs/modules/ROOT/pages/lazies.adoc diff --git a/CHANGELOG.md b/CHANGELOG.md index 96797abe..a11d28d0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,7 @@ # 1.0.4 * Added possibility to use multiple storages +* Added Lazy support # 1.0.3 diff --git a/docs/modules/ROOT/nav.adoc b/docs/modules/ROOT/nav.adoc index 86dc85bc..20b43255 100644 --- a/docs/modules/ROOT/nav.adoc +++ b/docs/modules/ROOT/nav.adoc @@ -2,5 +2,6 @@ * xref:installation.adoc[Installation] * xref:configuration.adoc[Configuration] * xref:working-copies.adoc[Working Copies] +* xref:lazies.adoc[Lazy References] * xref:migration.adoc[Migration] * xref:known-issues.adoc[Known issues] diff --git a/docs/modules/ROOT/pages/known-issues.adoc b/docs/modules/ROOT/pages/known-issues.adoc index 54706e47..6c1c9489 100644 --- a/docs/modules/ROOT/pages/known-issues.adoc +++ b/docs/modules/ROOT/pages/known-issues.adoc @@ -1,13 +1,5 @@ = Known issues -== Lazy references - -One of the core features of EclipseStore is its https://docs.eclipsestore.io/manual/storage/loading-data/lazy-loading/index.html[Lazy references]. -Unfortunately this requires our library to implement some kind of proxy. -That's something that takes a lot of effort to implement in our {product-name}. - -We created https://github.com/xdev-software/spring-data-eclipse-store/issues/31[an issue] for that but right now we *do not support Lazy references*. - == Query annotations In Spring-Data-JPA you can write a Query over methods of repositories like this: diff --git a/docs/modules/ROOT/pages/lazies.adoc b/docs/modules/ROOT/pages/lazies.adoc new file mode 100644 index 00000000..f568afee --- /dev/null +++ b/docs/modules/ROOT/pages/lazies.adoc @@ -0,0 +1,40 @@ += Lazy References + +Lazy Loading is an essential part of EclipseStore. +The basic mechanism is best explained in the https://docs.eclipsestore.io/manual/storage/loading-data/lazy-loading/index.html[EclipseStore-Docs]. + +In essence java objects which are wrapped in a *Lazy-Reference are not loaded with the startup of the EclipseStore-Storage but only if ``get()`` is called* on them. + +Lazy References are essential for big data sets that can't get loaded into memory. +Since {product-name} operates with xref:working-copies.adoc[working copies] using the EclipseStore-Lazy-References is not possible. +All Lazy References would be resolved and loaded into memory anyway. + +That's why we implemented ``SpringDataEclipseStoreLazy``. + +The usage is the same as with the EclipseStore-Lazies, but they are handled very differently. + +Simply wrap any kind of java object in the SpringDataEclipseStoreLazy-Wrapper and the wrapped object has a lazy loading behaviour. + +CAUTION: Lazy-References are not only loaded when needed, but also https://docs.eclipsestore.io/manual/storage/loading-data/lazy-loading/clearing-lazy-references.html#automatically[*cleared when they are no longer needed*]! + +Example: ``SpringDataEclipseStoreLazy.build(new HashMap())`` + +[source,java,title="https://github.com/xdev-software/spring-data-eclipse-store/tree/develop/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex/owner/Owner.java[Example from complex demo]"] +---- +package software.xdev.spring.data.eclipse.store.demo.complex.owner; +//... +import software.xdev.spring.data.eclipse.store.repository.lazy.SpringDataEclipseStoreLazy; + +public class Owner extends Person +{ + private String address; + + private Lazy> pets = SpringDataEclipseStoreLazy.build(new ArrayList<>()); + //... +---- + +== Internas + +SpringDataEclipseStoreLazies work as a proxy for the EclipseStore-Lazies. +As far as EclipseStore is concerned, a SpringDataEclipseStoreLazy-Object is a normal Java object that contains a Lazy-Reference. + +But when {product-name} creates the working copy, *the SpringDataEclipseStoreLazy-Reference is not resolved* but instead only a reference to the original Lazy-Object in EclipseStore is loaded. +As soon as ``get()`` is called on the SpringDataEclipseStoreLazy, a *new working copy of the lazy object* is created. diff --git a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex/ComplexDemoApplication.java b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex/ComplexDemoApplication.java index c7e2c7dd..33758888 100644 --- a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex/ComplexDemoApplication.java +++ b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex/ComplexDemoApplication.java @@ -103,6 +103,17 @@ public void run(final String... args) ); } ); + + LOG.info("----Owner-Lazy Pet loading----"); + this.ownerRepository.findAll().forEach( + o -> o.getPets().forEach( + pet -> LOG.info(String.format( + "Pet %s has owner %s %s", + pet.getName(), + o.getFirstName(), + o.getLastName())) + ) + ); } private static Visit createVisit() diff --git a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex/owner/Owner.java b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex/owner/Owner.java index 1cf16094..e9c0467c 100644 --- a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex/owner/Owner.java +++ b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex/owner/Owner.java @@ -19,10 +19,12 @@ import java.util.List; import java.util.Optional; +import org.eclipse.serializer.reference.Lazy; import org.springframework.core.style.ToStringCreator; import org.springframework.util.Assert; import software.xdev.spring.data.eclipse.store.demo.complex.model.Person; +import software.xdev.spring.data.eclipse.store.repository.lazy.SpringDataEclipseStoreLazy; public class Owner extends Person @@ -33,7 +35,7 @@ public class Owner extends Person private String telephone; - private final List pets = new ArrayList<>(); + private Lazy> pets = SpringDataEclipseStoreLazy.build(new ArrayList<>()); public String getAddress() { @@ -52,7 +54,12 @@ public String getTelephone() public List getPets() { - return this.pets; + return this.pets.get(); + } + + public void setPets(final List pets) + { + this.pets = SpringDataEclipseStoreLazy.build(pets); } public void addPet(final Pet pet) diff --git a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex/owner/OwnerRepository.java b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex/owner/OwnerRepository.java index 03b735b1..1c2b3e93 100644 --- a/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex/owner/OwnerRepository.java +++ b/spring-data-eclipse-store-demo/src/main/java/software/xdev/spring/data/eclipse/store/demo/complex/owner/OwnerRepository.java @@ -15,6 +15,8 @@ */ package software.xdev.spring.data.eclipse.store.demo.complex.owner; +import java.util.List; + import org.springframework.data.domain.Page; import org.springframework.data.domain.Pageable; import org.springframework.data.repository.Repository; @@ -28,5 +30,7 @@ public interface OwnerRepository extends Repository Page findAll(Pageable pageable); + List findAll(); + void deleteAll(); } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java index fef25ac7..56d3aa7b 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java @@ -32,6 +32,8 @@ * {@link Lazy}-Wrapper! Because SDES is making working copies of the stored data, the {@link Lazy} does not work as * expected. Instead, use this Wrapper. It brings the same functionality as the native {@link Lazy}-Wrapper but works * with working copies. + * + * @param the type of the lazily referenced element */ public interface SpringDataEclipseStoreLazy extends Lazy { @@ -57,11 +59,12 @@ static SpringDataEclipseStoreLazy.Default buildWithLazy(final Lazy laz } /** - * This class is very complex and its various membervariables all have their reason to exist. This code is very + * This class is very complex and its various member variables all have their reason to exist. This code is very * difficult to read due to its the functionality explained in the {@link SpringDataEclipseStoreLazyBinaryHandler}. * - * @param + * @param the type of the lazily referenced element */ + @SuppressWarnings({"java:S2065", "checkstyle:FinalClass"}) class Default implements SpringDataEclipseStoreLazy { private T objectToBeWrapped; @@ -69,7 +72,7 @@ class Default implements SpringDataEclipseStoreLazy private long objectId = Swizzling.notFoundId(); private transient ObjectSwizzling loader; private transient WorkingCopier copier; - private transient boolean isStored = false; + private transient boolean isStored; private Default(final Lazy lazySubject) { @@ -99,10 +102,10 @@ private Lazy ensureLazy() return this.wrappedLazy; } + @SuppressWarnings("unchecked") private Lazy createNewDefaultLazyWithClearableReference() { Objects.requireNonNull(this.loader); - Objects.requireNonNull(this.objectId); Objects.requireNonNull(this.copier); final T originalInstance = (T)this.loader.getObject(this.objectId); @@ -115,13 +118,6 @@ private Lazy createNewDefaultLazyWithClearableReference() ); } - @SuppressWarnings("all") - public static final Class> genericType() - { - // no idea how to get ".class" to work otherwise in conjunction with generics. - return (Class)SpringDataEclipseStoreLazy.Default.class; - } - @Override public T get() { @@ -195,9 +191,9 @@ public boolean clear(final ClearingEvaluator clearingEvaluator) @Override public long objectId() { - if(this.wrappedLazy != null && this.wrappedLazy instanceof Lazy.Default) + if(this.wrappedLazy != null && this.wrappedLazy instanceof final Lazy.Default wrappedTypedLazy) { - return ((Lazy.Default)this.wrappedLazy).objectId(); + return wrappedTypedLazy.objectId(); } return this.objectId; } @@ -217,7 +213,7 @@ public T getObjectToBeWrapped() @Override public SpringDataEclipseStoreLazy copyWithReference() { - final SpringDataEclipseStoreLazy.Default newLazy = new SpringDataEclipseStoreLazy.Default( + final SpringDataEclipseStoreLazy.Default newLazy = new SpringDataEclipseStoreLazy.Default<>( this.objectId(), this.loader, this.copier @@ -226,7 +222,6 @@ public SpringDataEclipseStoreLazy copyWithReference() return newLazy; } - // TODO is this necessary? @Override public void unlink() { @@ -234,10 +229,10 @@ public void unlink() { if(this.wrappedLazy != null) { - final Lazy.Default wrappedDefaultLazy = (Lazy.Default)this.wrappedLazy; + final Lazy.Default wrappedDefaultLazy = (Lazy.Default)this.wrappedLazy; wrappedDefaultLazy.$unlink(); final Field objectIdField = Lazy.Default.class.getDeclaredField("objectId"); - try(final FieldAccessModifier fam = FieldAccessModifier.prepareForField( + try(final FieldAccessModifier> fam = FieldAccessModifier.prepareForField( objectIdField, wrappedDefaultLazy)) { diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java index 13324385..95073f53 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java @@ -76,7 +76,7 @@ public SpringDataEclipseStoreLazyBinaryHandler( final WorkingCopier copier) { super( - SpringDataEclipseStoreLazy.Default.genericType(), + (Class)SpringDataEclipseStoreLazy.Default.class, CustomFields( CustomField(Object.class, "lazySubject"), CustomField(Object.class, "unwrappedSubject") From 7a6eec28f72da0fe7f5332c6041e7881a30d17b8 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Mon, 22 Apr 2024 09:14:03 +0200 Subject: [PATCH 77/98] Fix some checkstyle warnings --- .../PersonToTestInEclipseStoreRepository.java | 3 ++- .../store/helper/StorageDirectoryNameProvider.java | 8 ++++++-- .../isolated/tests/special/types/LazyDaoObject.java | 12 +++++++++--- .../isolated/tests/special/types/TypesData.java | 4 ++++ 4 files changed, 21 insertions(+), 6 deletions(-) diff --git a/spring-data-eclipse-store-jpa/src/test/java/software/xdev/spring/data/eclipse/store/jpa/integration/repository/PersonToTestInEclipseStoreRepository.java b/spring-data-eclipse-store-jpa/src/test/java/software/xdev/spring/data/eclipse/store/jpa/integration/repository/PersonToTestInEclipseStoreRepository.java index 1f2b5418..a5be72f5 100644 --- a/spring-data-eclipse-store-jpa/src/test/java/software/xdev/spring/data/eclipse/store/jpa/integration/repository/PersonToTestInEclipseStoreRepository.java +++ b/spring-data-eclipse-store-jpa/src/test/java/software/xdev/spring/data/eclipse/store/jpa/integration/repository/PersonToTestInEclipseStoreRepository.java @@ -3,6 +3,7 @@ import software.xdev.spring.data.eclipse.store.repository.interfaces.EclipseStoreListCrudRepository; -public interface PersonToTestInEclipseStoreRepository extends EclipseStoreListCrudRepository +public interface PersonToTestInEclipseStoreRepository + extends EclipseStoreListCrudRepository { } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/StorageDirectoryNameProvider.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/StorageDirectoryNameProvider.java index d34205b1..e63305fb 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/StorageDirectoryNameProvider.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/StorageDirectoryNameProvider.java @@ -20,10 +20,14 @@ public final class StorageDirectoryNameProvider { - private static final AtomicInteger seqNumber = new AtomicInteger(1); + private static final AtomicInteger SEQ_NUMBER = new AtomicInteger(1); + + private StorageDirectoryNameProvider() + { + } public static String getNewStorageDirectoryPath() { - return String.format("./target/tempstorage-%05d", seqNumber.getAndIncrement()); + return String.format("./target/tempstorage-%05d", SEQ_NUMBER.getAndIncrement()); } } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java index ad8f6f8d..f10223c8 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java @@ -27,6 +27,12 @@ public LazyDaoObject(final Integer id, final Lazy value) super(id, value); } + @Override + public int hashCode() + { + return super.hashCode(); + } + @Override public boolean equals(final Object o) { @@ -39,9 +45,9 @@ public boolean equals(final Object o) return false; } final ComplexObject> that = (ComplexObject>)o; - return Objects.equals(this.getId(), that.getId()) && - (this.getValue() == null && that.getValue() == null) || - Objects.equals( + return Objects.equals(this.getId(), that.getId()) + && (this.getValue() == null && that.getValue() == null) + || Objects.equals( this.getValue().get(), that.getValue().get()); } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java index 91241667..52cedb2d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java @@ -55,6 +55,10 @@ final class TypesData { + private TypesData() + { + } + public record ListOfTestArguments(List> testArguments) { public Stream toArguments() From e8cbefb3e6135e5d663252788411aade1effd832 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Mon, 22 Apr 2024 11:06:13 +0200 Subject: [PATCH 78/98] Refactoring --- CHANGELOG.md | 1 + docs/modules/ROOT/pages/lazies.adoc | 4 +- spring-data-eclipse-store/pom.xml | 1 + .../store/aot/EclipseStoreRuntimeHints.java | 2 +- .../data/eclipse/store/core/IdentitySet.java | 2 +- .../AlreadyRegisteredException.java | 2 +- .../DataTypeNotSupportedException.java | 2 +- .../exceptions/DifferentClassesException.java | 2 +- .../FieldAccessReflectionException.java | 2 +- .../exceptions/IdFieldFinalException.java | 2 +- .../IdGeneratorNotSupportedException.java | 2 +- .../LazyNotUnlinkableException.java | 9 +- .../exceptions/MergeFailedException.java | 2 +- .../exceptions/NoIdFieldFoundException.java | 2 +- .../NoPageableObjectFoundException.java | 2 +- .../exceptions/NotComparableException.java | 2 +- .../exceptions/StringBlankException.java | 2 +- .../importer/EclipseStoreDataImporter.java | 2 +- .../EclipseStoreDataImporterComponent.java | 3 +- .../store/repository/EclipseStoreStorage.java | 2 +- .../store/repository/EntityListProvider.java | 2 +- .../store/repository/EntitySetCollector.java | 2 +- .../store/repository/IdSetterProvider.java | 2 +- .../store/repository/PersistableChecker.java | 2 +- .../data/eclipse/store/repository/Query.java | 2 +- .../repository/RelayedPersistenceChecker.java | 2 +- .../data/eclipse/store/repository/Root.java | 2 +- .../store/repository/SupportedChecker.java | 4 +- .../store/repository/WorkingCopyRegistry.java | 2 +- .../store/repository/access/AccessHelper.java | 2 +- .../access/modifier/FieldAccessModifier.java | 2 +- .../access/modifier/FieldAccessibleMaker.java | 2 +- ...efaultEclipseStoreClientConfiguration.java | 2 +- .../EclipseStoreClientConfiguration.java | 2 +- .../EclipseStoreRepositoriesRegistrar.java | 2 +- ...StoreRepositoryConfigNamespaceHandler.java | 2 +- ...StoreRepositoryConfigurationExtension.java | 2 +- ...EclipseStoreStorageFoundationProvider.java | 3 +- .../EnableEclipseStoreRepositories.java | 5 +- .../EclipseStoreCrudRepository.java | 2 +- .../EclipseStoreCustomRepository.java | 2 +- .../EclipseStoreListCrudRepository.java | 2 +- ...tPagingAndSortingRepositoryRepository.java | 2 +- ...ePagingAndSortingRepositoryRepository.java | 2 +- .../interfaces/EclipseStoreRepository.java | 2 +- .../lazy/SpringDataEclipseStoreLazy.java | 2 +- ...ringDataEclipseStoreLazyBinaryHandler.java | 16 ++-- .../query/EclipseStoreQueryCreator.java | 2 +- .../FindAllEclipseStoreQueryProvider.java | 2 +- .../repository/query/ReflectedField.java | 2 +- .../StringBasedEclipseStoreQueryProvider.java | 2 +- .../query/criteria/AbstractCriteriaNode.java | 2 +- .../repository/query/criteria/Criteria.java | 2 +- .../query/criteria/CriteriaAndNode.java | 2 +- .../query/criteria/CriteriaOrNode.java | 2 +- .../query/criteria/CriteriaSingleNode.java | 2 +- .../query/executors/EntitySorter.java | 2 +- .../query/executors/ListQueryExecutor.java | 2 +- .../executors/PageableQueryExecutor.java | 2 +- .../PageableSortableCollectionQuerier.java | 2 +- .../query/executors/QueryExecutor.java | 2 +- .../query/executors/QueryExecutorCreator.java | 2 +- .../SingleOptionalQueryExecutor.java | 2 +- .../query/executors/SingleQueryExecutor.java | 2 +- .../EclipseStoreQueryLookupStrategy.java | 2 +- .../EclipseStoreRepositoryFactory.java | 2 +- .../EclipseStoreRepositoryFactoryBean.java | 2 +- .../repository/support/IdFieldFinder.java | 2 +- .../support/SimpleEclipseStoreRepository.java | 2 +- .../support/copier/DataTypeUtil.java | 2 +- .../support/copier/id/IdSetter.java | 2 +- .../support/copier/id/NotSettingIdSetter.java | 2 +- .../support/copier/id/SimpleIdSetter.java | 2 +- .../support/copier/id/strategy/IdFinder.java | 2 +- .../strategy/auto/AbstractAutoIdFinder.java | 2 +- .../id/strategy/auto/AutoIntegerIdFinder.java | 2 +- .../id/strategy/auto/AutoLongIdFinder.java | 2 +- .../id/strategy/auto/AutoStringIdFinder.java | 2 +- .../AbstractRegisteringCopier.java | 7 +- .../EclipseSerializerRegisteringCopier.java | 4 +- .../RegisteringObjectCopier.java | 4 +- ...RegisteringStorageToWorkingCopyCopier.java | 6 +- .../RegisteringWorkingCopyAndOriginal.java | 4 +- ...RegisteringWorkingCopyToStorageCopier.java | 6 +- .../working/ChangedObjectCollector.java | 2 +- .../HashSetChangedObjectCollector.java | 2 +- .../HashSetMergedTargetsCollector.java | 2 +- .../working/MergedTargetsCollector.java | 2 +- .../working/RecursiveWorkingCopier.java | 89 +++++++++++-------- .../support/copier/working/WorkingCopier.java | 2 +- .../copier/working/WorkingCopierCreator.java | 2 +- .../copier/working/WorkingCopierResult.java | 2 +- .../reposyncer/RepositorySynchronizer.java | 2 +- .../SimpleRepositorySynchronizer.java | 2 +- .../store/util/GenericObjectComparer.java | 2 +- .../data/eclipse/store/util/StringUtil.java | 2 +- .../store/helper/DummyWorkingCopier.java | 2 +- .../helper/StorageDirectoryNameProvider.java | 2 +- .../data/eclipse/store/helper/TestData.java | 2 +- .../data/eclipse/store/helper/TestUtil.java | 2 +- .../store/integration/TestConfiguration.java | 2 +- .../isolated/IsolatedTestAnnotations.java | 2 +- .../integration/isolated/package-info.java | 2 +- .../isolated/tests/keywords/KeywordsTest.java | 2 +- .../keywords/KeywordsTestConfiguration.java | 2 +- .../tests/keywords/MinimalDaoObject.java | 2 +- .../tests/keywords/MinimalRepository.java | 2 +- .../tests/lazy/ComplexLazyObject.java | 2 +- .../isolated/tests/lazy/LazyTest.java | 5 +- .../tests/lazy/LazyTestConfiguration.java | 2 +- .../isolated/tests/lazy/ObjectWithLazy.java | 2 +- .../tests/lazy/ObjectWithLazyHashMap.java | 2 +- .../lazy/ObjectWithLazyHashMapRepository.java | 2 +- .../tests/lazy/ObjectWithLazyHashSet.java | 2 +- .../lazy/ObjectWithLazyHashSetRepository.java | 2 +- .../tests/lazy/ObjectWithLazyList.java | 2 +- .../lazy/ObjectWithLazyListRepository.java | 2 +- .../tests/lazy/ObjectWithLazyRepository.java | 2 +- .../lazy/ObjectWithLazySimpleObject.java | 2 +- .../ObjectWithLazySimpleObjectRepository.java | 2 +- .../isolated/tests/lazy/SimpleObject.java | 2 +- .../special/types/BigDecimalDaoObject.java | 2 +- .../special/types/BigDecimalRepository.java | 2 +- .../special/types/BigIntegerDaoObject.java | 2 +- .../special/types/BigIntegerRepository.java | 2 +- .../special/types/CalendarDaoObject.java | 2 +- .../special/types/CalendarRepository.java | 2 +- .../tests/special/types/ComplexObject.java | 2 +- .../tests/special/types/DateDaoObject.java | 2 +- .../tests/special/types/DateRepository.java | 2 +- .../tests/special/types/EnumMapDaoObject.java | 2 +- .../special/types/EnumMapRepository.java | 2 +- .../tests/special/types/EnumSetDaoObject.java | 2 +- .../special/types/EnumSetRepository.java | 2 +- .../tests/special/types/LazyDaoObject.java | 2 +- .../tests/special/types/LazyRepository.java | 2 +- .../tests/special/types/ListDaoObject.java | 2 +- .../tests/special/types/ListRepository.java | 2 +- .../special/types/LocalDateDaoObject.java | 2 +- .../special/types/LocalDateRepository.java | 2 +- .../special/types/LocalDateTimeDaoObject.java | 2 +- .../types/LocalDateTimeRepository.java | 2 +- .../special/types/LocalTimeDaoObject.java | 2 +- .../special/types/LocalTimeRepository.java | 2 +- .../tests/special/types/MapDaoObject.java | 2 +- .../tests/special/types/MapRepository.java | 2 +- .../special/types/OptionalDaoObject.java | 2 +- .../special/types/OptionalRepository.java | 2 +- .../tests/special/types/SetDaoObject.java | 2 +- .../tests/special/types/SetRepository.java | 2 +- .../types/SpecialTypesTestConfiguration.java | 2 +- .../tests/special/types/TypesData.java | 2 +- .../tests/special/types/TypesTest.java | 2 +- .../shared/DefaultTestAnnotations.java | 2 +- .../shared/SharedTestConfiguration.java | 2 +- .../integration/shared/package-info.java | 2 +- .../shared/repositories/Child.java | 2 +- .../shared/repositories/ChildCustomer.java | 2 +- .../repositories/ChildCustomerRepository.java | 2 +- .../shared/repositories/Customer.java | 2 +- .../shared/repositories/CustomerAsRecord.java | 2 +- .../CustomerAsRecordRepository.java | 2 +- .../shared/repositories/CustomerNotCrud.java | 2 +- .../CustomerNotCrudRepository.java | 2 +- .../repositories/CustomerRepository.java | 2 +- .../CustomerRepositoryWithHashSet.java | 2 +- ...CustomerRepositoryWithNonFinalHashSet.java | 2 +- .../CustomerRepositoryWithQuery.java | 2 +- .../repositories/CustomerWithChild.java | 2 +- .../CustomerWithChildRepository.java | 2 +- .../repositories/CustomerWithHashSet.java | 2 +- .../CustomerWithNonFinalHashSet.java | 2 +- .../repositories/CustomerWithQuery.java | 2 +- .../integration/shared/repositories/Node.java | 2 +- .../shared/repositories/NodeRepository.java | 2 +- .../shared/repositories/Owner.java | 2 +- .../shared/repositories/OwnerRepository.java | 2 +- .../shared/repositories/ParentCustomer.java | 2 +- .../ParentCustomerRepository.java | 2 +- .../shared/repositories/SubCustomer.java | 2 +- .../repositories/SubCustomerRepository.java | 2 +- .../repositories/id/CustomerWithIdInt.java | 2 +- .../id/CustomerWithIdIntRepository.java | 2 +- .../id/CustomerWithIdInteger.java | 2 +- .../CustomerWithIdIntegerNoAutoGenerate.java | 2 +- ...WithIdIntegerNoAutoGenerateRepository.java | 2 +- .../id/CustomerWithIdIntegerRepository.java | 2 +- .../repositories/id/CustomerWithIdLong.java | 2 +- .../id/CustomerWithIdLongRepository.java | 2 +- .../repositories/id/CustomerWithIdString.java | 2 +- .../id/CustomerWithIdStringRepository.java | 2 +- .../repositories/id/CustomerWithPurchase.java | 2 +- .../id/CustomerWithPurchaseRepository.java | 2 +- .../shared/repositories/id/Purchase.java | 2 +- .../immutables/CustomerWithFinal.java | 2 +- .../immutables/CustomerWithFinalChild.java | 2 +- .../CustomerWithFinalChildRepository.java | 2 +- .../immutables/CustomerWithFinalId.java | 2 +- .../CustomerWithFinalIdRepository.java | 2 +- .../CustomerWithFinalRepository.java | 2 +- .../repositories/interfaces/CustomerCrud.java | 2 +- .../CustomerEclipseStoreCrudRepository.java | 2 +- ...ustomerEclipseStoreListCrudRepository.java | 2 +- ...seStoreListPagingAndSortingRepository.java | 2 +- ...clipseStorePagingAndSortingRepository.java | 2 +- .../CustomerEclipseStoreRepository.java | 2 +- .../interfaces/CustomerListCrud.java | 2 +- .../CustomerListPagingAndSorting.java | 2 +- .../interfaces/CustomerPagingAndSorting.java | 2 +- .../interfaces/CustomerSimple.java | 2 +- .../real/life/example/Article.java | 2 +- .../real/life/example/ArticleGroup.java | 2 +- .../real/life/example/Invoice.java | 2 +- .../real/life/example/InvoiceRepository.java | 2 +- .../real/life/example/Position.java | 2 +- .../real/life/example/PositionRepository.java | 2 +- .../real/life/example/Warehouse.java | 2 +- .../shared/tests/ChangeRootTests.java | 2 +- .../shared/tests/ConcurrencyTest.java | 2 +- .../integration/shared/tests/FinalTest.java | 2 +- .../integration/shared/tests/HashSetTest.java | 2 +- .../integration/shared/tests/IdTest.java | 2 +- .../shared/tests/InheritanceTest.java | 2 +- .../shared/tests/JpaCompatibilityTest.java | 2 +- .../integration/shared/tests/QueryTest.java | 2 +- .../shared/tests/RealLifeTests.java | 2 +- .../shared/tests/SimpleMultipleTest.java | 2 +- .../shared/tests/SimpleSingleTest.java | 2 +- .../shared/tests/SpecificInterfacesTest.java | 2 +- .../integration/shared/tests/StressTest.java | 2 +- .../shared/tests/WorkingCopyTests.java | 2 +- .../EclipseStoreQueryCreatorAndOrTest.java | 2 +- .../EclipseStoreQueryCreatorBooleanTest.java | 2 +- ...clipseStoreQueryCreatorCollectionTest.java | 2 +- ...lipseStoreQueryCreatorGreaterLessTest.java | 2 +- .../EclipseStoreQueryCreatorIsIsNotTest.java | 2 +- .../EclipseStoreQueryCreatorStringTest.java | 2 +- .../repository/query/QueryCreatorUtil.java | 2 +- ...PageableSortableCollectionQuerierTest.java | 2 +- .../support/copier/DataTypeUtilTest.java | 2 +- ...steringStorageToWorkingCopyCopierTest.java | 15 ++-- 241 files changed, 333 insertions(+), 299 deletions(-) rename spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/{copier => registering}/AbstractRegisteringCopier.java (95%) rename spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/{copier => registering}/EclipseSerializerRegisteringCopier.java (98%) rename spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/{copier => registering}/RegisteringObjectCopier.java (89%) rename spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/{copier => registering}/RegisteringStorageToWorkingCopyCopier.java (90%) rename spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/{copier => registering}/RegisteringWorkingCopyAndOriginal.java (90%) rename spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/{copier => registering}/RegisteringWorkingCopyToStorageCopier.java (89%) rename spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/{copier => registering}/RegisteringStorageToWorkingCopyCopierTest.java (91%) diff --git a/CHANGELOG.md b/CHANGELOG.md index a11d28d0..5a255ec2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ * Added possibility to use multiple storages * Added Lazy support +* Updated EclipseStore to version 1.3.1 # 1.0.3 diff --git a/docs/modules/ROOT/pages/lazies.adoc b/docs/modules/ROOT/pages/lazies.adoc index f568afee..55f93cbc 100644 --- a/docs/modules/ROOT/pages/lazies.adoc +++ b/docs/modules/ROOT/pages/lazies.adoc @@ -5,8 +5,8 @@ The basic mechanism is best explained in the https://docs.eclipsestore.io/manual In essence java objects which are wrapped in a *Lazy-Reference are not loaded with the startup of the EclipseStore-Storage but only if ``get()`` is called* on them. Lazy References are essential for big data sets that can't get loaded into memory. -Since {product-name} operates with xref:working-copies.adoc[working copies] using the EclipseStore-Lazy-References is not possible. -All Lazy References would be resolved and loaded into memory anyway. +Since {product-name} operates with xref:working-copies.adoc[working copies] using the EclipseStore-Lazy-References is not possible. + +If you are using the EclipseStore-Lazy-References, all references would be resolved and loaded into memory as soon as a working copy is created, because the ``get()``-Method is called to create a full working copy. That's why we implemented ``SpringDataEclipseStoreLazy``. + The usage is the same as with the EclipseStore-Lazies, but they are handled very differently. diff --git a/spring-data-eclipse-store/pom.xml b/spring-data-eclipse-store/pom.xml index fc24c45d..75948fe8 100644 --- a/spring-data-eclipse-store/pom.xml +++ b/spring-data-eclipse-store/pom.xml @@ -200,6 +200,7 @@ ${project.organization.url} + 2024 diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/aot/EclipseStoreRuntimeHints.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/aot/EclipseStoreRuntimeHints.java index 20352c97..8055cdae 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/aot/EclipseStoreRuntimeHints.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/aot/EclipseStoreRuntimeHints.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/core/IdentitySet.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/core/IdentitySet.java index d5af7575..2545c21c 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/core/IdentitySet.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/core/IdentitySet.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/AlreadyRegisteredException.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/AlreadyRegisteredException.java index a0ba3bf7..83b59d8c 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/AlreadyRegisteredException.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/AlreadyRegisteredException.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/DataTypeNotSupportedException.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/DataTypeNotSupportedException.java index c6184649..8f0b3579 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/DataTypeNotSupportedException.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/DataTypeNotSupportedException.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/DifferentClassesException.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/DifferentClassesException.java index 9eee8d81..ebe9a16b 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/DifferentClassesException.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/DifferentClassesException.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/FieldAccessReflectionException.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/FieldAccessReflectionException.java index a5c854c7..d64206ef 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/FieldAccessReflectionException.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/FieldAccessReflectionException.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/IdFieldFinalException.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/IdFieldFinalException.java index 2abfa3e2..144e2c55 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/IdFieldFinalException.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/IdFieldFinalException.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/IdGeneratorNotSupportedException.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/IdGeneratorNotSupportedException.java index 808049b7..98f221fc 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/IdGeneratorNotSupportedException.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/IdGeneratorNotSupportedException.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/LazyNotUnlinkableException.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/LazyNotUnlinkableException.java index 8c89e5cc..4bb9978f 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/LazyNotUnlinkableException.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/LazyNotUnlinkableException.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -15,6 +15,13 @@ */ package software.xdev.spring.data.eclipse.store.exceptions; +/** + * Is used when a {@link software.xdev.spring.data.eclipse.store.repository.lazy.SpringDataEclipseStoreLazy} is not able + * to get unlinked from the object tree. + *

+ * This exception should not be created by the user, but only within the Spring-Data-Eclipse-Store-Library. + *

+ */ public class LazyNotUnlinkableException extends RuntimeException { public LazyNotUnlinkableException(final String message, final Throwable e) diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/MergeFailedException.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/MergeFailedException.java index 0ce35b02..0a602b3c 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/MergeFailedException.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/MergeFailedException.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/NoIdFieldFoundException.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/NoIdFieldFoundException.java index cd9c6f7f..2f612539 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/NoIdFieldFoundException.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/NoIdFieldFoundException.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/NoPageableObjectFoundException.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/NoPageableObjectFoundException.java index c49733a4..3c71f94d 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/NoPageableObjectFoundException.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/NoPageableObjectFoundException.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/NotComparableException.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/NotComparableException.java index 115e2b8f..b5fe9aa1 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/NotComparableException.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/NotComparableException.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/StringBlankException.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/StringBlankException.java index 78d203f2..0546e418 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/StringBlankException.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/exceptions/StringBlankException.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporter.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporter.java index b21fc73c..c6109fa7 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporter.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporter.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporterComponent.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporterComponent.java index 4c024223..ddeb3add 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporterComponent.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/importer/EclipseStoreDataImporterComponent.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -56,6 +56,7 @@ public EclipseStoreDataImporterComponent( * * @return all the newly created {@link SimpleEclipseStoreRepository} for the specific entities. */ + @SuppressWarnings("java:S1452") public List> importData() { final Map beansOfEms = diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java index b4d8145f..a7764eb8 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EclipseStoreStorage.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EntityListProvider.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EntityListProvider.java index 1be8b552..e69c5f7b 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EntityListProvider.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EntityListProvider.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EntitySetCollector.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EntitySetCollector.java index d25edbfc..6d5b6936 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EntitySetCollector.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/EntitySetCollector.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/IdSetterProvider.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/IdSetterProvider.java index 1e2e7133..08b9536c 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/IdSetterProvider.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/IdSetterProvider.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/PersistableChecker.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/PersistableChecker.java index b342a204..7a70c405 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/PersistableChecker.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/PersistableChecker.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/Query.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/Query.java index f56ba3f1..9099f492 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/Query.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/Query.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/RelayedPersistenceChecker.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/RelayedPersistenceChecker.java index ab89f64a..0f82d03a 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/RelayedPersistenceChecker.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/RelayedPersistenceChecker.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/Root.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/Root.java index ad078410..7ccbbc7f 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/Root.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/Root.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/SupportedChecker.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/SupportedChecker.java index 9f143ab3..c09d5180 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/SupportedChecker.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/SupportedChecker.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -63,7 +63,7 @@ class Implementation implements SupportedChecker @Override public boolean isSupported(final Class clazz) { - return !UNSUPPORTED_DATA_TYPES.stream().anyMatch( + return UNSUPPORTED_DATA_TYPES.stream().noneMatch( unsupportedClazz -> unsupportedClazz.isAssignableFrom(clazz) ); } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/WorkingCopyRegistry.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/WorkingCopyRegistry.java index 9674fdb7..59d1422a 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/WorkingCopyRegistry.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/WorkingCopyRegistry.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/AccessHelper.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/AccessHelper.java index e77ef59f..06649b8a 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/AccessHelper.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/AccessHelper.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/modifier/FieldAccessModifier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/modifier/FieldAccessModifier.java index bd56de35..cee4cae2 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/modifier/FieldAccessModifier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/modifier/FieldAccessModifier.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/modifier/FieldAccessibleMaker.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/modifier/FieldAccessibleMaker.java index 5c0633d8..4381aff5 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/modifier/FieldAccessibleMaker.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/access/modifier/FieldAccessibleMaker.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/DefaultEclipseStoreClientConfiguration.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/DefaultEclipseStoreClientConfiguration.java index d621947d..d9659623 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/DefaultEclipseStoreClientConfiguration.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/DefaultEclipseStoreClientConfiguration.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreClientConfiguration.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreClientConfiguration.java index 4247b395..05f04c80 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreClientConfiguration.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreClientConfiguration.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoriesRegistrar.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoriesRegistrar.java index 5caeb6b7..c6fc042f 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoriesRegistrar.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoriesRegistrar.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoryConfigNamespaceHandler.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoryConfigNamespaceHandler.java index 61f3f770..a8d49b08 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoryConfigNamespaceHandler.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoryConfigNamespaceHandler.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoryConfigurationExtension.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoryConfigurationExtension.java index ecba9603..28fcd20f 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoryConfigurationExtension.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreRepositoryConfigurationExtension.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreStorageFoundationProvider.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreStorageFoundationProvider.java index 259c87e4..f01dfd08 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreStorageFoundationProvider.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EclipseStoreStorageFoundationProvider.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -24,5 +24,6 @@ */ public interface EclipseStoreStorageFoundationProvider { + @SuppressWarnings("java:S1452") EmbeddedStorageFoundation createEmbeddedStorageFoundation(); } diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EnableEclipseStoreRepositories.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EnableEclipseStoreRepositories.java index 405e033a..442e6be8 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EnableEclipseStoreRepositories.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/config/EnableEclipseStoreRepositories.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -45,7 +45,8 @@ @ComponentScan({ "software.xdev.spring.data.eclipse.store.importer", "software.xdev.spring.data.eclipse.store.repository", - "org.eclipse.store.integrations.spring.boot.types"}) + "org.eclipse.store.integrations.spring.boot.types", + "org.eclipse.store.integrations.spring.boot.types.converter"}) public @interface EnableEclipseStoreRepositories { diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreCrudRepository.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreCrudRepository.java index f9336ec4..325610c4 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreCrudRepository.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreCrudRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreCustomRepository.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreCustomRepository.java index f8883714..97c7b09e 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreCustomRepository.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreCustomRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreListCrudRepository.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreListCrudRepository.java index 700559fb..ac91ce71 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreListCrudRepository.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreListCrudRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreListPagingAndSortingRepositoryRepository.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreListPagingAndSortingRepositoryRepository.java index 1323550a..34a774fb 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreListPagingAndSortingRepositoryRepository.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreListPagingAndSortingRepositoryRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStorePagingAndSortingRepositoryRepository.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStorePagingAndSortingRepositoryRepository.java index c79b7238..33e65618 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStorePagingAndSortingRepositoryRepository.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStorePagingAndSortingRepositoryRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreRepository.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreRepository.java index 6ba02530..f70c739c 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreRepository.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/interfaces/EclipseStoreRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java index 56d3aa7b..5e9fdf72 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazy.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java index 95073f53..dfd6700a 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -34,7 +34,7 @@ /** * This is a complicated one. First off: this handler should only be used for WorkingCopies (see - * {@link software.xdev.spring.data.eclipse.store.repository.support.copier.copier.EclipseSerializerRegisteringCopier})! + * {@link software.xdev.spring.data.eclipse.store.repository.support.copier.registering.EclipseSerializerRegisteringCopier})! *

* First case:
* The user creates a {@link SpringDataEclipseStoreLazy} and puts a object in it. @@ -45,7 +45,7 @@ * Second case:
* The actual lazy object gets loaded from the actual storage. In this case the {@link ObjectSwizzling} is * important! It's the actual {@link ObjectSwizzling} from the storage (not from the - * {@link software.xdev.spring.data.eclipse.store.repository.support.copier.copier.EclipseSerializerRegisteringCopier}). + * {@link software.xdev.spring.data.eclipse.store.repository.support.copier.registering.EclipseSerializerRegisteringCopier}). * This means, the {@link SpringDataEclipseStoreLazy} holds the objectId of the original lazy in the original * storage. * Therefore if {@link SpringDataEclipseStoreLazy#get()} is called a new working copy of the lazy from the @@ -65,8 +65,8 @@ public final class SpringDataEclipseStoreLazyBinaryHandler ) ); - public static final int OFFSET_UNWRAPPED_OBJECT = 8; - public static final int OFFSET_LAZY = 0; + private static final int OFFSET_UNWRAPPED_OBJECT = 8; + private static final int OFFSET_LAZY = 0; private final ObjectSwizzling originalStoreLoader; private final WorkingCopier copier; @@ -76,6 +76,7 @@ public SpringDataEclipseStoreLazyBinaryHandler( final WorkingCopier copier) { super( + // Cast is necessary for the compiler (Class)SpringDataEclipseStoreLazy.Default.class, CustomFields( CustomField(Object.class, "lazySubject"), @@ -83,7 +84,7 @@ public SpringDataEclipseStoreLazyBinaryHandler( ) ); this.originalStoreLoader = Objects.requireNonNull(originalStoreLoader); - this.copier = copier; + this.copier = Objects.requireNonNull(copier); } @Override @@ -98,8 +99,7 @@ public void store( if(instance.isOriginalObject()) { // Store unwrapped Object - final long newObjectId = handler.applyEager(instance.getObjectToBeWrapped()); - data.store_long(OFFSET_UNWRAPPED_OBJECT, newObjectId); + data.store_long(OFFSET_UNWRAPPED_OBJECT, handler.applyEager(instance.getObjectToBeWrapped())); } else { diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreator.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreator.java index fb685694..6bed9ef5 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreator.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreator.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/FindAllEclipseStoreQueryProvider.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/FindAllEclipseStoreQueryProvider.java index 77e2de71..175e47b6 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/FindAllEclipseStoreQueryProvider.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/FindAllEclipseStoreQueryProvider.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/ReflectedField.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/ReflectedField.java index f3ece752..2fb19a78 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/ReflectedField.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/ReflectedField.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/StringBasedEclipseStoreQueryProvider.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/StringBasedEclipseStoreQueryProvider.java index 9fdfd8ca..957e958b 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/StringBasedEclipseStoreQueryProvider.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/StringBasedEclipseStoreQueryProvider.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/AbstractCriteriaNode.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/AbstractCriteriaNode.java index 876e3e42..fc62538a 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/AbstractCriteriaNode.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/AbstractCriteriaNode.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/Criteria.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/Criteria.java index 1ea456cd..7a211d7c 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/Criteria.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/Criteria.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/CriteriaAndNode.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/CriteriaAndNode.java index adcf44b4..0c683857 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/CriteriaAndNode.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/CriteriaAndNode.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/CriteriaOrNode.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/CriteriaOrNode.java index d7e84dd9..4e22b1b3 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/CriteriaOrNode.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/CriteriaOrNode.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/CriteriaSingleNode.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/CriteriaSingleNode.java index e6eddeeb..a0237d39 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/CriteriaSingleNode.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/criteria/CriteriaSingleNode.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/EntitySorter.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/EntitySorter.java index b34e1efb..48d7e5d9 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/EntitySorter.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/EntitySorter.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/ListQueryExecutor.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/ListQueryExecutor.java index 3a9d13e8..535036a2 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/ListQueryExecutor.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/ListQueryExecutor.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/PageableQueryExecutor.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/PageableQueryExecutor.java index cb4fe7ce..c21ffe16 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/PageableQueryExecutor.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/PageableQueryExecutor.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/PageableSortableCollectionQuerier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/PageableSortableCollectionQuerier.java index 25dc3923..13901115 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/PageableSortableCollectionQuerier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/PageableSortableCollectionQuerier.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/QueryExecutor.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/QueryExecutor.java index ebe92070..c2b312af 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/QueryExecutor.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/QueryExecutor.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/QueryExecutorCreator.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/QueryExecutorCreator.java index c5027e90..f802a9a8 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/QueryExecutorCreator.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/QueryExecutorCreator.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/SingleOptionalQueryExecutor.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/SingleOptionalQueryExecutor.java index eb06865b..ef0a98fa 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/SingleOptionalQueryExecutor.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/SingleOptionalQueryExecutor.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/SingleQueryExecutor.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/SingleQueryExecutor.java index 620cfd9f..d5f1c95f 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/SingleQueryExecutor.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/query/executors/SingleQueryExecutor.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreQueryLookupStrategy.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreQueryLookupStrategy.java index 3f0bf32b..06ca3f2b 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreQueryLookupStrategy.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreQueryLookupStrategy.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreRepositoryFactory.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreRepositoryFactory.java index 970a1ea2..f5ab612c 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreRepositoryFactory.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreRepositoryFactory.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreRepositoryFactoryBean.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreRepositoryFactoryBean.java index 6ab1907f..fb859e62 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreRepositoryFactoryBean.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/EclipseStoreRepositoryFactoryBean.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/IdFieldFinder.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/IdFieldFinder.java index c956cf6a..2e0a31e5 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/IdFieldFinder.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/IdFieldFinder.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/SimpleEclipseStoreRepository.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/SimpleEclipseStoreRepository.java index 2672f9d9..8e5ef8cc 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/SimpleEclipseStoreRepository.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/SimpleEclipseStoreRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/DataTypeUtil.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/DataTypeUtil.java index 1c56d322..7101400d 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/DataTypeUtil.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/DataTypeUtil.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/IdSetter.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/IdSetter.java index f3a08497..9a2f1da0 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/IdSetter.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/IdSetter.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/NotSettingIdSetter.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/NotSettingIdSetter.java index 4177bf27..c299b55d 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/NotSettingIdSetter.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/NotSettingIdSetter.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/SimpleIdSetter.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/SimpleIdSetter.java index 4be7128d..e59bc75f 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/SimpleIdSetter.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/SimpleIdSetter.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/IdFinder.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/IdFinder.java index b26de773..2618fa2b 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/IdFinder.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/IdFinder.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/auto/AbstractAutoIdFinder.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/auto/AbstractAutoIdFinder.java index ac603696..beb768f2 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/auto/AbstractAutoIdFinder.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/auto/AbstractAutoIdFinder.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/auto/AutoIntegerIdFinder.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/auto/AutoIntegerIdFinder.java index 39602d50..0f4b4535 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/auto/AutoIntegerIdFinder.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/auto/AutoIntegerIdFinder.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/auto/AutoLongIdFinder.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/auto/AutoLongIdFinder.java index db1e5ea9..b3b41e56 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/auto/AutoLongIdFinder.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/auto/AutoLongIdFinder.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/auto/AutoStringIdFinder.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/auto/AutoStringIdFinder.java index c4e835eb..afc2cbca 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/auto/AutoStringIdFinder.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/id/strategy/auto/AutoStringIdFinder.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/AbstractRegisteringCopier.java similarity index 95% rename from spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java rename to spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/AbstractRegisteringCopier.java index 51ef272e..d5bc900d 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/AbstractRegisteringCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/AbstractRegisteringCopier.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; +package software.xdev.spring.data.eclipse.store.repository.support.copier.registering; import org.eclipse.serializer.Serializer; import org.eclipse.serializer.SerializerFoundation; @@ -38,7 +38,7 @@ public abstract class AbstractRegisteringCopier implements RegisteringObjectCopi { private final EclipseSerializerRegisteringCopier actualCopier; - public AbstractRegisteringCopier( + protected AbstractRegisteringCopier( final SupportedChecker supportedChecker, final RegisteringWorkingCopyAndOriginal register, final ObjectSwizzling objectSwizzling, @@ -67,6 +67,7 @@ private PersistenceManager createPersistenceManager( .createPersistenceManager(); } + @SuppressWarnings("java:S1452") protected SerializerFoundation createSerializerFoundation() { final Reference buffer = X.Reference(null); diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/EclipseSerializerRegisteringCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/EclipseSerializerRegisteringCopier.java similarity index 98% rename from spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/EclipseSerializerRegisteringCopier.java rename to spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/EclipseSerializerRegisteringCopier.java index 4420a5a4..5ec09598 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/EclipseSerializerRegisteringCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/EclipseSerializerRegisteringCopier.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; +package software.xdev.spring.data.eclipse.store.repository.support.copier.registering; import java.util.HashMap; import java.util.Map; diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringObjectCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/RegisteringObjectCopier.java similarity index 89% rename from spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringObjectCopier.java rename to spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/RegisteringObjectCopier.java index e111941e..146cd700 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringObjectCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/RegisteringObjectCopier.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; +package software.xdev.spring.data.eclipse.store.repository.support.copier.registering; public interface RegisteringObjectCopier extends AutoCloseable { diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/RegisteringStorageToWorkingCopyCopier.java similarity index 90% rename from spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java rename to spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/RegisteringStorageToWorkingCopyCopier.java index 11084ac4..df11886e 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/RegisteringStorageToWorkingCopyCopier.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; +package software.xdev.spring.data.eclipse.store.repository.support.copier.registering; import org.eclipse.serializer.reference.ObjectSwizzling; @@ -36,7 +36,7 @@ public RegisteringStorageToWorkingCopyCopier( { super( supportedChecker, - (workingCopy, objectToStore) -> registry.register(workingCopy, objectToStore), + registry::register, objectSwizzling, copier ); diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyAndOriginal.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/RegisteringWorkingCopyAndOriginal.java similarity index 90% rename from spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyAndOriginal.java rename to spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/RegisteringWorkingCopyAndOriginal.java index b1153bae..3a9ca24d 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyAndOriginal.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/RegisteringWorkingCopyAndOriginal.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; +package software.xdev.spring.data.eclipse.store.repository.support.copier.registering; @FunctionalInterface public interface RegisteringWorkingCopyAndOriginal diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/RegisteringWorkingCopyToStorageCopier.java similarity index 89% rename from spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java rename to spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/RegisteringWorkingCopyToStorageCopier.java index e137ff5c..9fdc45f7 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringWorkingCopyToStorageCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/RegisteringWorkingCopyToStorageCopier.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; +package software.xdev.spring.data.eclipse.store.repository.support.copier.registering; import org.eclipse.serializer.reference.ObjectSwizzling; @@ -37,7 +37,7 @@ public RegisteringWorkingCopyToStorageCopier( { super( supportedChecker, - (workingCopy, objectToStore) -> registry.invertRegister(workingCopy, objectToStore), + registry::invertRegister, objectSwizzling, copier ); diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/ChangedObjectCollector.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/ChangedObjectCollector.java index d1cd9f5b..c3461f20 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/ChangedObjectCollector.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/ChangedObjectCollector.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/HashSetChangedObjectCollector.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/HashSetChangedObjectCollector.java index dc9fad70..fd3f31b1 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/HashSetChangedObjectCollector.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/HashSetChangedObjectCollector.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/HashSetMergedTargetsCollector.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/HashSetMergedTargetsCollector.java index 4e1c7cbc..3569e548 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/HashSetMergedTargetsCollector.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/HashSetMergedTargetsCollector.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/MergedTargetsCollector.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/MergedTargetsCollector.java index 86112646..4efaa8ad 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/MergedTargetsCollector.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/MergedTargetsCollector.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java index 25279520..c03949fa 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/RecursiveWorkingCopier.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -41,9 +41,9 @@ import software.xdev.spring.data.eclipse.store.repository.access.modifier.FieldAccessModifier; import software.xdev.spring.data.eclipse.store.repository.lazy.SpringDataEclipseStoreLazy; import software.xdev.spring.data.eclipse.store.repository.support.copier.DataTypeUtil; -import software.xdev.spring.data.eclipse.store.repository.support.copier.copier.RegisteringObjectCopier; -import software.xdev.spring.data.eclipse.store.repository.support.copier.copier.RegisteringStorageToWorkingCopyCopier; -import software.xdev.spring.data.eclipse.store.repository.support.copier.copier.RegisteringWorkingCopyToStorageCopier; +import software.xdev.spring.data.eclipse.store.repository.support.copier.registering.RegisteringObjectCopier; +import software.xdev.spring.data.eclipse.store.repository.support.copier.registering.RegisteringStorageToWorkingCopyCopier; +import software.xdev.spring.data.eclipse.store.repository.support.copier.registering.RegisteringWorkingCopyToStorageCopier; /** @@ -274,37 +274,14 @@ else if(DataTypeUtil.isSpringDataEclipseStoreLazy(valueOfSourceObject)) { // "Simple" object // get original value object - final Object originalValueObjectOfSource = - this.getOrCreateObjectForDatastore( - valueOfSourceObject, - false, - alreadyMergedTargets, - changedCollector); - if(valueOfTargetObject != originalValueObjectOfSource) - { - // If the reference is new, it must be set - fam.writeValueOfField( - targetObject, - originalValueObjectOfSource, - !targetObjectIsPartOfJavaPackage); - } - - if(this.isSpecialCaseWhereOnlyAFullCopyWorks(valueOfSourceObject)) - { - fam.writeValueOfField( - targetObject, - this.onlyCreateCopy(valueOfSourceObject, true), - !targetObjectIsPartOfJavaPackage); - } - else - { - // Merge after setting reference to avoid endless loops - this.mergeValues( - valueOfSourceObject, - originalValueObjectOfSource, - alreadyMergedTargets, - changedCollector); - } + this.mergeSimpleObjectValue( + targetObject, + alreadyMergedTargets, + changedCollector, + valueOfSourceObject, + valueOfTargetObject, + fam, + targetObjectIsPartOfJavaPackage); } } } @@ -315,6 +292,48 @@ else if(DataTypeUtil.isSpringDataEclipseStoreLazy(valueOfSourceObject)) } } + private void mergeSimpleObjectValue( + final E targetObject, + final MergedTargetsCollector alreadyMergedTargets, + final ChangedObjectCollector changedCollector, + final Object valueOfSourceObject, + final Object valueOfTargetObject, + final FieldAccessModifier fam, + final boolean targetObjectIsPartOfJavaPackage) throws IllegalAccessException + { + final Object originalValueObjectOfSource = + this.getOrCreateObjectForDatastore( + valueOfSourceObject, + false, + alreadyMergedTargets, + changedCollector); + if(valueOfTargetObject != originalValueObjectOfSource) + { + // If the reference is new, it must be set + fam.writeValueOfField( + targetObject, + originalValueObjectOfSource, + !targetObjectIsPartOfJavaPackage); + } + + if(this.isSpecialCaseWhereOnlyAFullCopyWorks(valueOfSourceObject)) + { + fam.writeValueOfField( + targetObject, + this.onlyCreateCopy(valueOfSourceObject, true), + !targetObjectIsPartOfJavaPackage); + } + else + { + // Merge after setting reference to avoid endless loops + this.mergeValues( + valueOfSourceObject, + originalValueObjectOfSource, + alreadyMergedTargets, + changedCollector); + } + } + private SpringDataEclipseStoreLazy createNewLazy( final SpringDataEclipseStoreLazy oldLazy, final SpringDataEclipseStoreLazy newLazy, diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/WorkingCopier.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/WorkingCopier.java index 43a8f928..fdf84e73 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/WorkingCopier.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/WorkingCopier.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/WorkingCopierCreator.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/WorkingCopierCreator.java index e5415938..4f0a50a8 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/WorkingCopierCreator.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/WorkingCopierCreator.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/WorkingCopierResult.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/WorkingCopierResult.java index b780b2da..c88bc711 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/WorkingCopierResult.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/copier/working/WorkingCopierResult.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/reposyncer/RepositorySynchronizer.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/reposyncer/RepositorySynchronizer.java index b071aae5..399552a2 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/reposyncer/RepositorySynchronizer.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/reposyncer/RepositorySynchronizer.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/reposyncer/SimpleRepositorySynchronizer.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/reposyncer/SimpleRepositorySynchronizer.java index 644b4fa8..5b812d77 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/reposyncer/SimpleRepositorySynchronizer.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/support/reposyncer/SimpleRepositorySynchronizer.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/util/GenericObjectComparer.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/util/GenericObjectComparer.java index 22bf49b3..633f6544 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/util/GenericObjectComparer.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/util/GenericObjectComparer.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/util/StringUtil.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/util/StringUtil.java index bcf1a600..8bea8d55 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/util/StringUtil.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/util/StringUtil.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/DummyWorkingCopier.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/DummyWorkingCopier.java index 2875144c..d07d0627 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/DummyWorkingCopier.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/DummyWorkingCopier.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/StorageDirectoryNameProvider.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/StorageDirectoryNameProvider.java index e63305fb..2813f208 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/StorageDirectoryNameProvider.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/StorageDirectoryNameProvider.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/TestData.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/TestData.java index 7ab5dddd..683d5e69 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/TestData.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/TestData.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/TestUtil.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/TestUtil.java index 5def490f..dcfc4e77 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/TestUtil.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/helper/TestUtil.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java index 855f7e5e..3f6557fd 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/TestConfiguration.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java index 0fddcacf..164c75e1 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/IsolatedTestAnnotations.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/package-info.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/package-info.java index a5d558eb..917d49c7 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/package-info.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/package-info.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java index 348d8980..e4e09179 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTestConfiguration.java index 241d778d..6c3d3a65 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTestConfiguration.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/KeywordsTestConfiguration.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalDaoObject.java index f306c867..c7c52c70 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalDaoObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalRepository.java index c1db0a3f..534c042b 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/keywords/MinimalRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ComplexLazyObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ComplexLazyObject.java index 07b57b68..02413a96 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ComplexLazyObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ComplexLazyObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java index dd1ce194..a9b5c3ff 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -318,7 +318,8 @@ void lazyClearBeforeSave() final ObjectWithLazy newLazy = new ObjectWithLazy<>(); final SimpleObject objectToStore = new SimpleObject(TestData.DUMMY_STRING); newLazy.setLazy(SpringDataEclipseStoreLazy.build(objectToStore)); - Assertions.assertThrows(IllegalStateException.class, () -> newLazy.getLazy().clear()); + final Lazy lazy = newLazy.getLazy(); + Assertions.assertThrows(IllegalStateException.class, () -> lazy.clear()); } @Test diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTestConfiguration.java index 625c98da..75dcafa4 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTestConfiguration.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/LazyTestConfiguration.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazy.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazy.java index 88a8eeb8..f670d298 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazy.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazy.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashMap.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashMap.java index 3ea0d2fd..10b2f430 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashMap.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashMap.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashMapRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashMapRepository.java index 7389aebb..3a4f8857 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashMapRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashMapRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashSet.java index 7a366f72..2f8b0cd4 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashSet.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashSet.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashSetRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashSetRepository.java index cffb92aa..070ff4b8 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashSetRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyHashSetRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyList.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyList.java index dc608f8e..e15783c0 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyList.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyList.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyListRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyListRepository.java index 964f6117..773e1d0d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyListRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyListRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyRepository.java index aab0c595..a0e4164f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazyRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazySimpleObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazySimpleObject.java index 3ae4c2b8..75dbfb07 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazySimpleObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazySimpleObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazySimpleObjectRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazySimpleObjectRepository.java index 9d413d7f..4bd550a6 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazySimpleObjectRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/ObjectWithLazySimpleObjectRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/SimpleObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/SimpleObject.java index 96d53b3e..f09879e4 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/SimpleObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/lazy/SimpleObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalDaoObject.java index 52c42c58..bbb331d6 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalDaoObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalRepository.java index f56eb4a8..44451dde 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigDecimalRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerDaoObject.java index 90dc44f1..5dba8163 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerDaoObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerRepository.java index 74a8d364..7dcc0f5e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/BigIntegerRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarDaoObject.java index 3b835475..df30ccbc 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarDaoObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarRepository.java index 187d33fb..85451deb 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/CalendarRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ComplexObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ComplexObject.java index 5561bb6c..6c5b61ab 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ComplexObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ComplexObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateDaoObject.java index f93dfa12..6a3b066f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateDaoObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateRepository.java index f967c16f..b25a000d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/DateRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapDaoObject.java index cd81c07c..dfd07ec3 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapDaoObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapRepository.java index 4f49be48..77f5ce6e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumMapRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetDaoObject.java index 31acf389..01738257 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetDaoObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetRepository.java index f2f186b8..aea2509a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/EnumSetRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java index f10223c8..a58bf983 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyDaoObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyRepository.java index a3cd5e37..812806ee 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LazyRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListDaoObject.java index f4cb80e7..8d6b1154 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListDaoObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListRepository.java index b0351524..3aad2865 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/ListRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateDaoObject.java index bf6cf781..c232caa1 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateDaoObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateRepository.java index 0aa50229..a44c110d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeDaoObject.java index 169ea937..6a4e5ac9 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeDaoObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeRepository.java index 737c6ebf..c5d83582 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalDateTimeRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeDaoObject.java index 953aeab5..6ae4c6b1 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeDaoObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeRepository.java index db1cac67..046295b0 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/LocalTimeRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapDaoObject.java index 372ec6b3..fc466f74 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapDaoObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapRepository.java index ebbb1d18..4e9e790d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/MapRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalDaoObject.java index 228abedc..6a50a276 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalDaoObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalRepository.java index 7868afc6..be0456d0 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/OptionalRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetDaoObject.java index be214b09..07dcf5dc 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetDaoObject.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetRepository.java index e3ed468b..c75f089f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SetRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SpecialTypesTestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SpecialTypesTestConfiguration.java index 1dfe164e..54a8bc9a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SpecialTypesTestConfiguration.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/SpecialTypesTestConfiguration.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java index 52cedb2d..0062d6de 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesData.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java index d7278d7a..2cc4ac96 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/special/types/TypesTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/DefaultTestAnnotations.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/DefaultTestAnnotations.java index 41a134d6..84295620 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/DefaultTestAnnotations.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/DefaultTestAnnotations.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/SharedTestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/SharedTestConfiguration.java index d4b6a582..565c2270 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/SharedTestConfiguration.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/SharedTestConfiguration.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/package-info.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/package-info.java index 77b2d9f2..0c47ebef 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/package-info.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/package-info.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Child.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Child.java index 549da2db..64521977 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Child.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Child.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomer.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomer.java index a243bdfe..136fb6b1 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomer.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomer.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomerRepository.java index 08622099..a45bed32 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ChildCustomerRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Customer.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Customer.java index 2ef2e24d..767ef6d9 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Customer.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Customer.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecord.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecord.java index 9c9df6c7..ab242afa 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecord.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecord.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecordRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecordRepository.java index a28803fa..8119fc23 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecordRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerAsRecordRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrud.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrud.java index fe960ddd..00835cdc 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrud.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrud.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrudRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrudRepository.java index df0ff39e..29e21eb9 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrudRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerNotCrudRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepository.java index 7c90c670..ec3c5fa2 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithHashSet.java index cf53de00..8e51bc5f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithHashSet.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithHashSet.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithNonFinalHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithNonFinalHashSet.java index e459843e..8cae4400 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithNonFinalHashSet.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithNonFinalHashSet.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithQuery.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithQuery.java index f845fed8..86d5b1d2 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithQuery.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerRepositoryWithQuery.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChild.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChild.java index 272318d8..07f1ca9d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChild.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChild.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChildRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChildRepository.java index e74bc81b..25e6e98d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChildRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithChildRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithHashSet.java index b46e5b72..f5e6158f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithHashSet.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithHashSet.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithNonFinalHashSet.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithNonFinalHashSet.java index 45009fd3..24cc8632 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithNonFinalHashSet.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithNonFinalHashSet.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithQuery.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithQuery.java index 43d6d234..b917f505 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithQuery.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/CustomerWithQuery.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Node.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Node.java index 27764c50..44a933d2 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Node.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Node.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/NodeRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/NodeRepository.java index efa0d716..43b0739f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/NodeRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/NodeRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Owner.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Owner.java index 896ed6a2..43ac8d71 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Owner.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/Owner.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/OwnerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/OwnerRepository.java index ce29f850..72a47207 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/OwnerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/OwnerRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomer.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomer.java index 2256d706..bda9afb6 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomer.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomer.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomerRepository.java index 29057f43..0758223a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/ParentCustomerRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomer.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomer.java index e72316ff..ccb5b68a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomer.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomer.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomerRepository.java index 321323a2..39188d6e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/SubCustomerRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInt.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInt.java index 4b4f4562..30a8c9ca 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInt.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInt.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntRepository.java index 888a123d..8e32578d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInteger.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInteger.java index b0a9e1e8..81cd2f1f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInteger.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdInteger.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java index 7618633b..c3540763 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerate.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java index 7ddc6171..55c15fe0 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerNoAutoGenerateRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerRepository.java index f6de36f0..8846c83a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdIntegerRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLong.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLong.java index 49d3f384..1fa239b0 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLong.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLong.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLongRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLongRepository.java index e86acdcc..d70b9b76 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLongRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdLongRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdString.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdString.java index eaa32ad8..4ff3e317 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdString.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdString.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdStringRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdStringRepository.java index c40f899e..7efb2535 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdStringRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithIdStringRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchase.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchase.java index c37d67c5..d55f7503 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchase.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchase.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchaseRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchaseRepository.java index 2f986e3a..9bc5eae8 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchaseRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/CustomerWithPurchaseRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/Purchase.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/Purchase.java index 52de0753..2a3af61e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/Purchase.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/id/Purchase.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinal.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinal.java index d0ddd64d..404bf5d9 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinal.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinal.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChild.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChild.java index 1bde2eae..359c8033 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChild.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChild.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChildRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChildRepository.java index 22e9d951..59061f54 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChildRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalChildRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalId.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalId.java index c10b2d74..4655a388 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalId.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalId.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalIdRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalIdRepository.java index ebb4df9e..83957816 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalIdRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalIdRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalRepository.java index 519b3f95..2daf2ab1 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/immutables/CustomerWithFinalRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerCrud.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerCrud.java index 7d9778f7..d549f64e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerCrud.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerCrud.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreCrudRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreCrudRepository.java index 64ff9274..5782778e 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreCrudRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreCrudRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java index 5fb57f8f..99fd8de1 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListCrudRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java index c0d0fb6d..575042ad 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreListPagingAndSortingRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java index 14b444c2..53710546 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStorePagingAndSortingRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreRepository.java index 0a476e5f..a86bc48a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerEclipseStoreRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListCrud.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListCrud.java index fe5c0c02..fedb81fb 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListCrud.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListCrud.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListPagingAndSorting.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListPagingAndSorting.java index 89ef5b9f..e18ddffa 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListPagingAndSorting.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerListPagingAndSorting.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerPagingAndSorting.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerPagingAndSorting.java index 4cf9b1c3..65837819 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerPagingAndSorting.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerPagingAndSorting.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerSimple.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerSimple.java index e5f8404b..23ff527d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerSimple.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/interfaces/CustomerSimple.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Article.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Article.java index f67cc905..a9d5d997 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Article.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Article.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/ArticleGroup.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/ArticleGroup.java index d8378911..dc73ba6d 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/ArticleGroup.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/ArticleGroup.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Invoice.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Invoice.java index 498f7492..868061ee 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Invoice.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Invoice.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/InvoiceRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/InvoiceRepository.java index b86bd835..baa35843 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/InvoiceRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/InvoiceRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Position.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Position.java index 85f40363..b0894b12 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Position.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Position.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/PositionRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/PositionRepository.java index 3692bbc5..c8656c26 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/PositionRepository.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/PositionRepository.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Warehouse.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Warehouse.java index ce814b84..8d5b0663 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Warehouse.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/repositories/real/life/example/Warehouse.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ChangeRootTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ChangeRootTests.java index 055c6078..356f6c1a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ChangeRootTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ChangeRootTests.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ConcurrencyTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ConcurrencyTest.java index 4e1ae8d8..81a7b087 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ConcurrencyTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/ConcurrencyTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/FinalTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/FinalTest.java index 74e48fb3..00d99a0a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/FinalTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/FinalTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/HashSetTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/HashSetTest.java index 29d451c0..62f494ee 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/HashSetTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/HashSetTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/IdTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/IdTest.java index 5833c0e4..cf6f91b9 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/IdTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/IdTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/InheritanceTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/InheritanceTest.java index 6cd03676..28da0952 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/InheritanceTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/InheritanceTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/JpaCompatibilityTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/JpaCompatibilityTest.java index ec626212..5a1a095f 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/JpaCompatibilityTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/JpaCompatibilityTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/QueryTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/QueryTest.java index 1bbd8778..bf6d24b1 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/QueryTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/QueryTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/RealLifeTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/RealLifeTests.java index bae2ea7c..026a3a05 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/RealLifeTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/RealLifeTests.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleMultipleTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleMultipleTest.java index 26855070..a9650158 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleMultipleTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleMultipleTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleSingleTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleSingleTest.java index 49a8c87e..4052eeef 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleSingleTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SimpleSingleTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SpecificInterfacesTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SpecificInterfacesTest.java index 07126440..e428269a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SpecificInterfacesTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/SpecificInterfacesTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/StressTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/StressTest.java index 0916f46e..a7f59903 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/StressTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/StressTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/WorkingCopyTests.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/WorkingCopyTests.java index 41c5311d..84de03cb 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/WorkingCopyTests.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/shared/tests/WorkingCopyTests.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorAndOrTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorAndOrTest.java index 344496c4..99541199 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorAndOrTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorAndOrTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorBooleanTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorBooleanTest.java index a3e4164e..87047cf1 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorBooleanTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorBooleanTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorCollectionTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorCollectionTest.java index 107b90fc..9c791de5 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorCollectionTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorCollectionTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorGreaterLessTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorGreaterLessTest.java index 652c21fe..c21f14f9 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorGreaterLessTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorGreaterLessTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorIsIsNotTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorIsIsNotTest.java index 7b8ae212..7414f93c 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorIsIsNotTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorIsIsNotTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorStringTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorStringTest.java index f05f6589..5908e5d9 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorStringTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/EclipseStoreQueryCreatorStringTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/QueryCreatorUtil.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/QueryCreatorUtil.java index 4d365471..c7c283f4 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/QueryCreatorUtil.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/QueryCreatorUtil.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/executors/PageableSortableCollectionQuerierTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/executors/PageableSortableCollectionQuerierTest.java index 9e8d6ebb..b6798947 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/executors/PageableSortableCollectionQuerierTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/query/executors/PageableSortableCollectionQuerierTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/DataTypeUtilTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/DataTypeUtilTest.java index b1ec1493..4f997a50 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/DataTypeUtilTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/DataTypeUtilTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopierTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/RegisteringStorageToWorkingCopyCopierTest.java similarity index 91% rename from spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopierTest.java rename to spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/RegisteringStorageToWorkingCopyCopierTest.java index d0e3a72f..2c54b385 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/copier/RegisteringStorageToWorkingCopyCopierTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/repository/support/copier/registering/RegisteringStorageToWorkingCopyCopierTest.java @@ -1,5 +1,5 @@ /* - * Copyright © 2023 XDEV Software (https://xdev.software) + * Copyright © 2024 XDEV Software (https://xdev.software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package software.xdev.spring.data.eclipse.store.repository.support.copier.copier; +package software.xdev.spring.data.eclipse.store.repository.support.copier.registering; import java.util.List; import java.util.stream.IntStream; @@ -21,6 +21,7 @@ import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; +import software.xdev.spring.data.eclipse.store.helper.DummyWorkingCopier; import software.xdev.spring.data.eclipse.store.repository.SupportedChecker; import software.xdev.spring.data.eclipse.store.repository.WorkingCopyRegistry; @@ -39,7 +40,7 @@ void testCopyManyCopiesSingle() new WorkingCopyRegistry(), new SupportedChecker.Implementation(), o -> null, - null)) + new DummyWorkingCopier())) { final List originalObjects = IntStream.range(0, 1_000).mapToObj( i -> new DummyData("Data" + i, i) @@ -59,7 +60,7 @@ void testCopyAgainSameObject() new WorkingCopyRegistry(), new SupportedChecker.Implementation(), o -> null, - null)) + new DummyWorkingCopier())) { final DummyData originalObject = new DummyData("Test", 1); @@ -78,7 +79,7 @@ void testCopyAgainTheCopy() new WorkingCopyRegistry(), new SupportedChecker.Implementation(), o -> null, - null)) + new DummyWorkingCopier())) { final DummyData originalObject = new DummyData("Test", 1); @@ -99,7 +100,7 @@ void testCopyManyCopiesBulk() new WorkingCopyRegistry(), new SupportedChecker.Implementation(), o -> null, - null)) + new DummyWorkingCopier())) { final List originalObjects = IntStream.range(0, 100_000).mapToObj( i -> new DummyData("Data" + i, i) @@ -119,7 +120,7 @@ void testCopyEmpty() new WorkingCopyRegistry(), new SupportedChecker.Implementation(), o -> null, - null)) + new DummyWorkingCopier())) { Assertions.assertThrows(NullPointerException.class, () -> copier.copy(null)); } From 58c8fde49e45de23c829a2bb3ce07dd48e6e2158 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Mon, 22 Apr 2024 12:50:28 +0200 Subject: [PATCH 79/98] Update SpringDataEclipseStoreLazyBinaryHandler.java --- .../lazy/SpringDataEclipseStoreLazyBinaryHandler.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java index dfd6700a..d505c10c 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java @@ -34,18 +34,20 @@ /** * This is a complicated one. First off: this handler should only be used for WorkingCopies (see - * {@link software.xdev.spring.data.eclipse.store.repository.support.copier.registering.EclipseSerializerRegisteringCopier})! + * {@link + * software.xdev.spring.data.eclipse.store.repository.support.copier.registering.EclipseSerializerRegisteringCopier})! *

* First case:
* The user creates a {@link SpringDataEclipseStoreLazy} and puts a object in it. * This object is stored as with a default {@link BinaryTypeHandler}. But when it gets loaded, * it does not load as the stored object, but it gets wrapped in a {@link Lazy#Reference(Object)}. - *

+ *

*

* Second case:
* The actual lazy object gets loaded from the actual storage. In this case the {@link ObjectSwizzling} is * important! It's the actual {@link ObjectSwizzling} from the storage (not from the - * {@link software.xdev.spring.data.eclipse.store.repository.support.copier.registering.EclipseSerializerRegisteringCopier}). + * {@link + * software.xdev.spring.data.eclipse.store.repository.support.copier.registering.EclipseSerializerRegisteringCopier}). * This means, the {@link SpringDataEclipseStoreLazy} holds the objectId of the original lazy in the original * storage. * Therefore if {@link SpringDataEclipseStoreLazy#get()} is called a new working copy of the lazy from the From 01f45da9c0e276da383014132e0fabf15c0bade6 Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Mon, 22 Apr 2024 13:20:24 +0200 Subject: [PATCH 80/98] Added deletion test --- ...ringDataEclipseStoreLazyBinaryHandler.java | 2 +- .../isolated/tests/deletion/DeletionTest.java | 66 +++++++++++++++++++ .../deletion/DeletionTestConfiguration.java | 28 ++++++++ .../tests/deletion/ReferencedDaoObject.java | 20 ++++++ .../tests/deletion/ReferencedRepository.java | 23 +++++++ .../tests/deletion/ReferencingDaoObject.java | 20 ++++++ .../tests/deletion/ReferencingRepository.java | 23 +++++++ 7 files changed, 181 insertions(+), 1 deletion(-) create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/DeletionTest.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/DeletionTestConfiguration.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencedDaoObject.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencedRepository.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencingDaoObject.java create mode 100644 spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencingRepository.java diff --git a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java index d505c10c..a6223a84 100644 --- a/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java +++ b/spring-data-eclipse-store/src/main/java/software/xdev/spring/data/eclipse/store/repository/lazy/SpringDataEclipseStoreLazyBinaryHandler.java @@ -41,7 +41,7 @@ * The user creates a {@link SpringDataEclipseStoreLazy} and puts a object in it. * This object is stored as with a default {@link BinaryTypeHandler}. But when it gets loaded, * it does not load as the stored object, but it gets wrapped in a {@link Lazy#Reference(Object)}. - *

+ *

*

* Second case:
* The actual lazy object gets loaded from the actual storage. In this case the {@link ObjectSwizzling} is diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/DeletionTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/DeletionTest.java new file mode 100644 index 00000000..b48f120d --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/DeletionTest.java @@ -0,0 +1,66 @@ +/* + * Copyright © 2024 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.deletion; + +import java.util.List; + +import org.junit.jupiter.api.Assertions; +import org.junit.jupiter.api.Test; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.test.context.ContextConfiguration; + +import software.xdev.spring.data.eclipse.store.helper.TestUtil; +import software.xdev.spring.data.eclipse.store.integration.isolated.IsolatedTestAnnotations; + + +/** + * These tests should show that all or most of the following keywords are available in this library: Repository query + * keywords + */ +@IsolatedTestAnnotations +@ContextConfiguration(classes = {DeletionTestConfiguration.class}) +class DeletionTest +{ + @Autowired + private DeletionTestConfiguration configuration; + + @Test + void simpleStoreAndRead( + final ReferencedRepository referencedRepository, + final ReferencingRepository referencingRepository) + { + final ReferencedDaoObject referencedObject = new ReferencedDaoObject("someValue"); + final ReferencingDaoObject referencingDaoObject = new ReferencingDaoObject(referencedObject); + referencingRepository.save(referencingDaoObject); + + Assertions.assertEquals(1, TestUtil.iterableToList(referencingRepository.findAll()).size()); + Assertions.assertEquals(1, TestUtil.iterableToList(referencedRepository.findAll()).size()); + + referencedRepository.delete(referencedObject); + + TestUtil.doBeforeAndAfterRestartOfDatastore( + this.configuration, + () -> { + Assertions.assertTrue(TestUtil.iterableToList(referencedRepository.findAll()).isEmpty()); + final List referencingDaoObjects = + TestUtil.iterableToList(referencingRepository.findAll()); + Assertions.assertEquals(1, referencingDaoObjects.size()); + Assertions.assertNotNull(referencingDaoObjects.get(0).value()); + } + ); + } +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/DeletionTestConfiguration.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/DeletionTestConfiguration.java new file mode 100644 index 00000000..0db7c903 --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/DeletionTestConfiguration.java @@ -0,0 +1,28 @@ +/* + * Copyright © 2024 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.deletion; + +import org.springframework.context.annotation.Configuration; + +import software.xdev.spring.data.eclipse.store.integration.TestConfiguration; +import software.xdev.spring.data.eclipse.store.repository.config.EnableEclipseStoreRepositories; + + +@Configuration +@EnableEclipseStoreRepositories(clientConfigurationClass = DeletionTestConfiguration.class) +public class DeletionTestConfiguration extends TestConfiguration +{ +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencedDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencedDaoObject.java new file mode 100644 index 00000000..6b2bb51b --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencedDaoObject.java @@ -0,0 +1,20 @@ +/* + * Copyright © 2024 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.deletion; + +public record ReferencedDaoObject(String value) +{ +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencedRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencedRepository.java new file mode 100644 index 00000000..7cc76772 --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencedRepository.java @@ -0,0 +1,23 @@ +/* + * Copyright © 2024 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.deletion; + +import org.springframework.data.repository.CrudRepository; + + +public interface ReferencedRepository extends CrudRepository +{ +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencingDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencingDaoObject.java new file mode 100644 index 00000000..8be86d5a --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencingDaoObject.java @@ -0,0 +1,20 @@ +/* + * Copyright © 2024 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.deletion; + +public record ReferencingDaoObject(ReferencedDaoObject value) +{ +} diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencingRepository.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencingRepository.java new file mode 100644 index 00000000..f89a1885 --- /dev/null +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencingRepository.java @@ -0,0 +1,23 @@ +/* + * Copyright © 2024 XDEV Software (https://xdev.software) + * + * 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. + */ +package software.xdev.spring.data.eclipse.store.integration.isolated.tests.deletion; + +import org.springframework.data.repository.CrudRepository; + + +public interface ReferencingRepository extends CrudRepository +{ +} From 7dcd74f31edb1948aa583e8d829138879d033f9f Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Mon, 22 Apr 2024 13:36:05 +0200 Subject: [PATCH 81/98] Update DeletionTest.java --- .../integration/isolated/tests/deletion/DeletionTest.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/DeletionTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/DeletionTest.java index b48f120d..082f8bda 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/DeletionTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/DeletionTest.java @@ -40,8 +40,8 @@ class DeletionTest @Test void simpleStoreAndRead( - final ReferencedRepository referencedRepository, - final ReferencingRepository referencingRepository) + @Autowired final ReferencedRepository referencedRepository, + @Autowired final ReferencingRepository referencingRepository) { final ReferencedDaoObject referencedObject = new ReferencedDaoObject("someValue"); final ReferencingDaoObject referencingDaoObject = new ReferencingDaoObject(referencedObject); From 578640486082f15ba27734506f132eb71468e8dc Mon Sep 17 00:00:00 2001 From: JohannesRabauer Date: Mon, 22 Apr 2024 15:36:11 +0200 Subject: [PATCH 82/98] Added more deletion tests --- .../isolated/tests/deletion/DeletionTest.java | 25 +++++++++++++++++-- .../tests/deletion/ReferencedDaoObject.java | 18 ++++++++++++- .../tests/deletion/ReferencingDaoObject.java | 18 ++++++++++++- 3 files changed, 57 insertions(+), 4 deletions(-) diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/DeletionTest.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/DeletionTest.java index 082f8bda..da5a3827 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/DeletionTest.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/DeletionTest.java @@ -39,7 +39,7 @@ class DeletionTest private DeletionTestConfiguration configuration; @Test - void simpleStoreAndRead( + void deleteReferencedObject( @Autowired final ReferencedRepository referencedRepository, @Autowired final ReferencingRepository referencingRepository) { @@ -59,7 +59,28 @@ void simpleStoreAndRead( final List referencingDaoObjects = TestUtil.iterableToList(referencingRepository.findAll()); Assertions.assertEquals(1, referencingDaoObjects.size()); - Assertions.assertNotNull(referencingDaoObjects.get(0).value()); + Assertions.assertNotNull(referencingDaoObjects.get(0).getValue()); + } + ); + } + + @Test + void restoreDeletedReferencedObject( + @Autowired final ReferencedRepository referencedRepository, + @Autowired final ReferencingRepository referencingRepository) + { + final ReferencedDaoObject referencedObject = new ReferencedDaoObject("someValue"); + final ReferencingDaoObject referencingDaoObject = new ReferencingDaoObject(referencedObject); + + referencingRepository.save(referencingDaoObject); + referencedRepository.delete(referencedObject); + referencingRepository.save(referencingDaoObject); + + TestUtil.doBeforeAndAfterRestartOfDatastore( + this.configuration, + () -> { + Assertions.assertEquals(1, TestUtil.iterableToList(referencingRepository.findAll()).size()); + Assertions.assertEquals(1, TestUtil.iterableToList(referencedRepository.findAll()).size()); } ); } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencedDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencedDaoObject.java index 6b2bb51b..94577218 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencedDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencedDaoObject.java @@ -15,6 +15,22 @@ */ package software.xdev.spring.data.eclipse.store.integration.isolated.tests.deletion; -public record ReferencedDaoObject(String value) +public class ReferencedDaoObject { + private String value; + + public ReferencedDaoObject(final String value) + { + this.value = value; + } + + public String getValue() + { + return this.value; + } + + public void setValue(final String value) + { + this.value = value; + } } diff --git a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencingDaoObject.java b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencingDaoObject.java index 8be86d5a..15d4cf5a 100644 --- a/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencingDaoObject.java +++ b/spring-data-eclipse-store/src/test/java/software/xdev/spring/data/eclipse/store/integration/isolated/tests/deletion/ReferencingDaoObject.java @@ -15,6 +15,22 @@ */ package software.xdev.spring.data.eclipse.store.integration.isolated.tests.deletion; -public record ReferencingDaoObject(ReferencedDaoObject value) +public class ReferencingDaoObject { + private ReferencedDaoObject value; + + public ReferencingDaoObject(final ReferencedDaoObject value) + { + this.value = value; + } + + public ReferencedDaoObject getValue() + { + return this.value; + } + + public void setValue(final ReferencedDaoObject value) + { + this.value = value; + } } From cbaab7d6ff6ec692bd38fc0e8c6ffd1b5c49a39e Mon Sep 17 00:00:00 2001 From: AB Date: Tue, 23 Apr 2024 08:35:54 +0200 Subject: [PATCH 83/98] Rename repo --- .github/workflows/update-from-template.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/update-from-template.yml b/.github/workflows/update-from-template.yml index 3d35a5cd..41a1bcd6 100644 --- a/.github/workflows/update-from-template.yml +++ b/.github/workflows/update-from-template.yml @@ -14,7 +14,7 @@ on: env: UPDATE_BRANCH: update-from-template - REMOTE_URL: https://github.com/xdev-software/base-template.git + REMOTE_URL: https://github.com/xdev-software/java-template.git REMOTE_BRANCH: master permissions: From 8c1ae59052b358e2a6f6532221a97931c4ef9723 Mon Sep 17 00:00:00 2001 From: AB Date: Tue, 23 Apr 2024 08:37:20 +0200 Subject: [PATCH 84/98] Update checkstyle --- .idea/checkstyle-idea.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.idea/checkstyle-idea.xml b/.idea/checkstyle-idea.xml index 5c1e5281..eb3fcd83 100644 --- a/.idea/checkstyle-idea.xml +++ b/.idea/checkstyle-idea.xml @@ -1,7 +1,7 @@ - 10.14.0 + 10.15.0 JavaOnlyWithTests true true From e1c2ac2c20c954d7747ed8a349f750076ab76d15 Mon Sep 17 00:00:00 2001 From: AB Date: Tue, 23 Apr 2024 08:37:49 +0200 Subject: [PATCH 85/98] Standardize template-placeholder --- SECURITY.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SECURITY.md b/SECURITY.md index 36d63052..34b9514d 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -2,4 +2,4 @@ ## Reporting a Vulnerability -Please report a security vulnerability [on GitHub Security Advisories](https://github.com/xdev-software/base-template/security/advisories/new). +Please report a security vulnerability [on GitHub Security Advisories](https://github.com/xdev-software/template-placeholder/security/advisories/new). From 29fd4deb26b6b013c857053364e1137556240c63 Mon Sep 17 00:00:00 2001 From: AB Date: Tue, 23 Apr 2024 08:43:43 +0200 Subject: [PATCH 86/98] Standardize template-placeholder I --- .run/Run Demo.run.xml | 2 +- CONTRIBUTING.md | 4 ++-- README.md | 12 ++++++------ pom.xml | 6 +++--- standard-maven-template-demo/pom.xml | 4 ++-- standard-maven-template/pom.xml | 12 ++++++------ 6 files changed, 20 insertions(+), 20 deletions(-) diff --git a/.run/Run Demo.run.xml b/.run/Run Demo.run.xml index 764b3b9c..5fb2bc27 100644 --- a/.run/Run Demo.run.xml +++ b/.run/Run Demo.run.xml @@ -1,7 +1,7 @@