You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@causeway.apache.org by da...@apache.org on 2024/01/19 12:07:03 UTC
(causeway) branch CAUSEWAY-3676 updated (8e8ec2d00f -> 1bedb5424b)
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a change to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
discard 8e8ec2d00f CAUSEWAY-3676: creates metaField within GqlvObjectSpec
discard 16b343bc2d CAUSEWAY-3676: inlines vars obtained from gqlvObjectSpec
discard 5855ba894b CAUSEWAY-3676: inlines utility method
discard 109d62ddec CAUSEWAY-3676: wip to considolate gqlvObjectSpec's two declarations of gqlObjectType (2)
discard d849118afa CAUSEWAY-3676: wip to considolate gqlvObjectSpec's two declarations of gqlObjectType
discard 35da048596 CAUSEWAY-3676: trivial
discard b1e45ef5a6 CAUSEWAY-3676: removes unused overloads
discard 42c71408d3 CAUSEWAY-3676: removes unused overload
discard 4a9d70bb6f CAUSEWAY-3676: uses overload
discard 4c5c72b046 CAUSEWAY-3676: introduces GraphQLTypeRegistry
discard 203efa77b5 CAUSEWAY-3676: refactorings
discard 46f7ec544e CAUSEWAY-3676 : tests failing, abandon
discard b31b580e76 CAUSEWAY-3676: renames GQLMutations to GqlMutations
discard 437688494c CAUSEWAY-3676: renames GQLMeta to GqlMeta
discard 69be9a8e77 CAUSEWAY-3676: uses EntityFacet to obtain version of GQLMeta
discard 0e1ddfd88c CAUSEWAY-3676: CAUSEWAY-3678 : fix after merge
discard a6b8b18c74 CAUSEWAY-3676: CAUSEWAY-3678 : extends EntityFacet to obtain the version of the entity
discard 8d62afc619 CAUSEWAY-3676: moves test domain into a 'university' namespace
discard 05258ec3f9 CAUSEWAY-3676: cleans up quite a bit...
discard 3011e24768 CAUSEWAY-3676: splits up Domain and Schema integ tests, also ...
discard 59b463b1aa CAUSEWAY-3676: deletes GqlSchema_detail_IntegTest
discard cc879d20a6 CAUSEWAY-3676: towards dumping the schema
discard 40ac65eea3 CAUSEWAY-3676: wip, resurrected first end to end test and also dumping the schema
discard 8cdbede4fe CAUSEWAY-3676 : wip
add fb970850cb Bump com.fasterxml.woodstox:woodstox-core from 6.5.1 to 6.6.0
add 0bedaa39a0 Merge pull request #2168 from apache/dependabot/maven/master/com.fasterxml.woodstox-woodstox-core-6.6.0
add b3d723badc CAUSEWAY-3675: adds suppress-auto-flush functionality
add 7486a81a0c CAUSEWAY-3675: fixes module-info declarations
add 100e044484 CAUSEWAY-3675: adds persistence.commons for pdf.js tests
add d3ceb22947 CAUSEWAY-3675: adds persistence commons module for pdf.js tests
add d8c270c267 CAUSEWAY-3675: adds persistence commons module for excel extension tests
add b4406eb095 CAUSEWAY-3675: fixes (?) integ tests in regressiontests-stable-domainmodel
add 983537baaf CAUSEWAY-3675: introduces FlushMgmt, adds additional guard in TransactionServiceSpring
add d3e330f8ad CAUSEWAY-3675: fixes (?) dependency for regression test
add b7dfd6a868 CAUSEWAY-3675: fixes (?) dependency for regression test in stable-config
add e2eb472d06 CAUSEWAY-3675: fixes (?) regression test in stable-layout
add 47c5e4b446 Merge pull request #2166 from apache/CAUSEWAY-3675
add 039c47956c CAUSEWAY-3671: declares 'createdByCommand' as mixin
add 86e571dbd9 CAUSEWAY-3671: reorg imports
add e219fe186c Merge pull request #2169 from apache/CAUSEWAY-3671
add df69154bf0 CAUSEWAY-3677 : fixes License and Privacy link violations on home page
add 40a447aa3f CAUSEWAY-3677 : fixes copyright confusion with template credit
add 72c6b2b03d CAUSEWAY-3677 : removes external resource references
add c9c00a1bcf CAUSEWAY-3671 : removes spurious supporting methods for Object_createdByCommand
add 32ba3aefda CAUSEWAY-3678: adds guard into RO's filter
add 97277cf851 Merge pull request #2170 from apache/CAUSEWAY-3678
add 7c0a05750d Bump actions/cache from 3 to 4
add b0144569ce Merge pull request #2172 from apache/dependabot/github_actions/master/actions/cache-4
add a9e82f2901 Bump org.owasp:dependency-check-maven from 9.0.8 to 9.0.9
add f0d5bdbf30 Merge pull request #2173 from apache/dependabot/maven/master/org.owasp-dependency-check-maven-9.0.9
add ae08941861 CAUSEWAY-2297: remove unused imports and Eclipse unsupported warning suppressions
add bc9ab7acfe CAUSEWAY-3677 : copies down gstatic fonts
add 9fafcc8b3f CAUSEWAY-3404: adds (simple) double-quoting operator
add 6ae5407625 CAUSEWAY-3404: fixes prev. commit
add 75155849cb CAUSEWAY-3404: quality of life improvements for ObjectGraph
add 0a63dff8f2 CAUSEWAY-3404: minor notes on prev. commit
new 9f75dc565e CAUSEWAY-3676 : wip
new 3751b2b569 CAUSEWAY-3676: wip, resurrected first end to end test and also dumping the schema
new f0090fd9f8 CAUSEWAY-3676: towards dumping the schema
new 46f3e9d029 CAUSEWAY-3676: deletes GqlSchema_detail_IntegTest
new ce0910636f CAUSEWAY-3676: splits up Domain and Schema integ tests, also ...
new ddbf7fdb48 CAUSEWAY-3676: cleans up quite a bit...
new 28d26839d9 CAUSEWAY-3676: moves test domain into a 'university' namespace
new 05b2c1c8fc CAUSEWAY-3676: CAUSEWAY-3678 : extends EntityFacet to obtain the version of the entity
new 0326b755cf CAUSEWAY-3676: uses EntityFacet to obtain version of GQLMeta
new 7c84bb809b CAUSEWAY-3676: renames GQLMeta to GqlMeta
new 58d453a557 CAUSEWAY-3676: renames GQLMutations to GqlMutations
new a26ec842c0 CAUSEWAY-3676 : tests failing, abandon
new 5fba37e289 CAUSEWAY-3676: refactorings
new d5ea89dada CAUSEWAY-3676: introduces GraphQLTypeRegistry
new 8e1cc273b8 CAUSEWAY-3676: uses overload
new 8137c9a6e1 CAUSEWAY-3676: removes unused overload
new 96928e259a CAUSEWAY-3676: removes unused overloads
new c5e6b05d50 CAUSEWAY-3676: trivial
new 9caf30ad1f CAUSEWAY-3676: wip to considolate gqlvObjectSpec's two declarations of gqlObjectType
new 604cae5c36 CAUSEWAY-3676: wip to considolate gqlvObjectSpec's two declarations of gqlObjectType (2)
new eecbd42622 CAUSEWAY-3676: inlines utility method
new 5ab4588281 CAUSEWAY-3676: inlines vars obtained from gqlvObjectSpec
new 1bedb5424b CAUSEWAY-3676: creates metaField within GqlvObjectSpec
This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version. This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:
* -- * -- B -- O -- O -- O (8e8ec2d00f)
\
N -- N -- N refs/heads/CAUSEWAY-3676 (1bedb5424b)
You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.
Any revisions marked "omit" are not gone; other references still
refer to them. Any revisions marked "discard" are gone forever.
The 23 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
.../workflows/ci-build-artifacts-no-push-maven.yml | 2 +-
.../workflows/ci-build-artifacts-push-maven.yml | 2 +-
.gitignore | 1 +
.../ROOT/pages/2024/2.0.0-RC5/mignotes.adoc | 23 +-
antora/supplemental-ui/css/docsearch.min.css | 4 +
.../supplemental-ui/css/fonts-googleapis-com.css | 862 +++++++++++++++++++++
...ntserrat-v26-JTUSjIg1_i6t8kCHKm459W1hyzbi.woff2 | Bin 0 -> 21288 bytes
...ntserrat-v26-JTUSjIg1_i6t8kCHKm459WRhyzbi.woff2 | Bin 0 -> 23516 bytes
...ntserrat-v26-JTUSjIg1_i6t8kCHKm459WZhyzbi.woff2 | Bin 0 -> 9512 bytes
...ntserrat-v26-JTUSjIg1_i6t8kCHKm459Wdhyzbi.woff2 | Bin 0 -> 27812 bytes
...montserrat-v26-JTUSjIg1_i6t8kCHKm459Wlhyw.woff2 | Bin 0 -> 33092 bytes
...Gs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqW106F15M.woff2 | Bin 0 -> 25968 bytes
...Gs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWt06F15M.woff2 | Bin 0 -> 37696 bytes
...Gs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWtE6F15M.woff2 | Bin 0 -> 54888 bytes
...Gs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWtU6F15M.woff2 | Bin 0 -> 4880 bytes
...Gs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWtk6F15M.woff2 | Bin 0 -> 17136 bytes
...Gs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWu06F15M.woff2 | Bin 0 -> 17064 bytes
...tYaGs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWuU6F.woff2 | Bin 0 -> 50296 bytes
...Gs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWuk6F15M.woff2 | Bin 0 -> 22780 bytes
...Gs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWvU6F15M.woff2 | Bin 0 -> 32204 bytes
...Gs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWxU6F15M.woff2 | Bin 0 -> 50484 bytes
...emvYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTS-muw.woff2 | Bin 0 -> 48236 bytes
...vYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTS2mu1aB.woff2 | Bin 0 -> 16516 bytes
...vYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTSCmu1aB.woff2 | Bin 0 -> 16552 bytes
...vYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTSGmu1aB.woff2 | Bin 0 -> 35328 bytes
...vYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTSKmu1aB.woff2 | Bin 0 -> 49436 bytes
...vYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTSOmu1aB.woff2 | Bin 0 -> 4524 bytes
...vYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTSumu1aB.woff2 | Bin 0 -> 26736 bytes
...vYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTSymu1aB.woff2 | Bin 0 -> 21272 bytes
...vYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTUGmu1aB.woff2 | Bin 0 -> 24984 bytes
...vYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTVOmu1aB.woff2 | Bin 0 -> 47136 bytes
.../raleway-v29-1Ptug8zYS_SKggPNyC0ITw.woff2 | Bin 0 -> 48208 bytes
.../raleway-v29-1Ptug8zYS_SKggPNyCAIT5lu.woff2 | Bin 0 -> 26788 bytes
.../raleway-v29-1Ptug8zYS_SKggPNyCIIT5lu.woff2 | Bin 0 -> 11176 bytes
.../raleway-v29-1Ptug8zYS_SKggPNyCMIT5lu.woff2 | Bin 0 -> 30744 bytes
.../raleway-v29-1Ptug8zYS_SKggPNyCkIT5lu.woff2 | Bin 0 -> 25828 bytes
antora/supplemental-ui/index.html | 33 +-
antora/supplemental-ui/js/docsearch.min.js | 4 +
.../services/metamodel/objgraph/ObjectGraph.java | 56 +-
.../objgraph/_ObjectGraphRelationMerger.java | 35 +-
bom/pom.xml | 2 +-
.../causeway/commons/internal/base/_Strings.java | 38 +-
.../org/apache/causeway/commons/io/DataSource.java | 9 +
.../core/config/CausewayConfiguration.java | 63 +-
core/metamodel/src/main/java/module-info.java | 1 +
.../services/metamodel/_ObjectGraphFactory.java | 14 +-
core/pom.xml | 2 +-
core/runtime/src/main/java/module-info.java | 1 +
.../core/runtime/flushmgmt/FlushMgmt.java} | 42 +-
.../runtimeservices/src/main/java/module-info.java | 1 -
.../CausewayModuleCoreRuntimeServices.java | 4 -
.../transaction/TransactionServiceSpring.java | 10 +-
.../integtests/ExcelModuleIntegTestAbstract.java | 3 +
.../applib/CausewayModuleExtAuditTrailApplib.java | 4 +-
.../contributions/Object_createdByCommand.java | 20 -
.../dom/ApplicationUserRepositoryAbstract.java | 2 -
extensions/vw/pdfjs/metamodel/pom.xml | 7 +
.../metamodel/PdfjsViewer_Abstract_IntegTest.java | 3 +
.../primary/ui/CommandReplayOnPrimaryService.java | 1 -
.../mixins/CommandLogEntry_replayQueue.java | 1 -
persistence/commons/src/main/java/module-info.java | 1 +
.../commons/CausewayModulePersistenceCommons.java | 9 -
.../changetracking/EntityChangeTrackerDefault.java | 100 ++-
.../PreAndPostValueEvaluatorServiceDefault.java | 4 +-
.../repository/RepositoryServiceDefault.java | 14 +-
regressiontests/stable-config/pom.xml | 3 +-
regressiontests/stable-domainmodel/pom.xml | 2 +-
.../integtest/Layout_Counter_IntegTest.java | 29 +-
.../integtest/Layout_SimpleObject_IntegTest.java | 3 +
regressiontests/stable/pom.xml | 7 +-
.../testdomain/conf/Configuration_headless.java | 22 +-
testing/fakedata/applib/pom.xml | 10 +-
.../objgraph/d3js/ObjectGraphRendererD3js.java | 2 +-
.../plantuml/ObjectGraphRendererPlantuml.java | 6 +-
.../CausewayRestfulObjectsInteractionFilter.java | 10 +-
75 files changed, 1266 insertions(+), 206 deletions(-)
create mode 100644 antora/supplemental-ui/css/docsearch.min.css
create mode 100644 antora/supplemental-ui/css/fonts-googleapis-com.css
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/montserrat-v26-JTUSjIg1_i6t8kCHKm459W1hyzbi.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/montserrat-v26-JTUSjIg1_i6t8kCHKm459WRhyzbi.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/montserrat-v26-JTUSjIg1_i6t8kCHKm459WZhyzbi.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/montserrat-v26-JTUSjIg1_i6t8kCHKm459Wdhyzbi.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/montserrat-v26-JTUSjIg1_i6t8kCHKm459Wlhyw.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memtYaGs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqW106F15M.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memtYaGs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWt06F15M.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memtYaGs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWtE6F15M.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memtYaGs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWtU6F15M.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memtYaGs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWtk6F15M.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memtYaGs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWu06F15M.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memtYaGs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWuU6F.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memtYaGs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWuk6F15M.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memtYaGs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWvU6F15M.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memtYaGs126MiZpBA-UFUIcVXSCEkx2cmqvXlWqWxU6F15M.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memvYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTS-muw.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memvYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTS2mu1aB.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memvYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTSCmu1aB.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memvYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTSGmu1aB.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memvYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTSKmu1aB.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memvYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTSOmu1aB.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memvYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTSumu1aB.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memvYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTSymu1aB.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memvYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTUGmu1aB.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/opensans-v40-memvYaGs126MiZpBA-UvWbX2vVnXBbObj2OVTVOmu1aB.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/raleway-v29-1Ptug8zYS_SKggPNyC0ITw.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/raleway-v29-1Ptug8zYS_SKggPNyCAIT5lu.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/raleway-v29-1Ptug8zYS_SKggPNyCIIT5lu.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/raleway-v29-1Ptug8zYS_SKggPNyCMIT5lu.woff2
create mode 100644 antora/supplemental-ui/font/fonts-gstatic-com/raleway-v29-1Ptug8zYS_SKggPNyCkIT5lu.woff2
create mode 100644 antora/supplemental-ui/js/docsearch.min.js
copy core/runtime/src/main/java/{module-info.java => org/apache/causeway/core/runtime/flushmgmt/FlushMgmt.java} (52%)
rename {core/runtimeservices/src/main/java/org/apache/causeway/core/runtimeservices => persistence/commons/src/main/java/org/apache/causeway/persistence/commons/integration}/repository/RepositoryServiceDefault.java (93%)
(causeway) 06/23: CAUSEWAY-3676: cleans up quite a bit...
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit ddbf7fdb4873dc3ff785e4bcf145d5e8d74a9778
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Wed Jan 17 23:27:57 2024 +0000
CAUSEWAY-3676: cleans up quite a bit...
---
.../viewer/test/domain/DepartmentRepository.java | 7 +
.../graphql/viewer/test/domain/DeptHead.java | 2 +-
.../viewer/test/domain/DeptHeadRepository.java | 5 +-
.../test/e2e/Domain_IntegTest.changeName._.gql | 14 -
.../e2e/Domain_IntegTest.changeName.approved.json | 1 -
.../test/e2e/Domain_IntegTest.createE1._.gql | 7 -
.../e2e/Domain_IntegTest.createE1.approved.json | 9 -
.../e2e/Domain_IntegTest.create_department._.gql | 7 +
...omain_IntegTest.create_department.approved.json | 9 +
...in_IntegTest.find_all_departments.approved.json | 4 +-
...IntegTest.find_department_and_change_name._.gql | 14 +
....find_department_and_change_name.approved.json} | 0
.../graphql/viewer/test/e2e/Domain_IntegTest.java | 107 ++-
.../test/e2e/Schema_IntegTest.schema.approved.json | 2 +-
.../graphql/test/src/test/resources/schema.gql | 2 +-
.../viewer/src/test/resources/testfiles/schema.gql | 802 ---------------------
16 files changed, 90 insertions(+), 902 deletions(-)
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DepartmentRepository.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DepartmentRepository.java
index 3b18e6c5ee..d700795331 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DepartmentRepository.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DepartmentRepository.java
@@ -48,4 +48,11 @@ public class DepartmentRepository {
repositoryService.removeAll(Department.class);
}
+ public Department findByName(final String name){
+ return findAll().stream().
+ filter(dept -> dept.getName().equals(name)).
+ findFirst().
+ orElse(null);
+ }
+
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHead.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHead.java
index ad82f41393..a919bfe645 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHead.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHead.java
@@ -80,7 +80,7 @@ public class DeptHead implements WithName {
@Action(semantics = SemanticsOf.IDEMPOTENT)
- public class changeDeptHead {
+ public class changeDepartment {
public DeptHead act(final Department department){
setDepartment(department);
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHeadRepository.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHeadRepository.java
index e96e0110c8..7b315f9574 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHeadRepository.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHeadRepository.java
@@ -49,7 +49,10 @@ public class DeptHeadRepository {
}
public DeptHead findByName(final String name){
- return findAll().stream().filter(e2->e2.getName().equals(name)).findFirst().orElse(null);
+ return findAll().stream().
+ filter(deptHead -> deptHead.getName().equals(name)).
+ findFirst().
+ orElse(null);
}
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.changeName._.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.changeName._.gql
deleted file mode 100644
index ffc29ff7f8..0000000000
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.changeName._.gql
+++ /dev/null
@@ -1,14 +0,0 @@
-{
- gqltestdomain_GQLTestDomainMenu {
- findE2(name:"foo") {
- name_gql_mutations {
- changeName(newName:"bar") {
- name
- department {
- name
- }
- }
- }
- }
- }
-}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.changeName.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.changeName.approved.json
deleted file mode 100644
index e57317ab99..0000000000
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.changeName.approved.json
+++ /dev/null
@@ -1 +0,0 @@
-{"data":{"gqltestdomain_GQLTestDomainMenu":{"findAllE2":[{"name":"foo","_gql_mutations":null}]}}}
\ No newline at end of file
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.createE1._.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.createE1._.gql
deleted file mode 100644
index da921aa207..0000000000
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.createE1._.gql
+++ /dev/null
@@ -1,7 +0,0 @@
-{
- gqltestdomain_GQLTestDomainMenu {
- createE1(name:"newbee"){
- name
- }
- }
-}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.createE1.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.createE1.approved.json
deleted file mode 100644
index b382db0f3c..0000000000
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.createE1.approved.json
+++ /dev/null
@@ -1,9 +0,0 @@
-{
- "data" : {
- "gqltestdomain_GQLTestDomainMenu" : {
- "createE1" : {
- "name" : "newbee"
- }
- }
- }
-}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.create_department._.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.create_department._.gql
new file mode 100644
index 0000000000..ab95101b5c
--- /dev/null
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.create_department._.gql
@@ -0,0 +1,7 @@
+{
+ gql_test_domain_TopLevelMenu {
+ createDepartment(name: "newbie") {
+ name
+ }
+ }
+}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.create_department.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.create_department.approved.json
new file mode 100644
index 0000000000..90328010f5
--- /dev/null
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.create_department.approved.json
@@ -0,0 +1,9 @@
+{
+ "data" : {
+ "gql_test_domain_TopLevelMenu" : {
+ "createDepartment" : {
+ "name" : "newbie"
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments.approved.json
index eace6ed631..56ffa2f775 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments.approved.json
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments.approved.json
@@ -4,14 +4,14 @@
"findAllDepartments" : [ {
"name" : "foo",
"_gql_meta" : {
- "id" : "1",
+ "id" : "2",
"logicalTypeName" : "gql.test.domain.Department",
"version" : null
}
}, {
"name" : "bar",
"_gql_meta" : {
- "id" : "2",
+ "id" : "3",
"logicalTypeName" : "gql.test.domain.Department",
"version" : null
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_department_and_change_name._.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_department_and_change_name._.gql
new file mode 100644
index 0000000000..9d90107009
--- /dev/null
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_department_and_change_name._.gql
@@ -0,0 +1,14 @@
+{
+ gql_test_domain_TopLevelMenu {
+ findDeptHeadByName(name: "foo") {
+ _gql_mutations {
+ changeName(newName: "bar") {
+ name
+ department {
+ name
+ }
+ }
+ }
+ }
+ }
+}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_department_and_change_name.approved.json
similarity index 100%
copy from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments.approved.json
copy to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_department_and_change_name.approved.json
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.java
index 0584dcb2f5..352f653784 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.java
@@ -18,6 +18,8 @@
*/
package org.apache.causeway.viewer.graphql.viewer.test.e2e;
+import lombok.val;
+
import java.util.ArrayList;
import java.util.List;
@@ -28,6 +30,7 @@ import org.approvaltests.reporters.DiffReporter;
import org.approvaltests.reporters.TextWebReporter;
import org.approvaltests.reporters.UseReporter;
import org.junit.jupiter.api.AfterEach;
+import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.condition.DisabledIfSystemProperty;
@@ -86,78 +89,56 @@ public class Domain_IntegTest extends CausewayViewerGraphqlTestModuleIntegTestAb
Approvals.verify(submit(), jsonOptions());
}
- //TODO started to fail on 2022-09-04, with testEntityRepository findAll being empty
- @Test @DisabledIfSystemProperty(named = "isRunningWithSurefire", matches = "true")
+ @Test
@UseReporter(DiffReporter.class)
- void createE1() throws Exception {
-
- //File targetFile3 = new File("src/test/resources/testfiles/targetFile3.gql");
-
- String response1 = transactionService.callTransactional(Propagation.REQUIRED, () -> {
+ void create_department() throws Exception {
- String submit = submit();
- // just to show we need to query in separate tranasction
- List<DeptHead> list = deptHeadRepository.findAll();
- assertTrue(list.isEmpty());
- return submit;
+ // when
+ val response = submit();
- }).ifFailureFail().getValue().get();
+ // then payload
+ Approvals.verify(response, jsonOptions());
- final List<Department> allDepartment = new ArrayList<>();
- transactionService.runTransactional(Propagation.REQUIRED, () -> {
-
- List<Department> all = departmentRepository.findAll();
- allDepartment.addAll(all);
-
- });
-
- assertEquals(1, allDepartment.size());
- assertEquals("newbee", allDepartment.get(0).getName());
-
- Approvals.verify(response1, jsonOptions());
+ // and also in the database
+ final List<Department> allDepartment =
+ transactionService.callTransactional(
+ Propagation.REQUIRED,
+ () -> departmentRepository.findAll()
+ ).valueAsNonNullElseFail();
+ assertThat(allDepartment)
+ .hasSize(1)
+ .element(0)
+ .extracting(Department::getName).isEqualTo("newbie");
}
- //TODO started to fail on 2023-07-25
- //disabled to rescue CI build
- @Test @DisabledIfSystemProperty(named = "isRunningWithSurefire", matches = "true")
+ @Test
+ @Disabled // does not yet call 'changeName' action
@UseReporter(DiffReporter.class)
- void changeName() throws Exception {
-
- List<DeptHead> deptHeadList = new ArrayList<>();
-
- transactionService.runTransactional(Propagation.REQUIRED, () -> {
-
- deptHeadList.add(deptHeadRepository.create("foo", null));
-
- });
-
- DeptHead deptHead = deptHeadList.get(0);
- assertEquals("foo", deptHead.getName());
- assertEquals(deptHead.getName(), topLevelMenu.findDeptHeadByName("foo").getName());
-
- String response = transactionService.callTransactional(Propagation.REQUIRED, () -> {
-
- return submit();
-
- }).ifFailureFail().getValue().get();
-
- deptHeadList.clear();
- transactionService.runTransactional(Propagation.REQUIRED, () -> {
-
- List<DeptHead> all = deptHeadRepository.findAll();
- deptHeadList.addAll(all);
-
- });
-
- DeptHead deptHeadModified = deptHeadList.get(0);
-
- //TODO: implement ...
-// assertEquals("bar", deptHeadModified.getName());
-//
-// Approvals.verify(response, new Options());
+ void find_department_and_change_name() throws Exception {
+ // given
+ transactionService.callTransactional(
+ Propagation.REQUIRED,
+ () -> deptHeadRepository.create("foo", null)
+ ).valueAsNonNullElseFail();
+
+ // when lookup 'foo' and change it to 'bar'
+ String response = transactionService.callTransactional(
+ Propagation.REQUIRED,
+ this::submit
+ ).valueAsNonNullElseFail();
+
+ // then payload
+ Approvals.verify(response, jsonOptions());
+
+ // and also in the database
+ DeptHead deptHeadAfter = transactionService.callTransactional(
+ Propagation.REQUIRED,
+ () -> deptHeadRepository.findByName("bar")
+ ).valueAsNullableElseFail();
+
+ assertThat(deptHeadAfter).isNotNull();
}
-
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema.approved.json
index fc3d84a3d6..cafdedb247 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema.approved.json
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema.approved.json
@@ -4806,7 +4806,7 @@
"name" : "gql_test_domain_DeptHead__DomainObject_mutators",
"description" : null,
"fields" : [ {
- "name" : "changeDeptHead",
+ "name" : "changeDepartment",
"description" : null,
"args" : [ {
"name" : "department",
diff --git a/incubator/viewers/graphql/test/src/test/resources/schema.gql b/incubator/viewers/graphql/test/src/test/resources/schema.gql
index 128cc4ba23..06fd0676ee 100644
--- a/incubator/viewers/graphql/test/src/test/resources/schema.gql
+++ b/incubator/viewers/graphql/test/src/test/resources/schema.gql
@@ -374,7 +374,7 @@ type gql_test_domain_DeptHead__DomainObject_meta {
}
type gql_test_domain_DeptHead__DomainObject_mutators {
- changeDeptHead(department: _gql_input__gql_test_domain_Department!): gql_test_domain_DeptHead
+ changeDepartment(department: _gql_input__gql_test_domain_Department!): gql_test_domain_DeptHead
changeName(newName: String!): gql_test_domain_DeptHead
}
diff --git a/incubator/viewers/graphql/viewer/src/test/resources/testfiles/schema.gql b/incubator/viewers/graphql/viewer/src/test/resources/testfiles/schema.gql
deleted file mode 100644
index f10e5556b8..0000000000
--- a/incubator/viewers/graphql/viewer/src/test/resources/testfiles/schema.gql
+++ /dev/null
@@ -1,802 +0,0 @@
-"Marks the field, argument, input field or enum value as deprecated"
-directive @deprecated(
- "The reason for the deprecation"
- reason: String = "No longer supported"
-) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
-
-"Directs the executor to include this field or fragment only when the `if` argument is true"
-directive @include(
- "Included when true."
- if: Boolean!
-) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT
-
-"Directs the executor to skip this field or fragment when the `if` argument is true."
-directive @skip(
- "Skipped when true."
- if: Boolean!
-) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT
-
-"Exposes a URL that specifies the behaviour of this scalar."
-directive @specifiedBy(
- "The URL that specifies the behaviour of this scalar."
- url: String!
-) on SCALAR
-
-type Query {
- causeway_applib_UserMenu: causeway_applib_UserMenu
- causeway_conf_ConfigurationMenu: causeway_conf_ConfigurationMenu
- causeway_security_LogoutMenu: causeway_security_LogoutMenu
- gql_test_domain_TopLevelMenu: gql_test_domain_TopLevelMenu
- numServices: Int
-}
-
-type causeway_applib_DomainObjectList {
- _gql_meta: causeway_applib_DomainObjectList__DomainObject_meta
- actionArguments: String
- actionId: String
- actionOwningFqcn: String
- elementTypeFqcn: String!
- title: String!
-}
-
-type causeway_applib_DomainObjectList__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_applib_FacetGroupNode {
- _gql_meta: causeway_applib_FacetGroupNode__DomainObject_meta
- facets: String!
-}
-
-type causeway_applib_FacetGroupNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_applib_ParameterNode {
- _gql_meta: causeway_applib_ParameterNode__DomainObject_meta
- parameter: String!
- parentNode: causeway_applib_node_ActionNode!
-}
-
-type causeway_applib_ParameterNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_applib_PropertyNode {
- _gql_meta: causeway_applib_PropertyNode__DomainObject_meta
- _gql_mutations: causeway_applib_PropertyNode__DomainObject_mutators
- mixedIn: String!
- parentNode: causeway_applib_TypeNode!
- property: String!
-}
-
-type causeway_applib_PropertyNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_applib_PropertyNode__DomainObject_mutators {
- streamChildNodes: java_util_stream_Stream
-}
-
-type causeway_applib_RoleMemento {
- _gql_meta: causeway_applib_RoleMemento__DomainObject_meta
- description: String!
- name: String!
-}
-
-type causeway_applib_RoleMemento__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_applib_TypeNode {
- _gql_meta: causeway_applib_TypeNode__DomainObject_meta
- domainClassDto: causeway_schema_metamodel_v2_DomainClassDto!
-}
-
-type causeway_applib_TypeNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_applib_UserMemento {
- _gql_meta: causeway_applib_UserMemento__DomainObject_meta
- authenticationCode: String!
- authenticationSource: String!
- avatarUrl: String
- impersonating: String!
- languageLocale: String
- multiTenancyToken: String
- name: String!
- numberFormatLocale: String
- realName: String
- roles: [causeway_applib_RoleMemento]
- timeFormatLocale: String
-}
-
-type causeway_applib_UserMemento__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_applib_UserMenu {
- me: causeway_applib_UserMemento
-}
-
-type causeway_applib_node_ActionNode {
- _gql_meta: causeway_applib_node_ActionNode__DomainObject_meta
- _gql_mutations: causeway_applib_node_ActionNode__DomainObject_mutators
- action: String!
- mixedIn: String!
- parentNode: causeway_applib_TypeNode!
-}
-
-type causeway_applib_node_ActionNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_applib_node_ActionNode__DomainObject_mutators {
- streamChildNodes: java_util_stream_Stream
-}
-
-type causeway_applib_node_CollectionNode {
- _gql_meta: causeway_applib_node_CollectionNode__DomainObject_meta
- _gql_mutations: causeway_applib_node_CollectionNode__DomainObject_mutators
- collection: String!
- mixedIn: String!
- parentNode: causeway_applib_TypeNode!
-}
-
-type causeway_applib_node_CollectionNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_applib_node_CollectionNode__DomainObject_mutators {
- streamChildNodes: java_util_stream_Stream
-}
-
-type causeway_applib_node_FacetAttrNode {
- _gql_meta: causeway_applib_node_FacetAttrNode__DomainObject_meta
- facetAttr: String!
- parentNode: causeway_applib_node_FacetNode!
-}
-
-type causeway_applib_node_FacetAttrNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_applib_node_FacetNode {
- _gql_meta: causeway_applib_node_FacetNode__DomainObject_meta
- facet: String!
- shadowed: String!
-}
-
-type causeway_applib_node_FacetNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_conf_ConfigurationMenu {
- configuration: causeway_conf_ConfigurationViewmodel
-}
-
-type causeway_conf_ConfigurationProperty {
- _gql_meta: causeway_conf_ConfigurationProperty__DomainObject_meta
- key: String!
- value: String!
-}
-
-type causeway_conf_ConfigurationProperty__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_conf_ConfigurationViewmodel {
- _gql_meta: causeway_conf_ConfigurationViewmodel__DomainObject_meta
- environment: [causeway_conf_ConfigurationProperty]
- primary: [causeway_conf_ConfigurationProperty]
- secondary: [causeway_conf_ConfigurationProperty]
-}
-
-type causeway_conf_ConfigurationViewmodel__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_feat_ApplicationFeatureViewModel {
- _gql_meta: causeway_feat_ApplicationFeatureViewModel__DomainObject_meta
- memberName: String!
- namespaceName: String!
- typeSimpleName: String!
-}
-
-type causeway_feat_ApplicationFeatureViewModel__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_feat_ApplicationNamespace {
- _gql_meta: causeway_feat_ApplicationNamespace__DomainObject_meta
- memberName: String!
- namespaceName: String!
- typeSimpleName: String!
-}
-
-type causeway_feat_ApplicationNamespace__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_feat_ApplicationType {
- _gql_meta: causeway_feat_ApplicationType__DomainObject_meta
- actions: [causeway_feat_ApplicationTypeAction]
- collections: [causeway_feat_ApplicationTypeCollection]
- memberName: String!
- namespaceName: String!
- properties: [causeway_feat_ApplicationTypeProperty]
- typeSimpleName: String!
-}
-
-type causeway_feat_ApplicationTypeAction {
- _gql_meta: causeway_feat_ApplicationTypeAction__DomainObject_meta
- actionSemantics: String!
- memberName: String!
- namespaceName: String!
- returnType: String!
- typeSimpleName: String!
-}
-
-type causeway_feat_ApplicationTypeAction__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_feat_ApplicationTypeCollection {
- _gql_meta: causeway_feat_ApplicationTypeCollection__DomainObject_meta
- derived: String!
- elementType: String!
- memberName: String!
- namespaceName: String!
- typeSimpleName: String!
-}
-
-type causeway_feat_ApplicationTypeCollection__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_feat_ApplicationTypeMember {
- _gql_meta: causeway_feat_ApplicationTypeMember__DomainObject_meta
- memberName: String!
- namespaceName: String!
- typeSimpleName: String!
-}
-
-type causeway_feat_ApplicationTypeMember__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_feat_ApplicationTypeProperty {
- _gql_meta: causeway_feat_ApplicationTypeProperty__DomainObject_meta
- derived: String!
- maxLength: String
- memberName: String!
- namespaceName: String!
- returnType: String!
- typeSimpleName: String!
- typicalLength: String
-}
-
-type causeway_feat_ApplicationTypeProperty__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_feat_ApplicationType__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_schema_metamodel_v2_DomainClassDto {
- _gql_meta: causeway_schema_metamodel_v2_DomainClassDto__DomainObject_meta
- actions: String!
- annotations: String!
- collections: String!
- facets: String!
- id: String!
- majorVersion: String
- minorVersion: String
- properties: String!
- service: String!
-}
-
-type causeway_schema_metamodel_v2_DomainClassDto__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_security_LoginRedirect {
- _gql_meta: causeway_security_LoginRedirect__DomainObject_meta
-}
-
-type causeway_security_LoginRedirect__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_security_LogoutMenu {
- logout: String
-}
-
-type causeway_testing_fixtures_FixtureResult {
- _gql_meta: causeway_testing_fixtures_FixtureResult__DomainObject_meta
- className: String!
- fixtureScriptClassName: String
- key: String!
-}
-
-type causeway_testing_fixtures_FixtureResult__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type gql_test_domain_Department {
- _gql_meta: gql_test_domain_Department__DomainObject_meta
- deptHead: gql_test_domain_DeptHead
- name: String!
-}
-
-type gql_test_domain_Department__DomainObject_meta {
- id: String!
- logicalTypeName: String!
- version: String
-}
-
-type gql_test_domain_DeptHead {
- _gql_meta: gql_test_domain_DeptHead__DomainObject_meta
- _gql_mutations: gql_test_domain_DeptHead__DomainObject_mutators
- department: gql_test_domain_Department
- name: String
-}
-
-type gql_test_domain_DeptHead__DomainObject_meta {
- id: String!
- logicalTypeName: String!
- version: String
-}
-
-type gql_test_domain_DeptHead__DomainObject_mutators {
- changeDeptHead(department: _gql_input__gql_test_domain_Department!): gql_test_domain_DeptHead
- changeName(newName: String!): gql_test_domain_DeptHead
-}
-
-type gql_test_domain_TopLevelMenu {
- createDepartment(deptHead: _gql_input__gql_test_domain_DeptHead, name: String): gql_test_domain_Department
- findAllDepartments: [gql_test_domain_Department]
- findAllDeptHeads: [gql_test_domain_DeptHead]
- findAllEntitiesWithName: [org_apache_causeway_viewer_graphql_viewer_test_domain_WithName]
- findDeptHeadByName(name: String): gql_test_domain_DeptHead
-}
-
-type java_lang_Runnable {
- _gql_meta: java_lang_Runnable__DomainObject_meta
-}
-
-type java_lang_Runnable__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type java_util_Map {
- _gql_meta: java_util_Map__DomainObject_meta
-}
-
-type java_util_Map__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type java_util_SortedMap {
- _gql_meta: java_util_SortedMap__DomainObject_meta
-}
-
-type java_util_SortedMap__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type java_util_concurrent_Callable {
- _gql_meta: java_util_concurrent_Callable__DomainObject_meta
-}
-
-type java_util_concurrent_Callable__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type java_util_function_BiFunction {
- _gql_meta: java_util_function_BiFunction__DomainObject_meta
-}
-
-type java_util_function_BiFunction__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type java_util_function_Consumer {
- _gql_meta: java_util_function_Consumer__DomainObject_meta
-}
-
-type java_util_function_Consumer__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type java_util_function_Function {
- _gql_meta: java_util_function_Function__DomainObject_meta
-}
-
-type java_util_function_Function__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type java_util_stream_Stream {
- _gql_meta: java_util_stream_Stream__DomainObject_meta
-}
-
-type java_util_stream_Stream__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type org_apache_causeway_commons_functional_Either {
- _gql_meta: org_apache_causeway_commons_functional_Either__DomainObject_meta
- _gql_mutations: org_apache_causeway_commons_functional_Either__DomainObject_mutators
- left: String!
- right: String!
-}
-
-type org_apache_causeway_commons_functional_Either__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type org_apache_causeway_commons_functional_Either__DomainObject_mutators {
- accept(leftConsumer: _gql_input__java_util_function_Consumer!, rightConsumer: _gql_input__java_util_function_Consumer!): String
- left: String
- map(leftMapper: _gql_input__java_util_function_Function!, rightMapper: _gql_input__java_util_function_Function!): org_apache_causeway_commons_functional_Either
- mapLeft(leftMapper: _gql_input__java_util_function_Function!): org_apache_causeway_commons_functional_Either
- mapRight(rightMapper: _gql_input__java_util_function_Function!): org_apache_causeway_commons_functional_Either
- right: String
-}
-
-type org_apache_causeway_commons_functional_Railway {
- _gql_meta: org_apache_causeway_commons_functional_Railway__DomainObject_meta
- _gql_mutations: org_apache_causeway_commons_functional_Railway__DomainObject_mutators
- failure: String!
- success: String!
-}
-
-type org_apache_causeway_commons_functional_Railway__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type org_apache_causeway_commons_functional_Railway__DomainObject_mutators {
- chain(chainingFunction: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Railway
- ifFailure(failureConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Railway
- ifSuccess(successConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Railway
- mapFailure(failureMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Railway
- mapSuccess(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Railway
-}
-
-type org_apache_causeway_commons_functional_ThrowingConsumer {
- _gql_meta: org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_meta
- _gql_mutations: org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_mutators
-}
-
-type org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_mutators {
- andThen(arg0: _gql_input__java_util_function_Consumer!): java_util_function_Consumer
- throwing(exceptionWrapper: _gql_input__java_util_function_BiFunction!): org_apache_causeway_commons_functional_ThrowingConsumer
-}
-
-type org_apache_causeway_commons_functional_ThrowingFunction {
- _gql_meta: org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_meta
- _gql_mutations: org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_mutators
-}
-
-type org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_mutators {
- andThen(arg0: _gql_input__java_util_function_Function!): java_util_function_Function
- compose(arg0: _gql_input__java_util_function_Function!): java_util_function_Function
- throwing(exceptionWrapper: _gql_input__java_util_function_BiFunction!): org_apache_causeway_commons_functional_ThrowingFunction
-}
-
-type org_apache_causeway_commons_functional_ThrowingRunnable {
- _gql_meta: org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_meta
- _gql_mutations: org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_mutators
-}
-
-type org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_mutators {
- callUncatched: String
- run: String
- runUncatched: String
- toCallable: java_util_concurrent_Callable
- toRunnable: java_lang_Runnable
-}
-
-type org_apache_causeway_commons_functional_Try {
- _gql_meta: org_apache_causeway_commons_functional_Try__DomainObject_meta
- _gql_mutations: org_apache_causeway_commons_functional_Try__DomainObject_mutators
- failure: String!
- success: String!
-}
-
-type org_apache_causeway_commons_functional_Try__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type org_apache_causeway_commons_functional_Try__DomainObject_mutators {
- accept(failureConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!, successConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Try
- flatMapSuccess(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
- flatMapSuccessAsNullable(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
- flatMapSuccessWhenPresent(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
- ifAbsentFail: org_apache_causeway_commons_functional_Try
- ifFailure(exceptionConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Try
- ifFailureFail: org_apache_causeway_commons_functional_Try
- ifSuccess(valueConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Try
- ifSuccessAsNullable(valueConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Try
- mapEmptyToFailure: org_apache_causeway_commons_functional_Try
- mapFailure(failureMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
- mapFailureToSuccess(recoveryMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
- mapSuccess(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
- mapSuccessAsNullable(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
- mapSuccessWhenPresent(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
- mapToEither(failureMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!, successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Either
- orCall(fallback: _gql_input__java_util_concurrent_Callable!): org_apache_causeway_commons_functional_Try
- then(next: _gql_input__java_util_concurrent_Callable!): org_apache_causeway_commons_functional_Try
- thenCall(callable: _gql_input__java_util_concurrent_Callable!): org_apache_causeway_commons_functional_Try
- thenRun(runnable: _gql_input__org_apache_causeway_commons_functional_ThrowingRunnable!): org_apache_causeway_commons_functional_Try
-}
-
-type org_apache_causeway_core_metamodel_inspect_model_MMNode {
- _gql_meta: org_apache_causeway_core_metamodel_inspect_model_MMNode__DomainObject_meta
-}
-
-type org_apache_causeway_core_metamodel_inspect_model_MMNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type org_apache_causeway_core_metamodel_inspect_model_MemberNode {
- _gql_meta: org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_meta
- _gql_mutations: org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_mutators
- mixedIn: String!
- parentNode: causeway_applib_TypeNode!
-}
-
-type org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_mutators {
- streamChildNodes: java_util_stream_Stream
-}
-
-type org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript {
- _gql_meta: org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__DomainObject_meta
- friendlyName: String!
- qualifiedName: String!
-}
-
-type org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type org_apache_causeway_viewer_graphql_viewer_test_domain_WithName {
- _gql_meta: org_apache_causeway_viewer_graphql_viewer_test_domain_WithName__DomainObject_meta
- name: String!
-}
-
-type org_apache_causeway_viewer_graphql_viewer_test_domain_WithName__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-input _gql_input__causeway_applib_DomainObjectList {
- id: ID!
-}
-
-input _gql_input__causeway_applib_FacetGroupNode {
- id: ID!
-}
-
-input _gql_input__causeway_applib_ParameterNode {
- id: ID!
-}
-
-input _gql_input__causeway_applib_PropertyNode {
- id: ID!
-}
-
-input _gql_input__causeway_applib_RoleMemento {
- id: ID!
-}
-
-input _gql_input__causeway_applib_TypeNode {
- id: ID!
-}
-
-input _gql_input__causeway_applib_UserMemento {
- id: ID!
-}
-
-input _gql_input__causeway_applib_node_ActionNode {
- id: ID!
-}
-
-input _gql_input__causeway_applib_node_CollectionNode {
- id: ID!
-}
-
-input _gql_input__causeway_applib_node_FacetAttrNode {
- id: ID!
-}
-
-input _gql_input__causeway_applib_node_FacetNode {
- id: ID!
-}
-
-input _gql_input__causeway_conf_ConfigurationProperty {
- id: ID!
-}
-
-input _gql_input__causeway_conf_ConfigurationViewmodel {
- id: ID!
-}
-
-input _gql_input__causeway_feat_ApplicationFeatureViewModel {
- id: ID!
-}
-
-input _gql_input__causeway_feat_ApplicationNamespace {
- id: ID!
-}
-
-input _gql_input__causeway_feat_ApplicationType {
- id: ID!
-}
-
-input _gql_input__causeway_feat_ApplicationTypeAction {
- id: ID!
-}
-
-input _gql_input__causeway_feat_ApplicationTypeCollection {
- id: ID!
-}
-
-input _gql_input__causeway_feat_ApplicationTypeMember {
- id: ID!
-}
-
-input _gql_input__causeway_feat_ApplicationTypeProperty {
- id: ID!
-}
-
-input _gql_input__causeway_schema_metamodel_v2_DomainClassDto {
- id: ID!
-}
-
-input _gql_input__causeway_security_LoginRedirect {
- id: ID!
-}
-
-input _gql_input__causeway_testing_fixtures_FixtureResult {
- id: ID!
-}
-
-input _gql_input__gql_test_domain_Department {
- id: ID!
-}
-
-input _gql_input__gql_test_domain_DeptHead {
- id: ID!
-}
-
-input _gql_input__java_lang_Runnable {
- id: ID!
-}
-
-input _gql_input__java_util_Map {
- id: ID!
-}
-
-input _gql_input__java_util_SortedMap {
- id: ID!
-}
-
-input _gql_input__java_util_concurrent_Callable {
- id: ID!
-}
-
-input _gql_input__java_util_function_BiFunction {
- id: ID!
-}
-
-input _gql_input__java_util_function_Consumer {
- id: ID!
-}
-
-input _gql_input__java_util_function_Function {
- id: ID!
-}
-
-input _gql_input__java_util_stream_Stream {
- id: ID!
-}
-
-input _gql_input__org_apache_causeway_commons_functional_Either {
- id: ID!
-}
-
-input _gql_input__org_apache_causeway_commons_functional_Railway {
- id: ID!
-}
-
-input _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer {
- id: ID!
-}
-
-input _gql_input__org_apache_causeway_commons_functional_ThrowingFunction {
- id: ID!
-}
-
-input _gql_input__org_apache_causeway_commons_functional_ThrowingRunnable {
- id: ID!
-}
-
-input _gql_input__org_apache_causeway_commons_functional_Try {
- id: ID!
-}
-
-input _gql_input__org_apache_causeway_core_metamodel_inspect_model_MMNode {
- id: ID!
-}
-
-input _gql_input__org_apache_causeway_core_metamodel_inspect_model_MemberNode {
- id: ID!
-}
-
-input _gql_input__org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript {
- id: ID!
-}
-
-input _gql_input__org_apache_causeway_viewer_graphql_viewer_test_domain_WithName {
- id: ID!
-}
(causeway) 15/23: CAUSEWAY-3676: uses overload
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit 8e1cc273b864eb99dfe089e73a8dd40036640a6a
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Fri Jan 19 11:26:36 2024 +0000
CAUSEWAY-3676: uses overload
---
.../causeway/viewer/graphql/viewer/source/GraphQLTypeRegistry.java | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQLTypeRegistry.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQLTypeRegistry.java
index a5fb72e23d..fda75e3252 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQLTypeRegistry.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQLTypeRegistry.java
@@ -30,12 +30,12 @@ public class GraphQLTypeRegistry {
final String logicalTypeName) {
if (typeToAdd instanceof GraphQLObjectType) {
- addTypeIfNotAlreadyPresent((GraphQLObjectType) typeToAdd, logicalTypeName);
+ addTypeIfNotAlreadyPresent((GraphQLObjectType) typeToAdd);
return;
}
if (typeToAdd instanceof GraphQLInputObjectType) {
- addTypeIfNotAlreadyPresent((GraphQLInputObjectType) typeToAdd, logicalTypeName);
+ addTypeIfNotAlreadyPresent((GraphQLInputObjectType) typeToAdd);
return;
}
(causeway) 03/23: CAUSEWAY-3676: towards dumping the schema
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit f0090fd9f843a428b7e59cfc3a474527118a75af
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Wed Jan 17 22:37:01 2024 +0000
CAUSEWAY-3676: towards dumping the schema
---
incubator/viewers/graphql/test/pom.xml | 4 ++++
.../CausewayViewerGraphqlTestModuleIntegTestAbstract.java | 4 ++--
...ngeName.submit.gql => EndToEnd_IntegTest.changeName.gql} | 0
....createE1.submit.gql => EndToEnd_IntegTest.createE1.gql} | 0
...bmit.gql => EndToEnd_IntegTest.find_all_departments.gql} | 0
.../viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.java | 11 +++++++++++
.../EndToEnd_IntegTest.schema.gql} | 0
.../viewer/test/schema/GqlSchema_detail_IntegTest.java | 4 +---
.../viewer/test/schema/GqlSchema_print_IntegTest.java | 13 +++++++++----
9 files changed, 27 insertions(+), 9 deletions(-)
diff --git a/incubator/viewers/graphql/test/pom.xml b/incubator/viewers/graphql/test/pom.xml
index c9a13bf825..2e85f61f34 100644
--- a/incubator/viewers/graphql/test/pom.xml
+++ b/incubator/viewers/graphql/test/pom.xml
@@ -43,6 +43,10 @@
<build>
<testResources>
+ <testResource>
+ <directory>src/test/resources</directory>
+ <filtering>true</filtering>
+ </testResource>
<testResource>
<directory>src/test/java</directory>
<filtering>false</filtering>
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
index 028d32d3b5..217dc0417f 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
@@ -141,7 +141,7 @@ public abstract class CausewayViewerGraphqlTestModuleIntegTestAbstract {
protected HttpGraphQlTester graphQlTester() {
WebTestClient client =
WebTestClient.bindToServer()
- .baseUrl("http://0.0.0.0:" + port + "/graphql")
+ .baseUrl(String.format("http://0.0.0.0:%d/graphql", port))
.build();
return HttpGraphQlTester.create(client);
}
@@ -155,7 +155,7 @@ public abstract class CausewayViewerGraphqlTestModuleIntegTestAbstract {
* @throws Exception if an error occurs during the submission
*/
protected String submit() throws Exception{
- val httpRequest = buildRequest(testInfo, ".submit.gql");
+ val httpRequest = buildRequest(testInfo, ".gql");
return submitRequest(httpRequest);
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.changeName.submit.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.changeName.gql
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.changeName.submit.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.changeName.gql
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.createE1.submit.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.createE1.gql
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.createE1.submit.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.createE1.gql
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.find_all_departments.submit.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.find_all_departments.gql
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.find_all_departments.submit.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.find_all_departments.gql
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.java
index b4bedbfa57..e4b1f40d40 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.java
@@ -18,6 +18,7 @@
*/
package org.apache.causeway.viewer.graphql.viewer.test.e2e;
+import java.io.File;
import java.io.IOException;
import java.lang.reflect.Method;
import java.net.URI;
@@ -25,6 +26,9 @@ import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.nio.charset.StandardCharsets;
+import java.nio.file.Files;
+import java.nio.file.Path;
+import java.nio.file.Paths;
import java.util.ArrayList;
import java.util.List;
@@ -53,6 +57,7 @@ import org.approvaltests.reporters.TextWebReporter;
import org.approvaltests.reporters.UseReporter;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
+import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.TestInfo;
import org.junit.jupiter.api.condition.DisabledIfSystemProperty;
@@ -93,6 +98,12 @@ public class EndToEnd_IntegTest extends CausewayViewerGraphqlTestModuleIntegTest
});
}
+ @Test
+ @UseReporter({MyWinMergeDiffReporter.class, DiffReporter.class})
+ void schema() throws Exception {
+ Approvals.verify(submit(), jsonOptions());
+ }
+
@Test
@UseReporter({MyWinMergeDiffReporter.class, DiffReporter.class})
void schema_types_name() throws Exception {
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/introspectquery/introspection-query-request.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.schema.gql
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/introspectquery/introspection-query-request.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.schema.gql
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_detail_IntegTest.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_detail_IntegTest.java
index 65f10c4874..bd709b2e19 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_detail_IntegTest.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_detail_IntegTest.java
@@ -22,6 +22,7 @@ import java.util.List;
import javax.inject.Inject;
+import org.apache.causeway.commons.internal.ioc._IocContainer;
import org.apache.causeway.viewer.graphql.viewer.test.domain.DeptHead;
import org.junit.jupiter.api.BeforeEach;
@@ -170,9 +171,6 @@ public class GqlSchema_detail_IntegTest extends CausewayViewerGraphqlTestModuleI
assertTrue(codeRegistry.hasDataFetcher(FieldCoordinates.coordinates("gqltestdomain_E1", "e2")));
DataFetcher<?> dataFetcher = codeRegistry.getDataFetcher(FieldCoordinates.coordinates("gqltestdomain_E1", "e2"), (GraphQLFieldDefinition) gqltestdomain_e1.getChildren().get(0));
assertNotNull(dataFetcher);
-
-
}
-
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_print_IntegTest.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_print_IntegTest.java
index b12cd83ef3..3ceac932e9 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_print_IntegTest.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_print_IntegTest.java
@@ -18,6 +18,9 @@
*/
package org.apache.causeway.viewer.graphql.viewer.test.schema;
+import java.io.File;
+import java.nio.file.Files;
+import java.nio.file.Paths;
import java.util.stream.Collectors;
import javax.inject.Inject;
@@ -60,17 +63,19 @@ public class GqlSchema_print_IntegTest extends CausewayViewerGraphqlTestModuleIn
assertNotNull(graphQlSourceForCauseway);
}
- @UseReporter({MyWinMergeDiffReporter.class, DiffReporter.class})
@Test
- void schema() {
+ void schema() throws Exception {
+
val graphQL = graphQlSourceForCauseway.graphQl();
val graphQLSchema = graphQL.getGraphQLSchema();
val printer = new SchemaPrinter();
- val schemaDefinition = printer.print(graphQLSchema);
+ val submit = printer.print(graphQLSchema);
+
+ File targetFile1 = new File("src/test/resources/schema.gql");
- Approvals.verify(schemaDefinition, gqlSchemaOptions());
+ Files.write(Paths.get(targetFile1.getPath()), submit.getBytes());
}
private Options gqlSchemaOptions() {
(causeway) 08/23: CAUSEWAY-3676: CAUSEWAY-3678 : extends EntityFacet to obtain the version of the entity
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit 05b2c1c8fc92f0b678c141f6b5ce88ae162d9133
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Thu Jan 18 10:51:10 2024 +0000
CAUSEWAY-3676: CAUSEWAY-3678 : extends EntityFacet to obtain the version of the entity
---
.../facets/object/entity/EntityFacet.java | 2 +
persistence/commons/src/main/java/module-info.java | 1 +
.../integration/version/EntityVersionAccessor.java | 24 +++++++++
.../version/EntityVersionAccessorDefault.java | 50 +++++++++++++++++++
.../metamodel/facets/entity/JdoEntityFacet.java | 9 ++++
.../jpa/applib/integration/HasVersion.java | 57 ++++++++++++++++++++++
.../jpa/integration/entity/JpaEntityFacet.java | 14 ++++++
7 files changed, 157 insertions(+)
diff --git a/core/metamodel/src/main/java/org/apache/causeway/core/metamodel/facets/object/entity/EntityFacet.java b/core/metamodel/src/main/java/org/apache/causeway/core/metamodel/facets/object/entity/EntityFacet.java
index 0d910321d7..4cc0dbe3bf 100644
--- a/core/metamodel/src/main/java/org/apache/causeway/core/metamodel/facets/object/entity/EntityFacet.java
+++ b/core/metamodel/src/main/java/org/apache/causeway/core/metamodel/facets/object/entity/EntityFacet.java
@@ -152,6 +152,8 @@ public interface EntityFacet extends Facet {
EntityState getEntityState(Object pojo);
+ Object versionOf(Object pojo);
+
/**
* Whether given method originates from byte code mangling.
* @param method
diff --git a/persistence/commons/src/main/java/module-info.java b/persistence/commons/src/main/java/module-info.java
index 76f5cf1358..8de9488e1f 100644
--- a/persistence/commons/src/main/java/module-info.java
+++ b/persistence/commons/src/main/java/module-info.java
@@ -21,6 +21,7 @@ module org.apache.causeway.persistence.commons {
exports org.apache.causeway.persistence.commons.metamodel.facets.prop.column;
exports org.apache.causeway.persistence.commons.integration.repository;
exports org.apache.causeway.persistence.commons.integration.changetracking;
+ exports org.apache.causeway.persistence.commons.integration.version;
requires java.annotation;
requires java.desktop;
diff --git a/persistence/commons/src/main/java/org/apache/causeway/persistence/commons/integration/version/EntityVersionAccessor.java b/persistence/commons/src/main/java/org/apache/causeway/persistence/commons/integration/version/EntityVersionAccessor.java
new file mode 100644
index 0000000000..a33b13815d
--- /dev/null
+++ b/persistence/commons/src/main/java/org/apache/causeway/persistence/commons/integration/version/EntityVersionAccessor.java
@@ -0,0 +1,24 @@
+/*
+ * 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.
+ */
+package org.apache.causeway.persistence.commons.integration.version;
+
+public interface EntityVersionAccessor {
+
+ Object versionOf(final Object domainObject);
+}
diff --git a/persistence/commons/src/main/java/org/apache/causeway/persistence/commons/integration/version/EntityVersionAccessorDefault.java b/persistence/commons/src/main/java/org/apache/causeway/persistence/commons/integration/version/EntityVersionAccessorDefault.java
new file mode 100644
index 0000000000..6df2581214
--- /dev/null
+++ b/persistence/commons/src/main/java/org/apache/causeway/persistence/commons/integration/version/EntityVersionAccessorDefault.java
@@ -0,0 +1,50 @@
+/*
+ * 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.
+ */
+package org.apache.causeway.persistence.commons.integration.version;
+
+import lombok.RequiredArgsConstructor;
+
+import javax.annotation.Priority;
+import javax.inject.Inject;
+
+import org.apache.causeway.applib.annotation.PriorityPrecedence;
+
+import org.apache.causeway.core.metamodel.facets.object.entity.EntityFacet;
+import org.apache.causeway.core.metamodel.object.ManagedObject;
+import org.apache.causeway.core.metamodel.objectmanager.ObjectManager;
+
+import org.springframework.stereotype.Service;
+
+@Service
+@Priority(PriorityPrecedence.LAST)
+@RequiredArgsConstructor(onConstructor_ = {@Inject})
+public class EntityVersionAccessorDefault implements EntityVersionAccessor {
+
+ private final ObjectManager objectManager;
+
+ @Override
+ public Object versionOf(Object domainObject) {
+ ManagedObject managedObject = objectManager.adapt(domainObject);
+ EntityFacet facet = managedObject.getSpecification().getFacet(EntityFacet.class);
+ if (facet != null) {
+ return facet.versionOf(domainObject);
+ }
+ return null;
+ }
+}
diff --git a/persistence/jdo/datanucleus/src/main/java/org/apache/causeway/persistence/jdo/datanucleus/metamodel/facets/entity/JdoEntityFacet.java b/persistence/jdo/datanucleus/src/main/java/org/apache/causeway/persistence/jdo/datanucleus/metamodel/facets/entity/JdoEntityFacet.java
index 97f53f6eee..e43cb82834 100644
--- a/persistence/jdo/datanucleus/src/main/java/org/apache/causeway/persistence/jdo/datanucleus/metamodel/facets/entity/JdoEntityFacet.java
+++ b/persistence/jdo/datanucleus/src/main/java/org/apache/causeway/persistence/jdo/datanucleus/metamodel/facets/entity/JdoEntityFacet.java
@@ -27,6 +27,7 @@ import java.util.function.Supplier;
import javax.inject.Inject;
import javax.jdo.FetchGroup;
+import javax.jdo.JDOHelper;
import javax.jdo.PersistenceManager;
import org.datanucleus.api.jdo.JDOQuery;
@@ -368,6 +369,14 @@ implements EntityFacet {
return DnEntityStateProvider.entityState(pojo);
}
+ @Override
+ public Object versionOf(Object pojo) {
+ if (getEntityState(pojo).isAttached()) {
+ return JDOHelper.getVersion(pojo);
+ }
+ return null;
+ }
+
@Override
public <T> T detach(final T pojo) {
return getPersistenceManager().detachCopy(pojo);
diff --git a/persistence/jpa/applib/src/main/java/org/apache/causeway/persistence/jpa/applib/integration/HasVersion.java b/persistence/jpa/applib/src/main/java/org/apache/causeway/persistence/jpa/applib/integration/HasVersion.java
new file mode 100644
index 0000000000..39a8f49de7
--- /dev/null
+++ b/persistence/jpa/applib/src/main/java/org/apache/causeway/persistence/jpa/applib/integration/HasVersion.java
@@ -0,0 +1,57 @@
+/*
+ * 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.
+ */
+package org.apache.causeway.persistence.jpa.applib.integration;
+
+import javax.inject.Inject;
+import javax.inject.Provider;
+import javax.persistence.PostLoad;
+import javax.persistence.PostPersist;
+import javax.persistence.PostRemove;
+import javax.persistence.PostUpdate;
+import javax.persistence.PrePersist;
+import javax.persistence.PreRemove;
+import javax.persistence.PreUpdate;
+
+import org.eclipse.persistence.sessions.UnitOfWork;
+import org.eclipse.persistence.sessions.changesets.DirectToFieldChangeRecord;
+import org.eclipse.persistence.sessions.changesets.ObjectChangeSet;
+
+import org.springframework.lang.Nullable;
+
+import org.apache.causeway.commons.collections.Can;
+import org.apache.causeway.commons.functional.Either;
+import org.apache.causeway.core.metamodel.object.ManagedObject;
+import org.apache.causeway.core.metamodel.object.ManagedObjects;
+import org.apache.causeway.core.metamodel.object.MmEntityUtils;
+import org.apache.causeway.core.metamodel.objectmanager.ObjectManager;
+import org.apache.causeway.core.metamodel.services.objectlifecycle.ObjectLifecyclePublisher;
+import org.apache.causeway.core.metamodel.services.objectlifecycle.PropertyChangeRecord;
+import org.apache.causeway.persistence.jpa.applib.services.JpaSupportService;
+
+import lombok.val;
+import lombok.extern.log4j.Log4j2;
+
+/**
+ * For domain entities to implement, in order to surface their version programmatically.
+ */
+public interface HasVersion<T> {
+
+ T getVersion();
+
+}
diff --git a/persistence/jpa/integration/src/main/java/org/apache/causeway/persistence/jpa/integration/entity/JpaEntityFacet.java b/persistence/jpa/integration/src/main/java/org/apache/causeway/persistence/jpa/integration/entity/JpaEntityFacet.java
index 994e164e3c..44faa0ad1d 100644
--- a/persistence/jpa/integration/src/main/java/org/apache/causeway/persistence/jpa/integration/entity/JpaEntityFacet.java
+++ b/persistence/jpa/integration/src/main/java/org/apache/causeway/persistence/jpa/integration/entity/JpaEntityFacet.java
@@ -23,8 +23,11 @@ import java.util.Optional;
import javax.inject.Inject;
import javax.persistence.EntityManager;
+import javax.persistence.LockModeType;
import javax.persistence.PersistenceUnitUtil;
+import org.apache.causeway.persistence.jpa.applib.integration.HasVersion;
+
import org.springframework.data.jpa.repository.JpaContext;
import org.springframework.lang.Nullable;
@@ -242,6 +245,17 @@ public class JpaEntityFacet
return _JpaEntityStateUtil.getEntityState(entityManager, persistenceUnitUtil, entityClass, primaryKeyType, pojo);
}
+ @Override
+ public Object versionOf(Object pojo) {
+ if (getEntityState(pojo).isAttached()) {
+ if (pojo instanceof HasVersion) {
+ return ((HasVersion<?>)pojo).getVersion();
+ }
+ }
+ return null;
+ }
+
+
@Override
public boolean isProxyEnhancement(final Method method) {
return false;
(causeway) 04/23: CAUSEWAY-3676: deletes GqlSchema_detail_IntegTest
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit 46f3e9d0293aed565ca99f73e107f7d67ef0c215
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Wed Jan 17 22:37:30 2024 +0000
CAUSEWAY-3676: deletes GqlSchema_detail_IntegTest
... too verbose
---
.../test/schema/GqlSchema_detail_IntegTest.java | 176 ---------------------
1 file changed, 176 deletions(-)
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_detail_IntegTest.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_detail_IntegTest.java
deleted file mode 100644
index bd709b2e19..0000000000
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_detail_IntegTest.java
+++ /dev/null
@@ -1,176 +0,0 @@
-/*
- * 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.
- */
-package org.apache.causeway.viewer.graphql.viewer.test.schema;
-
-import java.util.List;
-
-import javax.inject.Inject;
-
-import org.apache.causeway.commons.internal.ioc._IocContainer;
-import org.apache.causeway.viewer.graphql.viewer.test.domain.DeptHead;
-
-import org.junit.jupiter.api.BeforeEach;
-import org.junit.jupiter.api.Disabled;
-import org.junit.jupiter.api.Test;
-
-import org.springframework.transaction.annotation.Transactional;
-
-import org.apache.causeway.core.config.environment.CausewaySystemEnvironment;
-import org.apache.causeway.core.metamodel.spec.ObjectSpecification;
-import org.apache.causeway.core.metamodel.specloader.SpecificationLoader;
-import org.apache.causeway.viewer.graphql.viewer.source.GraphQlSourceForCauseway;
-import org.apache.causeway.viewer.graphql.viewer.test.CausewayViewerGraphqlTestModuleIntegTestAbstract;
-import org.apache.causeway.viewer.graphql.viewer.test.domain.Department;
-import org.apache.causeway.viewer.graphql.viewer.test.domain.TopLevelMenu;
-
-import static org.apache.causeway.commons.internal.assertions._Assert.assertEquals;
-import static org.apache.causeway.commons.internal.assertions._Assert.assertNotNull;
-import static org.apache.causeway.commons.internal.assertions._Assert.assertTrue;
-
-import graphql.GraphQL;
-import graphql.Scalars;
-import graphql.schema.DataFetcher;
-import graphql.schema.FieldCoordinates;
-import graphql.schema.GraphQLArgument;
-import graphql.schema.GraphQLCodeRegistry;
-import graphql.schema.GraphQLFieldDefinition;
-import graphql.schema.GraphQLList;
-import graphql.schema.GraphQLObjectType;
-import graphql.schema.GraphQLOutputType;
-import graphql.schema.GraphQLScalarType;
-import graphql.schema.GraphQLSchema;
-import graphql.schema.GraphQLSchemaElement;
-import graphql.schema.GraphQLType;
-import graphql.schema.GraphQLTypeReference;
-
-@Transactional
-public class GqlSchema_detail_IntegTest extends CausewayViewerGraphqlTestModuleIntegTestAbstract {
-
- @Inject private CausewaySystemEnvironment causewaySystemEnvironment;
- @Inject private SpecificationLoader specificationLoader;
- @Inject private GraphQlSourceForCauseway graphQlSourceForCauseway;
-
- @BeforeEach
- void beforeEach() {
- assertNotNull(causewaySystemEnvironment);
- assertNotNull(specificationLoader);
- assertNotNull(graphQlSourceForCauseway);
- }
-
-
- @Test
- @Disabled
- void detail() {
-
- GraphQLSchema x;
-
-// _IocContainer iocContainer = causewaySystemEnvironment.getIocContainer();
-// iocContainer.streamAllBeans().forEach(b->{
-// System.out.println(b.getId());
-// });
-
- System.out.println(port);
-
- ObjectSpecification objectSpecification1 = specificationLoader.specForType(Department.class).get();
- assertNotNull(objectSpecification1);
-
- ObjectSpecification objectSpecification2 = specificationLoader.specForType(DeptHead.class).get();
- assertNotNull(objectSpecification2);
-
- ObjectSpecification objectSpecification3 = specificationLoader.specForType(TopLevelMenu.class).get();
- assertNotNull(objectSpecification3);
-
- GraphQL graphQL = graphQlSourceForCauseway.graphQl();
- GraphQLSchema graphQLSchema = graphQL.getGraphQLSchema();
-
-
-// List<GraphQLNamedType> allTypesAsList = graphQLSchema.getAllTypesAsList();
-// allTypesAsList.forEach(t->{
-// System.out.println(t.getName());
-// });
-
- assertTrue(graphQLSchema.containsType("gqltestdomain_E1"));
- assertTrue(graphQLSchema.containsType("gqltestdomain_E2"));
- assertTrue(graphQLSchema.containsType("gqltestdomain_GQLTestDomainMenu"));
- assertTrue(graphQLSchema.containsType("_gql_input__gqltestdomain_E1"));
- assertTrue(graphQLSchema.containsType("_gql_input__gqltestdomain_E2"));
-
- GraphQLType gqltestdomain_e1 = graphQLSchema.getType("gqltestdomain_E1");
- List<GraphQLSchemaElement> children = gqltestdomain_e1.getChildren();
- assertEquals(3, children.size());
-
- GraphQLObjectType gqltestdomain_e2 = (GraphQLObjectType) graphQLSchema.getType("gqltestdomain_E2");
- List<GraphQLFieldDefinition> fields = gqltestdomain_e2.getFields();
- assertEquals(10, fields.size());
-
- GraphQLFieldDefinition f6 = fields.get(5);
- assertEquals("otherE2List", f6.getName());
- Class<? extends GraphQLOutputType> f6TypeClass = f6.getType().getClass();
- assertEquals(GraphQLList.class, f6TypeClass);
- GraphQLList list = (GraphQLList) f6.getType();
- GraphQLTypeReference originalWrappedType = (GraphQLTypeReference) list.getOriginalWrappedType();
- assertEquals(originalWrappedType.getName(), gqltestdomain_e2.getName());
-
- GraphQLFieldDefinition f7 = fields.get(6);
- assertEquals("stringList", f7.getName());
- Class<? extends GraphQLOutputType> f7TypeClass = f7.getType().getClass();
- assertEquals(GraphQLList.class, f7TypeClass);
- GraphQLList list2 = (GraphQLList) f7.getType();
- GraphQLScalarType originalWrappedType2 = (GraphQLScalarType) list2.getOriginalWrappedType();
- assertEquals(Scalars.GraphQLString, originalWrappedType2);
-
- GraphQLFieldDefinition f8 = fields.get(7);
- assertEquals("zintList", f8.getName());
- Class<? extends GraphQLOutputType> f8TypeClass = f8.getType().getClass();
- assertEquals(GraphQLList.class, f8TypeClass);
- GraphQLList list3 = (GraphQLList) f8.getType();
- GraphQLScalarType originalWrappedType3 = (GraphQLScalarType) list3.getOriginalWrappedType();
- assertEquals(Scalars.GraphQLInt, originalWrappedType3);
-
- GraphQLFieldDefinition f9 = fields.get(8);
- assertEquals("otherEntities", f9.getName());
- Class<? extends GraphQLOutputType> f9TypeClass = f9.getType().getClass();
- assertEquals(GraphQLList.class, f9TypeClass);
- GraphQLList list4 = (GraphQLList) f9.getType();
- GraphQLTypeReference originalWrappedType4 = (GraphQLTypeReference) list4.getOriginalWrappedType();
- assertEquals("org_apache_causeway_viewer_graphql_viewer_source_gqltestdomain_TestEntity", originalWrappedType4.getName());
-
- GraphQLFieldDefinition f10 = fields.get(9);
- assertEquals("_gql_mutations", f10.getName());
- GraphQLObjectType mutationType = (GraphQLObjectType) f10.getType();
- assertEquals("gqltestdomain_E2__DomainObject_mutators", mutationType.getName());
- assertEquals(1, mutationType.getFields().size());
- GraphQLFieldDefinition graphQLFieldDefinition = mutationType.getFields().get(0);
- assertEquals("changeDeptHead",graphQLFieldDefinition.getName());
- GraphQLArgument mutatorArgument = graphQLFieldDefinition.getArgument("e1");
-
- GraphQLType gqltestdomain_e1__domainObject_meta = graphQLSchema.getType("gqltestdomain_E1__DomainObject_meta");
- List<GraphQLSchemaElement> children1 = gqltestdomain_e1__domainObject_meta.getChildren();
- assertEquals(3, children1.size());
-
- GraphQLCodeRegistry codeRegistry = graphQLSchema.getCodeRegistry();
- assertNotNull(codeRegistry);
-
- // example of data fetches registered
- assertTrue(codeRegistry.hasDataFetcher(FieldCoordinates.coordinates("gqltestdomain_E1", "e2")));
- DataFetcher<?> dataFetcher = codeRegistry.getDataFetcher(FieldCoordinates.coordinates("gqltestdomain_E1", "e2"), (GraphQLFieldDefinition) gqltestdomain_e1.getChildren().get(0));
- assertNotNull(dataFetcher);
- }
-
-}
(causeway) 07/23: CAUSEWAY-3676: moves test domain into a 'university' namespace
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit 28d26839d9d868d94cb8341a3a5d7dacccfd370d
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Wed Jan 17 23:39:57 2024 +0000
CAUSEWAY-3676: moves test domain into a 'university' namespace
---
...ayViewerGraphqlTestModuleIntegTestAbstract.java | 4 +-
.../graphql/viewer/test/domain/Department.java | 14 +-
.../{TopLevelMenu.java => DepartmentMenu.java} | 21 +-
.../graphql/viewer/test/domain/DeptHead.java | 10 +-
.../{WithNameRepository.java => DeptHeadMenu.java} | 36 +-
...TestDomainModule.java => UniversityModule.java} | 4 +-
.../graphql/viewer/test/domain/WithName.java | 25 -
.../e2e/Domain_IntegTest.create_department._.gql | 2 +-
...omain_IntegTest.create_department.approved.json | 2 +-
.../Domain_IntegTest.find_all_departments._.gql | 2 +-
...in_IntegTest.find_all_departments.approved.json | 6 +-
...IntegTest.find_department_and_change_name._.gql | 2 +-
.../graphql/viewer/test/e2e/Domain_IntegTest.java | 7 +-
.../graphql/viewer/test/e2e/Schema_IntegTest.java | 18 -
.../test/e2e/Schema_IntegTest.schema.approved.json | 1321 +++++++++-----------
...chema_IntegTest.schema_types_name.approved.json | 34 +-
.../graphql/test/src/test/resources/schema.gql | 91 +-
17 files changed, 722 insertions(+), 877 deletions(-)
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
index f0ceb8a16c..6f88728dbf 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
@@ -65,7 +65,7 @@ import org.apache.causeway.persistence.jpa.eclipselink.CausewayModulePersistence
import org.apache.causeway.security.bypass.CausewayModuleSecurityBypass;
import org.apache.causeway.testing.fixtures.applib.CausewayModuleTestingFixturesApplib;
import org.apache.causeway.viewer.graphql.viewer.CausewayModuleIncViewerGraphqlViewer;
-import org.apache.causeway.viewer.graphql.viewer.test.domain.TestDomainModule;
+import org.apache.causeway.viewer.graphql.viewer.test.domain.UniversityModule;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.ObjectMapper;
@@ -99,7 +99,7 @@ public abstract class CausewayViewerGraphqlTestModuleIntegTestAbstract {
CausewayModuleTestingFixturesApplib.class,
CausewayModuleIncViewerGraphqlViewer.class,
- TestDomainModule.class
+ UniversityModule.class
})
@PropertySources({
@PropertySource(CausewayPresets.H2InMemory_withUniqueSchema),
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/Department.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/Department.java
index c9779a8921..4e0ca243e3 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/Department.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/Department.java
@@ -33,16 +33,17 @@ import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
-//@Profile("demo-jpa")
+import java.util.Comparator;
+
@Entity
@Table(
schema = "public",
name = "Department"
)
-@javax.inject.Named("gql.test.domain.Department")
+@javax.inject.Named("university.dept.Department")
@NoArgsConstructor
@DomainObject(nature = Nature.ENTITY)
-public class Department implements WithName, Comparable {
+public class Department implements Comparable<Department> {
public Department(String name, DeptHead deptHead) {
this.name = name;
@@ -59,12 +60,11 @@ public class Department implements WithName, Comparable {
@Getter @Setter
@Property
@OneToOne(optional = true)
- @JoinColumn(name = "employee_id")
+ @JoinColumn(name = "deptHead_id")
private DeptHead deptHead;
@Override
- public int compareTo(final Object o) {
- Department department = (Department) o;
- return this.getName().compareTo(department.getName());
+ public int compareTo(final Department o) {
+ return Comparator.comparing(Department::getName).compare(this, o);
}
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/TopLevelMenu.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DepartmentMenu.java
similarity index 76%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/TopLevelMenu.java
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DepartmentMenu.java
index baab6cca13..b4e2f22d97 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/TopLevelMenu.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DepartmentMenu.java
@@ -33,16 +33,14 @@ import org.apache.causeway.applib.annotation.SemanticsOf;
import lombok.RequiredArgsConstructor;
-@Named("gql.test.domain.TopLevelMenu")
+@Named("university.dept.DepartmentMenu")
@DomainService(
nature=NatureOfService.VIEW)
@javax.annotation.Priority(PriorityPrecedence.EARLY)
@RequiredArgsConstructor(onConstructor_ = {@Inject})
-public class TopLevelMenu {
+public class DepartmentMenu {
final DepartmentRepository departmentRepository;
- final DeptHeadRepository deptHeadRepository;
- final WithNameRepository withNameRepository;
@Action(semantics = SemanticsOf.NON_IDEMPOTENT)
public Department createDepartment(
@@ -57,20 +55,5 @@ public class TopLevelMenu {
return departmentRepository.findAll();
}
- @Action(semantics = SemanticsOf.SAFE)
- public List<DeptHead> findAllDeptHeads(){
- return deptHeadRepository.findAll();
- }
-
- @Action(semantics = SemanticsOf.SAFE)
- public List<WithName> findAllEntitiesWithName(){
- return withNameRepository.findAll();
- }
-
- @Action(semantics = SemanticsOf.SAFE)
- public DeptHead findDeptHeadByName(final String name){
- return deptHeadRepository.findByName(name);
- }
-
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHead.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHead.java
index a919bfe645..f42f4812e7 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHead.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHead.java
@@ -18,6 +18,7 @@
*/
package org.apache.causeway.viewer.graphql.viewer.test.domain;
+import java.util.Comparator;
import java.util.List;
import java.util.stream.Collectors;
@@ -46,9 +47,9 @@ import lombok.Setter;
schema = "public",
name = "DeptHead"
)
-@javax.inject.Named("gql.test.domain.DeptHead")
+@javax.inject.Named("university.dept.DeptHead")
@DomainObject(nature = Nature.ENTITY, bounding = Bounding.BOUNDED)
-public class DeptHead implements WithName {
+public class DeptHead implements Comparable<DeptHead> {
@Id
@GeneratedValue
@@ -99,7 +100,12 @@ public class DeptHead implements WithName {
}
}
+ @Override
+ public int compareTo(final DeptHead o) {
+ return Comparator.comparing(DeptHead::getName).compare(this, o);
+ }
@Inject @Transient DepartmentRepository departmentRepository;
+
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/WithNameRepository.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHeadMenu.java
similarity index 50%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/WithNameRepository.java
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHeadMenu.java
index fe5bf15b0c..a0434e76e4 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/WithNameRepository.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHeadMenu.java
@@ -18,29 +18,37 @@
*/
package org.apache.causeway.viewer.graphql.viewer.test.domain;
-import java.util.ArrayList;
import java.util.List;
import javax.inject.Inject;
+import javax.inject.Named;
-import org.springframework.stereotype.Repository;
+import org.springframework.lang.Nullable;
-@Repository
-public class WithNameRepository {
+import org.apache.causeway.applib.annotation.Action;
+import org.apache.causeway.applib.annotation.DomainService;
+import org.apache.causeway.applib.annotation.NatureOfService;
+import org.apache.causeway.applib.annotation.PriorityPrecedence;
+import org.apache.causeway.applib.annotation.SemanticsOf;
- @Inject private DepartmentRepository departmentRepository;
- @Inject private DeptHeadRepository deptHeadRepository;
+import lombok.RequiredArgsConstructor;
- public List<WithName> findAll() {
- final List<WithName> result = new ArrayList<>();
- result.addAll(departmentRepository.findAll());
- result.addAll(deptHeadRepository.findAll());
- return result;
+@Named("university.dept.DeptHeadMenu")
+@DomainService(nature=NatureOfService.VIEW)
+@javax.annotation.Priority(PriorityPrecedence.EARLY)
+@RequiredArgsConstructor(onConstructor_ = {@Inject})
+public class DeptHeadMenu {
+
+ final DeptHeadRepository deptHeadRepository;
+
+ @Action(semantics = SemanticsOf.SAFE)
+ public List<DeptHead> findAllDeptHeads(){
+ return deptHeadRepository.findAll();
}
- public void removeAll(){
- departmentRepository.removeAll();
- deptHeadRepository.removeAll();
+ @Action(semantics = SemanticsOf.SAFE)
+ public DeptHead findDeptHeadByName(final String name){
+ return deptHeadRepository.findByName(name);
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/TestDomainModule.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/UniversityModule.java
similarity index 93%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/TestDomainModule.java
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/UniversityModule.java
index 537ef8fe12..d1e7cf2fb2 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/TestDomainModule.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/UniversityModule.java
@@ -29,8 +29,8 @@ import org.apache.causeway.testing.fixtures.applib.modules.ModuleWithFixtures;
@Configuration
@ComponentScan
@EnableJpaRepositories
-@EntityScan(basePackageClasses = {TestDomainModule.class})
-public class TestDomainModule implements ModuleWithFixtures {
+@EntityScan(basePackageClasses = {UniversityModule.class})
+public class UniversityModule implements ModuleWithFixtures {
@Override
public FixtureScript getTeardownFixture() {
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/WithName.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/WithName.java
deleted file mode 100644
index aeb7dabdec..0000000000
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/WithName.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * 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.
- */
-package org.apache.causeway.viewer.graphql.viewer.test.domain;
-
-public interface WithName {
-
- public String getName();
-
-}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.create_department._.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.create_department._.gql
index ab95101b5c..f9f5a62d19 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.create_department._.gql
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.create_department._.gql
@@ -1,5 +1,5 @@
{
- gql_test_domain_TopLevelMenu {
+ university_dept_DepartmentMenu {
createDepartment(name: "newbie") {
name
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.create_department.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.create_department.approved.json
index 90328010f5..7625e509e7 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.create_department.approved.json
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.create_department.approved.json
@@ -1,6 +1,6 @@
{
"data" : {
- "gql_test_domain_TopLevelMenu" : {
+ "university_dept_DepartmentMenu" : {
"createDepartment" : {
"name" : "newbie"
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments._.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments._.gql
index c921e5677d..a9024b45f3 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments._.gql
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments._.gql
@@ -1,5 +1,5 @@
{
- gql_test_domain_TopLevelMenu {
+ university_dept_DepartmentMenu {
findAllDepartments {
name
_gql_meta {
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments.approved.json
index 56ffa2f775..f3645a3aa0 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments.approved.json
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments.approved.json
@@ -1,18 +1,18 @@
{
"data" : {
- "gql_test_domain_TopLevelMenu" : {
+ "university_dept_DepartmentMenu" : {
"findAllDepartments" : [ {
"name" : "foo",
"_gql_meta" : {
"id" : "2",
- "logicalTypeName" : "gql.test.domain.Department",
+ "logicalTypeName" : "university.dept.Department",
"version" : null
}
}, {
"name" : "bar",
"_gql_meta" : {
"id" : "3",
- "logicalTypeName" : "gql.test.domain.Department",
+ "logicalTypeName" : "university.dept.Department",
"version" : null
}
} ]
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_department_and_change_name._.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_department_and_change_name._.gql
index 9d90107009..c9814de893 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_department_and_change_name._.gql
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_department_and_change_name._.gql
@@ -1,5 +1,5 @@
{
- gql_test_domain_TopLevelMenu {
+ university_dept_DeptHeadMenu {
findDeptHeadByName(name: "foo") {
_gql_mutations {
changeName(newName: "bar") {
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.java
index 352f653784..1ce01e458d 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.java
@@ -20,19 +20,16 @@ package org.apache.causeway.viewer.graphql.viewer.test.e2e;
import lombok.val;
-import java.util.ArrayList;
import java.util.List;
import javax.inject.Inject;
import org.approvaltests.Approvals;
import org.approvaltests.reporters.DiffReporter;
-import org.approvaltests.reporters.TextWebReporter;
import org.approvaltests.reporters.UseReporter;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.condition.DisabledIfSystemProperty;
import static org.assertj.core.api.AssertionsForInterfaceTypes.assertThat;
@@ -44,7 +41,7 @@ import org.apache.causeway.viewer.graphql.viewer.test.domain.Department;
import org.apache.causeway.viewer.graphql.viewer.test.domain.DepartmentRepository;
import org.apache.causeway.viewer.graphql.viewer.test.domain.DeptHead;
import org.apache.causeway.viewer.graphql.viewer.test.domain.DeptHeadRepository;
-import org.apache.causeway.viewer.graphql.viewer.test.domain.TopLevelMenu;
+import org.apache.causeway.viewer.graphql.viewer.test.domain.DepartmentMenu;
import static org.apache.causeway.commons.internal.assertions._Assert.assertEquals;
import static org.apache.causeway.commons.internal.assertions._Assert.assertTrue;
@@ -56,7 +53,7 @@ public class Domain_IntegTest extends CausewayViewerGraphqlTestModuleIntegTestAb
@Inject DepartmentRepository departmentRepository;
@Inject DeptHeadRepository deptHeadRepository;
- @Inject TopLevelMenu topLevelMenu;
+ @Inject DepartmentMenu departmentMenu;
@AfterEach
void afterEach(){
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.java
index 816f43ae16..cfda766e7a 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.java
@@ -18,32 +18,14 @@
*/
package org.apache.causeway.viewer.graphql.viewer.test.e2e;
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.inject.Inject;
-
import org.apache.causeway.viewer.graphql.viewer.test.CausewayViewerGraphqlTestModuleIntegTestAbstract;
-import org.apache.causeway.viewer.graphql.viewer.test.domain.Department;
-
-import org.apache.causeway.viewer.graphql.viewer.test.domain.DeptHead;
-import org.apache.causeway.viewer.graphql.viewer.test.domain.DepartmentRepository;
-
-import org.apache.causeway.viewer.graphql.viewer.test.domain.DeptHeadRepository;
-
import org.approvaltests.Approvals;
import org.approvaltests.reporters.DiffReporter;
-import org.approvaltests.reporters.TextWebReporter;
import org.approvaltests.reporters.UseReporter;
-import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.condition.DisabledIfSystemProperty;
import org.springframework.test.context.ActiveProfiles;
-import org.springframework.transaction.annotation.Propagation;
-
-import org.apache.causeway.viewer.graphql.viewer.test.domain.TopLevelMenu;
import static org.apache.causeway.commons.internal.assertions._Assert.assertEquals;
import static org.apache.causeway.commons.internal.assertions._Assert.assertNotNull;
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema.approved.json
index cafdedb247..447ff3cb33 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema.approved.json
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema.approved.json
@@ -71,12 +71,23 @@
"isDeprecated" : false,
"deprecationReason" : null
}, {
- "name" : "gql_test_domain_TopLevelMenu",
+ "name" : "university_dept_DepartmentMenu",
"description" : null,
"args" : [ ],
"type" : {
"kind" : "OBJECT",
- "name" : "gql_test_domain_TopLevelMenu",
+ "name" : "university_dept_DepartmentMenu",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "university_dept_DeptHeadMenu",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "university_dept_DeptHeadMenu",
"ofType" : null
},
"isDeprecated" : false,
@@ -1450,29 +1461,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__gql_test_domain_Department",
- "description" : null,
- "fields" : null,
- "inputFields" : [ {
- "name" : "id",
- "description" : null,
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "SCALAR",
- "name" : "ID",
- "ofType" : null
- }
- },
- "defaultValue" : null
- } ],
- "interfaces" : null,
- "enumValues" : null,
- "possibleTypes" : null
- }, {
- "kind" : "INPUT_OBJECT",
- "name" : "_gql_input__gql_test_domain_DeptHead",
+ "name" : "_gql_input__java_lang_Runnable",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1494,7 +1483,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__java_lang_Runnable",
+ "name" : "_gql_input__java_util_Map",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1516,7 +1505,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__java_util_Map",
+ "name" : "_gql_input__java_util_SortedMap",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1538,7 +1527,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__java_util_SortedMap",
+ "name" : "_gql_input__java_util_concurrent_Callable",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1560,7 +1549,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__java_util_concurrent_Callable",
+ "name" : "_gql_input__java_util_function_BiFunction",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1582,7 +1571,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__java_util_function_BiFunction",
+ "name" : "_gql_input__java_util_function_Consumer",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1604,7 +1593,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__java_util_function_Consumer",
+ "name" : "_gql_input__java_util_function_Function",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1626,7 +1615,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__java_util_function_Function",
+ "name" : "_gql_input__java_util_stream_Stream",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1648,7 +1637,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__java_util_stream_Stream",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_Either",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1670,7 +1659,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__org_apache_causeway_commons_functional_Either",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_Railway",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1692,7 +1681,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__org_apache_causeway_commons_functional_Railway",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingConsumer",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1714,7 +1703,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingConsumer",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingFunction",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1736,7 +1725,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingFunction",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingRunnable",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1758,7 +1747,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingRunnable",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_Try",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1780,7 +1769,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__org_apache_causeway_commons_functional_Try",
+ "name" : "_gql_input__org_apache_causeway_core_metamodel_inspect_model_MMNode",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1802,7 +1791,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__org_apache_causeway_core_metamodel_inspect_model_MMNode",
+ "name" : "_gql_input__org_apache_causeway_core_metamodel_inspect_model_MemberNode",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1824,7 +1813,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__org_apache_causeway_core_metamodel_inspect_model_MemberNode",
+ "name" : "_gql_input__org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1846,7 +1835,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript",
+ "name" : "_gql_input__university_dept_Department",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -1868,7 +1857,7 @@
"possibleTypes" : null
}, {
"kind" : "INPUT_OBJECT",
- "name" : "_gql_input__org_apache_causeway_viewer_graphql_viewer_test_domain_WithName",
+ "name" : "_gql_input__university_dept_DeptHead",
"description" : null,
"fields" : null,
"inputFields" : [ {
@@ -4604,7 +4593,7 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "gql_test_domain_Department",
+ "name" : "java_lang_Runnable",
"description" : null,
"fields" : [ {
"name" : "_gql_meta",
@@ -4612,24 +4601,37 @@
"args" : [ ],
"type" : {
"kind" : "OBJECT",
- "name" : "gql_test_domain_Department__DomainObject_meta",
+ "name" : "java_lang_Runnable__DomainObject_meta",
"ofType" : null
},
"isDeprecated" : false,
"deprecationReason" : null
- }, {
- "name" : "deptHead",
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_lang_Runnable__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
"description" : null,
"args" : [ ],
"type" : {
- "kind" : "OBJECT",
- "name" : "gql_test_domain_DeptHead",
- "ofType" : null
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
},
"isDeprecated" : false,
"deprecationReason" : null
}, {
- "name" : "name",
+ "name" : "logicalTypeName",
"description" : null,
"args" : [ ],
"type" : {
@@ -4650,7 +4652,27 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "gql_test_domain_Department__DomainObject_meta",
+ "name" : "java_util_Map",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_util_Map__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_util_Map__DomainObject_meta",
"description" : null,
"fields" : [ {
"name" : "id",
@@ -4682,17 +4704,6 @@
},
"isDeprecated" : false,
"deprecationReason" : null
- }, {
- "name" : "version",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "SCALAR",
- "name" : "String",
- "ofType" : null
- },
- "isDeprecated" : false,
- "deprecationReason" : null
} ],
"inputFields" : null,
"interfaces" : [ ],
@@ -4700,7 +4711,7 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "gql_test_domain_DeptHead",
+ "name" : "java_util_SortedMap",
"description" : null,
"fields" : [ {
"name" : "_gql_meta",
@@ -4708,40 +4719,66 @@
"args" : [ ],
"type" : {
"kind" : "OBJECT",
- "name" : "gql_test_domain_DeptHead__DomainObject_meta",
+ "name" : "java_util_SortedMap__DomainObject_meta",
"ofType" : null
},
"isDeprecated" : false,
"deprecationReason" : null
- }, {
- "name" : "department",
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_util_SortedMap__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
"description" : null,
"args" : [ ],
"type" : {
- "kind" : "OBJECT",
- "name" : "gql_test_domain_Department",
- "ofType" : null
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
},
"isDeprecated" : false,
"deprecationReason" : null
}, {
- "name" : "name",
+ "name" : "logicalTypeName",
"description" : null,
"args" : [ ],
"type" : {
- "kind" : "SCALAR",
- "name" : "String",
- "ofType" : null
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
},
"isDeprecated" : false,
"deprecationReason" : null
- }, {
- "name" : "_gql_mutations",
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_util_concurrent_Callable",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
"description" : null,
"args" : [ ],
"type" : {
"kind" : "OBJECT",
- "name" : "gql_test_domain_DeptHead__DomainObject_mutators",
+ "name" : "java_util_concurrent_Callable__DomainObject_meta",
"ofType" : null
},
"isDeprecated" : false,
@@ -4753,7 +4790,7 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "gql_test_domain_DeptHead__DomainObject_meta",
+ "name" : "java_util_concurrent_Callable__DomainObject_meta",
"description" : null,
"fields" : [ {
"name" : "id",
@@ -4785,17 +4822,6 @@
},
"isDeprecated" : false,
"deprecationReason" : null
- }, {
- "name" : "version",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "SCALAR",
- "name" : "String",
- "ofType" : null
- },
- "isDeprecated" : false,
- "deprecationReason" : null
} ],
"inputFields" : null,
"interfaces" : [ ],
@@ -4803,52 +4829,15 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "gql_test_domain_DeptHead__DomainObject_mutators",
+ "name" : "java_util_function_BiFunction",
"description" : null,
"fields" : [ {
- "name" : "changeDepartment",
- "description" : null,
- "args" : [ {
- "name" : "department",
- "description" : null,
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "INPUT_OBJECT",
- "name" : "_gql_input__gql_test_domain_Department",
- "ofType" : null
- }
- },
- "defaultValue" : null
- } ],
- "type" : {
- "kind" : "OBJECT",
- "name" : "gql_test_domain_DeptHead",
- "ofType" : null
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- }, {
- "name" : "changeName",
+ "name" : "_gql_meta",
"description" : null,
- "args" : [ {
- "name" : "newName",
- "description" : null,
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "SCALAR",
- "name" : "String",
- "ofType" : null
- }
- },
- "defaultValue" : null
- } ],
+ "args" : [ ],
"type" : {
"kind" : "OBJECT",
- "name" : "gql_test_domain_DeptHead",
+ "name" : "java_util_function_BiFunction__DomainObject_meta",
"ofType" : null
},
"isDeprecated" : false,
@@ -4860,99 +4849,35 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "gql_test_domain_TopLevelMenu",
+ "name" : "java_util_function_BiFunction__DomainObject_meta",
"description" : null,
"fields" : [ {
- "name" : "createDepartment",
+ "name" : "id",
"description" : null,
- "args" : [ {
- "name" : "name",
- "description" : null,
- "type" : {
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
"kind" : "SCALAR",
"name" : "String",
"ofType" : null
- },
- "defaultValue" : null
- }, {
- "name" : "deptHead",
- "description" : null,
- "type" : {
- "kind" : "INPUT_OBJECT",
- "name" : "_gql_input__gql_test_domain_DeptHead",
- "ofType" : null
- },
- "defaultValue" : null
- } ],
- "type" : {
- "kind" : "OBJECT",
- "name" : "gql_test_domain_Department",
- "ofType" : null
+ }
},
"isDeprecated" : false,
"deprecationReason" : null
}, {
- "name" : "findAllDepartments",
+ "name" : "logicalTypeName",
"description" : null,
"args" : [ ],
"type" : {
- "kind" : "LIST",
+ "kind" : "NON_NULL",
"name" : null,
"ofType" : {
- "kind" : "OBJECT",
- "name" : "gql_test_domain_Department",
- "ofType" : null
- }
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- }, {
- "name" : "findAllDeptHeads",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "LIST",
- "name" : null,
- "ofType" : {
- "kind" : "OBJECT",
- "name" : "gql_test_domain_DeptHead",
- "ofType" : null
- }
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- }, {
- "name" : "findAllEntitiesWithName",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "LIST",
- "name" : null,
- "ofType" : {
- "kind" : "OBJECT",
- "name" : "org_apache_causeway_viewer_graphql_viewer_test_domain_WithName",
- "ofType" : null
- }
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- }, {
- "name" : "findDeptHeadByName",
- "description" : null,
- "args" : [ {
- "name" : "name",
- "description" : null,
- "type" : {
"kind" : "SCALAR",
"name" : "String",
"ofType" : null
- },
- "defaultValue" : null
- } ],
- "type" : {
- "kind" : "OBJECT",
- "name" : "gql_test_domain_DeptHead",
- "ofType" : null
+ }
},
"isDeprecated" : false,
"deprecationReason" : null
@@ -4963,7 +4888,7 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "java_lang_Runnable",
+ "name" : "java_util_function_Consumer",
"description" : null,
"fields" : [ {
"name" : "_gql_meta",
@@ -4971,7 +4896,7 @@
"args" : [ ],
"type" : {
"kind" : "OBJECT",
- "name" : "java_lang_Runnable__DomainObject_meta",
+ "name" : "java_util_function_Consumer__DomainObject_meta",
"ofType" : null
},
"isDeprecated" : false,
@@ -4983,7 +4908,7 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "java_lang_Runnable__DomainObject_meta",
+ "name" : "java_util_function_Consumer__DomainObject_meta",
"description" : null,
"fields" : [ {
"name" : "id",
@@ -5022,7 +4947,7 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "java_util_Map",
+ "name" : "java_util_function_Function",
"description" : null,
"fields" : [ {
"name" : "_gql_meta",
@@ -5030,7 +4955,7 @@
"args" : [ ],
"type" : {
"kind" : "OBJECT",
- "name" : "java_util_Map__DomainObject_meta",
+ "name" : "java_util_function_Function__DomainObject_meta",
"ofType" : null
},
"isDeprecated" : false,
@@ -5042,7 +4967,7 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "java_util_Map__DomainObject_meta",
+ "name" : "java_util_function_Function__DomainObject_meta",
"description" : null,
"fields" : [ {
"name" : "id",
@@ -5081,7 +5006,7 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "java_util_SortedMap",
+ "name" : "java_util_stream_Stream",
"description" : null,
"fields" : [ {
"name" : "_gql_meta",
@@ -5089,7 +5014,7 @@
"args" : [ ],
"type" : {
"kind" : "OBJECT",
- "name" : "java_util_SortedMap__DomainObject_meta",
+ "name" : "java_util_stream_Stream__DomainObject_meta",
"ofType" : null
},
"isDeprecated" : false,
@@ -5101,7 +5026,7 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "java_util_SortedMap__DomainObject_meta",
+ "name" : "java_util_stream_Stream__DomainObject_meta",
"description" : null,
"fields" : [ {
"name" : "id",
@@ -5140,7 +5065,7 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "java_util_concurrent_Callable",
+ "name" : "org_apache_causeway_commons_functional_Either",
"description" : null,
"fields" : [ {
"name" : "_gql_meta",
@@ -5148,22 +5073,13 @@
"args" : [ ],
"type" : {
"kind" : "OBJECT",
- "name" : "java_util_concurrent_Callable__DomainObject_meta",
+ "name" : "org_apache_causeway_commons_functional_Either__DomainObject_meta",
"ofType" : null
},
"isDeprecated" : false,
"deprecationReason" : null
- } ],
- "inputFields" : null,
- "interfaces" : [ ],
- "enumValues" : null,
- "possibleTypes" : null
- }, {
- "kind" : "OBJECT",
- "name" : "java_util_concurrent_Callable__DomainObject_meta",
- "description" : null,
- "fields" : [ {
- "name" : "id",
+ }, {
+ "name" : "left",
"description" : null,
"args" : [ ],
"type" : {
@@ -5178,7 +5094,7 @@
"isDeprecated" : false,
"deprecationReason" : null
}, {
- "name" : "logicalTypeName",
+ "name" : "right",
"description" : null,
"args" : [ ],
"type" : {
@@ -5192,22 +5108,13 @@
},
"isDeprecated" : false,
"deprecationReason" : null
- } ],
- "inputFields" : null,
- "interfaces" : [ ],
- "enumValues" : null,
- "possibleTypes" : null
- }, {
- "kind" : "OBJECT",
- "name" : "java_util_function_BiFunction",
- "description" : null,
- "fields" : [ {
- "name" : "_gql_meta",
+ }, {
+ "name" : "_gql_mutations",
"description" : null,
"args" : [ ],
"type" : {
"kind" : "OBJECT",
- "name" : "java_util_function_BiFunction__DomainObject_meta",
+ "name" : "org_apache_causeway_commons_functional_Either__DomainObject_mutators",
"ofType" : null
},
"isDeprecated" : false,
@@ -5219,7 +5126,7 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "java_util_function_BiFunction__DomainObject_meta",
+ "name" : "org_apache_causeway_commons_functional_Either__DomainObject_meta",
"description" : null,
"fields" : [ {
"name" : "id",
@@ -5258,15 +5165,148 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "java_util_function_Consumer",
+ "name" : "org_apache_causeway_commons_functional_Either__DomainObject_mutators",
"description" : null,
"fields" : [ {
- "name" : "_gql_meta",
+ "name" : "accept",
+ "description" : null,
+ "args" : [ {
+ "name" : "leftConsumer",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_Consumer",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ }, {
+ "name" : "rightConsumer",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_Consumer",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "left",
"description" : null,
"args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "map",
+ "description" : null,
+ "args" : [ {
+ "name" : "leftMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_Function",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ }, {
+ "name" : "rightMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_Function",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
"type" : {
"kind" : "OBJECT",
- "name" : "java_util_function_Consumer__DomainObject_meta",
+ "name" : "org_apache_causeway_commons_functional_Either",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mapLeft",
+ "description" : null,
+ "args" : [ {
+ "name" : "leftMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_Function",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Either",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mapRight",
+ "description" : null,
+ "args" : [ {
+ "name" : "rightMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_Function",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Either",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "right",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
"ofType" : null
},
"isDeprecated" : false,
@@ -5278,431 +5318,21 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "java_util_function_Consumer__DomainObject_meta",
+ "name" : "org_apache_causeway_commons_functional_Railway",
"description" : null,
"fields" : [ {
- "name" : "id",
+ "name" : "_gql_meta",
"description" : null,
"args" : [ ],
"type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "SCALAR",
- "name" : "String",
- "ofType" : null
- }
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Railway__DomainObject_meta",
+ "ofType" : null
},
"isDeprecated" : false,
"deprecationReason" : null
}, {
- "name" : "logicalTypeName",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "SCALAR",
- "name" : "String",
- "ofType" : null
- }
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- } ],
- "inputFields" : null,
- "interfaces" : [ ],
- "enumValues" : null,
- "possibleTypes" : null
- }, {
- "kind" : "OBJECT",
- "name" : "java_util_function_Function",
- "description" : null,
- "fields" : [ {
- "name" : "_gql_meta",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "OBJECT",
- "name" : "java_util_function_Function__DomainObject_meta",
- "ofType" : null
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- } ],
- "inputFields" : null,
- "interfaces" : [ ],
- "enumValues" : null,
- "possibleTypes" : null
- }, {
- "kind" : "OBJECT",
- "name" : "java_util_function_Function__DomainObject_meta",
- "description" : null,
- "fields" : [ {
- "name" : "id",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "SCALAR",
- "name" : "String",
- "ofType" : null
- }
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- }, {
- "name" : "logicalTypeName",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "SCALAR",
- "name" : "String",
- "ofType" : null
- }
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- } ],
- "inputFields" : null,
- "interfaces" : [ ],
- "enumValues" : null,
- "possibleTypes" : null
- }, {
- "kind" : "OBJECT",
- "name" : "java_util_stream_Stream",
- "description" : null,
- "fields" : [ {
- "name" : "_gql_meta",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "OBJECT",
- "name" : "java_util_stream_Stream__DomainObject_meta",
- "ofType" : null
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- } ],
- "inputFields" : null,
- "interfaces" : [ ],
- "enumValues" : null,
- "possibleTypes" : null
- }, {
- "kind" : "OBJECT",
- "name" : "java_util_stream_Stream__DomainObject_meta",
- "description" : null,
- "fields" : [ {
- "name" : "id",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "SCALAR",
- "name" : "String",
- "ofType" : null
- }
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- }, {
- "name" : "logicalTypeName",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "SCALAR",
- "name" : "String",
- "ofType" : null
- }
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- } ],
- "inputFields" : null,
- "interfaces" : [ ],
- "enumValues" : null,
- "possibleTypes" : null
- }, {
- "kind" : "OBJECT",
- "name" : "org_apache_causeway_commons_functional_Either",
- "description" : null,
- "fields" : [ {
- "name" : "_gql_meta",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "OBJECT",
- "name" : "org_apache_causeway_commons_functional_Either__DomainObject_meta",
- "ofType" : null
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- }, {
- "name" : "left",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "SCALAR",
- "name" : "String",
- "ofType" : null
- }
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- }, {
- "name" : "right",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "SCALAR",
- "name" : "String",
- "ofType" : null
- }
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- }, {
- "name" : "_gql_mutations",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "OBJECT",
- "name" : "org_apache_causeway_commons_functional_Either__DomainObject_mutators",
- "ofType" : null
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- } ],
- "inputFields" : null,
- "interfaces" : [ ],
- "enumValues" : null,
- "possibleTypes" : null
- }, {
- "kind" : "OBJECT",
- "name" : "org_apache_causeway_commons_functional_Either__DomainObject_meta",
- "description" : null,
- "fields" : [ {
- "name" : "id",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "SCALAR",
- "name" : "String",
- "ofType" : null
- }
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- }, {
- "name" : "logicalTypeName",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "SCALAR",
- "name" : "String",
- "ofType" : null
- }
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- } ],
- "inputFields" : null,
- "interfaces" : [ ],
- "enumValues" : null,
- "possibleTypes" : null
- }, {
- "kind" : "OBJECT",
- "name" : "org_apache_causeway_commons_functional_Either__DomainObject_mutators",
- "description" : null,
- "fields" : [ {
- "name" : "accept",
- "description" : null,
- "args" : [ {
- "name" : "leftConsumer",
- "description" : null,
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "INPUT_OBJECT",
- "name" : "_gql_input__java_util_function_Consumer",
- "ofType" : null
- }
- },
- "defaultValue" : null
- }, {
- "name" : "rightConsumer",
- "description" : null,
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "INPUT_OBJECT",
- "name" : "_gql_input__java_util_function_Consumer",
- "ofType" : null
- }
- },
- "defaultValue" : null
- } ],
- "type" : {
- "kind" : "SCALAR",
- "name" : "String",
- "ofType" : null
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- }, {
- "name" : "left",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "SCALAR",
- "name" : "String",
- "ofType" : null
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- }, {
- "name" : "map",
- "description" : null,
- "args" : [ {
- "name" : "leftMapper",
- "description" : null,
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "INPUT_OBJECT",
- "name" : "_gql_input__java_util_function_Function",
- "ofType" : null
- }
- },
- "defaultValue" : null
- }, {
- "name" : "rightMapper",
- "description" : null,
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "INPUT_OBJECT",
- "name" : "_gql_input__java_util_function_Function",
- "ofType" : null
- }
- },
- "defaultValue" : null
- } ],
- "type" : {
- "kind" : "OBJECT",
- "name" : "org_apache_causeway_commons_functional_Either",
- "ofType" : null
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- }, {
- "name" : "mapLeft",
- "description" : null,
- "args" : [ {
- "name" : "leftMapper",
- "description" : null,
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "INPUT_OBJECT",
- "name" : "_gql_input__java_util_function_Function",
- "ofType" : null
- }
- },
- "defaultValue" : null
- } ],
- "type" : {
- "kind" : "OBJECT",
- "name" : "org_apache_causeway_commons_functional_Either",
- "ofType" : null
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- }, {
- "name" : "mapRight",
- "description" : null,
- "args" : [ {
- "name" : "rightMapper",
- "description" : null,
- "type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "INPUT_OBJECT",
- "name" : "_gql_input__java_util_function_Function",
- "ofType" : null
- }
- },
- "defaultValue" : null
- } ],
- "type" : {
- "kind" : "OBJECT",
- "name" : "org_apache_causeway_commons_functional_Either",
- "ofType" : null
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- }, {
- "name" : "right",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "SCALAR",
- "name" : "String",
- "ofType" : null
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- } ],
- "inputFields" : null,
- "interfaces" : [ ],
- "enumValues" : null,
- "possibleTypes" : null
- }, {
- "kind" : "OBJECT",
- "name" : "org_apache_causeway_commons_functional_Railway",
- "description" : null,
- "fields" : [ {
- "name" : "_gql_meta",
- "description" : null,
- "args" : [ ],
- "type" : {
- "kind" : "OBJECT",
- "name" : "org_apache_causeway_commons_functional_Railway__DomainObject_meta",
- "ofType" : null
- },
- "isDeprecated" : false,
- "deprecationReason" : null
- }, {
- "name" : "failure",
+ "name" : "failure",
"description" : null,
"args" : [ ],
"type" : {
@@ -6913,7 +6543,107 @@
"args" : [ ],
"type" : {
"kind" : "OBJECT",
- "name" : "org_apache_causeway_core_metamodel_inspect_model_MMNode__DomainObject_meta",
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MMNode__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MMNode__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "parentNode",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_TypeNode",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mixedIn",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "_gql_mutations",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_mutators",
"ofType" : null
},
"isDeprecated" : false,
@@ -6925,7 +6655,7 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "org_apache_causeway_core_metamodel_inspect_model_MMNode__DomainObject_meta",
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_meta",
"description" : null,
"fields" : [ {
"name" : "id",
@@ -6964,36 +6694,41 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode",
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_mutators",
"description" : null,
"fields" : [ {
- "name" : "_gql_meta",
+ "name" : "streamChildNodes",
"description" : null,
"args" : [ ],
"type" : {
"kind" : "OBJECT",
- "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_meta",
+ "name" : "java_util_stream_Stream",
"ofType" : null
},
"isDeprecated" : false,
"deprecationReason" : null
- }, {
- "name" : "parentNode",
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
"description" : null,
"args" : [ ],
"type" : {
- "kind" : "NON_NULL",
- "name" : null,
- "ofType" : {
- "kind" : "OBJECT",
- "name" : "causeway_applib_TypeNode",
- "ofType" : null
- }
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__DomainObject_meta",
+ "ofType" : null
},
"isDeprecated" : false,
"deprecationReason" : null
}, {
- "name" : "mixedIn",
+ "name" : "friendlyName",
"description" : null,
"args" : [ ],
"type" : {
@@ -7008,13 +6743,17 @@
"isDeprecated" : false,
"deprecationReason" : null
}, {
- "name" : "_gql_mutations",
+ "name" : "qualifiedName",
"description" : null,
"args" : [ ],
"type" : {
- "kind" : "OBJECT",
- "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_mutators",
- "ofType" : null
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
},
"isDeprecated" : false,
"deprecationReason" : null
@@ -7025,7 +6764,7 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_meta",
+ "name" : "org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__DomainObject_meta",
"description" : null,
"fields" : [ {
"name" : "id",
@@ -7064,41 +6803,32 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_mutators",
+ "name" : "university_dept_Department",
"description" : null,
"fields" : [ {
- "name" : "streamChildNodes",
+ "name" : "_gql_meta",
"description" : null,
"args" : [ ],
"type" : {
"kind" : "OBJECT",
- "name" : "java_util_stream_Stream",
+ "name" : "university_dept_Department__DomainObject_meta",
"ofType" : null
},
"isDeprecated" : false,
"deprecationReason" : null
- } ],
- "inputFields" : null,
- "interfaces" : [ ],
- "enumValues" : null,
- "possibleTypes" : null
- }, {
- "kind" : "OBJECT",
- "name" : "org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript",
- "description" : null,
- "fields" : [ {
- "name" : "_gql_meta",
+ }, {
+ "name" : "deptHead",
"description" : null,
"args" : [ ],
"type" : {
"kind" : "OBJECT",
- "name" : "org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__DomainObject_meta",
+ "name" : "university_dept_DeptHead",
"ofType" : null
},
"isDeprecated" : false,
"deprecationReason" : null
}, {
- "name" : "friendlyName",
+ "name" : "name",
"description" : null,
"args" : [ ],
"type" : {
@@ -7112,16 +6842,54 @@
},
"isDeprecated" : false,
"deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "university_dept_DepartmentMenu",
+ "description" : null,
+ "fields" : [ {
+ "name" : "createDepartment",
+ "description" : null,
+ "args" : [ {
+ "name" : "name",
+ "description" : null,
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "defaultValue" : null
+ }, {
+ "name" : "deptHead",
+ "description" : null,
+ "type" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__university_dept_DeptHead",
+ "ofType" : null
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "university_dept_Department",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
}, {
- "name" : "qualifiedName",
+ "name" : "findAllDepartments",
"description" : null,
"args" : [ ],
"type" : {
- "kind" : "NON_NULL",
+ "kind" : "LIST",
"name" : null,
"ofType" : {
- "kind" : "SCALAR",
- "name" : "String",
+ "kind" : "OBJECT",
+ "name" : "university_dept_Department",
"ofType" : null
}
},
@@ -7134,7 +6902,7 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__DomainObject_meta",
+ "name" : "university_dept_Department__DomainObject_meta",
"description" : null,
"fields" : [ {
"name" : "id",
@@ -7166,6 +6934,17 @@
},
"isDeprecated" : false,
"deprecationReason" : null
+ }, {
+ "name" : "version",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
} ],
"inputFields" : null,
"interfaces" : [ ],
@@ -7173,7 +6952,7 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "org_apache_causeway_viewer_graphql_viewer_test_domain_WithName",
+ "name" : "university_dept_DeptHead",
"description" : null,
"fields" : [ {
"name" : "_gql_meta",
@@ -7181,7 +6960,18 @@
"args" : [ ],
"type" : {
"kind" : "OBJECT",
- "name" : "org_apache_causeway_viewer_graphql_viewer_test_domain_WithName__DomainObject_meta",
+ "name" : "university_dept_DeptHead__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "department",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "university_dept_Department",
"ofType" : null
},
"isDeprecated" : false,
@@ -7191,13 +6981,64 @@
"description" : null,
"args" : [ ],
"type" : {
- "kind" : "NON_NULL",
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "_gql_mutations",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "university_dept_DeptHead__DomainObject_mutators",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "university_dept_DeptHeadMenu",
+ "description" : null,
+ "fields" : [ {
+ "name" : "findAllDeptHeads",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "LIST",
"name" : null,
"ofType" : {
+ "kind" : "OBJECT",
+ "name" : "university_dept_DeptHead",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "findDeptHeadByName",
+ "description" : null,
+ "args" : [ {
+ "name" : "name",
+ "description" : null,
+ "type" : {
"kind" : "SCALAR",
"name" : "String",
"ofType" : null
- }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "university_dept_DeptHead",
+ "ofType" : null
},
"isDeprecated" : false,
"deprecationReason" : null
@@ -7208,7 +7049,7 @@
"possibleTypes" : null
}, {
"kind" : "OBJECT",
- "name" : "org_apache_causeway_viewer_graphql_viewer_test_domain_WithName__DomainObject_meta",
+ "name" : "university_dept_DeptHead__DomainObject_meta",
"description" : null,
"fields" : [ {
"name" : "id",
@@ -7240,6 +7081,74 @@
},
"isDeprecated" : false,
"deprecationReason" : null
+ }, {
+ "name" : "version",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "university_dept_DeptHead__DomainObject_mutators",
+ "description" : null,
+ "fields" : [ {
+ "name" : "changeDepartment",
+ "description" : null,
+ "args" : [ {
+ "name" : "department",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__university_dept_Department",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "university_dept_DeptHead",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "changeName",
+ "description" : null,
+ "args" : [ {
+ "name" : "newName",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "university_dept_DeptHead",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
} ],
"inputFields" : null,
"interfaces" : [ ],
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema_types_name.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema_types_name.approved.json
index fd14945df3..ca37cd5bb3 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema_types_name.approved.json
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema_types_name.approved.json
@@ -73,10 +73,6 @@
"name" : "_gql_input__causeway_security_LoginRedirect"
}, {
"name" : "_gql_input__causeway_testing_fixtures_FixtureResult"
- }, {
- "name" : "_gql_input__gql_test_domain_Department"
- }, {
- "name" : "_gql_input__gql_test_domain_DeptHead"
}, {
"name" : "_gql_input__java_lang_Runnable"
}, {
@@ -112,7 +108,9 @@
}, {
"name" : "_gql_input__org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript"
}, {
- "name" : "_gql_input__org_apache_causeway_viewer_graphql_viewer_test_domain_WithName"
+ "name" : "_gql_input__university_dept_Department"
+ }, {
+ "name" : "_gql_input__university_dept_DeptHead"
}, {
"name" : "causeway_applib_DomainObjectList"
}, {
@@ -217,18 +215,6 @@
"name" : "causeway_testing_fixtures_FixtureResult"
}, {
"name" : "causeway_testing_fixtures_FixtureResult__DomainObject_meta"
- }, {
- "name" : "gql_test_domain_Department"
- }, {
- "name" : "gql_test_domain_Department__DomainObject_meta"
- }, {
- "name" : "gql_test_domain_DeptHead"
- }, {
- "name" : "gql_test_domain_DeptHead__DomainObject_meta"
- }, {
- "name" : "gql_test_domain_DeptHead__DomainObject_mutators"
- }, {
- "name" : "gql_test_domain_TopLevelMenu"
}, {
"name" : "java_lang_Runnable"
}, {
@@ -312,9 +298,19 @@
}, {
"name" : "org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__DomainObject_meta"
}, {
- "name" : "org_apache_causeway_viewer_graphql_viewer_test_domain_WithName"
+ "name" : "university_dept_Department"
+ }, {
+ "name" : "university_dept_DepartmentMenu"
+ }, {
+ "name" : "university_dept_Department__DomainObject_meta"
+ }, {
+ "name" : "university_dept_DeptHead"
+ }, {
+ "name" : "university_dept_DeptHeadMenu"
+ }, {
+ "name" : "university_dept_DeptHead__DomainObject_meta"
}, {
- "name" : "org_apache_causeway_viewer_graphql_viewer_test_domain_WithName__DomainObject_meta"
+ "name" : "university_dept_DeptHead__DomainObject_mutators"
} ]
}
}
diff --git a/incubator/viewers/graphql/test/src/test/resources/schema.gql b/incubator/viewers/graphql/test/src/test/resources/schema.gql
index 06fd0676ee..3e029c4ddd 100644
--- a/incubator/viewers/graphql/test/src/test/resources/schema.gql
+++ b/incubator/viewers/graphql/test/src/test/resources/schema.gql
@@ -26,8 +26,9 @@ type Query {
causeway_applib_UserMenu: causeway_applib_UserMenu
causeway_conf_ConfigurationMenu: causeway_conf_ConfigurationMenu
causeway_security_LogoutMenu: causeway_security_LogoutMenu
- gql_test_domain_TopLevelMenu: gql_test_domain_TopLevelMenu
numServices: Int
+ university_dept_DepartmentMenu: university_dept_DepartmentMenu
+ university_dept_DeptHeadMenu: university_dept_DeptHeadMenu
}
type causeway_applib_DomainObjectList {
@@ -348,44 +349,6 @@ type causeway_testing_fixtures_FixtureResult__DomainObject_meta {
logicalTypeName: String!
}
-type gql_test_domain_Department {
- _gql_meta: gql_test_domain_Department__DomainObject_meta
- deptHead: gql_test_domain_DeptHead
- name: String!
-}
-
-type gql_test_domain_Department__DomainObject_meta {
- id: String!
- logicalTypeName: String!
- version: String
-}
-
-type gql_test_domain_DeptHead {
- _gql_meta: gql_test_domain_DeptHead__DomainObject_meta
- _gql_mutations: gql_test_domain_DeptHead__DomainObject_mutators
- department: gql_test_domain_Department
- name: String
-}
-
-type gql_test_domain_DeptHead__DomainObject_meta {
- id: String!
- logicalTypeName: String!
- version: String
-}
-
-type gql_test_domain_DeptHead__DomainObject_mutators {
- changeDepartment(department: _gql_input__gql_test_domain_Department!): gql_test_domain_DeptHead
- changeName(newName: String!): gql_test_domain_DeptHead
-}
-
-type gql_test_domain_TopLevelMenu {
- createDepartment(deptHead: _gql_input__gql_test_domain_DeptHead, name: String): gql_test_domain_Department
- findAllDepartments: [gql_test_domain_Department]
- findAllDeptHeads: [gql_test_domain_DeptHead]
- findAllEntitiesWithName: [org_apache_causeway_viewer_graphql_viewer_test_domain_WithName]
- findDeptHeadByName(name: String): gql_test_domain_DeptHead
-}
-
type java_lang_Runnable {
_gql_meta: java_lang_Runnable__DomainObject_meta
}
@@ -619,14 +582,44 @@ type org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__D
logicalTypeName: String!
}
-type org_apache_causeway_viewer_graphql_viewer_test_domain_WithName {
- _gql_meta: org_apache_causeway_viewer_graphql_viewer_test_domain_WithName__DomainObject_meta
+type university_dept_Department {
+ _gql_meta: university_dept_Department__DomainObject_meta
+ deptHead: university_dept_DeptHead
name: String!
}
-type org_apache_causeway_viewer_graphql_viewer_test_domain_WithName__DomainObject_meta {
+type university_dept_DepartmentMenu {
+ createDepartment(deptHead: _gql_input__university_dept_DeptHead, name: String): university_dept_Department
+ findAllDepartments: [university_dept_Department]
+}
+
+type university_dept_Department__DomainObject_meta {
id: String!
logicalTypeName: String!
+ version: String
+}
+
+type university_dept_DeptHead {
+ _gql_meta: university_dept_DeptHead__DomainObject_meta
+ _gql_mutations: university_dept_DeptHead__DomainObject_mutators
+ department: university_dept_Department
+ name: String
+}
+
+type university_dept_DeptHeadMenu {
+ findAllDeptHeads: [university_dept_DeptHead]
+ findDeptHeadByName(name: String): university_dept_DeptHead
+}
+
+type university_dept_DeptHead__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+ version: String
+}
+
+type university_dept_DeptHead__DomainObject_mutators {
+ changeDepartment(department: _gql_input__university_dept_Department!): university_dept_DeptHead
+ changeName(newName: String!): university_dept_DeptHead
}
input _gql_input__causeway_applib_DomainObjectList {
@@ -721,14 +714,6 @@ input _gql_input__causeway_testing_fixtures_FixtureResult {
id: ID!
}
-input _gql_input__gql_test_domain_Department {
- id: ID!
-}
-
-input _gql_input__gql_test_domain_DeptHead {
- id: ID!
-}
-
input _gql_input__java_lang_Runnable {
id: ID!
}
@@ -797,6 +782,10 @@ input _gql_input__org_apache_causeway_testing_fixtures_applib_fixturescripts_Fix
id: ID!
}
-input _gql_input__org_apache_causeway_viewer_graphql_viewer_test_domain_WithName {
+input _gql_input__university_dept_Department {
+ id: ID!
+}
+
+input _gql_input__university_dept_DeptHead {
id: ID!
}
(causeway) 01/23: CAUSEWAY-3676 : wip
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit 9f75dc565e58a5e326ac37b5f899ea7f24c5d1b8
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Tue Jan 16 18:32:37 2024 +0000
CAUSEWAY-3676 : wip
---
incubator/viewers/graphql/test/pom.xml | 36 +-
...yViewerGraphqlTestModuleIntegTestAbstract.java} | 22 +-
...=> EndToEnd_IntegTest.changeName.approved.json} | 0
...l => EndToEnd_IntegTest.createE1.approved.json} | 0
... => EndToEnd_IntegTest.findAllE1.approved.json} | 0
.../viewer/test/source/EndToEnd_IntegTest.java | 25 +-
...nd_IntegTest.simple_post_request.approved.json} | 0
.../viewer/test/source/GQLSchema_IntegTest.java | 53 +-
.../source/GQLSchema_IntegTest.schema.approved.gql | 806 +++++++++++++++++++++
.../viewer/test/source/gqltestdomain/E2.java | 3 +-
.../test/source/introspection-query-request.gql | 99 +++
11 files changed, 1029 insertions(+), 15 deletions(-)
diff --git a/incubator/viewers/graphql/test/pom.xml b/incubator/viewers/graphql/test/pom.xml
index edb1462b46..c9a13bf825 100644
--- a/incubator/viewers/graphql/test/pom.xml
+++ b/incubator/viewers/graphql/test/pom.xml
@@ -37,15 +37,28 @@
<git-plugin.propertiesDir>org/apache/causeway/incubator/viewer/graphql/test</git-plugin.propertiesDir>
<maven.install.skip>true</maven.install.skip>
<maven.deploy.skip>true</maven.deploy.skip>
+
+ <java.version>17</java.version>
</properties>
- <build>
+ <build>
<testResources>
<testResource>
<directory>src/test/java</directory>
<filtering>false</filtering>
</testResource>
</testResources>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <version>3.11.0</version>
+ <configuration>
+ <source>${java.version}</source>
+ <target>${java.version}</target>
+ </configuration>
+ </plugin>
+ </plugins>
</build>
<dependencies>
@@ -76,6 +89,12 @@
<artifactId>causeway-testing-fixtures-applib</artifactId>
<scope>test</scope>
</dependency>
+ <dependency>
+ <groupId>org.apache.causeway.testing</groupId>
+ <artifactId>causeway-testing-integtestsupport-applib</artifactId>
+ <scope>test</scope>
+ </dependency>
+
<dependency>
<groupId>com.h2database</groupId>
<artifactId>h2</artifactId>
@@ -97,8 +116,21 @@
</exclusion>
</exclusions>
</dependency>
+ <dependency>
+ <groupId>org.springframework.boot</groupId>
+ <artifactId>spring-boot-test-autoconfigure</artifactId>
+ <scope>test</scope>
+ </dependency>
+
+
+ <dependency>
+ <groupId>org.springframework.graphql</groupId>
+ <artifactId>spring-graphql-test</artifactId>
+ <version>1.2.4</version>
+ <scope>test</scope>
+ </dependency>
- </dependencies>
+ </dependencies>
</project>
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/TestDomainModuleIntegTestAbstract.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
similarity index 77%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/TestDomainModuleIntegTestAbstract.java
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
index 4fa5dbe48b..60c29aa2fb 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/TestDomainModuleIntegTestAbstract.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
@@ -18,15 +18,22 @@
*/
package org.apache.causeway.viewer.graphql.viewer.test.source;
+import org.junit.jupiter.api.MethodOrderer;
+import org.junit.jupiter.api.TestInstance;
+import org.junit.jupiter.api.TestMethodOrder;
+
import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
+import org.springframework.boot.test.autoconfigure.graphql.tester.AutoConfigureHttpGraphQlTester;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.boot.test.web.server.LocalServerPort;
import org.springframework.context.annotation.Import;
import org.springframework.context.annotation.PropertySource;
import org.springframework.context.annotation.PropertySources;
import org.springframework.data.jpa.repository.config.EnableJpaRepositories;
+import org.springframework.graphql.test.tester.HttpGraphQlTester;
import org.springframework.test.context.ActiveProfiles;
+import org.springframework.test.web.reactive.server.WebTestClient;
import org.apache.causeway.core.config.presets.CausewayPresets;
import org.apache.causeway.core.runtimeservices.CausewayModuleCoreRuntimeServices;
@@ -38,12 +45,15 @@ import org.apache.causeway.viewer.graphql.viewer.test.source.gqltestdomain.TestD
@SpringBootTest(
classes = {
- TestDomainModuleIntegTestAbstract.TestApp.class
+ CausewayViewerGraphqlTestModuleIntegTestAbstract.TestApp.class
},
webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT
)
+@AutoConfigureHttpGraphQlTester
+@TestInstance(TestInstance.Lifecycle.PER_CLASS)
+@TestMethodOrder(MethodOrderer.OrderAnnotation.class)
@ActiveProfiles("test")
-public class TestDomainModuleIntegTestAbstract {
+public class CausewayViewerGraphqlTestModuleIntegTestAbstract {
/**
* Compared to the production app manifest <code>domainapp.webapp.AppManifest</code>,
@@ -75,5 +85,13 @@ public class TestDomainModuleIntegTestAbstract {
@LocalServerPort
protected int port;
+ protected HttpGraphQlTester graphQlTester() {
+ WebTestClient client =
+ WebTestClient.bindToServer()
+ .baseUrl("http://0.0.0.0:" + port + "/graphql")
+ .build();
+ return HttpGraphQlTester.create(client);
+ }
+
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.changeName.approved.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.changeName.approved.json
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.changeName.approved.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.changeName.approved.json
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.createE1.approved.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.createE1.approved.json
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.createE1.approved.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.createE1.approved.json
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.findAllE1.approved.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.findAllE1.approved.json
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.findAllE1.approved.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.findAllE1.approved.json
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.java
index c1f44d58a2..26bef80b25 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.java
@@ -34,6 +34,8 @@ import javax.inject.Inject;
import com.fasterxml.jackson.databind.ObjectMapper;
+import org.apache.causeway.viewer.graphql.viewer.source.GraphQlServiceForCauseway;
+
import org.approvaltests.Approvals;
import org.approvaltests.core.Options;
import org.approvaltests.core.Scrubber;
@@ -45,6 +47,7 @@ import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.TestInfo;
import org.junit.jupiter.api.condition.DisabledIfSystemProperty;
+
import org.springframework.test.context.ActiveProfiles;
import org.springframework.transaction.annotation.Propagation;
@@ -69,12 +72,13 @@ import lombok.val;
//@Transactional NOT USING @Transactional since we are running server within same transaction otherwise
@ActiveProfiles("test")
-public class EndToEnd_IntegTest extends TestDomainModuleIntegTestAbstract {
+public class EndToEnd_IntegTest extends CausewayViewerGraphqlTestModuleIntegTestAbstract {
@Inject TransactionService transactionService;
@Inject CausewaySystemEnvironment causewaySystemEnvironment;
@Inject SpecificationLoader specificationLoader;
@Inject GraphQlSourceForCauseway graphQlSourceForCauseway;
+ @Inject GraphQlServiceForCauseway graphQlServiceForCauseway;
@Inject TestEntityRepository testEntityRepository;
@Inject GQLTestDomainMenu gqlTestDomainMenu;
@@ -103,12 +107,31 @@ public class EndToEnd_IntegTest extends TestDomainModuleIntegTestAbstract {
HttpClient client = HttpClient.newBuilder().build();
URI uri = URI.create("http://0.0.0.0:" + port + "/graphql/schema");
+
HttpRequest request = HttpRequest.newBuilder().uri(uri).GET().build();
File targetFile1 = new File("src/test/resources/testfiles/schema.gql");
HttpResponse<Path> response = client.send(request, HttpResponse.BodyHandlers.ofFile(targetFile1.toPath()));
}
+ @Test
+ void introspectionQuery() throws Exception {
+
+ HttpClient client = HttpClient.newBuilder().build();
+
+ URI uri = URI.create(String.format("http://0.0.0.0:%d/graphql", port));
+
+ String s = readResource("introspection-query-request.gql");
+// HttpRequest request = HttpRequest.newBuilder().uri(uri).POST(HttpRequest.BodyPublishers.ofString(s)).build();
+//
+// HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
+// String body = response.body();
+
+ //graphQlTester().documentName()
+
+
+ }
+
//TODO started to fail on 2022-04-22, with missing
//"name" : "_gql_input__org_apache_causeway_applib_services_inject_ServiceInjector"
//disabled to rescue CI build
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.simple_post_request.approved.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.simple_post_request.approved.json
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.simple_post_request.approved.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.simple_post_request.approved.json
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/GQLSchema_IntegTest.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/GQLSchema_IntegTest.java
index c49a74b826..35c63ef439 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/GQLSchema_IntegTest.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/GQLSchema_IntegTest.java
@@ -19,9 +19,17 @@
package org.apache.causeway.viewer.graphql.viewer.test.source;
import java.util.List;
+import java.util.stream.Collectors;
import javax.inject.Inject;
+import org.apache.causeway.commons.internal.base._Strings;
+import org.apache.causeway.commons.io.TextUtils;
+
+import org.approvaltests.Approvals;
+import org.approvaltests.core.Options;
+import org.approvaltests.reporters.DiffReporter;
+import org.approvaltests.reporters.UseReporter;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
@@ -54,18 +62,14 @@ import graphql.schema.GraphQLSchema;
import graphql.schema.GraphQLSchemaElement;
import graphql.schema.GraphQLType;
import graphql.schema.GraphQLTypeReference;
+import graphql.schema.idl.SchemaPrinter;
@Transactional
-public class GQLSchema_IntegTest extends TestDomainModuleIntegTestAbstract{
-
- @Inject
- private CausewaySystemEnvironment causewaySystemEnvironment;
-
- @Inject
- private SpecificationLoader specificationLoader;
+public class GQLSchema_IntegTest extends CausewayViewerGraphqlTestModuleIntegTestAbstract {
- @Inject
- private GraphQlSourceForCauseway graphQlSourceForCauseway;
+ @Inject private CausewaySystemEnvironment causewaySystemEnvironment;
+ @Inject private SpecificationLoader specificationLoader;
+ @Inject private GraphQlSourceForCauseway graphQlSourceForCauseway;
@BeforeEach
void beforeEach() {
@@ -74,6 +78,35 @@ public class GQLSchema_IntegTest extends TestDomainModuleIntegTestAbstract{
assertNotNull(graphQlSourceForCauseway);
}
+ @Test
+ @UseReporter(DiffReporter.class)
+ void schema() {
+
+ GraphQLSchema x;
+
+ GraphQL graphQL = graphQlSourceForCauseway.graphQl();
+ GraphQLSchema graphQLSchema = graphQL.getGraphQLSchema();
+
+ SchemaPrinter printer = new SchemaPrinter();
+
+ // Print schema
+ String schemaDefinition = printer.print(graphQLSchema);
+
+ Approvals.verify(schemaDefinition, gqlSchemaOptions());
+ }
+
+ private Options gqlSchemaOptions() {
+ return new Options()
+ .withScrubber(this::unixLineEndings)
+ .forFile().withExtension(".gql");
+ }
+
+ private String unixLineEndings(final String input) {
+ return TextUtils.streamLines(input)
+ .collect(Collectors.joining("\n"));
+ }
+
+
@Test
@Disabled
void assert_stuff_works() {
@@ -98,6 +131,8 @@ public class GQLSchema_IntegTest extends TestDomainModuleIntegTestAbstract{
GraphQL graphQL = graphQlSourceForCauseway.graphQl();
GraphQLSchema graphQLSchema = graphQL.getGraphQLSchema();
+
+
// List<GraphQLNamedType> allTypesAsList = graphQLSchema.getAllTypesAsList();
// allTypesAsList.forEach(t->{
// System.out.println(t.getName());
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/GQLSchema_IntegTest.schema.approved.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/GQLSchema_IntegTest.schema.approved.gql
new file mode 100644
index 0000000000..5b095b0170
--- /dev/null
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/GQLSchema_IntegTest.schema.approved.gql
@@ -0,0 +1,806 @@
+"Marks the field, argument, input field or enum value as deprecated"
+directive @deprecated(
+ "The reason for the deprecation"
+ reason: String = "No longer supported"
+ ) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
+
+"Directs the executor to include this field or fragment only when the `if` argument is true"
+directive @include(
+ "Included when true."
+ if: Boolean!
+ ) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT
+
+"Directs the executor to skip this field or fragment when the `if` argument is true."
+directive @skip(
+ "Skipped when true."
+ if: Boolean!
+ ) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT
+
+"Exposes a URL that specifies the behaviour of this scalar."
+directive @specifiedBy(
+ "The URL that specifies the behaviour of this scalar."
+ url: String!
+ ) on SCALAR
+
+type Query {
+ causeway_applib_UserMenu: causeway_applib_UserMenu
+ causeway_conf_ConfigurationMenu: causeway_conf_ConfigurationMenu
+ causeway_security_LogoutMenu: causeway_security_LogoutMenu
+ gqltestdomain_GQLTestDomainMenu: gqltestdomain_GQLTestDomainMenu
+ numServices: Int
+}
+
+type causeway_applib_DomainObjectList {
+ _gql_meta: causeway_applib_DomainObjectList__DomainObject_meta
+ actionArguments: String
+ actionId: String
+ actionOwningFqcn: String
+ elementTypeFqcn: String!
+ title: String!
+}
+
+type causeway_applib_DomainObjectList__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_applib_FacetGroupNode {
+ _gql_meta: causeway_applib_FacetGroupNode__DomainObject_meta
+ facets: String!
+}
+
+type causeway_applib_FacetGroupNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_applib_ParameterNode {
+ _gql_meta: causeway_applib_ParameterNode__DomainObject_meta
+ parameter: String!
+ parentNode: causeway_applib_node_ActionNode!
+}
+
+type causeway_applib_ParameterNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_applib_PropertyNode {
+ _gql_meta: causeway_applib_PropertyNode__DomainObject_meta
+ _gql_mutations: causeway_applib_PropertyNode__DomainObject_mutators
+ mixedIn: String!
+ parentNode: causeway_applib_TypeNode!
+ property: String!
+}
+
+type causeway_applib_PropertyNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_applib_PropertyNode__DomainObject_mutators {
+ streamChildNodes: java_util_stream_Stream
+}
+
+type causeway_applib_RoleMemento {
+ _gql_meta: causeway_applib_RoleMemento__DomainObject_meta
+ description: String!
+ name: String!
+}
+
+type causeway_applib_RoleMemento__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_applib_TypeNode {
+ _gql_meta: causeway_applib_TypeNode__DomainObject_meta
+ domainClassDto: causeway_schema_metamodel_v2_DomainClassDto!
+}
+
+type causeway_applib_TypeNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_applib_UserMemento {
+ _gql_meta: causeway_applib_UserMemento__DomainObject_meta
+ authenticationCode: String!
+ authenticationSource: String!
+ avatarUrl: String
+ impersonating: String!
+ languageLocale: String
+ multiTenancyToken: String
+ name: String!
+ numberFormatLocale: String
+ realName: String
+ roles: [causeway_applib_RoleMemento]
+ timeFormatLocale: String
+}
+
+type causeway_applib_UserMemento__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_applib_UserMenu {
+ me: causeway_applib_UserMemento
+}
+
+type causeway_applib_node_ActionNode {
+ _gql_meta: causeway_applib_node_ActionNode__DomainObject_meta
+ _gql_mutations: causeway_applib_node_ActionNode__DomainObject_mutators
+ action: String!
+ mixedIn: String!
+ parentNode: causeway_applib_TypeNode!
+}
+
+type causeway_applib_node_ActionNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_applib_node_ActionNode__DomainObject_mutators {
+ streamChildNodes: java_util_stream_Stream
+}
+
+type causeway_applib_node_CollectionNode {
+ _gql_meta: causeway_applib_node_CollectionNode__DomainObject_meta
+ _gql_mutations: causeway_applib_node_CollectionNode__DomainObject_mutators
+ collection: String!
+ mixedIn: String!
+ parentNode: causeway_applib_TypeNode!
+}
+
+type causeway_applib_node_CollectionNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_applib_node_CollectionNode__DomainObject_mutators {
+ streamChildNodes: java_util_stream_Stream
+}
+
+type causeway_applib_node_FacetAttrNode {
+ _gql_meta: causeway_applib_node_FacetAttrNode__DomainObject_meta
+ facetAttr: String!
+ parentNode: causeway_applib_node_FacetNode!
+}
+
+type causeway_applib_node_FacetAttrNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_applib_node_FacetNode {
+ _gql_meta: causeway_applib_node_FacetNode__DomainObject_meta
+ facet: String!
+ shadowed: String!
+}
+
+type causeway_applib_node_FacetNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_conf_ConfigurationMenu {
+ configuration: causeway_conf_ConfigurationViewmodel
+}
+
+type causeway_conf_ConfigurationProperty {
+ _gql_meta: causeway_conf_ConfigurationProperty__DomainObject_meta
+ key: String!
+ value: String!
+}
+
+type causeway_conf_ConfigurationProperty__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_conf_ConfigurationViewmodel {
+ _gql_meta: causeway_conf_ConfigurationViewmodel__DomainObject_meta
+ environment: [causeway_conf_ConfigurationProperty]
+ primary: [causeway_conf_ConfigurationProperty]
+ secondary: [causeway_conf_ConfigurationProperty]
+}
+
+type causeway_conf_ConfigurationViewmodel__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_feat_ApplicationFeatureViewModel {
+ _gql_meta: causeway_feat_ApplicationFeatureViewModel__DomainObject_meta
+ memberName: String!
+ namespaceName: String!
+ typeSimpleName: String!
+}
+
+type causeway_feat_ApplicationFeatureViewModel__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_feat_ApplicationNamespace {
+ _gql_meta: causeway_feat_ApplicationNamespace__DomainObject_meta
+ memberName: String!
+ namespaceName: String!
+ typeSimpleName: String!
+}
+
+type causeway_feat_ApplicationNamespace__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_feat_ApplicationType {
+ _gql_meta: causeway_feat_ApplicationType__DomainObject_meta
+ actions: [causeway_feat_ApplicationTypeAction]
+ collections: [causeway_feat_ApplicationTypeCollection]
+ memberName: String!
+ namespaceName: String!
+ properties: [causeway_feat_ApplicationTypeProperty]
+ typeSimpleName: String!
+}
+
+type causeway_feat_ApplicationTypeAction {
+ _gql_meta: causeway_feat_ApplicationTypeAction__DomainObject_meta
+ actionSemantics: String!
+ memberName: String!
+ namespaceName: String!
+ returnType: String!
+ typeSimpleName: String!
+}
+
+type causeway_feat_ApplicationTypeAction__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_feat_ApplicationTypeCollection {
+ _gql_meta: causeway_feat_ApplicationTypeCollection__DomainObject_meta
+ derived: String!
+ elementType: String!
+ memberName: String!
+ namespaceName: String!
+ typeSimpleName: String!
+}
+
+type causeway_feat_ApplicationTypeCollection__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_feat_ApplicationTypeMember {
+ _gql_meta: causeway_feat_ApplicationTypeMember__DomainObject_meta
+ memberName: String!
+ namespaceName: String!
+ typeSimpleName: String!
+}
+
+type causeway_feat_ApplicationTypeMember__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_feat_ApplicationTypeProperty {
+ _gql_meta: causeway_feat_ApplicationTypeProperty__DomainObject_meta
+ derived: String!
+ maxLength: String
+ memberName: String!
+ namespaceName: String!
+ returnType: String!
+ typeSimpleName: String!
+ typicalLength: String
+}
+
+type causeway_feat_ApplicationTypeProperty__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_feat_ApplicationType__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_schema_metamodel_v2_DomainClassDto {
+ _gql_meta: causeway_schema_metamodel_v2_DomainClassDto__DomainObject_meta
+ actions: String!
+ annotations: String!
+ collections: String!
+ facets: String!
+ id: String!
+ majorVersion: String
+ minorVersion: String
+ properties: String!
+ service: String!
+}
+
+type causeway_schema_metamodel_v2_DomainClassDto__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_security_LoginRedirect {
+ _gql_meta: causeway_security_LoginRedirect__DomainObject_meta
+}
+
+type causeway_security_LoginRedirect__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_security_LogoutMenu {
+ logout: String
+}
+
+type causeway_testing_fixtures_FixtureResult {
+ _gql_meta: causeway_testing_fixtures_FixtureResult__DomainObject_meta
+ className: String!
+ fixtureScriptClassName: String
+ key: String!
+}
+
+type causeway_testing_fixtures_FixtureResult__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type gqltestdomain_E1 {
+ _gql_meta: gqltestdomain_E1__DomainObject_meta
+ e2: gqltestdomain_E2
+ name: String!
+}
+
+type gqltestdomain_E1__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+ version: String
+}
+
+type gqltestdomain_E2 {
+ _gql_meta: gqltestdomain_E2__DomainObject_meta
+ _gql_mutations: gqltestdomain_E2__DomainObject_mutators
+ e1: gqltestdomain_E1
+ name: String
+ otherE2List: [gqltestdomain_E2]
+ otherEntities: [org_apache_causeway_viewer_graphql_viewer_test_source_gqltestdomain_TestEntity]
+ stringList: [String]
+ zintList: [Int]
+}
+
+type gqltestdomain_E2__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+ version: String
+}
+
+type gqltestdomain_E2__DomainObject_mutators {
+ changeE1(e1: _gql_input__gqltestdomain_E1!): gqltestdomain_E2
+ changeName(newName: String!): gqltestdomain_E2
+}
+
+type gqltestdomain_GQLTestDomainMenu {
+ createE1(e2: _gql_input__gqltestdomain_E2, name: String): gqltestdomain_E1
+ findAllE1: [gqltestdomain_E1]
+ findAllE2: [gqltestdomain_E2]
+ findAllTestEntities: [org_apache_causeway_viewer_graphql_viewer_test_source_gqltestdomain_TestEntity]
+ findE2(name: String): gqltestdomain_E2
+}
+
+type java_lang_Runnable {
+ _gql_meta: java_lang_Runnable__DomainObject_meta
+}
+
+type java_lang_Runnable__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type java_util_Map {
+ _gql_meta: java_util_Map__DomainObject_meta
+}
+
+type java_util_Map__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type java_util_SortedMap {
+ _gql_meta: java_util_SortedMap__DomainObject_meta
+}
+
+type java_util_SortedMap__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type java_util_concurrent_Callable {
+ _gql_meta: java_util_concurrent_Callable__DomainObject_meta
+}
+
+type java_util_concurrent_Callable__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type java_util_function_BiFunction {
+ _gql_meta: java_util_function_BiFunction__DomainObject_meta
+}
+
+type java_util_function_BiFunction__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type java_util_function_Consumer {
+ _gql_meta: java_util_function_Consumer__DomainObject_meta
+}
+
+type java_util_function_Consumer__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type java_util_function_Function {
+ _gql_meta: java_util_function_Function__DomainObject_meta
+}
+
+type java_util_function_Function__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type java_util_stream_Stream {
+ _gql_meta: java_util_stream_Stream__DomainObject_meta
+}
+
+type java_util_stream_Stream__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type org_apache_causeway_commons_functional_Either {
+ _gql_meta: org_apache_causeway_commons_functional_Either__DomainObject_meta
+ _gql_mutations: org_apache_causeway_commons_functional_Either__DomainObject_mutators
+ left: String!
+ right: String!
+}
+
+type org_apache_causeway_commons_functional_Either__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type org_apache_causeway_commons_functional_Either__DomainObject_mutators {
+ accept(leftConsumer: _gql_input__java_util_function_Consumer!, rightConsumer: _gql_input__java_util_function_Consumer!): String
+ left: String
+ map(leftMapper: _gql_input__java_util_function_Function!, rightMapper: _gql_input__java_util_function_Function!): org_apache_causeway_commons_functional_Either
+ mapLeft(leftMapper: _gql_input__java_util_function_Function!): org_apache_causeway_commons_functional_Either
+ mapRight(rightMapper: _gql_input__java_util_function_Function!): org_apache_causeway_commons_functional_Either
+ right: String
+}
+
+type org_apache_causeway_commons_functional_Railway {
+ _gql_meta: org_apache_causeway_commons_functional_Railway__DomainObject_meta
+ _gql_mutations: org_apache_causeway_commons_functional_Railway__DomainObject_mutators
+ failure: String!
+ success: String!
+}
+
+type org_apache_causeway_commons_functional_Railway__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type org_apache_causeway_commons_functional_Railway__DomainObject_mutators {
+ chain(chainingFunction: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Railway
+ ifFailure(failureConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Railway
+ ifSuccess(successConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Railway
+ mapFailure(failureMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Railway
+ mapSuccess(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Railway
+}
+
+type org_apache_causeway_commons_functional_ThrowingConsumer {
+ _gql_meta: org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_meta
+ _gql_mutations: org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_mutators
+}
+
+type org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_mutators {
+ andThen(arg0: _gql_input__java_util_function_Consumer!): java_util_function_Consumer
+ throwing(exceptionWrapper: _gql_input__java_util_function_BiFunction!): org_apache_causeway_commons_functional_ThrowingConsumer
+}
+
+type org_apache_causeway_commons_functional_ThrowingFunction {
+ _gql_meta: org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_meta
+ _gql_mutations: org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_mutators
+}
+
+type org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_mutators {
+ andThen(arg0: _gql_input__java_util_function_Function!): java_util_function_Function
+ compose(arg0: _gql_input__java_util_function_Function!): java_util_function_Function
+ throwing(exceptionWrapper: _gql_input__java_util_function_BiFunction!): org_apache_causeway_commons_functional_ThrowingFunction
+}
+
+type org_apache_causeway_commons_functional_ThrowingRunnable {
+ _gql_meta: org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_meta
+ _gql_mutations: org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_mutators
+}
+
+type org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_mutators {
+ callUncatched: String
+ run: String
+ runUncatched: String
+ toCallable: java_util_concurrent_Callable
+ toRunnable: java_lang_Runnable
+}
+
+type org_apache_causeway_commons_functional_Try {
+ _gql_meta: org_apache_causeway_commons_functional_Try__DomainObject_meta
+ _gql_mutations: org_apache_causeway_commons_functional_Try__DomainObject_mutators
+ failure: String!
+ success: String!
+}
+
+type org_apache_causeway_commons_functional_Try__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type org_apache_causeway_commons_functional_Try__DomainObject_mutators {
+ accept(failureConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!, successConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Try
+ flatMapSuccess(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
+ flatMapSuccessAsNullable(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
+ flatMapSuccessWhenPresent(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
+ ifAbsentFail: org_apache_causeway_commons_functional_Try
+ ifFailure(exceptionConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Try
+ ifFailureFail: org_apache_causeway_commons_functional_Try
+ ifSuccess(valueConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Try
+ ifSuccessAsNullable(valueConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Try
+ mapEmptyToFailure: org_apache_causeway_commons_functional_Try
+ mapFailure(failureMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
+ mapFailureToSuccess(recoveryMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
+ mapSuccess(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
+ mapSuccessAsNullable(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
+ mapSuccessWhenPresent(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
+ mapToEither(failureMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!, successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Either
+ orCall(fallback: _gql_input__java_util_concurrent_Callable!): org_apache_causeway_commons_functional_Try
+ then(next: _gql_input__java_util_concurrent_Callable!): org_apache_causeway_commons_functional_Try
+ thenCall(callable: _gql_input__java_util_concurrent_Callable!): org_apache_causeway_commons_functional_Try
+ thenRun(runnable: _gql_input__org_apache_causeway_commons_functional_ThrowingRunnable!): org_apache_causeway_commons_functional_Try
+}
+
+type org_apache_causeway_core_metamodel_inspect_model_MMNode {
+ _gql_meta: org_apache_causeway_core_metamodel_inspect_model_MMNode__DomainObject_meta
+}
+
+type org_apache_causeway_core_metamodel_inspect_model_MMNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type org_apache_causeway_core_metamodel_inspect_model_MemberNode {
+ _gql_meta: org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_meta
+ _gql_mutations: org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_mutators
+ mixedIn: String!
+ parentNode: causeway_applib_TypeNode!
+}
+
+type org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_mutators {
+ streamChildNodes: java_util_stream_Stream
+}
+
+type org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript {
+ _gql_meta: org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__DomainObject_meta
+ friendlyName: String!
+ qualifiedName: String!
+}
+
+type org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type org_apache_causeway_viewer_graphql_viewer_test_source_gqltestdomain_TestEntity {
+ _gql_meta: org_apache_causeway_viewer_graphql_viewer_test_source_gqltestdomain_TestEntity__DomainObject_meta
+ name: String!
+}
+
+type org_apache_causeway_viewer_graphql_viewer_test_source_gqltestdomain_TestEntity__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+input _gql_input__causeway_applib_DomainObjectList {
+ id: ID!
+}
+
+input _gql_input__causeway_applib_FacetGroupNode {
+ id: ID!
+}
+
+input _gql_input__causeway_applib_ParameterNode {
+ id: ID!
+}
+
+input _gql_input__causeway_applib_PropertyNode {
+ id: ID!
+}
+
+input _gql_input__causeway_applib_RoleMemento {
+ id: ID!
+}
+
+input _gql_input__causeway_applib_TypeNode {
+ id: ID!
+}
+
+input _gql_input__causeway_applib_UserMemento {
+ id: ID!
+}
+
+input _gql_input__causeway_applib_node_ActionNode {
+ id: ID!
+}
+
+input _gql_input__causeway_applib_node_CollectionNode {
+ id: ID!
+}
+
+input _gql_input__causeway_applib_node_FacetAttrNode {
+ id: ID!
+}
+
+input _gql_input__causeway_applib_node_FacetNode {
+ id: ID!
+}
+
+input _gql_input__causeway_conf_ConfigurationProperty {
+ id: ID!
+}
+
+input _gql_input__causeway_conf_ConfigurationViewmodel {
+ id: ID!
+}
+
+input _gql_input__causeway_feat_ApplicationFeatureViewModel {
+ id: ID!
+}
+
+input _gql_input__causeway_feat_ApplicationNamespace {
+ id: ID!
+}
+
+input _gql_input__causeway_feat_ApplicationType {
+ id: ID!
+}
+
+input _gql_input__causeway_feat_ApplicationTypeAction {
+ id: ID!
+}
+
+input _gql_input__causeway_feat_ApplicationTypeCollection {
+ id: ID!
+}
+
+input _gql_input__causeway_feat_ApplicationTypeMember {
+ id: ID!
+}
+
+input _gql_input__causeway_feat_ApplicationTypeProperty {
+ id: ID!
+}
+
+input _gql_input__causeway_schema_metamodel_v2_DomainClassDto {
+ id: ID!
+}
+
+input _gql_input__causeway_security_LoginRedirect {
+ id: ID!
+}
+
+input _gql_input__causeway_testing_fixtures_FixtureResult {
+ id: ID!
+}
+
+input _gql_input__gqltestdomain_E1 {
+ id: ID!
+}
+
+input _gql_input__gqltestdomain_E2 {
+ id: ID!
+}
+
+input _gql_input__java_lang_Runnable {
+ id: ID!
+}
+
+input _gql_input__java_util_Map {
+ id: ID!
+}
+
+input _gql_input__java_util_SortedMap {
+ id: ID!
+}
+
+input _gql_input__java_util_concurrent_Callable {
+ id: ID!
+}
+
+input _gql_input__java_util_function_BiFunction {
+ id: ID!
+}
+
+input _gql_input__java_util_function_Consumer {
+ id: ID!
+}
+
+input _gql_input__java_util_function_Function {
+ id: ID!
+}
+
+input _gql_input__java_util_stream_Stream {
+ id: ID!
+}
+
+input _gql_input__org_apache_causeway_commons_functional_Either {
+ id: ID!
+}
+
+input _gql_input__org_apache_causeway_commons_functional_Railway {
+ id: ID!
+}
+
+input _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer {
+ id: ID!
+}
+
+input _gql_input__org_apache_causeway_commons_functional_ThrowingFunction {
+ id: ID!
+}
+
+input _gql_input__org_apache_causeway_commons_functional_ThrowingRunnable {
+ id: ID!
+}
+
+input _gql_input__org_apache_causeway_commons_functional_Try {
+ id: ID!
+}
+
+input _gql_input__org_apache_causeway_core_metamodel_inspect_model_MMNode {
+ id: ID!
+}
+
+input _gql_input__org_apache_causeway_core_metamodel_inspect_model_MemberNode {
+ id: ID!
+}
+
+input _gql_input__org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript {
+ id: ID!
+}
+
+input _gql_input__org_apache_causeway_viewer_graphql_viewer_test_source_gqltestdomain_TestEntity {
+ id: ID!
+}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/E2.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/E2.java
index d2af239bc8..157b8ee882 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/E2.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/E2.java
@@ -35,6 +35,7 @@ import javax.persistence.Table;
import javax.persistence.Transient;
import org.apache.causeway.applib.annotation.Action;
+import org.apache.causeway.applib.annotation.Bounding;
import org.apache.causeway.applib.annotation.Collection;
import org.apache.causeway.applib.annotation.DomainObject;
import org.apache.causeway.applib.annotation.Nature;
@@ -51,7 +52,7 @@ import lombok.Setter;
name = "E2"
)
@Named("gqltestdomain.E2")
-@DomainObject(nature = Nature.ENTITY)
+@DomainObject(nature = Nature.ENTITY, bounding = Bounding.BOUNDED)
public class E2 implements TestEntity{
@Id
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/introspection-query-request.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/introspection-query-request.gql
new file mode 100644
index 0000000000..d0dc5a1cfc
--- /dev/null
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/introspection-query-request.gql
@@ -0,0 +1,99 @@
+query IntrospectionQuery {
+ __schema {
+ queryType {
+ name
+ }
+ mutationType {
+ name
+ }
+ subscriptionType {
+ name
+ }
+ types {
+ ...FullType
+ }
+ directives {
+ name
+ description
+ locations
+ args {
+ ...InputValue
+ }
+ }
+ }
+}
+
+fragment FullType on __Type {
+ kind
+ name
+ description
+ fields(includeDeprecated: true) {
+ name
+ description
+ args {
+ ...InputValue
+ }
+ type {
+ ...TypeRef
+ }
+ isDeprecated
+ deprecationReason
+ }
+ inputFields {
+ ...InputValue
+ }
+ interfaces {
+ ...TypeRef
+ }
+ enumValues(includeDeprecated: true) {
+ name
+ description
+ isDeprecated
+ deprecationReason
+ }
+ possibleTypes {
+ ...TypeRef
+ }
+}
+
+fragment InputValue on __InputValue {
+ name
+ description
+ type {
+ ...TypeRef
+ }
+ defaultValue
+}
+
+fragment TypeRef on __Type {
+ kind
+ name
+ ofType {
+ kind
+ name
+ ofType {
+ kind
+ name
+ ofType {
+ kind
+ name
+ ofType {
+ kind
+ name
+ ofType {
+ kind
+ name
+ ofType {
+ kind
+ name
+ ofType {
+ kind
+ name
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+}
\ No newline at end of file
(causeway) 05/23: CAUSEWAY-3676: splits up Domain and Schema integ tests, also ...
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit ce0910636ff23da33bfbd8217833b890eac16f57
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Wed Jan 17 22:50:56 2024 +0000
CAUSEWAY-3676: splits up Domain and Schema integ tests, also ...
... make sure that iterate over the metamodel in well-defined order
---
...ayViewerGraphqlTestModuleIntegTestAbstract.java | 2 +-
.../viewer/graphql/viewer/test/ScratchPad.java | 2 +
...eName.gql => Domain_IntegTest.changeName._.gql} | 0
...n => Domain_IntegTest.changeName.approved.json} | 0
...reateE1.gql => Domain_IntegTest.createE1._.gql} | 0
...son => Domain_IntegTest.createE1.approved.json} | 0
...=> Domain_IntegTest.find_all_departments._.gql} | 0
...n_IntegTest.find_all_departments.approved.json} | 0
...dToEnd_IntegTest.java => Domain_IntegTest.java} | 69 +-
.../graphql/viewer/test/e2e/Schema_IntegTest.java | 69 +
...st.schema.gql => Schema_IntegTest.schema._.gql} | 0
.../test/e2e/Schema_IntegTest.schema.approved.json | 7320 ++++++++++++++++++++
...ql => Schema_IntegTest.schema_types_name._.gql} | 0
...hema_IntegTest.schema_types_name.approved.json} | 2 +-
.../WinMergeGqlDiffReporter.java} | 7 +-
.../schema.gql} | 0
.../viewer/source/GraphQlSourceForCauseway.java | 5 +
17 files changed, 7412 insertions(+), 64 deletions(-)
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
index 217dc0417f..f0ceb8a16c 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
@@ -155,7 +155,7 @@ public abstract class CausewayViewerGraphqlTestModuleIntegTestAbstract {
* @throws Exception if an error occurs during the submission
*/
protected String submit() throws Exception{
- val httpRequest = buildRequest(testInfo, ".gql");
+ val httpRequest = buildRequest(testInfo, "._.gql");
return submitRequest(httpRequest);
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/ScratchPad.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/ScratchPad.java
index a0df76afc2..c6bc4489f6 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/ScratchPad.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/ScratchPad.java
@@ -24,6 +24,7 @@ import java.util.List;
import java.util.Set;
import org.junit.jupiter.api.Assertions;
+import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
import graphql.Scalars;
@@ -48,6 +49,7 @@ class ScratchPad {
}
@Test
+ @Disabled
public void xxx(){
// given
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.changeName.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.changeName._.gql
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.changeName.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.changeName._.gql
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.changeName.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.changeName.approved.json
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.changeName.approved.json
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.changeName.approved.json
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.createE1.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.createE1._.gql
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.createE1.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.createE1._.gql
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.createE1.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.createE1.approved.json
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.createE1.approved.json
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.createE1.approved.json
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.find_all_departments.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments._.gql
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.find_all_departments.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments._.gql
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.find_all_departments.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments.approved.json
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.find_all_departments.approved.json
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.find_all_departments.approved.json
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.java
similarity index 75%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.java
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.java
index e4b1f40d40..0584dcb2f5 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Domain_IntegTest.java
@@ -18,73 +18,38 @@
*/
package org.apache.causeway.viewer.graphql.viewer.test.e2e;
-import java.io.File;
-import java.io.IOException;
-import java.lang.reflect.Method;
-import java.net.URI;
-import java.net.http.HttpClient;
-import java.net.http.HttpRequest;
-import java.net.http.HttpResponse;
-import java.nio.charset.StandardCharsets;
-import java.nio.file.Files;
-import java.nio.file.Path;
-import java.nio.file.Paths;
import java.util.ArrayList;
import java.util.List;
import javax.inject.Inject;
-import com.fasterxml.jackson.core.JsonProcessingException;
-import com.fasterxml.jackson.databind.ObjectMapper;
-
-import org.apache.causeway.viewer.graphql.viewer.source.GraphQlServiceForCauseway;
-
-import org.apache.causeway.viewer.graphql.viewer.test.CausewayViewerGraphqlTestModuleIntegTestAbstract;
-
-import org.apache.causeway.viewer.graphql.viewer.test.domain.Department;
-
-import org.apache.causeway.viewer.graphql.viewer.test.domain.DeptHead;
-import org.apache.causeway.viewer.graphql.viewer.test.domain.DepartmentRepository;
-
-import org.apache.causeway.viewer.graphql.viewer.test.domain.DeptHeadRepository;
-
-import org.apache.causeway.viewer.graphql.viewer.test.schema.MyWinMergeDiffReporter;
-
import org.approvaltests.Approvals;
-import org.approvaltests.core.Options;
import org.approvaltests.reporters.DiffReporter;
import org.approvaltests.reporters.TextWebReporter;
import org.approvaltests.reporters.UseReporter;
import org.junit.jupiter.api.AfterEach;
-import org.junit.jupiter.api.BeforeEach;
-import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.TestInfo;
import org.junit.jupiter.api.condition.DisabledIfSystemProperty;
+import static org.assertj.core.api.AssertionsForInterfaceTypes.assertThat;
+
import org.springframework.test.context.ActiveProfiles;
import org.springframework.transaction.annotation.Propagation;
-import org.apache.causeway.applib.services.xactn.TransactionService;
-import org.apache.causeway.commons.internal.resources._Resources;
-import org.apache.causeway.core.config.environment.CausewaySystemEnvironment;
-import org.apache.causeway.core.metamodel.specloader.SpecificationLoader;
-import org.apache.causeway.viewer.graphql.viewer.source.GraphQlSourceForCauseway;
+import org.apache.causeway.viewer.graphql.viewer.test.CausewayViewerGraphqlTestModuleIntegTestAbstract;
+import org.apache.causeway.viewer.graphql.viewer.test.domain.Department;
+import org.apache.causeway.viewer.graphql.viewer.test.domain.DepartmentRepository;
+import org.apache.causeway.viewer.graphql.viewer.test.domain.DeptHead;
+import org.apache.causeway.viewer.graphql.viewer.test.domain.DeptHeadRepository;
import org.apache.causeway.viewer.graphql.viewer.test.domain.TopLevelMenu;
import static org.apache.causeway.commons.internal.assertions._Assert.assertEquals;
-import static org.apache.causeway.commons.internal.assertions._Assert.assertNotNull;
import static org.apache.causeway.commons.internal.assertions._Assert.assertTrue;
-import static org.assertj.core.api.AssertionsForInterfaceTypes.assertThat;
-
-import lombok.Value;
-import lombok.val;
-
//NOT USING @Transactional since we are running server within same transaction otherwise
@ActiveProfiles("test")
-public class EndToEnd_IntegTest extends CausewayViewerGraphqlTestModuleIntegTestAbstract {
+public class Domain_IntegTest extends CausewayViewerGraphqlTestModuleIntegTestAbstract {
@Inject DepartmentRepository departmentRepository;
@Inject DeptHeadRepository deptHeadRepository;
@@ -98,21 +63,9 @@ public class EndToEnd_IntegTest extends CausewayViewerGraphqlTestModuleIntegTest
});
}
- @Test
- @UseReporter({MyWinMergeDiffReporter.class, DiffReporter.class})
- void schema() throws Exception {
- Approvals.verify(submit(), jsonOptions());
- }
-
- @Test
- @UseReporter({MyWinMergeDiffReporter.class, DiffReporter.class})
- void schema_types_name() throws Exception {
- Approvals.verify(submit(), jsonOptions());
- }
-
@Test
- @UseReporter({MyWinMergeDiffReporter.class, DiffReporter.class})
+ @UseReporter(DiffReporter.class)
void find_all_departments() throws Exception {
// given
@@ -135,7 +88,7 @@ public class EndToEnd_IntegTest extends CausewayViewerGraphqlTestModuleIntegTest
//TODO started to fail on 2022-09-04, with testEntityRepository findAll being empty
@Test @DisabledIfSystemProperty(named = "isRunningWithSurefire", matches = "true")
- @UseReporter(TextWebReporter.class)
+ @UseReporter(DiffReporter.class)
void createE1() throws Exception {
//File targetFile3 = new File("src/test/resources/testfiles/targetFile3.gql");
@@ -168,7 +121,7 @@ public class EndToEnd_IntegTest extends CausewayViewerGraphqlTestModuleIntegTest
//TODO started to fail on 2023-07-25
//disabled to rescue CI build
@Test @DisabledIfSystemProperty(named = "isRunningWithSurefire", matches = "true")
- @UseReporter(TextWebReporter.class)
+ @UseReporter(DiffReporter.class)
void changeName() throws Exception {
List<DeptHead> deptHeadList = new ArrayList<>();
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.java
new file mode 100644
index 0000000000..816f43ae16
--- /dev/null
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.java
@@ -0,0 +1,69 @@
+/*
+ * 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.
+ */
+package org.apache.causeway.viewer.graphql.viewer.test.e2e;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.inject.Inject;
+
+import org.apache.causeway.viewer.graphql.viewer.test.CausewayViewerGraphqlTestModuleIntegTestAbstract;
+
+import org.apache.causeway.viewer.graphql.viewer.test.domain.Department;
+
+import org.apache.causeway.viewer.graphql.viewer.test.domain.DeptHead;
+import org.apache.causeway.viewer.graphql.viewer.test.domain.DepartmentRepository;
+
+import org.apache.causeway.viewer.graphql.viewer.test.domain.DeptHeadRepository;
+
+import org.approvaltests.Approvals;
+import org.approvaltests.reporters.DiffReporter;
+import org.approvaltests.reporters.TextWebReporter;
+import org.approvaltests.reporters.UseReporter;
+import org.junit.jupiter.api.AfterEach;
+import org.junit.jupiter.api.Test;
+import org.junit.jupiter.api.condition.DisabledIfSystemProperty;
+
+import org.springframework.test.context.ActiveProfiles;
+import org.springframework.transaction.annotation.Propagation;
+
+import org.apache.causeway.viewer.graphql.viewer.test.domain.TopLevelMenu;
+
+import static org.apache.causeway.commons.internal.assertions._Assert.assertEquals;
+import static org.apache.causeway.commons.internal.assertions._Assert.assertNotNull;
+import static org.apache.causeway.commons.internal.assertions._Assert.assertTrue;
+
+import static org.assertj.core.api.AssertionsForInterfaceTypes.assertThat;
+
+
+@ActiveProfiles("test")
+public class Schema_IntegTest extends CausewayViewerGraphqlTestModuleIntegTestAbstract {
+
+ @Test
+ @UseReporter(DiffReporter.class)
+ void schema() throws Exception {
+ Approvals.verify(submit(), jsonOptions());
+ }
+
+ @Test
+ @UseReporter(DiffReporter.class)
+ void schema_types_name() throws Exception {
+ Approvals.verify(submit(), jsonOptions());
+ }
+}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.schema.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema._.gql
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.schema.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema._.gql
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema.approved.json
new file mode 100644
index 0000000000..fc3d84a3d6
--- /dev/null
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema.approved.json
@@ -0,0 +1,7320 @@
+{
+ "data" : {
+ "__schema" : {
+ "queryType" : {
+ "name" : "Query"
+ },
+ "mutationType" : null,
+ "subscriptionType" : null,
+ "types" : [ {
+ "kind" : "SCALAR",
+ "name" : "Boolean",
+ "description" : "Built-in Boolean",
+ "fields" : null,
+ "inputFields" : null,
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "description" : "Built-in ID",
+ "fields" : null,
+ "inputFields" : null,
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "SCALAR",
+ "name" : "Int",
+ "description" : "Built-in Int",
+ "fields" : null,
+ "inputFields" : null,
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "Query",
+ "description" : null,
+ "fields" : [ {
+ "name" : "causeway_applib_UserMenu",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_UserMenu",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "causeway_conf_ConfigurationMenu",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_conf_ConfigurationMenu",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "causeway_security_LogoutMenu",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_security_LogoutMenu",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "gql_test_domain_TopLevelMenu",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_TopLevelMenu",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "numServices",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "Int",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "description" : "Built-in String",
+ "fields" : null,
+ "inputFields" : null,
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "__Directive",
+ "description" : null,
+ "fields" : [ {
+ "name" : "name",
+ "description" : "The __Directive type represents a Directive that a server supports.",
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "description",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "isRepeatable",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "Boolean",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "locations",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "ENUM",
+ "name" : "__DirectiveLocation",
+ "ofType" : null
+ }
+ }
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "args",
+ "description" : null,
+ "args" : [ {
+ "name" : "includeDeprecated",
+ "description" : null,
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "Boolean",
+ "ofType" : null
+ },
+ "defaultValue" : "false"
+ } ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "__InputValue",
+ "ofType" : null
+ }
+ }
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "onOperation",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "Boolean",
+ "ofType" : null
+ },
+ "isDeprecated" : true,
+ "deprecationReason" : "Use `locations`."
+ }, {
+ "name" : "onFragment",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "Boolean",
+ "ofType" : null
+ },
+ "isDeprecated" : true,
+ "deprecationReason" : "Use `locations`."
+ }, {
+ "name" : "onField",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "Boolean",
+ "ofType" : null
+ },
+ "isDeprecated" : true,
+ "deprecationReason" : "Use `locations`."
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "ENUM",
+ "name" : "__DirectiveLocation",
+ "description" : "An enum describing valid locations where a directive can be placed",
+ "fields" : null,
+ "inputFields" : null,
+ "interfaces" : null,
+ "enumValues" : [ {
+ "name" : "QUERY",
+ "description" : "Indicates the directive is valid on queries.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "MUTATION",
+ "description" : "Indicates the directive is valid on mutations.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "SUBSCRIPTION",
+ "description" : "Indicates the directive is valid on subscriptions.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "FIELD",
+ "description" : "Indicates the directive is valid on fields.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "FRAGMENT_DEFINITION",
+ "description" : "Indicates the directive is valid on fragment definitions.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "FRAGMENT_SPREAD",
+ "description" : "Indicates the directive is valid on fragment spreads.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "INLINE_FRAGMENT",
+ "description" : "Indicates the directive is valid on inline fragments.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "VARIABLE_DEFINITION",
+ "description" : "Indicates the directive is valid on variable definitions.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "SCHEMA",
+ "description" : "Indicates the directive is valid on a schema SDL definition.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "SCALAR",
+ "description" : "Indicates the directive is valid on a scalar SDL definition.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "OBJECT",
+ "description" : "Indicates the directive is valid on an object SDL definition.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "FIELD_DEFINITION",
+ "description" : "Indicates the directive is valid on a field SDL definition.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "ARGUMENT_DEFINITION",
+ "description" : "Indicates the directive is valid on a field argument SDL definition.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "INTERFACE",
+ "description" : "Indicates the directive is valid on an interface SDL definition.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "UNION",
+ "description" : "Indicates the directive is valid on an union SDL definition.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "ENUM",
+ "description" : "Indicates the directive is valid on an enum SDL definition.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "ENUM_VALUE",
+ "description" : "Indicates the directive is valid on an enum value SDL definition.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "INPUT_OBJECT",
+ "description" : "Indicates the directive is valid on an input object SDL definition.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "INPUT_FIELD_DEFINITION",
+ "description" : "Indicates the directive is valid on an input object field SDL definition.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "__EnumValue",
+ "description" : null,
+ "fields" : [ {
+ "name" : "name",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "description",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "isDeprecated",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "Boolean",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "deprecationReason",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "__Field",
+ "description" : null,
+ "fields" : [ {
+ "name" : "name",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "description",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "args",
+ "description" : null,
+ "args" : [ {
+ "name" : "includeDeprecated",
+ "description" : null,
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "Boolean",
+ "ofType" : null
+ },
+ "defaultValue" : "false"
+ } ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "__InputValue",
+ "ofType" : null
+ }
+ }
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "type",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "__Type",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "isDeprecated",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "Boolean",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "deprecationReason",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "__InputValue",
+ "description" : null,
+ "fields" : [ {
+ "name" : "name",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "description",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "type",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "__Type",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "defaultValue",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "isDeprecated",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "Boolean",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "deprecationReason",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "__Schema",
+ "description" : "A GraphQL Introspection defines the capabilities of a GraphQL server. It exposes all available types and directives on the server, the entry points for query, mutation, and subscription operations.",
+ "fields" : [ {
+ "name" : "description",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "types",
+ "description" : "A list of all types supported by this server.",
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "__Type",
+ "ofType" : null
+ }
+ }
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "queryType",
+ "description" : "The type that query operations will be rooted at.",
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "__Type",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mutationType",
+ "description" : "If this server supports mutation, the type that mutation operations will be rooted at.",
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "__Type",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "directives",
+ "description" : "'A list of all directives supported by this server.",
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "__Directive",
+ "ofType" : null
+ }
+ }
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "subscriptionType",
+ "description" : "'If this server support subscription, the type that subscription operations will be rooted at.",
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "__Type",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "__Type",
+ "description" : null,
+ "fields" : [ {
+ "name" : "kind",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "ENUM",
+ "name" : "__TypeKind",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "name",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "description",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "fields",
+ "description" : null,
+ "args" : [ {
+ "name" : "includeDeprecated",
+ "description" : null,
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "Boolean",
+ "ofType" : null
+ },
+ "defaultValue" : "false"
+ } ],
+ "type" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "__Field",
+ "ofType" : null
+ }
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "interfaces",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "__Type",
+ "ofType" : null
+ }
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "possibleTypes",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "__Type",
+ "ofType" : null
+ }
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "enumValues",
+ "description" : null,
+ "args" : [ {
+ "name" : "includeDeprecated",
+ "description" : null,
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "Boolean",
+ "ofType" : null
+ },
+ "defaultValue" : "false"
+ } ],
+ "type" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "__EnumValue",
+ "ofType" : null
+ }
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "inputFields",
+ "description" : null,
+ "args" : [ {
+ "name" : "includeDeprecated",
+ "description" : null,
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "Boolean",
+ "ofType" : null
+ },
+ "defaultValue" : "false"
+ } ],
+ "type" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "__InputValue",
+ "ofType" : null
+ }
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "ofType",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "__Type",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "specifiedByUrl",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "ENUM",
+ "name" : "__TypeKind",
+ "description" : "An enum describing what kind of type a given __Type is",
+ "fields" : null,
+ "inputFields" : null,
+ "interfaces" : null,
+ "enumValues" : [ {
+ "name" : "SCALAR",
+ "description" : "Indicates this type is a scalar. 'specifiedByUrl' is a valid field",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "OBJECT",
+ "description" : "Indicates this type is an object. `fields` and `interfaces` are valid fields.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "INTERFACE",
+ "description" : "Indicates this type is an interface. `fields` and `possibleTypes` are valid fields.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "UNION",
+ "description" : "Indicates this type is a union. `possibleTypes` is a valid field.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "ENUM",
+ "description" : "Indicates this type is an enum. `enumValues` is a valid field.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "INPUT_OBJECT",
+ "description" : "Indicates this type is an input object. `inputFields` is a valid field.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "LIST",
+ "description" : "Indicates this type is a list. `ofType` is a valid field.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "NON_NULL",
+ "description" : "Indicates this type is a non-null. `ofType` is a valid field.",
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_applib_DomainObjectList",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_applib_FacetGroupNode",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_applib_ParameterNode",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_applib_PropertyNode",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_applib_RoleMemento",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_applib_TypeNode",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_applib_UserMemento",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_applib_node_ActionNode",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_applib_node_CollectionNode",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_applib_node_FacetAttrNode",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_applib_node_FacetNode",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_conf_ConfigurationProperty",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_conf_ConfigurationViewmodel",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_feat_ApplicationFeatureViewModel",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_feat_ApplicationNamespace",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_feat_ApplicationType",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_feat_ApplicationTypeAction",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_feat_ApplicationTypeCollection",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_feat_ApplicationTypeMember",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_feat_ApplicationTypeProperty",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_schema_metamodel_v2_DomainClassDto",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_security_LoginRedirect",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__causeway_testing_fixtures_FixtureResult",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__gql_test_domain_Department",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__gql_test_domain_DeptHead",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_lang_Runnable",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_Map",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_SortedMap",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_concurrent_Callable",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_BiFunction",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_Consumer",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_Function",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_stream_Stream",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_Either",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_Railway",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingConsumer",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingFunction",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingRunnable",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_Try",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_core_metamodel_inspect_model_MMNode",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_core_metamodel_inspect_model_MemberNode",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_viewer_graphql_viewer_test_domain_WithName",
+ "description" : null,
+ "fields" : null,
+ "inputFields" : [ {
+ "name" : "id",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "ID",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "interfaces" : null,
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_DomainObjectList",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_DomainObjectList__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "actionArguments",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "actionId",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "actionOwningFqcn",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "elementTypeFqcn",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "title",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_DomainObjectList__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_FacetGroupNode",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_FacetGroupNode__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "facets",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_FacetGroupNode__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_ParameterNode",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_ParameterNode__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "parameter",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "parentNode",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_ActionNode",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_ParameterNode__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_PropertyNode",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_PropertyNode__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "parentNode",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_TypeNode",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "property",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mixedIn",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "_gql_mutations",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_PropertyNode__DomainObject_mutators",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_PropertyNode__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_PropertyNode__DomainObject_mutators",
+ "description" : null,
+ "fields" : [ {
+ "name" : "streamChildNodes",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_util_stream_Stream",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_RoleMemento",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_RoleMemento__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "description",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "name",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_RoleMemento__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_TypeNode",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_TypeNode__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "domainClassDto",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_schema_metamodel_v2_DomainClassDto",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_TypeNode__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_UserMemento",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_UserMemento__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "authenticationCode",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "realName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "avatarUrl",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "name",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "languageLocale",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "numberFormatLocale",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "timeFormatLocale",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "authenticationSource",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "multiTenancyToken",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "impersonating",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "roles",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_RoleMemento",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_UserMemento__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_UserMenu",
+ "description" : null,
+ "fields" : [ {
+ "name" : "me",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_UserMemento",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_ActionNode",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_ActionNode__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "action",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "parentNode",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_TypeNode",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mixedIn",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "_gql_mutations",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_ActionNode__DomainObject_mutators",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_ActionNode__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_ActionNode__DomainObject_mutators",
+ "description" : null,
+ "fields" : [ {
+ "name" : "streamChildNodes",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_util_stream_Stream",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_CollectionNode",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_CollectionNode__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "collection",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "parentNode",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_TypeNode",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mixedIn",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "_gql_mutations",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_CollectionNode__DomainObject_mutators",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_CollectionNode__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_CollectionNode__DomainObject_mutators",
+ "description" : null,
+ "fields" : [ {
+ "name" : "streamChildNodes",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_util_stream_Stream",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_FacetAttrNode",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_FacetAttrNode__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "facetAttr",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "parentNode",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_FacetNode",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_FacetAttrNode__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_FacetNode",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_FacetNode__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "facet",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "shadowed",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_node_FacetNode__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_conf_ConfigurationMenu",
+ "description" : null,
+ "fields" : [ {
+ "name" : "configuration",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_conf_ConfigurationViewmodel",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_conf_ConfigurationProperty",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_conf_ConfigurationProperty__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "key",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "value",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_conf_ConfigurationProperty__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_conf_ConfigurationViewmodel",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_conf_ConfigurationViewmodel__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "environment",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_conf_ConfigurationProperty",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "primary",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_conf_ConfigurationProperty",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "secondary",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_conf_ConfigurationProperty",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_conf_ConfigurationViewmodel__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationFeatureViewModel",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationFeatureViewModel__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "namespaceName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "typeSimpleName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "memberName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationFeatureViewModel__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationNamespace",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationNamespace__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "namespaceName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "typeSimpleName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "memberName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationNamespace__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationType",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationType__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "namespaceName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "typeSimpleName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "memberName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "actions",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationTypeAction",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "properties",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationTypeProperty",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "collections",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationTypeCollection",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationTypeAction",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationTypeAction__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "returnType",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "actionSemantics",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "namespaceName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "typeSimpleName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "memberName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationTypeAction__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationTypeCollection",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationTypeCollection__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "elementType",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "derived",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "namespaceName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "typeSimpleName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "memberName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationTypeCollection__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationTypeMember",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationTypeMember__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "namespaceName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "typeSimpleName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "memberName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationTypeMember__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationTypeProperty",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationTypeProperty__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "returnType",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "derived",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "maxLength",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "typicalLength",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "namespaceName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "typeSimpleName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "memberName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationTypeProperty__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_feat_ApplicationType__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_schema_metamodel_v2_DomainClassDto",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_schema_metamodel_v2_DomainClassDto__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "actions",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "annotations",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "collections",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "facets",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "majorVersion",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "minorVersion",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "properties",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "service",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_schema_metamodel_v2_DomainClassDto__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_security_LoginRedirect",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_security_LoginRedirect__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_security_LoginRedirect__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_security_LogoutMenu",
+ "description" : null,
+ "fields" : [ {
+ "name" : "logout",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_testing_fixtures_FixtureResult",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_testing_fixtures_FixtureResult__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "fixtureScriptClassName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "className",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "key",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "causeway_testing_fixtures_FixtureResult__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_Department",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_Department__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "deptHead",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_DeptHead",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "name",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_Department__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "version",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_DeptHead",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_DeptHead__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "department",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_Department",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "name",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "_gql_mutations",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_DeptHead__DomainObject_mutators",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_DeptHead__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "version",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_DeptHead__DomainObject_mutators",
+ "description" : null,
+ "fields" : [ {
+ "name" : "changeDeptHead",
+ "description" : null,
+ "args" : [ {
+ "name" : "department",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__gql_test_domain_Department",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_DeptHead",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "changeName",
+ "description" : null,
+ "args" : [ {
+ "name" : "newName",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_DeptHead",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_TopLevelMenu",
+ "description" : null,
+ "fields" : [ {
+ "name" : "createDepartment",
+ "description" : null,
+ "args" : [ {
+ "name" : "name",
+ "description" : null,
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "defaultValue" : null
+ }, {
+ "name" : "deptHead",
+ "description" : null,
+ "type" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__gql_test_domain_DeptHead",
+ "ofType" : null
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_Department",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "findAllDepartments",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_Department",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "findAllDeptHeads",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_DeptHead",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "findAllEntitiesWithName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "LIST",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_viewer_graphql_viewer_test_domain_WithName",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "findDeptHeadByName",
+ "description" : null,
+ "args" : [ {
+ "name" : "name",
+ "description" : null,
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "gql_test_domain_DeptHead",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_lang_Runnable",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_lang_Runnable__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_lang_Runnable__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_util_Map",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_util_Map__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_util_Map__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_util_SortedMap",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_util_SortedMap__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_util_SortedMap__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_util_concurrent_Callable",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_util_concurrent_Callable__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_util_concurrent_Callable__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_util_function_BiFunction",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_util_function_BiFunction__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_util_function_BiFunction__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_util_function_Consumer",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_util_function_Consumer__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_util_function_Consumer__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_util_function_Function",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_util_function_Function__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_util_function_Function__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_util_stream_Stream",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_util_stream_Stream__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "java_util_stream_Stream__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Either",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Either__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "left",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "right",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "_gql_mutations",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Either__DomainObject_mutators",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Either__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Either__DomainObject_mutators",
+ "description" : null,
+ "fields" : [ {
+ "name" : "accept",
+ "description" : null,
+ "args" : [ {
+ "name" : "leftConsumer",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_Consumer",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ }, {
+ "name" : "rightConsumer",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_Consumer",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "left",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "map",
+ "description" : null,
+ "args" : [ {
+ "name" : "leftMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_Function",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ }, {
+ "name" : "rightMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_Function",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Either",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mapLeft",
+ "description" : null,
+ "args" : [ {
+ "name" : "leftMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_Function",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Either",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mapRight",
+ "description" : null,
+ "args" : [ {
+ "name" : "rightMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_Function",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Either",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "right",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Railway",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Railway__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "failure",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "success",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "_gql_mutations",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Railway__DomainObject_mutators",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Railway__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Railway__DomainObject_mutators",
+ "description" : null,
+ "fields" : [ {
+ "name" : "chain",
+ "description" : null,
+ "args" : [ {
+ "name" : "chainingFunction",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingFunction",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Railway",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "ifFailure",
+ "description" : null,
+ "args" : [ {
+ "name" : "failureConsumer",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingConsumer",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Railway",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "ifSuccess",
+ "description" : null,
+ "args" : [ {
+ "name" : "successConsumer",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingConsumer",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Railway",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mapFailure",
+ "description" : null,
+ "args" : [ {
+ "name" : "failureMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingFunction",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Railway",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mapSuccess",
+ "description" : null,
+ "args" : [ {
+ "name" : "successMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingFunction",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Railway",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_ThrowingConsumer",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "_gql_mutations",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_mutators",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_mutators",
+ "description" : null,
+ "fields" : [ {
+ "name" : "andThen",
+ "description" : null,
+ "args" : [ {
+ "name" : "arg0",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_Consumer",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_util_function_Consumer",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "throwing",
+ "description" : null,
+ "args" : [ {
+ "name" : "exceptionWrapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_BiFunction",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_ThrowingConsumer",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_ThrowingFunction",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "_gql_mutations",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_mutators",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_mutators",
+ "description" : null,
+ "fields" : [ {
+ "name" : "andThen",
+ "description" : null,
+ "args" : [ {
+ "name" : "arg0",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_Function",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_util_function_Function",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "compose",
+ "description" : null,
+ "args" : [ {
+ "name" : "arg0",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_Function",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_util_function_Function",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "throwing",
+ "description" : null,
+ "args" : [ {
+ "name" : "exceptionWrapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_function_BiFunction",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_ThrowingFunction",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_ThrowingRunnable",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "_gql_mutations",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_mutators",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_mutators",
+ "description" : null,
+ "fields" : [ {
+ "name" : "callUncatched",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "run",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "runUncatched",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "toCallable",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_util_concurrent_Callable",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "toRunnable",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_lang_Runnable",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "failure",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "success",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "_gql_mutations",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try__DomainObject_mutators",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try__DomainObject_mutators",
+ "description" : null,
+ "fields" : [ {
+ "name" : "accept",
+ "description" : null,
+ "args" : [ {
+ "name" : "failureConsumer",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingConsumer",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ }, {
+ "name" : "successConsumer",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingConsumer",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "flatMapSuccess",
+ "description" : null,
+ "args" : [ {
+ "name" : "successMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingFunction",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "flatMapSuccessAsNullable",
+ "description" : null,
+ "args" : [ {
+ "name" : "successMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingFunction",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "flatMapSuccessWhenPresent",
+ "description" : null,
+ "args" : [ {
+ "name" : "successMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingFunction",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "ifAbsentFail",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "ifFailure",
+ "description" : null,
+ "args" : [ {
+ "name" : "exceptionConsumer",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingConsumer",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "ifFailureFail",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "ifSuccess",
+ "description" : null,
+ "args" : [ {
+ "name" : "valueConsumer",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingConsumer",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "ifSuccessAsNullable",
+ "description" : null,
+ "args" : [ {
+ "name" : "valueConsumer",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingConsumer",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mapEmptyToFailure",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mapFailure",
+ "description" : null,
+ "args" : [ {
+ "name" : "failureMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingFunction",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mapFailureToSuccess",
+ "description" : null,
+ "args" : [ {
+ "name" : "recoveryMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingFunction",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mapSuccess",
+ "description" : null,
+ "args" : [ {
+ "name" : "successMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingFunction",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mapSuccessAsNullable",
+ "description" : null,
+ "args" : [ {
+ "name" : "successMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingFunction",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mapSuccessWhenPresent",
+ "description" : null,
+ "args" : [ {
+ "name" : "successMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingFunction",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mapToEither",
+ "description" : null,
+ "args" : [ {
+ "name" : "failureMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingFunction",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ }, {
+ "name" : "successMapper",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingFunction",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Either",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "orCall",
+ "description" : null,
+ "args" : [ {
+ "name" : "fallback",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_concurrent_Callable",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "then",
+ "description" : null,
+ "args" : [ {
+ "name" : "next",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_concurrent_Callable",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "thenCall",
+ "description" : null,
+ "args" : [ {
+ "name" : "callable",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__java_util_concurrent_Callable",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "thenRun",
+ "description" : null,
+ "args" : [ {
+ "name" : "runnable",
+ "description" : null,
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "INPUT_OBJECT",
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingRunnable",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_commons_functional_Try",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MMNode",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MMNode__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MMNode__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "parentNode",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "OBJECT",
+ "name" : "causeway_applib_TypeNode",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "mixedIn",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "_gql_mutations",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_mutators",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_mutators",
+ "description" : null,
+ "fields" : [ {
+ "name" : "streamChildNodes",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "java_util_stream_Stream",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "friendlyName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "qualifiedName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_viewer_graphql_viewer_test_domain_WithName",
+ "description" : null,
+ "fields" : [ {
+ "name" : "_gql_meta",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_viewer_graphql_viewer_test_domain_WithName__DomainObject_meta",
+ "ofType" : null
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "name",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ }, {
+ "kind" : "OBJECT",
+ "name" : "org_apache_causeway_viewer_graphql_viewer_test_domain_WithName__DomainObject_meta",
+ "description" : null,
+ "fields" : [ {
+ "name" : "id",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ }, {
+ "name" : "logicalTypeName",
+ "description" : null,
+ "args" : [ ],
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "isDeprecated" : false,
+ "deprecationReason" : null
+ } ],
+ "inputFields" : null,
+ "interfaces" : [ ],
+ "enumValues" : null,
+ "possibleTypes" : null
+ } ],
+ "directives" : [ {
+ "name" : "include",
+ "description" : "Directs the executor to include this field or fragment only when the `if` argument is true",
+ "locations" : [ "FIELD", "FRAGMENT_SPREAD", "INLINE_FRAGMENT" ],
+ "args" : [ {
+ "name" : "if",
+ "description" : "Included when true.",
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "Boolean",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ]
+ }, {
+ "name" : "skip",
+ "description" : "Directs the executor to skip this field or fragment when the `if` argument is true.",
+ "locations" : [ "FIELD", "FRAGMENT_SPREAD", "INLINE_FRAGMENT" ],
+ "args" : [ {
+ "name" : "if",
+ "description" : "Skipped when true.",
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "Boolean",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ]
+ }, {
+ "name" : "deprecated",
+ "description" : "Marks the field, argument, input field or enum value as deprecated",
+ "locations" : [ "FIELD_DEFINITION", "ARGUMENT_DEFINITION", "ENUM_VALUE", "INPUT_FIELD_DEFINITION" ],
+ "args" : [ {
+ "name" : "reason",
+ "description" : "The reason for the deprecation",
+ "type" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ },
+ "defaultValue" : "\"No longer supported\""
+ } ]
+ }, {
+ "name" : "specifiedBy",
+ "description" : "Exposes a URL that specifies the behaviour of this scalar.",
+ "locations" : [ "SCALAR" ],
+ "args" : [ {
+ "name" : "url",
+ "description" : "The URL that specifies the behaviour of this scalar.",
+ "type" : {
+ "kind" : "NON_NULL",
+ "name" : null,
+ "ofType" : {
+ "kind" : "SCALAR",
+ "name" : "String",
+ "ofType" : null
+ }
+ },
+ "defaultValue" : null
+ } ]
+ } ]
+ }
+ }
+}
\ No newline at end of file
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.schema_types_name.submit.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema_types_name._.gql
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.schema_types_name.submit.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema_types_name._.gql
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.schema_types_name.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema_types_name.approved.json
similarity index 99%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.schema_types_name.approved.json
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema_types_name.approved.json
index 57aa17d2bb..fd14945df3 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.schema_types_name.approved.json
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Schema_IntegTest.schema_types_name.approved.json
@@ -228,7 +228,7 @@
}, {
"name" : "gql_test_domain_DeptHead__DomainObject_mutators"
}, {
- "name" : "gqltestdomain_GQLTestDomainMenu"
+ "name" : "gql_test_domain_TopLevelMenu"
}, {
"name" : "java_lang_Runnable"
}, {
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/MyWinMergeDiffReporter.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/utils/WinMergeGqlDiffReporter.java
similarity index 79%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/MyWinMergeDiffReporter.java
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/utils/WinMergeGqlDiffReporter.java
index 0816357034..732fa8d119 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/MyWinMergeDiffReporter.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/utils/WinMergeGqlDiffReporter.java
@@ -1,6 +1,5 @@
-package org.apache.causeway.viewer.graphql.viewer.test.schema;
+package org.apache.causeway.viewer.graphql.viewer.test.utils;
-import java.util.Arrays;
import java.util.List;
import org.approvaltests.reporters.DiffInfo;
@@ -9,7 +8,7 @@ import org.approvaltests.reporters.GenericDiffReporter;
import com.spun.util.ArrayUtils;
-public class MyWinMergeDiffReporter extends GenericDiffReporter {
+public class WinMergeGqlDiffReporter extends GenericDiffReporter {
private static DiffInfo WIN_MERGE_REPORTER =
new DiffInfo(DiffPrograms.Windows.WIN_MERGE_REPORTER.diffProgram,
@@ -21,7 +20,7 @@ public class MyWinMergeDiffReporter extends GenericDiffReporter {
)
);
- public MyWinMergeDiffReporter() {
+ public WinMergeGqlDiffReporter() {
super(WIN_MERGE_REPORTER);
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_print_IntegTest.schema.approved.gql b/incubator/viewers/graphql/test/src/test/resources/schema.gql
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_print_IntegTest.schema.approved.gql
rename to incubator/viewers/graphql/test/src/test/resources/schema.gql
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQlSourceForCauseway.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQlSourceForCauseway.java
index 5d76c596d6..47a717d99a 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQlSourceForCauseway.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQlSourceForCauseway.java
@@ -22,12 +22,16 @@ import static graphql.schema.FieldCoordinates.coordinates;
import static graphql.schema.GraphQLFieldDefinition.newFieldDefinition;
import static graphql.schema.GraphQLObjectType.newObject;
+import java.util.Comparator;
import java.util.HashSet;
import java.util.Set;
import javax.annotation.PostConstruct;
import javax.inject.Inject;
+import org.apache.causeway.applib.id.HasLogicalType;
+import org.apache.causeway.core.metamodel.spec.ObjectSpecification;
+
import org.springframework.graphql.execution.GraphQlSource;
import org.springframework.stereotype.Service;
@@ -90,6 +94,7 @@ public class GraphQlSourceForCauseway implements GraphQlSource {
specificationLoader.snapshotSpecifications()
.distinct((a, b) -> a.getLogicalTypeName().equals(b.getLogicalTypeName()))
+ .sorted(Comparator.comparing(HasLogicalType::getLogicalTypeName))
.forEach(objectSpecification -> {
val logicalTypeName = objectSpecification.getLogicalTypeName();
(causeway) 11/23: CAUSEWAY-3676: renames GQLMutations to GqlMutations
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit 58d453a557c55867335a9196f50467322a5516e2
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Thu Jan 18 19:14:40 2024 +0000
CAUSEWAY-3676: renames GQLMutations to GqlMutations
---
.../graphql/viewer/source/{GQLMutations.java => GqlMutations.java} | 2 +-
.../apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GQLMutations.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlMutations.java
similarity index 97%
rename from incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GQLMutations.java
rename to incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlMutations.java
index 768a7782f6..27d1cb4e27 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GQLMutations.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlMutations.java
@@ -26,7 +26,7 @@ import org.apache.causeway.applib.services.bookmark.BookmarkService;
import lombok.Data;
@Data
-public class GQLMutations {
+public class GqlMutations {
private final Bookmark bookmark;
private final BookmarkService bookmarkService;
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
index 55b43e5780..b1f6983e2e 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
@@ -356,7 +356,7 @@ public class ObjectTypeFactory {
//
// Bookmark bookmark = bookmarkService.bookmarkFor(environment.getSource()).orElse(null);
// if (bookmark == null) return null; //TODO: is this correct ?
-// return new GQLMutations(bookmark, bookmarkService, mutatorsTypeFields);
+// return new GqlMutations(bookmark, bookmarkService, mutatorsTypeFields);
// }
// });
//
(causeway) 13/23: CAUSEWAY-3676: refactorings
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit 5fba37e2890f42542936071bb8d76fa3a4219107
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Fri Jan 19 10:26:47 2024 +0000
CAUSEWAY-3676: refactorings
---
...ayViewerGraphqlTestModuleIntegTestAbstract.java | 8 +-
.../test/schema/GqlSchema_print_IntegTest.java | 5 +-
.../graphql/viewer/src/main/java/module-info.java | 1 +
...ecutionStrategyResolvingWithinInteraction.java} | 4 +-
.../ExecutionGraphQlServiceForCauseway.java} | 4 +-
.../GraphQlSourceForCauseway.java | 15 ++-
.../viewer/source/{GqlMeta.java => GqlvMeta.java} | 5 +-
.../{GqlMutations.java => GqlvMutations.java} | 2 +-
.../graphql/viewer/source/GqlvObjectSpec.java | 7 +-
.../graphql/viewer/source/ObjectTypeFactory.java | 103 ++++++++++++++-------
10 files changed, 96 insertions(+), 58 deletions(-)
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
index 6f88728dbf..c5c9437e74 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
@@ -36,8 +36,8 @@ import org.apache.causeway.commons.internal.resources._Resources;
import org.apache.causeway.core.config.environment.CausewaySystemEnvironment;
import org.apache.causeway.core.metamodel.specloader.SpecificationLoader;
-import org.apache.causeway.viewer.graphql.viewer.source.GraphQlServiceForCauseway;
-import org.apache.causeway.viewer.graphql.viewer.source.GraphQlSourceForCauseway;
+import org.apache.causeway.viewer.graphql.viewer.integration.ExecutionGraphQlServiceForCauseway;
+import org.apache.causeway.viewer.graphql.viewer.integration.GraphQlSourceForCauseway;
import org.approvaltests.core.Options;
import org.junit.jupiter.api.BeforeEach;
@@ -115,7 +115,7 @@ public abstract class CausewayViewerGraphqlTestModuleIntegTestAbstract {
@Inject protected SpecificationLoader specificationLoader;
@Inject protected TransactionService transactionService;
@Inject protected GraphQlSourceForCauseway graphQlSourceForCauseway;
- @Inject protected GraphQlServiceForCauseway graphQlServiceForCauseway;
+ @Inject protected ExecutionGraphQlServiceForCauseway executionGraphQlServiceForCauseway;
@LocalServerPort
protected int port;
@@ -127,7 +127,7 @@ public abstract class CausewayViewerGraphqlTestModuleIntegTestAbstract {
assertNotNull(specificationLoader);
assertNotNull(transactionService);
assertNotNull(graphQlSourceForCauseway);
- assertNotNull(graphQlServiceForCauseway);
+ assertNotNull(executionGraphQlServiceForCauseway);
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_print_IntegTest.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_print_IntegTest.java
index 3ceac932e9..561a7b6900 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_print_IntegTest.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_print_IntegTest.java
@@ -29,17 +29,14 @@ import org.apache.causeway.commons.io.TextUtils;
import org.apache.causeway.viewer.graphql.viewer.test.CausewayViewerGraphqlTestModuleIntegTestAbstract;
-import org.approvaltests.Approvals;
import org.approvaltests.core.Options;
-import org.approvaltests.reporters.DiffReporter;
-import org.approvaltests.reporters.UseReporter;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
import org.springframework.transaction.annotation.Transactional;
import org.apache.causeway.core.config.environment.CausewaySystemEnvironment;
import org.apache.causeway.core.metamodel.specloader.SpecificationLoader;
-import org.apache.causeway.viewer.graphql.viewer.source.GraphQlSourceForCauseway;
+import org.apache.causeway.viewer.graphql.viewer.integration.GraphQlSourceForCauseway;
import static org.apache.causeway.commons.internal.assertions._Assert.assertEquals;
import static org.apache.causeway.commons.internal.assertions._Assert.assertNotNull;
diff --git a/incubator/viewers/graphql/viewer/src/main/java/module-info.java b/incubator/viewers/graphql/viewer/src/main/java/module-info.java
index a6d381a48e..a1bf0e3120 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/module-info.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/module-info.java
@@ -1,6 +1,7 @@
module org.apache.causeway.incubator.viewer.graphql.viewer {
exports org.apache.causeway.viewer.graphql.viewer;
exports org.apache.causeway.viewer.graphql.viewer.source;
+ exports org.apache.causeway.viewer.graphql.viewer.integration;
requires com.fasterxml.jackson.core;
requires com.fasterxml.jackson.databind;
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ExecutionStrategyResolvingWithinInteraction.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/integration/AsyncExecutionStrategyResolvingWithinInteraction.java
similarity index 92%
rename from incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ExecutionStrategyResolvingWithinInteraction.java
rename to incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/integration/AsyncExecutionStrategyResolvingWithinInteraction.java
index d88f289bb3..a94655eb96 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ExecutionStrategyResolvingWithinInteraction.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/integration/AsyncExecutionStrategyResolvingWithinInteraction.java
@@ -16,7 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.causeway.viewer.graphql.viewer.source;
+package org.apache.causeway.viewer.graphql.viewer.integration;
import java.util.concurrent.CompletableFuture;
@@ -34,7 +34,7 @@ import lombok.RequiredArgsConstructor;
@Service
@RequiredArgsConstructor(onConstructor_ = {@Inject})
-public class ExecutionStrategyResolvingWithinInteraction extends AsyncExecutionStrategy {
+public class AsyncExecutionStrategyResolvingWithinInteraction extends AsyncExecutionStrategy {
private final InteractionService interactionService;
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQlServiceForCauseway.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/integration/ExecutionGraphQlServiceForCauseway.java
similarity index 93%
rename from incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQlServiceForCauseway.java
rename to incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/integration/ExecutionGraphQlServiceForCauseway.java
index 281d2f709f..85e06ba3ee 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQlServiceForCauseway.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/integration/ExecutionGraphQlServiceForCauseway.java
@@ -16,7 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.causeway.viewer.graphql.viewer.source;
+package org.apache.causeway.viewer.graphql.viewer.integration;
import javax.inject.Inject;
@@ -36,7 +36,7 @@ import reactor.core.publisher.Mono;
*/
@Service()
@RequiredArgsConstructor(onConstructor_ = {@Inject})
-public class GraphQlServiceForCauseway implements ExecutionGraphQlService {
+public class ExecutionGraphQlServiceForCauseway implements ExecutionGraphQlService {
private final BatchLoaderRegistry batchLoaderRegistry;
private final GraphQlSource graphQlSource;
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQlSourceForCauseway.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/integration/GraphQlSourceForCauseway.java
similarity index 91%
rename from incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQlSourceForCauseway.java
rename to incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/integration/GraphQlSourceForCauseway.java
index 3dc550fa9c..2e697b6a5b 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQlSourceForCauseway.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/integration/GraphQlSourceForCauseway.java
@@ -16,7 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.causeway.viewer.graphql.viewer.source;
+package org.apache.causeway.viewer.graphql.viewer.integration;
import static graphql.schema.FieldCoordinates.coordinates;
import static graphql.schema.GraphQLFieldDefinition.newFieldDefinition;
@@ -33,6 +33,11 @@ import org.apache.causeway.applib.id.HasLogicalType;
import org.apache.causeway.core.metamodel.spec.ObjectSpecification;
+import org.apache.causeway.viewer.graphql.viewer.integration.AsyncExecutionStrategyResolvingWithinInteraction;
+
+import org.apache.causeway.viewer.graphql.viewer.source.ObjectTypeFactory;
+import org.apache.causeway.viewer.graphql.viewer.source.QueryFieldFactory;
+
import org.springframework.graphql.execution.GraphQlSource;
import org.springframework.stereotype.Service;
@@ -44,7 +49,6 @@ import org.apache.causeway.core.metamodel.specloader.SpecificationLoader;
import graphql.GraphQL;
import graphql.Scalars;
-import graphql.execution.instrumentation.tracing.TracingInstrumentation;
import graphql.schema.DataFetcher;
import graphql.schema.GraphQLCodeRegistry;
import graphql.schema.GraphQLObjectType;
@@ -61,7 +65,7 @@ public class GraphQlSourceForCauseway implements GraphQlSource {
private final SpecificationLoader specificationLoader;
private final CausewayConfiguration causewayConfiguration;
private final CausewaySystemEnvironment causewaySystemEnvironment;
- private final ExecutionStrategyResolvingWithinInteraction executionStrategy;
+ private final AsyncExecutionStrategyResolvingWithinInteraction executionStrategy;
private final ObjectTypeFactory objectTypeFactory;
private final QueryFieldFactory queryFieldFactory;
@@ -124,7 +128,10 @@ public class GraphQlSourceForCauseway implements GraphQlSource {
private void handleObjectSpec(
final ObjectSpecification objectSpec,
final Set<GraphQLType> graphQLObjectTypes,
- final GraphQLObjectType.Builder queryBuilder, final GraphQLCodeRegistry.Builder codeRegistryBuilder) {
+ final GraphQLObjectType.Builder queryBuilder,
+ final GraphQLCodeRegistry.Builder codeRegistryBuilder
+ ) {
+
switch (objectSpec.getBeanSort()) {
case ABSTRACT:
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlMeta.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvMeta.java
similarity index 96%
rename from incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlMeta.java
rename to incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvMeta.java
index 4a464fb620..c51c9df2dd 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlMeta.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvMeta.java
@@ -28,8 +28,11 @@ import lombok.Data;
import java.util.Objects;
import java.util.Optional;
+/**
+ * Metadata for every domain object.
+ */
@Data
-public class GqlMeta {
+public class GqlvMeta {
private final Bookmark bookmark;
private final BookmarkService bookmarkService;
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlMutations.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvMutations.java
similarity index 97%
rename from incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlMutations.java
rename to incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvMutations.java
index 27d1cb4e27..49303b7852 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlMutations.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvMutations.java
@@ -26,7 +26,7 @@ import org.apache.causeway.applib.services.bookmark.BookmarkService;
import lombok.Data;
@Data
-public class GqlMutations {
+public class GqlvMutations {
private final Bookmark bookmark;
private final BookmarkService bookmarkService;
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
index 1f77da06ec..adec308cd5 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
@@ -37,14 +37,9 @@ public class GqlvObjectSpec {
}
@Getter private final GraphQLObjectType.Builder objectTypeBuilder;
-
@Getter private final GraphQLObjectType metaType;
- static GqlvObjectSpec gqlv(final ObjectSpecification objectSpec) {
- return new GqlvObjectSpec(objectSpec);
- }
-
- GqlvObjectSpec(final ObjectSpecification objectSpec) {
+ public GqlvObjectSpec(final ObjectSpecification objectSpec) {
this.objectSpec = objectSpec;
this.objectTypeBuilder = newObject().name(getLogicalTypeNameSanitized());
this.metaType = _GraphQLObjectType.create(getLogicalTypeNameSanitized(), getBeanSort());
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
index 919fc90df4..4490daf6c9 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
@@ -54,6 +54,7 @@ import graphql.schema.GraphQLFieldDefinition;
import graphql.schema.GraphQLInputObjectField;
import graphql.schema.GraphQLInputObjectType;
import graphql.schema.GraphQLInputType;
+import graphql.schema.GraphQLNamedType;
import graphql.schema.GraphQLObjectType;
import graphql.schema.GraphQLOutputType;
import graphql.schema.GraphQLType;
@@ -62,10 +63,13 @@ import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.RequiredArgsConstructor;
import lombok.experimental.UtilityClass;
+import lombok.extern.java.Log;
+import lombok.extern.log4j.Log4j2;
import lombok.val;
@Component
@RequiredArgsConstructor(onConstructor_ = {@Inject})
+@Log4j2
public class ObjectTypeFactory {
final static String GQL_INPUTTYPE_PREFIX = "_gql_input__";
@@ -105,13 +109,13 @@ public class ObjectTypeFactory {
final Set<GraphQLType> graphQLObjectTypes,
final GraphQLCodeRegistry.Builder codeRegistryBuilder) {
- val gqlvObjectSpec = GqlvObjectSpec.gqlv(objectSpec);
+ val gqlvObjectSpec = new GqlvObjectSpec(objectSpec);
// create meta field type
- BeanSort objectSpecificationBeanSort = objectSpec.getBeanSort();
+ BeanSort objectSpecificationBeanSort = gqlvObjectSpec.getBeanSort();
final String logicalTypeNameSanitized = gqlvObjectSpec.getLogicalTypeNameSanitized();
- GraphQLObjectType metaType = _GraphQLObjectType.create(logicalTypeNameSanitized, objectSpecificationBeanSort);
+ GraphQLObjectType metaType = gqlvObjectSpec.getMetaType();
addTypeIfNotAlreadyPresent(graphQLObjectTypes, metaType, logicalTypeNameSanitized);
@@ -128,6 +132,7 @@ public class ObjectTypeFactory {
.type(nonNull(Scalars.GraphQLID))
.build());
GraphQLInputType inputType = inputTypeBuilder.build();
+
addTypeIfNotAlreadyPresent(graphQLObjectTypes, inputType, inputTypeName);
// add fields
@@ -166,33 +171,63 @@ public class ObjectTypeFactory {
void addTypeIfNotAlreadyPresent(
final Set<GraphQLType> graphQLObjectTypes,
final GraphQLType typeToAdd,
- final String logicalTypeName){
+ final String logicalTypeName) {
- boolean present;
- if (typeToAdd.getClass().isAssignableFrom(GraphQLObjectType.class)){
- GraphQLObjectType typeToAdd1 = (GraphQLObjectType) typeToAdd;
- present = graphQLObjectTypes.stream()
- .filter(o -> o.getClass().isAssignableFrom(GraphQLObjectType.class))
- .map(GraphQLObjectType.class::cast)
- .filter(ot -> ot.getName().equals(typeToAdd1.getName()))
- .findFirst().isPresent();
- } else {
- // must be input type
- GraphQLInputObjectType typeToAdd1 = (GraphQLInputObjectType) typeToAdd;
- present = graphQLObjectTypes.stream()
- .filter(o -> o.getClass().isAssignableFrom(GraphQLInputObjectType.class))
- .map(GraphQLInputObjectType.class::cast)
- .filter(ot -> ot.getName().equals(typeToAdd1.getName()))
- .findFirst().isPresent();
+ if (typeToAdd instanceof GraphQLObjectType) {
+ addTypeIfNotAlreadyPresent(graphQLObjectTypes, (GraphQLObjectType) typeToAdd, logicalTypeName);
+ return;
+ }
+
+ if (typeToAdd instanceof GraphQLInputObjectType) {
+ addTypeIfNotAlreadyPresent(graphQLObjectTypes, (GraphQLInputObjectType) typeToAdd, logicalTypeName);
+ return;
}
- if (present){
+
+ // TODO: none of these types yet handled
+ // GraphQLTypeReference
+ // GraphQLScalarType
+ // GraphQLCompositeType
+ // GraphQLUnionType
+ // GraphQLEnumType
+ // GraphQLInterfaceType
+ // GraphQLList
+ // GraphQLNonNull
+ log.warn("GraphQLType {} not yet implemented", typeToAdd.getClass().getName());
+ }
+
+ private static void addTypeIfNotAlreadyPresent(
+ final Set<GraphQLType> graphQLObjectTypes,
+ final GraphQLInputObjectType typeToAdd,
+ final String logicalTypeName) {
+ if (isPresent(graphQLObjectTypes, typeToAdd, GraphQLInputObjectType.class)){
// For now we just log and skip
- System.out.println("==== DOUBLE ====");
- System.out.println(logicalTypeName);
+ log.info("GraphQLInputObjectType for {} already present", logicalTypeName);
+ return;
+ }
+ graphQLObjectTypes.add(typeToAdd);
+ }
- } else {
- graphQLObjectTypes.add(typeToAdd);
+ void addTypeIfNotAlreadyPresent(
+ final Set<GraphQLType> graphQLObjectTypes,
+ final GraphQLObjectType typeToAdd,
+ final String logicalTypeName){
+
+ if (isPresent(graphQLObjectTypes, typeToAdd, GraphQLObjectType.class)){
+ // For now we just log and skip
+ log.info("GraphQLObjectType for {} already present", logicalTypeName);
+ return;
}
+ graphQLObjectTypes.add(typeToAdd);
+ }
+
+ private static boolean isPresent(
+ final Set<GraphQLType> graphQLObjectTypes,
+ final GraphQLNamedType typeToAdd,
+ final Class<? extends GraphQLNamedType> cls) {
+ return graphQLObjectTypes.stream()
+ .filter(o -> o.getClass().isAssignableFrom(cls))
+ .map(cls::cast)
+ .anyMatch(ot -> ot.getName().equals(typeToAdd.getName()));
}
void createAndRegisterDataFetchersForField(
@@ -249,7 +284,7 @@ public class ObjectTypeFactory {
//
// Bookmark bookmark = bookmarkService.bookmarkFor(environment.getSource()).orElse(null);
// if (bookmark == null) return null; //TODO: is this correct ?
-// return new GqlMutations(bookmark, bookmarkService, mutatorsTypeFields);
+// return new GqlvMutations(bookmark, bookmarkService, mutatorsTypeFields);
// }
// });
//
@@ -258,7 +293,7 @@ public class ObjectTypeFactory {
// @Override
// public Object get(DataFetchingEnvironment environment) throws Exception {
//
-// GqlMeta gqlMeta = environment.getSource();
+// GqlvMeta gqlMeta = environment.getSource();
//
// return gqlMeta.id();
// }
@@ -404,24 +439,24 @@ public class ObjectTypeFactory {
codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(graphQLObjectType, gql_meta), (DataFetcher<Object>) environment -> {
return bookmarkService.bookmarkFor(environment.getSource())
- .map(bookmark -> new GqlMeta(bookmark, bookmarkService, objectManager))
+ .map(bookmark -> new GqlvMeta(bookmark, bookmarkService, objectManager))
.orElse(null); //TODO: is this correct ?
});
codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(metaType, Fields.id), (DataFetcher<Object>) environment -> {
- GqlMeta gqlMeta = environment.getSource();
- return gqlMeta.id();
+ GqlvMeta gqlvMeta = environment.getSource();
+ return gqlvMeta.id();
});
codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(metaType, Fields.logicalTypeName), (DataFetcher<Object>) environment -> {
- GqlMeta gqlMeta = environment.getSource();
- return gqlMeta.logicalTypeName();
+ GqlvMeta gqlvMeta = environment.getSource();
+ return gqlvMeta.logicalTypeName();
});
if (objectSpecificationBeanSort == BeanSort.ENTITY) {
codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(metaType, Fields.version), (DataFetcher<Object>) environment -> {
- GqlMeta gqlMeta = environment.getSource();
- return gqlMeta.version();
+ GqlvMeta gqlvMeta = environment.getSource();
+ return gqlvMeta.version();
});
}
(causeway) 17/23: CAUSEWAY-3676: removes unused overloads
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit 96928e259a55aa3c5673559fba0e44d0ad6e377f
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Fri Jan 19 11:29:40 2024 +0000
CAUSEWAY-3676: removes unused overloads
---
.../viewer/graphql/viewer/source/GraphQLTypeRegistry.java | 12 ------------
.../viewer/graphql/viewer/source/ObjectTypeFactory.java | 3 +--
2 files changed, 1 insertion(+), 14 deletions(-)
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQLTypeRegistry.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQLTypeRegistry.java
index cfd507e57b..908029d3f4 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQLTypeRegistry.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQLTypeRegistry.java
@@ -25,18 +25,6 @@ public class GraphQLTypeRegistry {
}
-
- void addTypeIfNotAlreadyPresent(
- final GraphQLInputObjectType typeToAdd,
- final String logicalTypeName) {
- if (isPresent(typeToAdd, GraphQLInputObjectType.class)){
- // For now we just log and skip
- log.info("GraphQLInputObjectType for {} already present", logicalTypeName);
- return;
- }
- graphQLObjectTypes.add(typeToAdd);
- }
-
void addTypeIfNotAlreadyPresent(
final GraphQLObjectType typeToAdd,
final String logicalTypeName){
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
index e6adec3a55..38cbc372fd 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
@@ -111,11 +111,10 @@ public class ObjectTypeFactory {
// create meta field type
BeanSort objectSpecificationBeanSort = gqlvObjectSpec.getBeanSort();
- final String logicalTypeNameSanitized = gqlvObjectSpec.getLogicalTypeNameSanitized();
GraphQLObjectType metaType = gqlvObjectSpec.getMetaType();
- graphQLTypeRegistry.addTypeIfNotAlreadyPresent(metaType, logicalTypeNameSanitized);
+ graphQLTypeRegistry.addTypeIfNotAlreadyPresent(gqlvObjectSpec.getMetaType());
// add meta field
val _gql_meta_Field = newFieldDefinition().name("_gql_meta").type(metaType).build();
(causeway) 19/23: CAUSEWAY-3676: wip to considolate gqlvObjectSpec's two declarations of gqlObjectType
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit 9caf30ad1ff9a4c8bcce513a14be65e03429bfea
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Fri Jan 19 11:42:34 2024 +0000
CAUSEWAY-3676: wip to considolate gqlvObjectSpec's two declarations of gqlObjectType
---
.../viewer/graphql/viewer/source/GqlvObjectSpec.java | 16 ++++++++--------
.../viewer/graphql/viewer/source/ObjectTypeFactory.java | 14 +++++++-------
2 files changed, 15 insertions(+), 15 deletions(-)
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
index 6a6a80de08..d2c6712342 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
@@ -36,13 +36,13 @@ public class GqlvObjectSpec {
return objectSpec.getBeanSort();
}
- @Getter private final GraphQLObjectType.Builder objectTypeBuilder;
- @Getter private final GraphQLObjectType metaType;
+ @Getter private final GraphQLObjectType.Builder gqlObjectTypeBuilder;
+ @Getter private final GraphQLObjectType gqlObjectType;
public GqlvObjectSpec(final ObjectSpecification objectSpec) {
this.objectSpec = objectSpec;
- this.objectTypeBuilder = newObject().name(getLogicalTypeNameSanitized());
- this.metaType = _GraphQLObjectType.create(getLogicalTypeNameSanitized(), getBeanSort());
+ this.gqlObjectTypeBuilder = newObject().name(getLogicalTypeNameSanitized());
+ this.gqlObjectType = _GraphQLObjectType.create(getLogicalTypeNameSanitized(), getBeanSort());
}
@@ -67,7 +67,7 @@ public class GqlvObjectSpec {
_LogicalTypeName.sanitized(logicalTypeNameOfField))
: nonNull(GraphQLTypeReference.typeRef(
_LogicalTypeName.sanitized(logicalTypeNameOfField))));
- getObjectTypeBuilder().field(fieldBuilder);
+ getGqlObjectTypeBuilder().field(fieldBuilder);
break;
@@ -80,7 +80,7 @@ public class GqlvObjectSpec {
.type(otoa.isOptional()
? Scalars.GraphQLString
: nonNull(Scalars.GraphQLString));
- getObjectTypeBuilder().field(valueBuilder);
+ getGqlObjectTypeBuilder().field(valueBuilder);
break;
@@ -104,14 +104,14 @@ public class GqlvObjectSpec {
.name(otom.getId())
.type(GraphQLList.list(GraphQLTypeReference.typeRef(
_LogicalTypeName.sanitized(logicalTypeNameOfField))));
- objectTypeBuilder.field(fieldBuilder);
+ gqlObjectTypeBuilder.field(fieldBuilder);
break;
case VALUE:
GraphQLFieldDefinition.Builder valueBuilder = newFieldDefinition()
.name(otom.getId())
.type(GraphQLList.list(TypeMapper.typeFor(elementType.getCorrespondingClass())));
- objectTypeBuilder.field(valueBuilder);
+ gqlObjectTypeBuilder.field(valueBuilder);
break;
}
}
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
index 31344fe9e9..c763b7a9d6 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
@@ -112,13 +112,13 @@ public class ObjectTypeFactory {
// create meta field type
BeanSort objectSpecificationBeanSort = gqlvObjectSpec.getBeanSort();
- GraphQLObjectType metaType = gqlvObjectSpec.getMetaType();
-
- graphQLTypeRegistry.addTypeIfNotAlreadyPresent(gqlvObjectSpec.getMetaType());
-
+ GraphQLObjectType metaType = gqlvObjectSpec.getGqlObjectType();
// add meta field
val _gql_meta_Field = newFieldDefinition().name("_gql_meta").type(metaType).build();
- gqlvObjectSpec.getObjectTypeBuilder().field(_gql_meta_Field);
+ gqlvObjectSpec.getGqlObjectTypeBuilder().field(_gql_meta_Field);
+
+ graphQLTypeRegistry.addTypeIfNotAlreadyPresent(gqlvObjectSpec.getGqlObjectType());
+
// create input type
@@ -141,10 +141,10 @@ public class ObjectTypeFactory {
// add actions
MutatorsDataForEntity mutatorsDataForEntity =
- addActions(gqlvObjectSpec.getLogicalTypeNameSanitized(), objectSpec, gqlvObjectSpec.getObjectTypeBuilder());
+ addActions(gqlvObjectSpec.getLogicalTypeNameSanitized(), objectSpec, gqlvObjectSpec.getGqlObjectTypeBuilder());
// build and register object type
- GraphQLObjectType graphQLObjectType = gqlvObjectSpec.getObjectTypeBuilder().build();
+ GraphQLObjectType graphQLObjectType = gqlvObjectSpec.getGqlObjectTypeBuilder().name(gqlvObjectSpec.getLogicalTypeNameSanitized()).build();
graphQLTypeRegistry.addTypeIfNotAlreadyPresent(graphQLObjectType, gqlvObjectSpec.getLogicalTypeNameSanitized());
(causeway) 02/23: CAUSEWAY-3676: wip, resurrected first end to end test and also dumping the schema
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit 3751b2b5690e55705cee0e90e5de2f56ddb7afaa
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Wed Jan 17 19:35:28 2024 +0000
CAUSEWAY-3676: wip, resurrected first end to end test and also dumping the schema
---
.../causeway/viewer/graphql/viewer/test/.gitignore | 2 +
...ayViewerGraphqlTestModuleIntegTestAbstract.java | 211 +++++
.../viewer/test/{source => }/ScratchPad.java | 2 +-
.../E1.java => domain/Department.java} | 24 +-
.../viewer/test/domain/DepartmentRepository.java | 51 ++
.../gqltestdomain/E2.java => domain/DeptHead.java} | 84 +-
.../viewer/test/domain/DeptHeadRepository.java | 55 ++
.../gqltestdomain => domain}/TestDomainModule.java | 6 +-
.../TopLevelMenu.java} | 35 +-
.../TestEntity.java => domain/WithName.java} | 4 +-
.../WithNameRepository.java} | 28 +-
.../EndToEnd_IntegTest.changeName.approved.json | 0
.../EndToEnd_IntegTest.changeName.submit.gql | 2 +-
.../EndToEnd_IntegTest.createE1.approved.json | 0
.../EndToEnd_IntegTest.createE1.submit.gql | 0
...nd_IntegTest.find_all_departments.approved.json | 21 +
...oEnd_IntegTest.find_all_departments.submit.gql} | 4 +-
.../viewer/test/e2e/EndToEnd_IntegTest.java | 199 +++++
...oEnd_IntegTest.schema_types_name.approved.json} | 188 ++--
...ndToEnd_IntegTest.schema_types_name.submit.gql} | 0
.../introspection-query-request.gql | 0
.../GqlSchema_detail_IntegTest.java} | 60 +-
.../test/schema/GqlSchema_print_IntegTest.java | 87 ++
.../GqlSchema_print_IntegTest.schema.approved.gql} | 54 +-
.../viewer/test/schema/MyWinMergeDiffReporter.java | 28 +
.../viewer/graphql/viewer/test/source/.gitignore | 1 -
...ayViewerGraphqlTestModuleIntegTestAbstract.java | 97 ---
.../EndToEnd_IntegTest.findAllE1.approved.json | 14 -
.../viewer/test/source/EndToEnd_IntegTest.java | 284 -------
.../source/gqltestdomain/TestEntityRepository.java | 77 --
.../viewer/src/test/resources/testfiles/schema.gql | 943 ++++++++++++---------
31 files changed, 1479 insertions(+), 1082 deletions(-)
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/.gitignore b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/.gitignore
new file mode 100644
index 0000000000..837d57bea7
--- /dev/null
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/.gitignore
@@ -0,0 +1,2 @@
+*.received.gql
+*.received.json
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
new file mode 100644
index 0000000000..028d32d3b5
--- /dev/null
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
@@ -0,0 +1,211 @@
+/*
+ * 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.
+ */
+package org.apache.causeway.viewer.graphql.viewer.test;
+
+import lombok.Value;
+import lombok.val;
+
+import java.io.IOException;
+import java.lang.reflect.Method;
+import java.net.URI;
+import java.net.http.HttpClient;
+import java.net.http.HttpRequest;
+import java.net.http.HttpResponse;
+import java.nio.charset.StandardCharsets;
+
+import javax.inject.Inject;
+
+import org.apache.causeway.applib.services.xactn.TransactionService;
+import org.apache.causeway.commons.internal.resources._Resources;
+
+import org.apache.causeway.core.config.environment.CausewaySystemEnvironment;
+import org.apache.causeway.core.metamodel.specloader.SpecificationLoader;
+import org.apache.causeway.viewer.graphql.viewer.source.GraphQlServiceForCauseway;
+import org.apache.causeway.viewer.graphql.viewer.source.GraphQlSourceForCauseway;
+
+import org.approvaltests.core.Options;
+import org.junit.jupiter.api.BeforeEach;
+import org.junit.jupiter.api.MethodOrderer;
+import org.junit.jupiter.api.TestInfo;
+import org.junit.jupiter.api.TestInstance;
+import org.junit.jupiter.api.TestMethodOrder;
+
+import org.springframework.boot.SpringBootConfiguration;
+import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
+import org.springframework.boot.test.autoconfigure.graphql.tester.AutoConfigureHttpGraphQlTester;
+import org.springframework.boot.test.context.SpringBootTest;
+import org.springframework.boot.test.web.server.LocalServerPort;
+import org.springframework.context.annotation.Import;
+import org.springframework.context.annotation.PropertySource;
+import org.springframework.context.annotation.PropertySources;
+import org.springframework.data.jpa.repository.config.EnableJpaRepositories;
+import org.springframework.graphql.test.tester.HttpGraphQlTester;
+import org.springframework.test.context.ActiveProfiles;
+import org.springframework.test.web.reactive.server.WebTestClient;
+
+import org.apache.causeway.core.config.presets.CausewayPresets;
+import org.apache.causeway.core.runtimeservices.CausewayModuleCoreRuntimeServices;
+import org.apache.causeway.persistence.jpa.eclipselink.CausewayModulePersistenceJpaEclipselink;
+import org.apache.causeway.security.bypass.CausewayModuleSecurityBypass;
+import org.apache.causeway.testing.fixtures.applib.CausewayModuleTestingFixturesApplib;
+import org.apache.causeway.viewer.graphql.viewer.CausewayModuleIncViewerGraphqlViewer;
+import org.apache.causeway.viewer.graphql.viewer.test.domain.TestDomainModule;
+
+import com.fasterxml.jackson.core.JsonProcessingException;
+import com.fasterxml.jackson.databind.ObjectMapper;
+
+import static org.apache.causeway.commons.internal.assertions._Assert.assertNotNull;
+
+@SpringBootTest(
+ classes = {
+ CausewayViewerGraphqlTestModuleIntegTestAbstract.TestApp.class
+ },
+ webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT
+)
+@AutoConfigureHttpGraphQlTester
+@TestInstance(TestInstance.Lifecycle.PER_CLASS)
+@TestMethodOrder(MethodOrderer.OrderAnnotation.class)
+@ActiveProfiles("test")
+public abstract class CausewayViewerGraphqlTestModuleIntegTestAbstract {
+
+ /**
+ * Compared to the production app manifest <code>domainapp.webapp.AppManifest</code>,
+ * here we in effect disable security checks, and we exclude any web/UI modules.
+ */
+ @SpringBootConfiguration
+ @EnableAutoConfiguration
+ @EnableJpaRepositories
+ @Import({
+
+ CausewayModuleCoreRuntimeServices.class,
+ CausewayModuleSecurityBypass.class,
+ CausewayModulePersistenceJpaEclipselink.class,
+ CausewayModuleTestingFixturesApplib.class,
+ CausewayModuleIncViewerGraphqlViewer.class,
+
+ TestDomainModule.class
+ })
+ @PropertySources({
+ @PropertySource(CausewayPresets.H2InMemory_withUniqueSchema),
+ @PropertySource(CausewayPresets.UseLog4j2Test),
+ @PropertySource(CausewayPresets.SilenceMetaModel),
+ @PropertySource(CausewayPresets.SilenceProgrammingModel),
+ })
+ public static class TestApp {
+
+ }
+
+ @Inject protected CausewaySystemEnvironment causewaySystemEnvironment;
+ @Inject protected SpecificationLoader specificationLoader;
+ @Inject protected TransactionService transactionService;
+ @Inject protected GraphQlSourceForCauseway graphQlSourceForCauseway;
+ @Inject protected GraphQlServiceForCauseway graphQlServiceForCauseway;
+
+ @LocalServerPort
+ protected int port;
+
+ @BeforeEach
+ void init(final TestInfo testInfo) {
+ this.testInfo = testInfo;
+ assertNotNull(causewaySystemEnvironment);
+ assertNotNull(specificationLoader);
+ assertNotNull(transactionService);
+ assertNotNull(graphQlSourceForCauseway);
+ assertNotNull(graphQlServiceForCauseway);
+ }
+
+
+ /**
+ * Populated automatically by JUnit5
+ */
+ protected TestInfo testInfo;
+
+ private ObjectMapper objectMapper = new ObjectMapper();
+
+ protected HttpGraphQlTester graphQlTester() {
+ WebTestClient client =
+ WebTestClient.bindToServer()
+ .baseUrl("http://0.0.0.0:" + port + "/graphql")
+ .build();
+ return HttpGraphQlTester.create(client);
+ }
+
+
+ /**
+ * Builds an HTTP request based on the current {@link TestInfo}, with suffix <code>.submit.gql</code>,
+ * and unmarshalls the response as a string
+ *
+ * @return the response body as a string
+ * @throws Exception if an error occurs during the submission
+ */
+ protected String submit() throws Exception{
+ val httpRequest = buildRequest(testInfo, ".submit.gql");
+ return submitRequest(httpRequest);
+ }
+
+ @Value
+ protected static class GqlBody {
+ String query;
+ }
+
+ protected HttpRequest buildRequest(
+ final TestInfo testInfo,
+ final String resourceSuffix) throws IOException {
+
+ val testMethodName = testInfo.getTestMethod().map(Method::getName).get();
+ val resourceName = getClass().getSimpleName() + "." + testMethodName + resourceSuffix;
+ val resourceContents = readResource(resourceName);
+
+ val uri = URI.create(String.format("http://0.0.0.0:%d/graphql", port));
+
+ val gqlBody = new GqlBody(resourceContents);
+ val gqlBodyStr = objectMapper.writeValueAsString(gqlBody);
+ val bodyPublisher = HttpRequest.BodyPublishers.ofString(gqlBodyStr);
+
+ return HttpRequest.newBuilder().
+ uri(uri).
+ POST(bodyPublisher).
+ setHeader("Content-Type", "application/json").
+ build();
+ }
+
+ private String submitRequest(final HttpRequest request) throws IOException, InterruptedException {
+ val responseBodyHandler = HttpResponse.BodyHandlers.ofString();
+ val httpClient = HttpClient.newBuilder().build();
+ val httpResponse = httpClient.send(request, responseBodyHandler);
+ return httpResponse.body();
+ }
+
+ private String readResource(final String resourceName) throws IOException {
+ return _Resources.loadAsString(getClass(), resourceName, StandardCharsets.UTF_8);
+ }
+
+ protected Options jsonOptions() {
+ return new Options().withScrubber(s -> {
+ try {
+ return objectMapper.writerWithDefaultPrettyPrinter().writeValueAsString(objectMapper.readTree(s));
+ } catch (JsonProcessingException e) {
+ throw new RuntimeException(e);
+ }
+ })
+ .forFile().withExtension(".json");
+ }
+
+
+}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/ScratchPad.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/ScratchPad.java
similarity index 97%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/ScratchPad.java
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/ScratchPad.java
index 824f1b4bc1..a0df76afc2 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/ScratchPad.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/ScratchPad.java
@@ -16,7 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.causeway.viewer.graphql.viewer.test.source;
+package org.apache.causeway.viewer.graphql.viewer.test;
import java.util.ArrayList;
import java.util.HashSet;
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/E1.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/Department.java
similarity index 74%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/E1.java
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/Department.java
index 2cb68b146c..c9779a8921 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/E1.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/Department.java
@@ -16,9 +16,8 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.causeway.viewer.graphql.viewer.test.source.gqltestdomain;
+package org.apache.causeway.viewer.graphql.viewer.test.domain;
-import javax.inject.Named;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
@@ -31,17 +30,24 @@ import org.apache.causeway.applib.annotation.Nature;
import org.apache.causeway.applib.annotation.Property;
import lombok.Getter;
+import lombok.NoArgsConstructor;
import lombok.Setter;
//@Profile("demo-jpa")
@Entity
@Table(
schema = "public",
- name = "E1"
+ name = "Department"
)
-@Named("gqltestdomain.E1")
+@javax.inject.Named("gql.test.domain.Department")
+@NoArgsConstructor
@DomainObject(nature = Nature.ENTITY)
-public class E1 implements TestEntity, Comparable {
+public class Department implements WithName, Comparable {
+
+ public Department(String name, DeptHead deptHead) {
+ this.name = name;
+ this.deptHead = deptHead;
+ }
@Id
@GeneratedValue
@@ -53,12 +59,12 @@ public class E1 implements TestEntity, Comparable {
@Getter @Setter
@Property
@OneToOne(optional = true)
- @JoinColumn(name = "e2_id")
- private E2 e2;
+ @JoinColumn(name = "employee_id")
+ private DeptHead deptHead;
@Override
public int compareTo(final Object o) {
- E1 e1 = (E1) o;
- return this.getName().compareTo(e1.getName());
+ Department department = (Department) o;
+ return this.getName().compareTo(department.getName());
}
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DepartmentRepository.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DepartmentRepository.java
new file mode 100644
index 0000000000..3b18e6c5ee
--- /dev/null
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DepartmentRepository.java
@@ -0,0 +1,51 @@
+/*
+ * 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.
+ */
+package org.apache.causeway.viewer.graphql.viewer.test.domain;
+
+import java.util.List;
+
+import javax.inject.Inject;
+
+import org.springframework.lang.Nullable;
+import org.springframework.stereotype.Repository;
+
+import org.apache.causeway.applib.services.repository.RepositoryService;
+
+@Repository
+public class DepartmentRepository {
+
+ @Inject private RepositoryService repositoryService;
+
+ public Department create(final String name, @Nullable final DeptHead deptHead) {
+ Department department = new Department(name, deptHead);
+ department.setName(name);
+ department.setDeptHead(deptHead);
+ repositoryService.persistAndFlush(department);
+ return department;
+ }
+
+ public List<Department> findAll() {
+ return repositoryService.allInstances(Department.class);
+ }
+
+ public void removeAll(){
+ repositoryService.removeAll(Department.class);
+ }
+
+}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/E2.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHead.java
similarity index 55%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/E2.java
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHead.java
index 157b8ee882..ad82f41393 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/E2.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHead.java
@@ -16,27 +16,23 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.causeway.viewer.graphql.viewer.test.source.gqltestdomain;
+package org.apache.causeway.viewer.graphql.viewer.test.domain;
-import java.util.ArrayList;
import java.util.List;
import java.util.stream.Collectors;
import javax.inject.Inject;
-import javax.inject.Named;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
-import javax.persistence.OneToMany;
import javax.persistence.OneToOne;
import javax.persistence.Table;
import javax.persistence.Transient;
import org.apache.causeway.applib.annotation.Action;
import org.apache.causeway.applib.annotation.Bounding;
-import org.apache.causeway.applib.annotation.Collection;
import org.apache.causeway.applib.annotation.DomainObject;
import org.apache.causeway.applib.annotation.Nature;
import org.apache.causeway.applib.annotation.Property;
@@ -45,15 +41,14 @@ import org.apache.causeway.applib.annotation.SemanticsOf;
import lombok.Getter;
import lombok.Setter;
-//@Profile("demo-jpa")
@Entity
@Table(
schema = "public",
- name = "E2"
+ name = "DeptHead"
)
-@Named("gqltestdomain.E2")
+@javax.inject.Named("gql.test.domain.DeptHead")
@DomainObject(nature = Nature.ENTITY, bounding = Bounding.BOUNDED)
-public class E2 implements TestEntity{
+public class DeptHead implements WithName {
@Id
@GeneratedValue
@@ -66,56 +61,45 @@ public class E2 implements TestEntity{
@Getter @Setter
@Property
@OneToOne(optional = true)
- @JoinColumn(name = "e1_id")
- private E1 e1;
+ @JoinColumn(name = "department_id")
+ private Department department;
- @Action(semantics = SemanticsOf.IDEMPOTENT)
- public E2 changeName(final String newName){
- setName(newName);
- return this;
- }
-
- public String default0ChangeName(){
- return getName();
- }
@Action(semantics = SemanticsOf.IDEMPOTENT)
- public E2 changeE1(final E1 e1){
- setE1(e1);
- return this;
- }
+ public class changeName {
- public List<E1> choices0ChangeE1(){
- return testEntityRepository.findAllE1().stream().filter(e->e!=getE1()).collect(Collectors.toList());
- }
+ public DeptHead act(final String newName){
+ setName(newName);
+ return DeptHead.this;
+ }
- public String validateChangeE1(final E1 e1){
- if (getE1() == e1) return "Already there";
- return null;
+ public String default0Act(){
+ return getName();
+ }
}
- @OneToMany
- @Getter @Setter
- private List<E2> otherE2List = new ArrayList<>();
-
- @Getter @Setter
- @Collection
- private List<String> stringList = new ArrayList<>();
- @Getter @Setter
- @Collection
- private List<Integer> zintList = new ArrayList<>();
-
- @Action(semantics = SemanticsOf.SAFE)
- public List<TestEntity> otherEntities(){
- List<TestEntity> result = new ArrayList<>();
- result.addAll(testEntityRepository.findAllE1());
- result.addAll(testEntityRepository.findAllE2().stream().filter(e2->e2!=this).collect(Collectors.toList()));
- return result;
+ @Action(semantics = SemanticsOf.IDEMPOTENT)
+ public class changeDeptHead {
+
+ public DeptHead act(final Department department){
+ setDepartment(department);
+ return DeptHead.this;
+ }
+
+ public List<Department> choices0Act(){
+ return departmentRepository.findAll().stream().
+ filter(d -> d != getDepartment()).
+ collect(Collectors.toList());
+ }
+
+ public String validateAct(final Department department){
+ if (getDepartment() == department) return "Already there";
+ return null;
+ }
}
- @Inject
- @Transient
- TestEntityRepository testEntityRepository;
+
+ @Inject @Transient DepartmentRepository departmentRepository;
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHeadRepository.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHeadRepository.java
new file mode 100644
index 0000000000..e96e0110c8
--- /dev/null
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/DeptHeadRepository.java
@@ -0,0 +1,55 @@
+/*
+ * 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.
+ */
+package org.apache.causeway.viewer.graphql.viewer.test.domain;
+
+import java.util.List;
+
+import javax.inject.Inject;
+
+import org.springframework.lang.Nullable;
+import org.springframework.stereotype.Repository;
+
+import org.apache.causeway.applib.services.repository.RepositoryService;
+
+@Repository
+public class DeptHeadRepository {
+
+ @Inject private RepositoryService repositoryService;
+
+ public DeptHead create(final String name, @Nullable final Department department) {
+ DeptHead deptHead = new DeptHead();
+ deptHead.setName(name);
+ deptHead.setDepartment(department);
+ repositoryService.persistAndFlush(deptHead);
+ return deptHead;
+ }
+
+ public List<DeptHead> findAll() {
+ return repositoryService.allInstances(DeptHead.class);
+ }
+
+ public void removeAll(){
+ repositoryService.removeAll(DeptHead.class);
+ }
+
+ public DeptHead findByName(final String name){
+ return findAll().stream().filter(e2->e2.getName().equals(name)).findFirst().orElse(null);
+ }
+
+}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/TestDomainModule.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/TestDomainModule.java
similarity index 89%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/TestDomainModule.java
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/TestDomainModule.java
index 26ebcf8225..537ef8fe12 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/TestDomainModule.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/TestDomainModule.java
@@ -16,7 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.causeway.viewer.graphql.viewer.test.source.gqltestdomain;
+package org.apache.causeway.viewer.graphql.viewer.test.domain;
import org.springframework.boot.autoconfigure.domain.EntityScan;
import org.springframework.context.annotation.ComponentScan;
@@ -37,8 +37,8 @@ public class TestDomainModule implements ModuleWithFixtures {
return new FixtureScript() {
@Override
protected void execute(ExecutionContext executionContext) {
- repositoryService.removeAll(E1.class);
- repositoryService.removeAll(E2.class);
+ repositoryService.removeAll(Department.class);
+ repositoryService.removeAll(DeptHead.class);
}
};
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/GQLTestDomainMenu.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/TopLevelMenu.java
similarity index 66%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/GQLTestDomainMenu.java
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/TopLevelMenu.java
index 8ff8d37593..baab6cca13 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/GQLTestDomainMenu.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/TopLevelMenu.java
@@ -16,7 +16,7 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.causeway.viewer.graphql.viewer.test.source.gqltestdomain;
+package org.apache.causeway.viewer.graphql.viewer.test.domain;
import java.util.List;
@@ -33,39 +33,44 @@ import org.apache.causeway.applib.annotation.SemanticsOf;
import lombok.RequiredArgsConstructor;
-@Named("gqltestdomain.GQLTestDomainMenu")
+@Named("gql.test.domain.TopLevelMenu")
@DomainService(
nature=NatureOfService.VIEW)
@javax.annotation.Priority(PriorityPrecedence.EARLY)
@RequiredArgsConstructor(onConstructor_ = {@Inject})
-public class GQLTestDomainMenu {
+public class TopLevelMenu {
+
+ final DepartmentRepository departmentRepository;
+ final DeptHeadRepository deptHeadRepository;
+ final WithNameRepository withNameRepository;
@Action(semantics = SemanticsOf.NON_IDEMPOTENT)
- public E1 createE1(final String name, @Nullable final E2 e2){
- return testEntityRepository.createE1(name, e2);
+ public Department createDepartment(
+ final String name,
+ @Nullable final DeptHead deptHead
+ ){
+ return departmentRepository.create(name, deptHead);
}
@Action(semantics = SemanticsOf.SAFE)
- public List<E1> findAllE1(){
- return testEntityRepository.findAllE1();
+ public List<Department> findAllDepartments(){
+ return departmentRepository.findAll();
}
@Action(semantics = SemanticsOf.SAFE)
- public List<E2> findAllE2(){
- return testEntityRepository.findAllE2();
+ public List<DeptHead> findAllDeptHeads(){
+ return deptHeadRepository.findAll();
}
@Action(semantics = SemanticsOf.SAFE)
- public List<TestEntity> findAllTestEntities(){
- return testEntityRepository.findAllTestEntities();
+ public List<WithName> findAllEntitiesWithName(){
+ return withNameRepository.findAll();
}
@Action(semantics = SemanticsOf.SAFE)
- public E2 findE2(final String name){
- return testEntityRepository.findE2ByName(name);
+ public DeptHead findDeptHeadByName(final String name){
+ return deptHeadRepository.findByName(name);
}
- @Inject
- TestEntityRepository testEntityRepository;
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/TestEntity.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/WithName.java
similarity index 88%
copy from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/TestEntity.java
copy to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/WithName.java
index b6ebc7575a..aeb7dabdec 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/TestEntity.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/WithName.java
@@ -16,9 +16,9 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.causeway.viewer.graphql.viewer.test.source.gqltestdomain;
+package org.apache.causeway.viewer.graphql.viewer.test.domain;
-public interface TestEntity {
+public interface WithName {
public String getName();
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/TestEntity.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/WithNameRepository.java
similarity index 53%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/TestEntity.java
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/WithNameRepository.java
index b6ebc7575a..fe5bf15b0c 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/TestEntity.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/domain/WithNameRepository.java
@@ -16,10 +16,32 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.causeway.viewer.graphql.viewer.test.source.gqltestdomain;
+package org.apache.causeway.viewer.graphql.viewer.test.domain;
-public interface TestEntity {
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.inject.Inject;
+
+import org.springframework.stereotype.Repository;
+
+@Repository
+public class WithNameRepository {
+
+ @Inject private DepartmentRepository departmentRepository;
+ @Inject private DeptHeadRepository deptHeadRepository;
+
+ public List<WithName> findAll() {
+ final List<WithName> result = new ArrayList<>();
+ result.addAll(departmentRepository.findAll());
+ result.addAll(deptHeadRepository.findAll());
+ return result;
+ }
+
+ public void removeAll(){
+ departmentRepository.removeAll();
+ deptHeadRepository.removeAll();
+ }
- public String getName();
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.changeName.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.changeName.approved.json
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.changeName.approved.json
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.changeName.approved.json
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.changeName.submit.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.changeName.submit.gql
similarity index 89%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.changeName.submit.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.changeName.submit.gql
index e2b8760084..ffc29ff7f8 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.changeName.submit.gql
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.changeName.submit.gql
@@ -4,7 +4,7 @@
name_gql_mutations {
changeName(newName:"bar") {
name
- e1 {
+ department {
name
}
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.createE1.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.createE1.approved.json
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.createE1.approved.json
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.createE1.approved.json
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.createE1.submit.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.createE1.submit.gql
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.createE1.submit.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.createE1.submit.gql
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.find_all_departments.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.find_all_departments.approved.json
new file mode 100644
index 0000000000..eace6ed631
--- /dev/null
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.find_all_departments.approved.json
@@ -0,0 +1,21 @@
+{
+ "data" : {
+ "gql_test_domain_TopLevelMenu" : {
+ "findAllDepartments" : [ {
+ "name" : "foo",
+ "_gql_meta" : {
+ "id" : "1",
+ "logicalTypeName" : "gql.test.domain.Department",
+ "version" : null
+ }
+ }, {
+ "name" : "bar",
+ "_gql_meta" : {
+ "id" : "2",
+ "logicalTypeName" : "gql.test.domain.Department",
+ "version" : null
+ }
+ } ]
+ }
+ }
+}
\ No newline at end of file
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.findAllE1.submit.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.find_all_departments.submit.gql
similarity index 65%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.findAllE1.submit.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.find_all_departments.submit.gql
index 38e7907d5b..c921e5677d 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.findAllE1.submit.gql
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.find_all_departments.submit.gql
@@ -1,6 +1,6 @@
{
- gqltestdomain_GQLTestDomainMenu {
- findAllE1 {
+ gql_test_domain_TopLevelMenu {
+ findAllDepartments {
name
_gql_meta {
id
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.java
new file mode 100644
index 0000000000..b4bedbfa57
--- /dev/null
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.java
@@ -0,0 +1,199 @@
+/*
+ * 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.
+ */
+package org.apache.causeway.viewer.graphql.viewer.test.e2e;
+
+import java.io.IOException;
+import java.lang.reflect.Method;
+import java.net.URI;
+import java.net.http.HttpClient;
+import java.net.http.HttpRequest;
+import java.net.http.HttpResponse;
+import java.nio.charset.StandardCharsets;
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.inject.Inject;
+
+import com.fasterxml.jackson.core.JsonProcessingException;
+import com.fasterxml.jackson.databind.ObjectMapper;
+
+import org.apache.causeway.viewer.graphql.viewer.source.GraphQlServiceForCauseway;
+
+import org.apache.causeway.viewer.graphql.viewer.test.CausewayViewerGraphqlTestModuleIntegTestAbstract;
+
+import org.apache.causeway.viewer.graphql.viewer.test.domain.Department;
+
+import org.apache.causeway.viewer.graphql.viewer.test.domain.DeptHead;
+import org.apache.causeway.viewer.graphql.viewer.test.domain.DepartmentRepository;
+
+import org.apache.causeway.viewer.graphql.viewer.test.domain.DeptHeadRepository;
+
+import org.apache.causeway.viewer.graphql.viewer.test.schema.MyWinMergeDiffReporter;
+
+import org.approvaltests.Approvals;
+import org.approvaltests.core.Options;
+import org.approvaltests.reporters.DiffReporter;
+import org.approvaltests.reporters.TextWebReporter;
+import org.approvaltests.reporters.UseReporter;
+import org.junit.jupiter.api.AfterEach;
+import org.junit.jupiter.api.BeforeEach;
+import org.junit.jupiter.api.Test;
+import org.junit.jupiter.api.TestInfo;
+import org.junit.jupiter.api.condition.DisabledIfSystemProperty;
+
+import org.springframework.test.context.ActiveProfiles;
+import org.springframework.transaction.annotation.Propagation;
+
+import org.apache.causeway.applib.services.xactn.TransactionService;
+import org.apache.causeway.commons.internal.resources._Resources;
+import org.apache.causeway.core.config.environment.CausewaySystemEnvironment;
+import org.apache.causeway.core.metamodel.specloader.SpecificationLoader;
+import org.apache.causeway.viewer.graphql.viewer.source.GraphQlSourceForCauseway;
+import org.apache.causeway.viewer.graphql.viewer.test.domain.TopLevelMenu;
+
+import static org.apache.causeway.commons.internal.assertions._Assert.assertEquals;
+import static org.apache.causeway.commons.internal.assertions._Assert.assertNotNull;
+import static org.apache.causeway.commons.internal.assertions._Assert.assertTrue;
+
+import static org.assertj.core.api.AssertionsForInterfaceTypes.assertThat;
+
+import lombok.Value;
+import lombok.val;
+
+
+//NOT USING @Transactional since we are running server within same transaction otherwise
+@ActiveProfiles("test")
+public class EndToEnd_IntegTest extends CausewayViewerGraphqlTestModuleIntegTestAbstract {
+
+ @Inject DepartmentRepository departmentRepository;
+ @Inject DeptHeadRepository deptHeadRepository;
+ @Inject TopLevelMenu topLevelMenu;
+
+ @AfterEach
+ void afterEach(){
+ transactionService.runTransactional(Propagation.REQUIRED, () -> {
+ departmentRepository.removeAll();
+ deptHeadRepository.removeAll();
+ });
+ }
+
+ @Test
+ @UseReporter({MyWinMergeDiffReporter.class, DiffReporter.class})
+ void schema_types_name() throws Exception {
+ Approvals.verify(submit(), jsonOptions());
+ }
+
+
+ @Test
+ @UseReporter({MyWinMergeDiffReporter.class, DiffReporter.class})
+ void find_all_departments() throws Exception {
+
+ // given
+ transactionService.runTransactional(Propagation.REQUIRED, () -> {
+
+ departmentRepository.create("foo", null);
+ departmentRepository.create("bar", null);
+ transactionService.flushTransaction();
+
+ List<Department> allDepartment = departmentRepository.findAll();
+ assertThat(allDepartment).hasSize(2);
+
+ List<DeptHead> allDeptHead = deptHeadRepository.findAll();
+ assertThat(allDeptHead).isEmpty();
+ });
+
+ // when, then
+ Approvals.verify(submit(), jsonOptions());
+ }
+
+ //TODO started to fail on 2022-09-04, with testEntityRepository findAll being empty
+ @Test @DisabledIfSystemProperty(named = "isRunningWithSurefire", matches = "true")
+ @UseReporter(TextWebReporter.class)
+ void createE1() throws Exception {
+
+ //File targetFile3 = new File("src/test/resources/testfiles/targetFile3.gql");
+
+ String response1 = transactionService.callTransactional(Propagation.REQUIRED, () -> {
+
+ String submit = submit();
+ // just to show we need to query in separate tranasction
+ List<DeptHead> list = deptHeadRepository.findAll();
+ assertTrue(list.isEmpty());
+ return submit;
+
+ }).ifFailureFail().getValue().get();
+
+ final List<Department> allDepartment = new ArrayList<>();
+ transactionService.runTransactional(Propagation.REQUIRED, () -> {
+
+ List<Department> all = departmentRepository.findAll();
+ allDepartment.addAll(all);
+
+ });
+
+ assertEquals(1, allDepartment.size());
+ assertEquals("newbee", allDepartment.get(0).getName());
+
+ Approvals.verify(response1, jsonOptions());
+
+ }
+
+ //TODO started to fail on 2023-07-25
+ //disabled to rescue CI build
+ @Test @DisabledIfSystemProperty(named = "isRunningWithSurefire", matches = "true")
+ @UseReporter(TextWebReporter.class)
+ void changeName() throws Exception {
+
+ List<DeptHead> deptHeadList = new ArrayList<>();
+
+ transactionService.runTransactional(Propagation.REQUIRED, () -> {
+
+ deptHeadList.add(deptHeadRepository.create("foo", null));
+
+ });
+
+ DeptHead deptHead = deptHeadList.get(0);
+ assertEquals("foo", deptHead.getName());
+ assertEquals(deptHead.getName(), topLevelMenu.findDeptHeadByName("foo").getName());
+
+ String response = transactionService.callTransactional(Propagation.REQUIRED, () -> {
+
+ return submit();
+
+ }).ifFailureFail().getValue().get();
+
+ deptHeadList.clear();
+ transactionService.runTransactional(Propagation.REQUIRED, () -> {
+
+ List<DeptHead> all = deptHeadRepository.findAll();
+ deptHeadList.addAll(all);
+
+ });
+
+ DeptHead deptHeadModified = deptHeadList.get(0);
+
+ //TODO: implement ...
+// assertEquals("bar", deptHeadModified.getName());
+//
+// Approvals.verify(response, new Options());
+
+ }
+
+
+}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.simple_post_request.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.schema_types_name.approved.json
similarity index 53%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.simple_post_request.approved.json
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.schema_types_name.approved.json
index 9dca72bb91..57aa17d2bb 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.simple_post_request.approved.json
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.schema_types_name.approved.json
@@ -27,22 +27,10 @@
"name" : "__Type"
}, {
"name" : "__TypeKind"
- }, {
- "name" : "_gql_input__gqltestdomain_E1"
- }, {
- "name" : "_gql_input__gqltestdomain_E2"
- }, {
- "name" : "_gql_input__causeway_applib_ActionNode"
- }, {
- "name" : "_gql_input__causeway_applib_CollectionNode"
}, {
"name" : "_gql_input__causeway_applib_DomainObjectList"
- }, {
- "name" : "_gql_input__causeway_applib_FacetAttrNode"
}, {
"name" : "_gql_input__causeway_applib_FacetGroupNode"
- }, {
- "name" : "_gql_input__causeway_applib_FacetNode"
}, {
"name" : "_gql_input__causeway_applib_ParameterNode"
}, {
@@ -53,6 +41,14 @@
"name" : "_gql_input__causeway_applib_TypeNode"
}, {
"name" : "_gql_input__causeway_applib_UserMemento"
+ }, {
+ "name" : "_gql_input__causeway_applib_node_ActionNode"
+ }, {
+ "name" : "_gql_input__causeway_applib_node_CollectionNode"
+ }, {
+ "name" : "_gql_input__causeway_applib_node_FacetAttrNode"
+ }, {
+ "name" : "_gql_input__causeway_applib_node_FacetNode"
}, {
"name" : "_gql_input__causeway_conf_ConfigurationProperty"
}, {
@@ -71,74 +67,64 @@
"name" : "_gql_input__causeway_feat_ApplicationTypeMember"
}, {
"name" : "_gql_input__causeway_feat_ApplicationTypeProperty"
+ }, {
+ "name" : "_gql_input__causeway_schema_metamodel_v2_DomainClassDto"
}, {
"name" : "_gql_input__causeway_security_LoginRedirect"
}, {
"name" : "_gql_input__causeway_testing_fixtures_FixtureResult"
}, {
- "name" : "_gql_input__java_util_SortedMap"
+ "name" : "_gql_input__gql_test_domain_Department"
}, {
- "name" : "_gql_input__java_util_stream_Stream"
+ "name" : "_gql_input__gql_test_domain_DeptHead"
}, {
- "name" : "_gql_input__org_apache_causeway_applib_services_inject_ServiceInjector"
- }, {
- "name" : "_gql_input__org_apache_causeway_core_metamodel_inspect_model_MMNode"
+ "name" : "_gql_input__java_lang_Runnable"
}, {
- "name" : "_gql_input__org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript"
+ "name" : "_gql_input__java_util_Map"
}, {
- "name" : "_gql_input__org_apache_causeway_viewer_graphql_viewer_source_gqltestdomain_TestEntity"
+ "name" : "_gql_input__java_util_SortedMap"
}, {
- "name" : "gqltestdomain_E1"
+ "name" : "_gql_input__java_util_concurrent_Callable"
}, {
- "name" : "gqltestdomain_E1__DomainObject_meta"
+ "name" : "_gql_input__java_util_function_BiFunction"
}, {
- "name" : "gqltestdomain_E2"
+ "name" : "_gql_input__java_util_function_Consumer"
}, {
- "name" : "gqltestdomain_E2__DomainObject_meta"
+ "name" : "_gql_input__java_util_function_Function"
}, {
- "name" : "gqltestdomain_E2__DomainObject_mutators"
+ "name" : "_gql_input__java_util_stream_Stream"
}, {
- "name" : "gqltestdomain_GQLTestDomainMenu"
+ "name" : "_gql_input__org_apache_causeway_commons_functional_Either"
}, {
- "name" : "causeway_applib_ActionNode"
+ "name" : "_gql_input__org_apache_causeway_commons_functional_Railway"
}, {
- "name" : "causeway_applib_ActionNode__DomainObject_meta"
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingConsumer"
}, {
- "name" : "causeway_applib_ActionNode__DomainObject_mutators"
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingFunction"
}, {
- "name" : "causeway_applib_CollectionNode"
+ "name" : "_gql_input__org_apache_causeway_commons_functional_ThrowingRunnable"
}, {
- "name" : "causeway_applib_CollectionNode__DomainObject_meta"
+ "name" : "_gql_input__org_apache_causeway_commons_functional_Try"
}, {
- "name" : "causeway_applib_CollectionNode__DomainObject_mutators"
+ "name" : "_gql_input__org_apache_causeway_core_metamodel_inspect_model_MMNode"
}, {
- "name" : "causeway_applib_DomainObjectList"
+ "name" : "_gql_input__org_apache_causeway_core_metamodel_inspect_model_MemberNode"
}, {
- "name" : "causeway_applib_DomainObjectList__DomainObject_meta"
+ "name" : "_gql_input__org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript"
}, {
- "name" : "causeway_applib_FacetAttrNode"
+ "name" : "_gql_input__org_apache_causeway_viewer_graphql_viewer_test_domain_WithName"
}, {
- "name" : "causeway_applib_FacetAttrNode__DomainObject_meta"
+ "name" : "causeway_applib_DomainObjectList"
}, {
- "name" : "causeway_applib_FacetAttrNode__DomainObject_mutators"
+ "name" : "causeway_applib_DomainObjectList__DomainObject_meta"
}, {
"name" : "causeway_applib_FacetGroupNode"
}, {
"name" : "causeway_applib_FacetGroupNode__DomainObject_meta"
- }, {
- "name" : "causeway_applib_FacetGroupNode__DomainObject_mutators"
- }, {
- "name" : "causeway_applib_FacetNode"
- }, {
- "name" : "causeway_applib_FacetNode__DomainObject_meta"
- }, {
- "name" : "causeway_applib_FacetNode__DomainObject_mutators"
}, {
"name" : "causeway_applib_ParameterNode"
}, {
"name" : "causeway_applib_ParameterNode__DomainObject_meta"
- }, {
- "name" : "causeway_applib_ParameterNode__DomainObject_mutators"
}, {
"name" : "causeway_applib_PropertyNode"
}, {
@@ -153,14 +139,32 @@
"name" : "causeway_applib_TypeNode"
}, {
"name" : "causeway_applib_TypeNode__DomainObject_meta"
- }, {
- "name" : "causeway_applib_TypeNode__DomainObject_mutators"
}, {
"name" : "causeway_applib_UserMemento"
}, {
"name" : "causeway_applib_UserMemento__DomainObject_meta"
}, {
"name" : "causeway_applib_UserMenu"
+ }, {
+ "name" : "causeway_applib_node_ActionNode"
+ }, {
+ "name" : "causeway_applib_node_ActionNode__DomainObject_meta"
+ }, {
+ "name" : "causeway_applib_node_ActionNode__DomainObject_mutators"
+ }, {
+ "name" : "causeway_applib_node_CollectionNode"
+ }, {
+ "name" : "causeway_applib_node_CollectionNode__DomainObject_meta"
+ }, {
+ "name" : "causeway_applib_node_CollectionNode__DomainObject_mutators"
+ }, {
+ "name" : "causeway_applib_node_FacetAttrNode"
+ }, {
+ "name" : "causeway_applib_node_FacetAttrNode__DomainObject_meta"
+ }, {
+ "name" : "causeway_applib_node_FacetNode"
+ }, {
+ "name" : "causeway_applib_node_FacetNode__DomainObject_meta"
}, {
"name" : "causeway_conf_ConfigurationMenu"
}, {
@@ -199,6 +203,10 @@
"name" : "causeway_feat_ApplicationTypeProperty__DomainObject_meta"
}, {
"name" : "causeway_feat_ApplicationType__DomainObject_meta"
+ }, {
+ "name" : "causeway_schema_metamodel_v2_DomainClassDto"
+ }, {
+ "name" : "causeway_schema_metamodel_v2_DomainClassDto__DomainObject_meta"
}, {
"name" : "causeway_security_LoginRedirect"
}, {
@@ -209,33 +217,105 @@
"name" : "causeway_testing_fixtures_FixtureResult"
}, {
"name" : "causeway_testing_fixtures_FixtureResult__DomainObject_meta"
+ }, {
+ "name" : "gql_test_domain_Department"
+ }, {
+ "name" : "gql_test_domain_Department__DomainObject_meta"
+ }, {
+ "name" : "gql_test_domain_DeptHead"
+ }, {
+ "name" : "gql_test_domain_DeptHead__DomainObject_meta"
+ }, {
+ "name" : "gql_test_domain_DeptHead__DomainObject_mutators"
+ }, {
+ "name" : "gqltestdomain_GQLTestDomainMenu"
+ }, {
+ "name" : "java_lang_Runnable"
+ }, {
+ "name" : "java_lang_Runnable__DomainObject_meta"
+ }, {
+ "name" : "java_util_Map"
+ }, {
+ "name" : "java_util_Map__DomainObject_meta"
}, {
"name" : "java_util_SortedMap"
}, {
"name" : "java_util_SortedMap__DomainObject_meta"
+ }, {
+ "name" : "java_util_concurrent_Callable"
+ }, {
+ "name" : "java_util_concurrent_Callable__DomainObject_meta"
+ }, {
+ "name" : "java_util_function_BiFunction"
+ }, {
+ "name" : "java_util_function_BiFunction__DomainObject_meta"
+ }, {
+ "name" : "java_util_function_Consumer"
+ }, {
+ "name" : "java_util_function_Consumer__DomainObject_meta"
+ }, {
+ "name" : "java_util_function_Function"
+ }, {
+ "name" : "java_util_function_Function__DomainObject_meta"
}, {
"name" : "java_util_stream_Stream"
}, {
"name" : "java_util_stream_Stream__DomainObject_meta"
}, {
- "name" : "org_apache_causeway_applib_services_inject_ServiceInjector"
+ "name" : "org_apache_causeway_commons_functional_Either"
+ }, {
+ "name" : "org_apache_causeway_commons_functional_Either__DomainObject_meta"
+ }, {
+ "name" : "org_apache_causeway_commons_functional_Either__DomainObject_mutators"
+ }, {
+ "name" : "org_apache_causeway_commons_functional_Railway"
+ }, {
+ "name" : "org_apache_causeway_commons_functional_Railway__DomainObject_meta"
+ }, {
+ "name" : "org_apache_causeway_commons_functional_Railway__DomainObject_mutators"
+ }, {
+ "name" : "org_apache_causeway_commons_functional_ThrowingConsumer"
+ }, {
+ "name" : "org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_meta"
+ }, {
+ "name" : "org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_mutators"
}, {
- "name" : "org_apache_causeway_applib_services_inject_ServiceInjector__DomainObject_meta"
+ "name" : "org_apache_causeway_commons_functional_ThrowingFunction"
}, {
- "name" : "org_apache_causeway_applib_services_inject_ServiceInjector__DomainObject_mutators"
+ "name" : "org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_meta"
+ }, {
+ "name" : "org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_mutators"
+ }, {
+ "name" : "org_apache_causeway_commons_functional_ThrowingRunnable"
+ }, {
+ "name" : "org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_meta"
+ }, {
+ "name" : "org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_mutators"
+ }, {
+ "name" : "org_apache_causeway_commons_functional_Try"
+ }, {
+ "name" : "org_apache_causeway_commons_functional_Try__DomainObject_meta"
+ }, {
+ "name" : "org_apache_causeway_commons_functional_Try__DomainObject_mutators"
}, {
"name" : "org_apache_causeway_core_metamodel_inspect_model_MMNode"
}, {
"name" : "org_apache_causeway_core_metamodel_inspect_model_MMNode__DomainObject_meta"
+ }, {
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode"
+ }, {
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_meta"
+ }, {
+ "name" : "org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_mutators"
}, {
"name" : "org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript"
}, {
"name" : "org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__DomainObject_meta"
}, {
- "name" : "org_apache_causeway_viewer_graphql_viewer_source_gqltestdomain_TestEntity"
+ "name" : "org_apache_causeway_viewer_graphql_viewer_test_domain_WithName"
}, {
- "name" : "org_apache_causeway_viewer_graphql_viewer_source_gqltestdomain_TestEntity__DomainObject_meta"
+ "name" : "org_apache_causeway_viewer_graphql_viewer_test_domain_WithName__DomainObject_meta"
} ]
}
}
-}
+}
\ No newline at end of file
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.simple_post_request.submit.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.schema_types_name.submit.gql
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.simple_post_request.submit.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/EndToEnd_IntegTest.schema_types_name.submit.gql
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/introspection-query-request.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/introspectquery/introspection-query-request.gql
similarity index 100%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/introspection-query-request.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/introspectquery/introspection-query-request.gql
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/GQLSchema_IntegTest.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_detail_IntegTest.java
similarity index 80%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/GQLSchema_IntegTest.java
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_detail_IntegTest.java
index 35c63ef439..65f10c4874 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/GQLSchema_IntegTest.java
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_detail_IntegTest.java
@@ -16,32 +16,27 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.causeway.viewer.graphql.viewer.test.source;
+package org.apache.causeway.viewer.graphql.viewer.test.schema;
import java.util.List;
-import java.util.stream.Collectors;
import javax.inject.Inject;
-import org.apache.causeway.commons.internal.base._Strings;
-import org.apache.causeway.commons.io.TextUtils;
+import org.apache.causeway.viewer.graphql.viewer.test.domain.DeptHead;
-import org.approvaltests.Approvals;
-import org.approvaltests.core.Options;
-import org.approvaltests.reporters.DiffReporter;
-import org.approvaltests.reporters.UseReporter;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;
+
import org.springframework.transaction.annotation.Transactional;
import org.apache.causeway.core.config.environment.CausewaySystemEnvironment;
import org.apache.causeway.core.metamodel.spec.ObjectSpecification;
import org.apache.causeway.core.metamodel.specloader.SpecificationLoader;
import org.apache.causeway.viewer.graphql.viewer.source.GraphQlSourceForCauseway;
-import org.apache.causeway.viewer.graphql.viewer.test.source.gqltestdomain.E1;
-import org.apache.causeway.viewer.graphql.viewer.test.source.gqltestdomain.E2;
-import org.apache.causeway.viewer.graphql.viewer.test.source.gqltestdomain.GQLTestDomainMenu;
+import org.apache.causeway.viewer.graphql.viewer.test.CausewayViewerGraphqlTestModuleIntegTestAbstract;
+import org.apache.causeway.viewer.graphql.viewer.test.domain.Department;
+import org.apache.causeway.viewer.graphql.viewer.test.domain.TopLevelMenu;
import static org.apache.causeway.commons.internal.assertions._Assert.assertEquals;
import static org.apache.causeway.commons.internal.assertions._Assert.assertNotNull;
@@ -62,10 +57,9 @@ import graphql.schema.GraphQLSchema;
import graphql.schema.GraphQLSchemaElement;
import graphql.schema.GraphQLType;
import graphql.schema.GraphQLTypeReference;
-import graphql.schema.idl.SchemaPrinter;
@Transactional
-public class GQLSchema_IntegTest extends CausewayViewerGraphqlTestModuleIntegTestAbstract {
+public class GqlSchema_detail_IntegTest extends CausewayViewerGraphqlTestModuleIntegTestAbstract {
@Inject private CausewaySystemEnvironment causewaySystemEnvironment;
@Inject private SpecificationLoader specificationLoader;
@@ -78,38 +72,10 @@ public class GQLSchema_IntegTest extends CausewayViewerGraphqlTestModuleIntegTes
assertNotNull(graphQlSourceForCauseway);
}
- @Test
- @UseReporter(DiffReporter.class)
- void schema() {
-
- GraphQLSchema x;
-
- GraphQL graphQL = graphQlSourceForCauseway.graphQl();
- GraphQLSchema graphQLSchema = graphQL.getGraphQLSchema();
-
- SchemaPrinter printer = new SchemaPrinter();
-
- // Print schema
- String schemaDefinition = printer.print(graphQLSchema);
-
- Approvals.verify(schemaDefinition, gqlSchemaOptions());
- }
-
- private Options gqlSchemaOptions() {
- return new Options()
- .withScrubber(this::unixLineEndings)
- .forFile().withExtension(".gql");
- }
-
- private String unixLineEndings(final String input) {
- return TextUtils.streamLines(input)
- .collect(Collectors.joining("\n"));
- }
-
@Test
@Disabled
- void assert_stuff_works() {
+ void detail() {
GraphQLSchema x;
@@ -120,13 +86,13 @@ public class GQLSchema_IntegTest extends CausewayViewerGraphqlTestModuleIntegTes
System.out.println(port);
- ObjectSpecification objectSpecification1 = specificationLoader.specForType(E1.class).get();
+ ObjectSpecification objectSpecification1 = specificationLoader.specForType(Department.class).get();
assertNotNull(objectSpecification1);
- ObjectSpecification objectSpecification2 = specificationLoader.specForType(E2.class).get();
+ ObjectSpecification objectSpecification2 = specificationLoader.specForType(DeptHead.class).get();
assertNotNull(objectSpecification2);
- ObjectSpecification objectSpecification3 = specificationLoader.specForType(GQLTestDomainMenu.class).get();
+ ObjectSpecification objectSpecification3 = specificationLoader.specForType(TopLevelMenu.class).get();
assertNotNull(objectSpecification3);
GraphQL graphQL = graphQlSourceForCauseway.graphQl();
@@ -146,7 +112,7 @@ public class GQLSchema_IntegTest extends CausewayViewerGraphqlTestModuleIntegTes
GraphQLType gqltestdomain_e1 = graphQLSchema.getType("gqltestdomain_E1");
List<GraphQLSchemaElement> children = gqltestdomain_e1.getChildren();
- assertEquals(5, children.size());
+ assertEquals(3, children.size());
GraphQLObjectType gqltestdomain_e2 = (GraphQLObjectType) graphQLSchema.getType("gqltestdomain_E2");
List<GraphQLFieldDefinition> fields = gqltestdomain_e2.getFields();
@@ -190,7 +156,7 @@ public class GQLSchema_IntegTest extends CausewayViewerGraphqlTestModuleIntegTes
assertEquals("gqltestdomain_E2__DomainObject_mutators", mutationType.getName());
assertEquals(1, mutationType.getFields().size());
GraphQLFieldDefinition graphQLFieldDefinition = mutationType.getFields().get(0);
- assertEquals("changeE1",graphQLFieldDefinition.getName());
+ assertEquals("changeDeptHead",graphQLFieldDefinition.getName());
GraphQLArgument mutatorArgument = graphQLFieldDefinition.getArgument("e1");
GraphQLType gqltestdomain_e1__domainObject_meta = graphQLSchema.getType("gqltestdomain_E1__DomainObject_meta");
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_print_IntegTest.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_print_IntegTest.java
new file mode 100644
index 0000000000..b12cd83ef3
--- /dev/null
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_print_IntegTest.java
@@ -0,0 +1,87 @@
+/*
+ * 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.
+ */
+package org.apache.causeway.viewer.graphql.viewer.test.schema;
+
+import java.util.stream.Collectors;
+
+import javax.inject.Inject;
+
+import org.apache.causeway.commons.io.TextUtils;
+
+import org.apache.causeway.viewer.graphql.viewer.test.CausewayViewerGraphqlTestModuleIntegTestAbstract;
+
+import org.approvaltests.Approvals;
+import org.approvaltests.core.Options;
+import org.approvaltests.reporters.DiffReporter;
+import org.approvaltests.reporters.UseReporter;
+import org.junit.jupiter.api.BeforeEach;
+import org.junit.jupiter.api.Test;
+import org.springframework.transaction.annotation.Transactional;
+
+import org.apache.causeway.core.config.environment.CausewaySystemEnvironment;
+import org.apache.causeway.core.metamodel.specloader.SpecificationLoader;
+import org.apache.causeway.viewer.graphql.viewer.source.GraphQlSourceForCauseway;
+
+import static org.apache.causeway.commons.internal.assertions._Assert.assertEquals;
+import static org.apache.causeway.commons.internal.assertions._Assert.assertNotNull;
+import static org.apache.causeway.commons.internal.assertions._Assert.assertTrue;
+
+import graphql.schema.idl.SchemaPrinter;
+
+import lombok.val;
+
+@Transactional
+public class GqlSchema_print_IntegTest extends CausewayViewerGraphqlTestModuleIntegTestAbstract {
+
+ @Inject private CausewaySystemEnvironment causewaySystemEnvironment;
+ @Inject private SpecificationLoader specificationLoader;
+ @Inject private GraphQlSourceForCauseway graphQlSourceForCauseway;
+
+ @BeforeEach
+ void beforeEach() {
+ assertNotNull(causewaySystemEnvironment);
+ assertNotNull(specificationLoader);
+ assertNotNull(graphQlSourceForCauseway);
+ }
+
+ @UseReporter({MyWinMergeDiffReporter.class, DiffReporter.class})
+ @Test
+ void schema() {
+ val graphQL = graphQlSourceForCauseway.graphQl();
+ val graphQLSchema = graphQL.getGraphQLSchema();
+
+ val printer = new SchemaPrinter();
+
+ val schemaDefinition = printer.print(graphQLSchema);
+
+ Approvals.verify(schemaDefinition, gqlSchemaOptions());
+ }
+
+ private Options gqlSchemaOptions() {
+ return new Options()
+ .withScrubber(this::unixLineEndings)
+ .forFile().withExtension(".gql");
+ }
+
+ private String unixLineEndings(final String input) {
+ return TextUtils.streamLines(input)
+ .collect(Collectors.joining("\n"));
+ }
+
+}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/GQLSchema_IntegTest.schema.approved.gql b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_print_IntegTest.schema.approved.gql
similarity index 93%
rename from incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/GQLSchema_IntegTest.schema.approved.gql
rename to incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_print_IntegTest.schema.approved.gql
index 5b095b0170..128cc4ba23 100644
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/GQLSchema_IntegTest.schema.approved.gql
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/GqlSchema_print_IntegTest.schema.approved.gql
@@ -26,7 +26,7 @@ type Query {
causeway_applib_UserMenu: causeway_applib_UserMenu
causeway_conf_ConfigurationMenu: causeway_conf_ConfigurationMenu
causeway_security_LogoutMenu: causeway_security_LogoutMenu
- gqltestdomain_GQLTestDomainMenu: gqltestdomain_GQLTestDomainMenu
+ gql_test_domain_TopLevelMenu: gql_test_domain_TopLevelMenu
numServices: Int
}
@@ -348,46 +348,42 @@ type causeway_testing_fixtures_FixtureResult__DomainObject_meta {
logicalTypeName: String!
}
-type gqltestdomain_E1 {
- _gql_meta: gqltestdomain_E1__DomainObject_meta
- e2: gqltestdomain_E2
+type gql_test_domain_Department {
+ _gql_meta: gql_test_domain_Department__DomainObject_meta
+ deptHead: gql_test_domain_DeptHead
name: String!
}
-type gqltestdomain_E1__DomainObject_meta {
+type gql_test_domain_Department__DomainObject_meta {
id: String!
logicalTypeName: String!
version: String
}
-type gqltestdomain_E2 {
- _gql_meta: gqltestdomain_E2__DomainObject_meta
- _gql_mutations: gqltestdomain_E2__DomainObject_mutators
- e1: gqltestdomain_E1
+type gql_test_domain_DeptHead {
+ _gql_meta: gql_test_domain_DeptHead__DomainObject_meta
+ _gql_mutations: gql_test_domain_DeptHead__DomainObject_mutators
+ department: gql_test_domain_Department
name: String
- otherE2List: [gqltestdomain_E2]
- otherEntities: [org_apache_causeway_viewer_graphql_viewer_test_source_gqltestdomain_TestEntity]
- stringList: [String]
- zintList: [Int]
}
-type gqltestdomain_E2__DomainObject_meta {
+type gql_test_domain_DeptHead__DomainObject_meta {
id: String!
logicalTypeName: String!
version: String
}
-type gqltestdomain_E2__DomainObject_mutators {
- changeE1(e1: _gql_input__gqltestdomain_E1!): gqltestdomain_E2
- changeName(newName: String!): gqltestdomain_E2
+type gql_test_domain_DeptHead__DomainObject_mutators {
+ changeDeptHead(department: _gql_input__gql_test_domain_Department!): gql_test_domain_DeptHead
+ changeName(newName: String!): gql_test_domain_DeptHead
}
-type gqltestdomain_GQLTestDomainMenu {
- createE1(e2: _gql_input__gqltestdomain_E2, name: String): gqltestdomain_E1
- findAllE1: [gqltestdomain_E1]
- findAllE2: [gqltestdomain_E2]
- findAllTestEntities: [org_apache_causeway_viewer_graphql_viewer_test_source_gqltestdomain_TestEntity]
- findE2(name: String): gqltestdomain_E2
+type gql_test_domain_TopLevelMenu {
+ createDepartment(deptHead: _gql_input__gql_test_domain_DeptHead, name: String): gql_test_domain_Department
+ findAllDepartments: [gql_test_domain_Department]
+ findAllDeptHeads: [gql_test_domain_DeptHead]
+ findAllEntitiesWithName: [org_apache_causeway_viewer_graphql_viewer_test_domain_WithName]
+ findDeptHeadByName(name: String): gql_test_domain_DeptHead
}
type java_lang_Runnable {
@@ -623,12 +619,12 @@ type org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__D
logicalTypeName: String!
}
-type org_apache_causeway_viewer_graphql_viewer_test_source_gqltestdomain_TestEntity {
- _gql_meta: org_apache_causeway_viewer_graphql_viewer_test_source_gqltestdomain_TestEntity__DomainObject_meta
+type org_apache_causeway_viewer_graphql_viewer_test_domain_WithName {
+ _gql_meta: org_apache_causeway_viewer_graphql_viewer_test_domain_WithName__DomainObject_meta
name: String!
}
-type org_apache_causeway_viewer_graphql_viewer_test_source_gqltestdomain_TestEntity__DomainObject_meta {
+type org_apache_causeway_viewer_graphql_viewer_test_domain_WithName__DomainObject_meta {
id: String!
logicalTypeName: String!
}
@@ -725,11 +721,11 @@ input _gql_input__causeway_testing_fixtures_FixtureResult {
id: ID!
}
-input _gql_input__gqltestdomain_E1 {
+input _gql_input__gql_test_domain_Department {
id: ID!
}
-input _gql_input__gqltestdomain_E2 {
+input _gql_input__gql_test_domain_DeptHead {
id: ID!
}
@@ -801,6 +797,6 @@ input _gql_input__org_apache_causeway_testing_fixtures_applib_fixturescripts_Fix
id: ID!
}
-input _gql_input__org_apache_causeway_viewer_graphql_viewer_test_source_gqltestdomain_TestEntity {
+input _gql_input__org_apache_causeway_viewer_graphql_viewer_test_domain_WithName {
id: ID!
}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/MyWinMergeDiffReporter.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/MyWinMergeDiffReporter.java
new file mode 100644
index 0000000000..0816357034
--- /dev/null
+++ b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/schema/MyWinMergeDiffReporter.java
@@ -0,0 +1,28 @@
+package org.apache.causeway.viewer.graphql.viewer.test.schema;
+
+import java.util.Arrays;
+import java.util.List;
+
+import org.approvaltests.reporters.DiffInfo;
+import org.approvaltests.reporters.DiffPrograms;
+import org.approvaltests.reporters.GenericDiffReporter;
+
+import com.spun.util.ArrayUtils;
+
+public class MyWinMergeDiffReporter extends GenericDiffReporter {
+
+ private static DiffInfo WIN_MERGE_REPORTER =
+ new DiffInfo(DiffPrograms.Windows.WIN_MERGE_REPORTER.diffProgram,
+ ArrayUtils.combine(
+ List.of(".gql"),
+ ArrayUtils.combine(
+ GenericDiffReporter.TEXT_FILE_EXTENSIONS,
+ GenericDiffReporter.IMAGE_FILE_EXTENSIONS)
+ )
+ );
+
+ public MyWinMergeDiffReporter() {
+ super(WIN_MERGE_REPORTER);
+ }
+
+}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/.gitignore b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/.gitignore
deleted file mode 100644
index 1718626ba0..0000000000
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/.gitignore
+++ /dev/null
@@ -1 +0,0 @@
-*.received.gql
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/CausewayViewerGraphqlTestModuleIntegTestAbstract.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
deleted file mode 100644
index 60c29aa2fb..0000000000
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/CausewayViewerGraphqlTestModuleIntegTestAbstract.java
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- * 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.
- */
-package org.apache.causeway.viewer.graphql.viewer.test.source;
-
-import org.junit.jupiter.api.MethodOrderer;
-import org.junit.jupiter.api.TestInstance;
-import org.junit.jupiter.api.TestMethodOrder;
-
-import org.springframework.boot.SpringBootConfiguration;
-import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
-import org.springframework.boot.test.autoconfigure.graphql.tester.AutoConfigureHttpGraphQlTester;
-import org.springframework.boot.test.context.SpringBootTest;
-import org.springframework.boot.test.web.server.LocalServerPort;
-import org.springframework.context.annotation.Import;
-import org.springframework.context.annotation.PropertySource;
-import org.springframework.context.annotation.PropertySources;
-import org.springframework.data.jpa.repository.config.EnableJpaRepositories;
-import org.springframework.graphql.test.tester.HttpGraphQlTester;
-import org.springframework.test.context.ActiveProfiles;
-import org.springframework.test.web.reactive.server.WebTestClient;
-
-import org.apache.causeway.core.config.presets.CausewayPresets;
-import org.apache.causeway.core.runtimeservices.CausewayModuleCoreRuntimeServices;
-import org.apache.causeway.persistence.jpa.eclipselink.CausewayModulePersistenceJpaEclipselink;
-import org.apache.causeway.security.bypass.CausewayModuleSecurityBypass;
-import org.apache.causeway.testing.fixtures.applib.CausewayModuleTestingFixturesApplib;
-import org.apache.causeway.viewer.graphql.viewer.CausewayModuleIncViewerGraphqlViewer;
-import org.apache.causeway.viewer.graphql.viewer.test.source.gqltestdomain.TestDomainModule;
-
-@SpringBootTest(
- classes = {
- CausewayViewerGraphqlTestModuleIntegTestAbstract.TestApp.class
- },
- webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT
-)
-@AutoConfigureHttpGraphQlTester
-@TestInstance(TestInstance.Lifecycle.PER_CLASS)
-@TestMethodOrder(MethodOrderer.OrderAnnotation.class)
-@ActiveProfiles("test")
-public class CausewayViewerGraphqlTestModuleIntegTestAbstract {
-
- /**
- * Compared to the production app manifest <code>domainapp.webapp.AppManifest</code>,
- * here we in effect disable security checks, and we exclude any web/UI modules.
- */
- @SpringBootConfiguration
- @EnableAutoConfiguration
- @EnableJpaRepositories
- @Import({
-
- CausewayModuleCoreRuntimeServices.class,
- CausewayModuleSecurityBypass.class,
- CausewayModulePersistenceJpaEclipselink.class,
- CausewayModuleTestingFixturesApplib.class,
- CausewayModuleIncViewerGraphqlViewer.class,
-
- TestDomainModule.class
- })
- @PropertySources({
- @PropertySource(CausewayPresets.H2InMemory_withUniqueSchema),
- @PropertySource(CausewayPresets.UseLog4j2Test),
- @PropertySource(CausewayPresets.SilenceMetaModel),
- @PropertySource(CausewayPresets.SilenceProgrammingModel),
- })
- public static class TestApp {
-
- }
-
- @LocalServerPort
- protected int port;
-
- protected HttpGraphQlTester graphQlTester() {
- WebTestClient client =
- WebTestClient.bindToServer()
- .baseUrl("http://0.0.0.0:" + port + "/graphql")
- .build();
- return HttpGraphQlTester.create(client);
- }
-
-
-}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.findAllE1.approved.json b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.findAllE1.approved.json
deleted file mode 100644
index cb50540424..0000000000
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.findAllE1.approved.json
+++ /dev/null
@@ -1,14 +0,0 @@
-{
- "data" : {
- "gqltestdomain_GQLTestDomainMenu" : {
- "findAllE1" : [ {
- "name" : "foo",
- "_gql_meta" : {
- "id" : "2",
- "logicalTypeName" : "gqltestdomain.E1",
- "version" : null
- }
- } ]
- }
- }
-}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.java
deleted file mode 100644
index 26bef80b25..0000000000
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/EndToEnd_IntegTest.java
+++ /dev/null
@@ -1,284 +0,0 @@
-/*
- * 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.
- */
-package org.apache.causeway.viewer.graphql.viewer.test.source;
-
-import java.io.File;
-import java.io.IOException;
-import java.lang.reflect.Method;
-import java.net.URI;
-import java.net.http.HttpClient;
-import java.net.http.HttpRequest;
-import java.net.http.HttpResponse;
-import java.nio.charset.StandardCharsets;
-import java.nio.file.Path;
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.inject.Inject;
-
-import com.fasterxml.jackson.databind.ObjectMapper;
-
-import org.apache.causeway.viewer.graphql.viewer.source.GraphQlServiceForCauseway;
-
-import org.approvaltests.Approvals;
-import org.approvaltests.core.Options;
-import org.approvaltests.core.Scrubber;
-import org.approvaltests.reporters.TextWebReporter;
-import org.approvaltests.reporters.UseReporter;
-import org.junit.jupiter.api.AfterEach;
-import org.junit.jupiter.api.BeforeEach;
-import org.junit.jupiter.api.Disabled;
-import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.TestInfo;
-import org.junit.jupiter.api.condition.DisabledIfSystemProperty;
-
-import org.springframework.test.context.ActiveProfiles;
-import org.springframework.transaction.annotation.Propagation;
-
-import org.apache.causeway.applib.services.xactn.TransactionService;
-import org.apache.causeway.commons.internal.resources._Resources;
-import org.apache.causeway.core.config.environment.CausewaySystemEnvironment;
-import org.apache.causeway.core.metamodel.specloader.SpecificationLoader;
-import org.apache.causeway.viewer.graphql.viewer.source.GraphQlSourceForCauseway;
-import org.apache.causeway.viewer.graphql.viewer.test.source.gqltestdomain.E1;
-import org.apache.causeway.viewer.graphql.viewer.test.source.gqltestdomain.E2;
-import org.apache.causeway.viewer.graphql.viewer.test.source.gqltestdomain.GQLTestDomainMenu;
-import org.apache.causeway.viewer.graphql.viewer.test.source.gqltestdomain.TestEntityRepository;
-
-import static org.apache.causeway.commons.internal.assertions._Assert.assertEquals;
-import static org.apache.causeway.commons.internal.assertions._Assert.assertNotNull;
-import static org.apache.causeway.commons.internal.assertions._Assert.assertTrue;
-
-import lombok.Data;
-import lombok.SneakyThrows;
-import lombok.val;
-
-
-//@Transactional NOT USING @Transactional since we are running server within same transaction otherwise
-@ActiveProfiles("test")
-public class EndToEnd_IntegTest extends CausewayViewerGraphqlTestModuleIntegTestAbstract {
-
- @Inject TransactionService transactionService;
- @Inject CausewaySystemEnvironment causewaySystemEnvironment;
- @Inject SpecificationLoader specificationLoader;
- @Inject GraphQlSourceForCauseway graphQlSourceForCauseway;
- @Inject GraphQlServiceForCauseway graphQlServiceForCauseway;
-
- @Inject TestEntityRepository testEntityRepository;
- @Inject GQLTestDomainMenu gqlTestDomainMenu;
-
- private TestInfo testInfo;
- private ObjectMapper objectMapper = new ObjectMapper();
-
- @BeforeEach
- void beforeEach(final TestInfo testInfo) {
- this.testInfo = testInfo;
- assertNotNull(causewaySystemEnvironment);
- assertNotNull(specificationLoader);
- assertNotNull(graphQlSourceForCauseway);
- }
-
- @AfterEach
- void afterEach(){
- transactionService.runTransactional(Propagation.REQUIRED, () -> {
- testEntityRepository.removeAll();
- });
- }
-
- @Test
- @Disabled("Creates schema.gql file for convenience")
- void print_schema_works() throws Exception {
-
- HttpClient client = HttpClient.newBuilder().build();
- URI uri = URI.create("http://0.0.0.0:" + port + "/graphql/schema");
-
- HttpRequest request = HttpRequest.newBuilder().uri(uri).GET().build();
- File targetFile1 = new File("src/test/resources/testfiles/schema.gql");
- HttpResponse<Path> response = client.send(request, HttpResponse.BodyHandlers.ofFile(targetFile1.toPath()));
-
- }
-
- @Test
- void introspectionQuery() throws Exception {
-
- HttpClient client = HttpClient.newBuilder().build();
-
- URI uri = URI.create(String.format("http://0.0.0.0:%d/graphql", port));
-
- String s = readResource("introspection-query-request.gql");
-// HttpRequest request = HttpRequest.newBuilder().uri(uri).POST(HttpRequest.BodyPublishers.ofString(s)).build();
-//
-// HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
-// String body = response.body();
-
- //graphQlTester().documentName()
-
-
- }
-
- //TODO started to fail on 2022-04-22, with missing
- //"name" : "_gql_input__org_apache_causeway_applib_services_inject_ServiceInjector"
- //disabled to rescue CI build
- @Test @DisabledIfSystemProperty(named = "isRunningWithSurefire", matches = "true")
- @UseReporter(TextWebReporter.class)
- void simple_post_request() throws Exception {
-
- Approvals.verify(submit(), gqlOptions());
-
- }
-
-
- @Test @DisabledIfSystemProperty(named = "isRunningWithSurefire", matches = "true")
- @UseReporter(TextWebReporter.class)
- void findAllE1() throws Exception {
-
- // given
- transactionService.runTransactional(Propagation.REQUIRED, () -> {
- E1 foo = testEntityRepository.createE1("foo", null);
- testEntityRepository.createE2("bar", null);
- transactionService.flushTransaction();
- List<E1> allE1 = testEntityRepository.findAllE1();
- assertTrue(allE1.size()==1);
- List<E2> allE2 = testEntityRepository.findAllE2();
- assertTrue(allE2.size()==1);
- });
-
- // when, then
- Approvals.verify(submit(), gqlOptions());
-
- }
-
- //TODO started to fail on 2022-09-04, with testEntityRepository findAllE1 being empty
- @Test @DisabledIfSystemProperty(named = "isRunningWithSurefire", matches = "true")
- @UseReporter(TextWebReporter.class)
- void createE1() throws Exception {
-
- //File targetFile3 = new File("src/test/resources/testfiles/targetFile3.gql");
-
- String response1 = transactionService.callTransactional(Propagation.REQUIRED, () -> {
-
- String submit = submit();
- // just to show we need to query in separate tranasction
- List<E2> list = testEntityRepository.findAllE2();
- assertTrue(list.isEmpty());
- return submit;
-
- }).ifFailureFail().getValue().get();
-
- final List<E1> allE1 = new ArrayList<>();
- transactionService.runTransactional(Propagation.REQUIRED, () -> {
-
- List<E1> all = testEntityRepository.findAllE1();
- allE1.addAll(all);
-
- });
-
- assertEquals(1, allE1.size());
- assertEquals("newbee", allE1.get(0).getName());
-
- Approvals.verify(response1, gqlOptions());
-
- }
-
- //TODO started to fail on 2023-07-25
- //disabled to rescue CI build
- @Test @DisabledIfSystemProperty(named = "isRunningWithSurefire", matches = "true")
- @UseReporter(TextWebReporter.class)
- void changeName() throws Exception {
-
- List<E2> e2List = new ArrayList<>();
-
- transactionService.runTransactional(Propagation.REQUIRED, () -> {
-
- e2List.add(testEntityRepository.createE2("foo", null));
-
- });
-
- E2 e2 = e2List.get(0);
- assertEquals("foo", e2.getName());
- assertEquals(e2.getName(), gqlTestDomainMenu.findE2("foo").getName());
-
- String response = transactionService.callTransactional(Propagation.REQUIRED, () -> {
-
- return submit();
-
- }).ifFailureFail().getValue().get();
-
- e2List.clear();
- transactionService.runTransactional(Propagation.REQUIRED, () -> {
-
- List<E2> all = testEntityRepository.findAllE2();
- e2List.addAll(all);
-
- });
-
- E2 e2Modified = e2List.get(0);
-
- //TODO: implement ...
-// assertEquals("bar", e2Modified.getName());
-//
-// Approvals.verify(response, new Options());
-
- }
-
-
- private String submit() throws Exception{
- val httpRequest = buildRequestWithResource();
- return submitRequest(httpRequest);
- }
-
- @Data
- static class GqlBody {
- String query;
- }
-
- private HttpRequest buildRequestWithResource() throws IOException {
- val testMethodName = testInfo.getTestMethod().map(Method::getName).get();
- val resourceName = getClass().getSimpleName() + "." + testMethodName + ".submit.gql";
- val resourceContents = readResource(resourceName);
- val gqlBody = new GqlBody();
- gqlBody.setQuery(resourceContents);
- String gqlBodyStr = objectMapper.writeValueAsString(gqlBody);
- val bodyPublisher = HttpRequest.BodyPublishers.ofString(gqlBodyStr);
- val uri = URI.create("http://0.0.0.0:" + port + "/graphql");
- return HttpRequest.newBuilder().uri(uri).POST(bodyPublisher).setHeader("Content-Type", "application/json").build();
- }
-
- private String submitRequest(final HttpRequest request) throws IOException, InterruptedException {
- val responseBodyHandler = HttpResponse.BodyHandlers.ofString();
- val httpClient = HttpClient.newBuilder().build();
- val httpResponse = httpClient.send(request, responseBodyHandler);
- return httpResponse.body();
- }
-
- private String readResource(final String resourceName) throws IOException {
- return _Resources.loadAsString(getClass(), resourceName, StandardCharsets.UTF_8);
- }
-
- private Options gqlOptions() {
- return new Options().withScrubber(new Scrubber() {
- @SneakyThrows
- @Override
- public String scrub(final String s) {
- return objectMapper.writerWithDefaultPrettyPrinter().writeValueAsString(objectMapper.readTree(s));
- }
- }).forFile().withExtension(".gql");
- }
-
-}
diff --git a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/TestEntityRepository.java b/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/TestEntityRepository.java
deleted file mode 100644
index 86f3bcb3e8..0000000000
--- a/incubator/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/source/gqltestdomain/TestEntityRepository.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
- * 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.
- */
-package org.apache.causeway.viewer.graphql.viewer.test.source.gqltestdomain;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.inject.Inject;
-
-import org.springframework.lang.Nullable;
-import org.springframework.stereotype.Repository;
-
-import org.apache.causeway.applib.services.repository.RepositoryService;
-
-@Repository
-public class TestEntityRepository {
-
- @Inject
- private RepositoryService repositoryService;
-
- public E1 createE1(final String name, @Nullable final E2 e2) {
- E1 e1 = new E1();
- e1.setName(name);
- e1.setE2(e2);
- repositoryService.persistAndFlush(e1);
- return e1;
- }
-
- public E2 createE2(final String name, @Nullable final E1 e1) {
- E2 e2 = new E2();
- e2.setName(name);
- e2.setE1(e1);
- repositoryService.persistAndFlush(e2);
- return e2;
- }
-
- public List<E1> findAllE1() {
- return repositoryService.allInstances(E1.class);
- }
-
- public List<E2> findAllE2() {
- return repositoryService.allInstances(E2.class);
- }
-
- public List<TestEntity> findAllTestEntities() {
- final List<TestEntity> result = new ArrayList<>();
- result.addAll(findAllE1());
- result.addAll(findAllE2());
- return result;
- }
-
- public void removeAll(){
- repositoryService.removeAll(E1.class);
- repositoryService.removeAll(E2.class);
- }
-
- public E2 findE2ByName(final String name){
- return findAllE2().stream().filter(e2->e2.getName().equals(name)).findFirst().orElse(null);
- }
-
-}
diff --git a/incubator/viewers/graphql/viewer/src/test/resources/testfiles/schema.gql b/incubator/viewers/graphql/viewer/src/test/resources/testfiles/schema.gql
index 0c51d5ca83..f10e5556b8 100644
--- a/incubator/viewers/graphql/viewer/src/test/resources/testfiles/schema.gql
+++ b/incubator/viewers/graphql/viewer/src/test/resources/testfiles/schema.gql
@@ -1,645 +1,802 @@
+"Marks the field, argument, input field or enum value as deprecated"
+directive @deprecated(
+ "The reason for the deprecation"
+ reason: String = "No longer supported"
+) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
+
"Directs the executor to include this field or fragment only when the `if` argument is true"
directive @include(
"Included when true."
if: Boolean!
- ) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT
+) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT
-"Directs the executor to skip this field or fragment when the `if`'argument is true."
+"Directs the executor to skip this field or fragment when the `if` argument is true."
directive @skip(
"Skipped when true."
if: Boolean!
- ) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT
-
-"Marks the field, argument, input field or enum value as deprecated"
-directive @deprecated(
- "The reason for the deprecation"
- reason: String = "No longer supported"
- ) on FIELD_DEFINITION | ARGUMENT_DEFINITION | ENUM_VALUE | INPUT_FIELD_DEFINITION
+) on FIELD | FRAGMENT_SPREAD | INLINE_FRAGMENT
"Exposes a URL that specifies the behaviour of this scalar."
directive @specifiedBy(
"The URL that specifies the behaviour of this scalar."
url: String!
- ) on SCALAR
+) on SCALAR
type Query {
- gqltestdomain_GQLTestDomainMenu: gqltestdomain_GQLTestDomainMenu
- causeway_applib_UserMenu: causeway_applib_UserMenu
- causeway_conf_ConfigurationMenu: causeway_conf_ConfigurationMenu
- causeway_security_LogoutMenu: causeway_security_LogoutMenu
- numServices: Int
-}
-
-type gqltestdomain_E1 {
- _gql_meta: gqltestdomain_E1__DomainObject_meta
- e2: gqltestdomain_E2
- logicalTypeName: String
- name: String!
- objectIdentifier: String
-}
-
-type gqltestdomain_E1__DomainObject_meta {
- id: String!
- logicalTypeName: String!
- version: String
-}
-
-type gqltestdomain_E2 {
- _gql_meta: gqltestdomain_E2__DomainObject_meta
- _gql_mutations: gqltestdomain_E2__DomainObject_mutators
- e1: gqltestdomain_E1
- logicalTypeName: String
- name: String!
- objectIdentifier: String
- otherE2List: [gqltestdomain_E2]
- otherEntities: [org_apache_causeway_viewer_graphql_viewer_source_gqltestdomain_TestEntity]
- stringList: [String]
- zintList: [Int]
-}
-
-type gqltestdomain_E2__DomainObject_meta {
- id: String!
- logicalTypeName: String!
- version: String
-}
-
-type gqltestdomain_E2__DomainObject_mutators {
- changeE1(e1: _gql_input__gqltestdomain_E1!): gqltestdomain_E2
- changeName(newName: String!): gqltestdomain_E2
-}
-
-type gqltestdomain_GQLTestDomainMenu {
- createE1(e2: _gql_input__gqltestdomain_E2, name: String): gqltestdomain_E1
- findAllE1: [gqltestdomain_E1]
- findAllE2: [gqltestdomain_E2]
- findAllTestEntities: [org_apache_causeway_viewer_graphql_viewer_source_gqltestdomain_TestEntity]
-}
-
-type causeway_applib_ActionNode {
- _gql_meta: causeway_applib_ActionNode__DomainObject_meta
- _gql_mutations: causeway_applib_ActionNode__DomainObject_mutators
- action: String!
- logicalTypeName: String
- objectIdentifier: String
-}
-
-type causeway_applib_ActionNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_applib_ActionNode__DomainObject_mutators {
- createTitle: String
- streamChildNodes: java_util_stream_Stream
-}
-
-type causeway_applib_CollectionNode {
- _gql_meta: causeway_applib_CollectionNode__DomainObject_meta
- _gql_mutations: causeway_applib_CollectionNode__DomainObject_mutators
- collection: String!
- logicalTypeName: String
- objectIdentifier: String
- parentNode: causeway_applib_TypeNode!
-}
-
-type causeway_applib_CollectionNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
-}
-
-type causeway_applib_CollectionNode__DomainObject_mutators {
- createTitle: String
- streamChildNodes: java_util_stream_Stream
+ causeway_applib_UserMenu: causeway_applib_UserMenu
+ causeway_conf_ConfigurationMenu: causeway_conf_ConfigurationMenu
+ causeway_security_LogoutMenu: causeway_security_LogoutMenu
+ gql_test_domain_TopLevelMenu: gql_test_domain_TopLevelMenu
+ numServices: Int
}
type causeway_applib_DomainObjectList {
- _gql_meta: causeway_applib_DomainObjectList__DomainObject_meta
- actionArguments: String
- actionId: String
- actionOwningFqcn: String
- elementTypeFqcn: String!
- logicalTypeName: String
- objectIdentifier: String
+ _gql_meta: causeway_applib_DomainObjectList__DomainObject_meta
+ actionArguments: String
+ actionId: String
+ actionOwningFqcn: String
+ elementTypeFqcn: String!
+ title: String!
}
type causeway_applib_DomainObjectList__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+ id: String!
+ logicalTypeName: String!
}
-type causeway_applib_FacetAttrNode {
- _gql_meta: causeway_applib_FacetAttrNode__DomainObject_meta
- _gql_mutations: causeway_applib_FacetAttrNode__DomainObject_mutators
- facetAttr: String!
- logicalTypeName: String
- objectIdentifier: String
- parentNode: causeway_applib_FacetNode!
+type causeway_applib_FacetGroupNode {
+ _gql_meta: causeway_applib_FacetGroupNode__DomainObject_meta
+ facets: String!
}
-type causeway_applib_FacetAttrNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+type causeway_applib_FacetGroupNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
-type causeway_applib_FacetAttrNode__DomainObject_mutators {
- createTitle: String
- streamChildNodes: java_util_stream_Stream
+type causeway_applib_ParameterNode {
+ _gql_meta: causeway_applib_ParameterNode__DomainObject_meta
+ parameter: String!
+ parentNode: causeway_applib_node_ActionNode!
}
-type causeway_applib_FacetGroupNode {
- _gql_meta: causeway_applib_FacetGroupNode__DomainObject_meta
- _gql_mutations: causeway_applib_FacetGroupNode__DomainObject_mutators
- facets: String!
- logicalTypeName: String
- objectIdentifier: String
+type causeway_applib_ParameterNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
-type causeway_applib_FacetGroupNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+type causeway_applib_PropertyNode {
+ _gql_meta: causeway_applib_PropertyNode__DomainObject_meta
+ _gql_mutations: causeway_applib_PropertyNode__DomainObject_mutators
+ mixedIn: String!
+ parentNode: causeway_applib_TypeNode!
+ property: String!
}
-type causeway_applib_FacetGroupNode__DomainObject_mutators {
- createTitle: String
- streamChildNodes: java_util_stream_Stream
+type causeway_applib_PropertyNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
-type causeway_applib_FacetNode {
- _gql_meta: causeway_applib_FacetNode__DomainObject_meta
- _gql_mutations: causeway_applib_FacetNode__DomainObject_mutators
- facet: String!
- logicalTypeName: String
- objectIdentifier: String
+type causeway_applib_PropertyNode__DomainObject_mutators {
+ streamChildNodes: java_util_stream_Stream
}
-type causeway_applib_FacetNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+type causeway_applib_RoleMemento {
+ _gql_meta: causeway_applib_RoleMemento__DomainObject_meta
+ description: String!
+ name: String!
}
-type causeway_applib_FacetNode__DomainObject_mutators {
- createTitle: String
- streamChildNodes: java_util_stream_Stream
+type causeway_applib_RoleMemento__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
-type causeway_applib_ParameterNode {
- _gql_meta: causeway_applib_ParameterNode__DomainObject_meta
- _gql_mutations: causeway_applib_ParameterNode__DomainObject_mutators
- logicalTypeName: String
- objectIdentifier: String
- parameter: String!
- parentNode: causeway_applib_ActionNode!
+type causeway_applib_TypeNode {
+ _gql_meta: causeway_applib_TypeNode__DomainObject_meta
+ domainClassDto: causeway_schema_metamodel_v2_DomainClassDto!
}
-type causeway_applib_ParameterNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+type causeway_applib_TypeNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
-type causeway_applib_ParameterNode__DomainObject_mutators {
- createTitle: String
- streamChildNodes: java_util_stream_Stream
+type causeway_applib_UserMemento {
+ _gql_meta: causeway_applib_UserMemento__DomainObject_meta
+ authenticationCode: String!
+ authenticationSource: String!
+ avatarUrl: String
+ impersonating: String!
+ languageLocale: String
+ multiTenancyToken: String
+ name: String!
+ numberFormatLocale: String
+ realName: String
+ roles: [causeway_applib_RoleMemento]
+ timeFormatLocale: String
}
-type causeway_applib_PropertyNode {
- _gql_meta: causeway_applib_PropertyNode__DomainObject_meta
- _gql_mutations: causeway_applib_PropertyNode__DomainObject_mutators
- logicalTypeName: String
- objectIdentifier: String
- parentNode: causeway_applib_TypeNode!
- property: String!
+type causeway_applib_UserMemento__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
-type causeway_applib_PropertyNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+type causeway_applib_UserMenu {
+ me: causeway_applib_UserMemento
}
-type causeway_applib_PropertyNode__DomainObject_mutators {
- createTitle: String
- streamChildNodes: java_util_stream_Stream
+type causeway_applib_node_ActionNode {
+ _gql_meta: causeway_applib_node_ActionNode__DomainObject_meta
+ _gql_mutations: causeway_applib_node_ActionNode__DomainObject_mutators
+ action: String!
+ mixedIn: String!
+ parentNode: causeway_applib_TypeNode!
}
-type causeway_applib_RoleMemento {
- _gql_meta: causeway_applib_RoleMemento__DomainObject_meta
- description: String!
- logicalTypeName: String
- name: String!
- objectIdentifier: String
+type causeway_applib_node_ActionNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
-type causeway_applib_RoleMemento__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+type causeway_applib_node_ActionNode__DomainObject_mutators {
+ streamChildNodes: java_util_stream_Stream
}
-type causeway_applib_TypeNode {
- _gql_meta: causeway_applib_TypeNode__DomainObject_meta
- _gql_mutations: causeway_applib_TypeNode__DomainObject_mutators
- domainClassDto: String!
- logicalTypeName: String
- objectIdentifier: String
+type causeway_applib_node_CollectionNode {
+ _gql_meta: causeway_applib_node_CollectionNode__DomainObject_meta
+ _gql_mutations: causeway_applib_node_CollectionNode__DomainObject_mutators
+ collection: String!
+ mixedIn: String!
+ parentNode: causeway_applib_TypeNode!
}
-type causeway_applib_TypeNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+type causeway_applib_node_CollectionNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
-type causeway_applib_TypeNode__DomainObject_mutators {
- createTitle: String
- streamChildNodes: java_util_stream_Stream
+type causeway_applib_node_CollectionNode__DomainObject_mutators {
+ streamChildNodes: java_util_stream_Stream
}
-type causeway_applib_UserMemento {
- _gql_meta: causeway_applib_UserMemento__DomainObject_meta
- _gql_mutations: causeway_applib_UserMemento__DomainObject_mutators
- authenticationCode: String!
- authenticationSource: String!
- avatarUrl: String
- impersonating: String!
- languageLocale: String
- logicalTypeName: String
- multiTenancyToken: String
- name: String!
- numberFormatLocale: String
- objectIdentifier: String
- realName: String
- roles: [causeway_applib_RoleMemento]
- timeFormatLocale: String
+type causeway_applib_node_FacetAttrNode {
+ _gql_meta: causeway_applib_node_FacetAttrNode__DomainObject_meta
+ facetAttr: String!
+ parentNode: causeway_applib_node_FacetNode!
}
-type causeway_applib_UserMemento__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+type causeway_applib_node_FacetAttrNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
-type causeway_applib_UserMemento__DomainObject_mutators {
- isCurrentUser(userName: String): Boolean
+type causeway_applib_node_FacetNode {
+ _gql_meta: causeway_applib_node_FacetNode__DomainObject_meta
+ facet: String!
+ shadowed: String!
}
-type causeway_applib_UserMenu {
- me: causeway_applib_UserMemento
+type causeway_applib_node_FacetNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
type causeway_conf_ConfigurationMenu {
- configuration: causeway_conf_ConfigurationViewmodel
+ configuration: causeway_conf_ConfigurationViewmodel
}
type causeway_conf_ConfigurationProperty {
- _gql_meta: causeway_conf_ConfigurationProperty__DomainObject_meta
- key: String!
- logicalTypeName: String
- objectIdentifier: String
- value: String!
+ _gql_meta: causeway_conf_ConfigurationProperty__DomainObject_meta
+ key: String!
+ value: String!
}
type causeway_conf_ConfigurationProperty__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+ id: String!
+ logicalTypeName: String!
}
type causeway_conf_ConfigurationViewmodel {
- _gql_meta: causeway_conf_ConfigurationViewmodel__DomainObject_meta
- configuration: [causeway_conf_ConfigurationProperty]
- environment: [causeway_conf_ConfigurationProperty]
- logicalTypeName: String
- objectIdentifier: String
+ _gql_meta: causeway_conf_ConfigurationViewmodel__DomainObject_meta
+ environment: [causeway_conf_ConfigurationProperty]
+ primary: [causeway_conf_ConfigurationProperty]
+ secondary: [causeway_conf_ConfigurationProperty]
}
type causeway_conf_ConfigurationViewmodel__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+ id: String!
+ logicalTypeName: String!
}
type causeway_feat_ApplicationFeatureViewModel {
- _gql_meta: causeway_feat_ApplicationFeatureViewModel__DomainObject_meta
- logicalTypeName: String
- memberName: String!
- namespaceName: String!
- objectIdentifier: String
- typeSimpleName: String!
+ _gql_meta: causeway_feat_ApplicationFeatureViewModel__DomainObject_meta
+ memberName: String!
+ namespaceName: String!
+ typeSimpleName: String!
}
type causeway_feat_ApplicationFeatureViewModel__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+ id: String!
+ logicalTypeName: String!
}
type causeway_feat_ApplicationNamespace {
- _gql_meta: causeway_feat_ApplicationNamespace__DomainObject_meta
- logicalTypeName: String
- memberName: String!
- namespaceName: String!
- objectIdentifier: String
- typeSimpleName: String!
+ _gql_meta: causeway_feat_ApplicationNamespace__DomainObject_meta
+ memberName: String!
+ namespaceName: String!
+ typeSimpleName: String!
}
type causeway_feat_ApplicationNamespace__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+ id: String!
+ logicalTypeName: String!
}
type causeway_feat_ApplicationType {
- _gql_meta: causeway_feat_ApplicationType__DomainObject_meta
- actions: [causeway_feat_ApplicationTypeAction]
- collections: [causeway_feat_ApplicationTypeCollection]
- logicalTypeName: String
- memberName: String!
- namespaceName: String!
- objectIdentifier: String
- properties: [causeway_feat_ApplicationTypeProperty]
- typeSimpleName: String!
+ _gql_meta: causeway_feat_ApplicationType__DomainObject_meta
+ actions: [causeway_feat_ApplicationTypeAction]
+ collections: [causeway_feat_ApplicationTypeCollection]
+ memberName: String!
+ namespaceName: String!
+ properties: [causeway_feat_ApplicationTypeProperty]
+ typeSimpleName: String!
}
type causeway_feat_ApplicationTypeAction {
- _gql_meta: causeway_feat_ApplicationTypeAction__DomainObject_meta
- actionSemantics: String!
- logicalTypeName: String
- memberName: String!
- namespaceName: String!
- objectIdentifier: String
- returnType: String!
- typeSimpleName: String!
+ _gql_meta: causeway_feat_ApplicationTypeAction__DomainObject_meta
+ actionSemantics: String!
+ memberName: String!
+ namespaceName: String!
+ returnType: String!
+ typeSimpleName: String!
}
type causeway_feat_ApplicationTypeAction__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+ id: String!
+ logicalTypeName: String!
}
type causeway_feat_ApplicationTypeCollection {
- _gql_meta: causeway_feat_ApplicationTypeCollection__DomainObject_meta
- derived: String!
- elementType: String!
- logicalTypeName: String
- memberName: String!
- namespaceName: String!
- objectIdentifier: String
- typeSimpleName: String!
+ _gql_meta: causeway_feat_ApplicationTypeCollection__DomainObject_meta
+ derived: String!
+ elementType: String!
+ memberName: String!
+ namespaceName: String!
+ typeSimpleName: String!
}
type causeway_feat_ApplicationTypeCollection__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+ id: String!
+ logicalTypeName: String!
}
type causeway_feat_ApplicationTypeMember {
- _gql_meta: causeway_feat_ApplicationTypeMember__DomainObject_meta
- logicalTypeName: String
- memberName: String!
- namespaceName: String!
- objectIdentifier: String
- typeSimpleName: String!
+ _gql_meta: causeway_feat_ApplicationTypeMember__DomainObject_meta
+ memberName: String!
+ namespaceName: String!
+ typeSimpleName: String!
}
type causeway_feat_ApplicationTypeMember__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+ id: String!
+ logicalTypeName: String!
}
type causeway_feat_ApplicationTypeProperty {
- _gql_meta: causeway_feat_ApplicationTypeProperty__DomainObject_meta
- derived: String!
- logicalTypeName: String
- maxLength: String
- memberName: String!
- namespaceName: String!
- objectIdentifier: String
- returnType: String!
- typeSimpleName: String!
- typicalLength: String
+ _gql_meta: causeway_feat_ApplicationTypeProperty__DomainObject_meta
+ derived: String!
+ maxLength: String
+ memberName: String!
+ namespaceName: String!
+ returnType: String!
+ typeSimpleName: String!
+ typicalLength: String
}
type causeway_feat_ApplicationTypeProperty__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+ id: String!
+ logicalTypeName: String!
}
type causeway_feat_ApplicationType__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+ id: String!
+ logicalTypeName: String!
+}
+
+type causeway_schema_metamodel_v2_DomainClassDto {
+ _gql_meta: causeway_schema_metamodel_v2_DomainClassDto__DomainObject_meta
+ actions: String!
+ annotations: String!
+ collections: String!
+ facets: String!
+ id: String!
+ majorVersion: String
+ minorVersion: String
+ properties: String!
+ service: String!
+}
+
+type causeway_schema_metamodel_v2_DomainClassDto__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
type causeway_security_LoginRedirect {
- _gql_meta: causeway_security_LoginRedirect__DomainObject_meta
- logicalTypeName: String
- objectIdentifier: String
+ _gql_meta: causeway_security_LoginRedirect__DomainObject_meta
}
type causeway_security_LoginRedirect__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+ id: String!
+ logicalTypeName: String!
}
type causeway_security_LogoutMenu {
- logout: String
+ logout: String
}
type causeway_testing_fixtures_FixtureResult {
- _gql_meta: causeway_testing_fixtures_FixtureResult__DomainObject_meta
- className: String!
- fixtureScriptClassName: String
- key: String!
- logicalTypeName: String
- objectIdentifier: String
+ _gql_meta: causeway_testing_fixtures_FixtureResult__DomainObject_meta
+ className: String!
+ fixtureScriptClassName: String
+ key: String!
}
type causeway_testing_fixtures_FixtureResult__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+ id: String!
+ logicalTypeName: String!
+}
+
+type gql_test_domain_Department {
+ _gql_meta: gql_test_domain_Department__DomainObject_meta
+ deptHead: gql_test_domain_DeptHead
+ name: String!
+}
+
+type gql_test_domain_Department__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+ version: String
+}
+
+type gql_test_domain_DeptHead {
+ _gql_meta: gql_test_domain_DeptHead__DomainObject_meta
+ _gql_mutations: gql_test_domain_DeptHead__DomainObject_mutators
+ department: gql_test_domain_Department
+ name: String
+}
+
+type gql_test_domain_DeptHead__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+ version: String
+}
+
+type gql_test_domain_DeptHead__DomainObject_mutators {
+ changeDeptHead(department: _gql_input__gql_test_domain_Department!): gql_test_domain_DeptHead
+ changeName(newName: String!): gql_test_domain_DeptHead
+}
+
+type gql_test_domain_TopLevelMenu {
+ createDepartment(deptHead: _gql_input__gql_test_domain_DeptHead, name: String): gql_test_domain_Department
+ findAllDepartments: [gql_test_domain_Department]
+ findAllDeptHeads: [gql_test_domain_DeptHead]
+ findAllEntitiesWithName: [org_apache_causeway_viewer_graphql_viewer_test_domain_WithName]
+ findDeptHeadByName(name: String): gql_test_domain_DeptHead
+}
+
+type java_lang_Runnable {
+ _gql_meta: java_lang_Runnable__DomainObject_meta
+}
+
+type java_lang_Runnable__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type java_util_Map {
+ _gql_meta: java_util_Map__DomainObject_meta
+}
+
+type java_util_Map__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
type java_util_SortedMap {
- _gql_meta: java_util_SortedMap__DomainObject_meta
- logicalTypeName: String
- objectIdentifier: String
+ _gql_meta: java_util_SortedMap__DomainObject_meta
}
type java_util_SortedMap__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+ id: String!
+ logicalTypeName: String!
+}
+
+type java_util_concurrent_Callable {
+ _gql_meta: java_util_concurrent_Callable__DomainObject_meta
+}
+
+type java_util_concurrent_Callable__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type java_util_function_BiFunction {
+ _gql_meta: java_util_function_BiFunction__DomainObject_meta
+}
+
+type java_util_function_BiFunction__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type java_util_function_Consumer {
+ _gql_meta: java_util_function_Consumer__DomainObject_meta
+}
+
+type java_util_function_Consumer__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type java_util_function_Function {
+ _gql_meta: java_util_function_Function__DomainObject_meta
+}
+
+type java_util_function_Function__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
type java_util_stream_Stream {
- _gql_meta: java_util_stream_Stream__DomainObject_meta
- logicalTypeName: String
- objectIdentifier: String
+ _gql_meta: java_util_stream_Stream__DomainObject_meta
}
type java_util_stream_Stream__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+ id: String!
+ logicalTypeName: String!
}
-type org_apache_causeway_applib_services_inject_ServiceInjector {
- _gql_meta: org_apache_causeway_applib_services_inject_ServiceInjector__DomainObject_meta
- _gql_mutations: org_apache_causeway_applib_services_inject_ServiceInjector__DomainObject_mutators
- logicalTypeName: String
- objectIdentifier: String
+type org_apache_causeway_commons_functional_Either {
+ _gql_meta: org_apache_causeway_commons_functional_Either__DomainObject_meta
+ _gql_mutations: org_apache_causeway_commons_functional_Either__DomainObject_mutators
+ left: String!
+ right: String!
}
-type org_apache_causeway_applib_services_inject_ServiceInjector__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+type org_apache_causeway_commons_functional_Either__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
-type org_apache_causeway_applib_services_inject_ServiceInjector__DomainObject_mutators {
- injectServicesInto(domainObject: String): String
+type org_apache_causeway_commons_functional_Either__DomainObject_mutators {
+ accept(leftConsumer: _gql_input__java_util_function_Consumer!, rightConsumer: _gql_input__java_util_function_Consumer!): String
+ left: String
+ map(leftMapper: _gql_input__java_util_function_Function!, rightMapper: _gql_input__java_util_function_Function!): org_apache_causeway_commons_functional_Either
+ mapLeft(leftMapper: _gql_input__java_util_function_Function!): org_apache_causeway_commons_functional_Either
+ mapRight(rightMapper: _gql_input__java_util_function_Function!): org_apache_causeway_commons_functional_Either
+ right: String
}
-type org_apache_causeway_core_metamodel_inspect_model_MMNode {
- _gql_meta: org_apache_causeway_core_metamodel_inspect_model_MMNode__DomainObject_meta
- logicalTypeName: String
- objectIdentifier: String
+type org_apache_causeway_commons_functional_Railway {
+ _gql_meta: org_apache_causeway_commons_functional_Railway__DomainObject_meta
+ _gql_mutations: org_apache_causeway_commons_functional_Railway__DomainObject_mutators
+ failure: String!
+ success: String!
}
-type org_apache_causeway_core_metamodel_inspect_model_MMNode__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+type org_apache_causeway_commons_functional_Railway__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
-type org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript {
- _gql_meta: org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__DomainObject_meta
- friendlyName: String!
- logicalTypeName: String
- objectIdentifier: String
- qualifiedName: String!
+type org_apache_causeway_commons_functional_Railway__DomainObject_mutators {
+ chain(chainingFunction: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Railway
+ ifFailure(failureConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Railway
+ ifSuccess(successConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Railway
+ mapFailure(failureMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Railway
+ mapSuccess(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Railway
}
-type org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+type org_apache_causeway_commons_functional_ThrowingConsumer {
+ _gql_meta: org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_meta
+ _gql_mutations: org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_mutators
}
-type org_apache_causeway_viewer_graphql_viewer_source_gqltestdomain_TestEntity {
- _gql_meta: org_apache_causeway_viewer_graphql_viewer_source_gqltestdomain_TestEntity__DomainObject_meta
- logicalTypeName: String
- name: String!
- objectIdentifier: String
+type org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
-type org_apache_causeway_viewer_graphql_viewer_source_gqltestdomain_TestEntity__DomainObject_meta {
- id: String!
- logicalTypeName: String!
+type org_apache_causeway_commons_functional_ThrowingConsumer__DomainObject_mutators {
+ andThen(arg0: _gql_input__java_util_function_Consumer!): java_util_function_Consumer
+ throwing(exceptionWrapper: _gql_input__java_util_function_BiFunction!): org_apache_causeway_commons_functional_ThrowingConsumer
}
-input _gql_input__gqltestdomain_E1 {
- id: ID!
+type org_apache_causeway_commons_functional_ThrowingFunction {
+ _gql_meta: org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_meta
+ _gql_mutations: org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_mutators
}
-input _gql_input__gqltestdomain_E2 {
- id: ID!
+type org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
-input _gql_input__causeway_applib_ActionNode {
- id: ID!
+type org_apache_causeway_commons_functional_ThrowingFunction__DomainObject_mutators {
+ andThen(arg0: _gql_input__java_util_function_Function!): java_util_function_Function
+ compose(arg0: _gql_input__java_util_function_Function!): java_util_function_Function
+ throwing(exceptionWrapper: _gql_input__java_util_function_BiFunction!): org_apache_causeway_commons_functional_ThrowingFunction
}
-input _gql_input__causeway_applib_CollectionNode {
- id: ID!
+type org_apache_causeway_commons_functional_ThrowingRunnable {
+ _gql_meta: org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_meta
+ _gql_mutations: org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_mutators
}
-input _gql_input__causeway_applib_DomainObjectList {
- id: ID!
+type org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
}
-input _gql_input__causeway_applib_FacetAttrNode {
- id: ID!
+type org_apache_causeway_commons_functional_ThrowingRunnable__DomainObject_mutators {
+ callUncatched: String
+ run: String
+ runUncatched: String
+ toCallable: java_util_concurrent_Callable
+ toRunnable: java_lang_Runnable
}
-input _gql_input__causeway_applib_FacetGroupNode {
- id: ID!
+type org_apache_causeway_commons_functional_Try {
+ _gql_meta: org_apache_causeway_commons_functional_Try__DomainObject_meta
+ _gql_mutations: org_apache_causeway_commons_functional_Try__DomainObject_mutators
+ failure: String!
+ success: String!
+}
+
+type org_apache_causeway_commons_functional_Try__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type org_apache_causeway_commons_functional_Try__DomainObject_mutators {
+ accept(failureConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!, successConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Try
+ flatMapSuccess(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
+ flatMapSuccessAsNullable(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
+ flatMapSuccessWhenPresent(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
+ ifAbsentFail: org_apache_causeway_commons_functional_Try
+ ifFailure(exceptionConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Try
+ ifFailureFail: org_apache_causeway_commons_functional_Try
+ ifSuccess(valueConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Try
+ ifSuccessAsNullable(valueConsumer: _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer!): org_apache_causeway_commons_functional_Try
+ mapEmptyToFailure: org_apache_causeway_commons_functional_Try
+ mapFailure(failureMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
+ mapFailureToSuccess(recoveryMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
+ mapSuccess(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
+ mapSuccessAsNullable(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
+ mapSuccessWhenPresent(successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Try
+ mapToEither(failureMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!, successMapper: _gql_input__org_apache_causeway_commons_functional_ThrowingFunction!): org_apache_causeway_commons_functional_Either
+ orCall(fallback: _gql_input__java_util_concurrent_Callable!): org_apache_causeway_commons_functional_Try
+ then(next: _gql_input__java_util_concurrent_Callable!): org_apache_causeway_commons_functional_Try
+ thenCall(callable: _gql_input__java_util_concurrent_Callable!): org_apache_causeway_commons_functional_Try
+ thenRun(runnable: _gql_input__org_apache_causeway_commons_functional_ThrowingRunnable!): org_apache_causeway_commons_functional_Try
+}
+
+type org_apache_causeway_core_metamodel_inspect_model_MMNode {
+ _gql_meta: org_apache_causeway_core_metamodel_inspect_model_MMNode__DomainObject_meta
+}
+
+type org_apache_causeway_core_metamodel_inspect_model_MMNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type org_apache_causeway_core_metamodel_inspect_model_MemberNode {
+ _gql_meta: org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_meta
+ _gql_mutations: org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_mutators
+ mixedIn: String!
+ parentNode: causeway_applib_TypeNode!
+}
+
+type org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type org_apache_causeway_core_metamodel_inspect_model_MemberNode__DomainObject_mutators {
+ streamChildNodes: java_util_stream_Stream
+}
+
+type org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript {
+ _gql_meta: org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__DomainObject_meta
+ friendlyName: String!
+ qualifiedName: String!
+}
+
+type org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+type org_apache_causeway_viewer_graphql_viewer_test_domain_WithName {
+ _gql_meta: org_apache_causeway_viewer_graphql_viewer_test_domain_WithName__DomainObject_meta
+ name: String!
}
-input _gql_input__causeway_applib_FacetNode {
- id: ID!
+type org_apache_causeway_viewer_graphql_viewer_test_domain_WithName__DomainObject_meta {
+ id: String!
+ logicalTypeName: String!
+}
+
+input _gql_input__causeway_applib_DomainObjectList {
+ id: ID!
+}
+
+input _gql_input__causeway_applib_FacetGroupNode {
+ id: ID!
}
input _gql_input__causeway_applib_ParameterNode {
- id: ID!
+ id: ID!
}
input _gql_input__causeway_applib_PropertyNode {
- id: ID!
+ id: ID!
}
input _gql_input__causeway_applib_RoleMemento {
- id: ID!
+ id: ID!
}
input _gql_input__causeway_applib_TypeNode {
- id: ID!
+ id: ID!
}
input _gql_input__causeway_applib_UserMemento {
- id: ID!
+ id: ID!
+}
+
+input _gql_input__causeway_applib_node_ActionNode {
+ id: ID!
+}
+
+input _gql_input__causeway_applib_node_CollectionNode {
+ id: ID!
+}
+
+input _gql_input__causeway_applib_node_FacetAttrNode {
+ id: ID!
+}
+
+input _gql_input__causeway_applib_node_FacetNode {
+ id: ID!
}
input _gql_input__causeway_conf_ConfigurationProperty {
- id: ID!
+ id: ID!
}
input _gql_input__causeway_conf_ConfigurationViewmodel {
- id: ID!
+ id: ID!
}
input _gql_input__causeway_feat_ApplicationFeatureViewModel {
- id: ID!
+ id: ID!
}
input _gql_input__causeway_feat_ApplicationNamespace {
- id: ID!
+ id: ID!
}
input _gql_input__causeway_feat_ApplicationType {
- id: ID!
+ id: ID!
}
input _gql_input__causeway_feat_ApplicationTypeAction {
- id: ID!
+ id: ID!
}
input _gql_input__causeway_feat_ApplicationTypeCollection {
- id: ID!
+ id: ID!
}
input _gql_input__causeway_feat_ApplicationTypeMember {
- id: ID!
+ id: ID!
}
input _gql_input__causeway_feat_ApplicationTypeProperty {
- id: ID!
+ id: ID!
+}
+
+input _gql_input__causeway_schema_metamodel_v2_DomainClassDto {
+ id: ID!
}
input _gql_input__causeway_security_LoginRedirect {
- id: ID!
+ id: ID!
}
input _gql_input__causeway_testing_fixtures_FixtureResult {
- id: ID!
+ id: ID!
+}
+
+input _gql_input__gql_test_domain_Department {
+ id: ID!
+}
+
+input _gql_input__gql_test_domain_DeptHead {
+ id: ID!
+}
+
+input _gql_input__java_lang_Runnable {
+ id: ID!
+}
+
+input _gql_input__java_util_Map {
+ id: ID!
}
input _gql_input__java_util_SortedMap {
- id: ID!
+ id: ID!
+}
+
+input _gql_input__java_util_concurrent_Callable {
+ id: ID!
+}
+
+input _gql_input__java_util_function_BiFunction {
+ id: ID!
+}
+
+input _gql_input__java_util_function_Consumer {
+ id: ID!
+}
+
+input _gql_input__java_util_function_Function {
+ id: ID!
}
input _gql_input__java_util_stream_Stream {
- id: ID!
+ id: ID!
+}
+
+input _gql_input__org_apache_causeway_commons_functional_Either {
+ id: ID!
+}
+
+input _gql_input__org_apache_causeway_commons_functional_Railway {
+ id: ID!
}
-input _gql_input__org_apache_causeway_applib_services_inject_ServiceInjector {
- id: ID!
+input _gql_input__org_apache_causeway_commons_functional_ThrowingConsumer {
+ id: ID!
+}
+
+input _gql_input__org_apache_causeway_commons_functional_ThrowingFunction {
+ id: ID!
+}
+
+input _gql_input__org_apache_causeway_commons_functional_ThrowingRunnable {
+ id: ID!
+}
+
+input _gql_input__org_apache_causeway_commons_functional_Try {
+ id: ID!
}
input _gql_input__org_apache_causeway_core_metamodel_inspect_model_MMNode {
- id: ID!
+ id: ID!
+}
+
+input _gql_input__org_apache_causeway_core_metamodel_inspect_model_MemberNode {
+ id: ID!
}
input _gql_input__org_apache_causeway_testing_fixtures_applib_fixturescripts_FixtureScript {
- id: ID!
+ id: ID!
}
-input _gql_input__org_apache_causeway_viewer_graphql_viewer_source_gqltestdomain_TestEntity {
- id: ID!
+input _gql_input__org_apache_causeway_viewer_graphql_viewer_test_domain_WithName {
+ id: ID!
}
(causeway) 23/23: CAUSEWAY-3676: creates metaField within GqlvObjectSpec
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit 1bedb5424b13fd84201da11c882d1055eb078749
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Fri Jan 19 11:56:43 2024 +0000
CAUSEWAY-3676: creates metaField within GqlvObjectSpec
---
.../causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java | 9 ++++++++-
.../viewer/graphql/viewer/source/ObjectTypeFactory.java | 11 +----------
2 files changed, 9 insertions(+), 11 deletions(-)
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
index 2079bb682a..3f4e3795e8 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
@@ -37,20 +37,27 @@ public class GqlvObjectSpec {
}
@Getter private final GraphQLObjectType metaType;
+ @Getter private final GraphQLFieldDefinition metaField;
+
@Getter private final GraphQLObjectType.Builder gqlObjectTypeBuilder;
public GqlvObjectSpec(final ObjectSpecification objectSpec) {
this.objectSpec = objectSpec;
this.gqlObjectTypeBuilder = newObject().name(getLogicalTypeNameSanitized());
+ // meta type
val metaTypeBuilder = newObject().name(getLogicalTypeNameSanitized() + "__DomainObject_meta");
metaTypeBuilder.field(ObjectTypeFactory.Fields.id);
metaTypeBuilder.field(ObjectTypeFactory.Fields.logicalTypeName);
if (getBeanSort() == BeanSort.ENTITY) {
metaTypeBuilder.field(ObjectTypeFactory.Fields.version);
}
-
this.metaType = metaTypeBuilder.build();
+
+ // meta field
+ metaField = newFieldDefinition().name("_gql_meta").type(metaType).build();
+ gqlObjectTypeBuilder.field(metaField);
+
}
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
index 503a6fd4fd..688d01988c 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
@@ -106,18 +106,9 @@ public class ObjectTypeFactory {
val gqlvObjectSpec = new GqlvObjectSpec(objectSpec);
- // create meta field type
-
- GraphQLObjectType metaType = gqlvObjectSpec.getMetaType();
-
- // add meta field
- val _gql_meta_Field = newFieldDefinition().name("_gql_meta").type(metaType).build();
- gqlvObjectSpec.getGqlObjectTypeBuilder().field(_gql_meta_Field);
-
graphQLTypeRegistry.addTypeIfNotAlreadyPresent(gqlvObjectSpec.getMetaType());
-
// create input type
String inputTypeName = GQL_INPUTTYPE_PREFIX + gqlvObjectSpec.getLogicalTypeNameSanitized();
GraphQLInputObjectType.Builder inputTypeBuilder = newInputObject().name(inputTypeName);
@@ -147,7 +138,7 @@ public class ObjectTypeFactory {
// create and register data fetchers
createAndRegisterDataFetchersForMetaData(
- codeRegistryBuilder, gqlvObjectSpec.getBeanSort(), gqlvObjectSpec.getMetaType(), _gql_meta_Field, graphQLObjectType);
+ codeRegistryBuilder, gqlvObjectSpec.getBeanSort(), gqlvObjectSpec.getMetaType(), gqlvObjectSpec.getMetaField(), graphQLObjectType);
if (mutatorsDataForEntity!=null) {
createAndRegisterDataFetchersForMutators(
codeRegistryBuilder, gqlvObjectSpec.getBeanSort(), mutatorsDataForEntity, graphQLObjectType);
(causeway) 20/23: CAUSEWAY-3676: wip to considolate gqlvObjectSpec's two declarations of gqlObjectType (2)
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit 604cae5c36ab8d76ad6587a4a9b03bfec66911a1
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Fri Jan 19 11:43:46 2024 +0000
CAUSEWAY-3676: wip to considolate gqlvObjectSpec's two declarations of gqlObjectType (2)
---
.../apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
index c763b7a9d6..779bb518f0 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
@@ -145,7 +145,7 @@ public class ObjectTypeFactory {
// build and register object type
GraphQLObjectType graphQLObjectType = gqlvObjectSpec.getGqlObjectTypeBuilder().name(gqlvObjectSpec.getLogicalTypeNameSanitized()).build();
- graphQLTypeRegistry.addTypeIfNotAlreadyPresent(graphQLObjectType, gqlvObjectSpec.getLogicalTypeNameSanitized());
+ graphQLTypeRegistry.addTypeIfNotAlreadyPresent(graphQLObjectType);
// create and register data fetchers
(causeway) 12/23: CAUSEWAY-3676 : tests failing, abandon
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit a26ec842c0f42b5a7d2ce731869c250dc6d84c6f
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Thu Jan 18 23:33:38 2024 +0000
CAUSEWAY-3676 : tests failing, abandon
---
.../object/entity/_EntityFacetForTesting.java | 5 +
.../graphql/viewer/source/GqlvObjectSpec.java | 124 ++++++++
.../viewer/source/GraphQlSourceForCauseway.java | 78 ++---
.../graphql/viewer/source/ObjectTypeFactory.java | 315 +++++++++------------
.../graphql/viewer/source/QueryFieldFactory.java | 2 +-
.../viewer/graphql/viewer/source/TypeMapper.java | 4 +-
.../{_Utils.java => _GraphQLObjectType.java} | 27 +-
.../source/{_Utils.java => _LogicalTypeName.java} | 20 +-
8 files changed, 318 insertions(+), 257 deletions(-)
diff --git a/core/metamodel/src/main/java/org/apache/causeway/core/metamodel/facets/object/entity/_EntityFacetForTesting.java b/core/metamodel/src/main/java/org/apache/causeway/core/metamodel/facets/object/entity/_EntityFacetForTesting.java
index b94dc4026a..38ba7c8848 100644
--- a/core/metamodel/src/main/java/org/apache/causeway/core/metamodel/facets/object/entity/_EntityFacetForTesting.java
+++ b/core/metamodel/src/main/java/org/apache/causeway/core/metamodel/facets/object/entity/_EntityFacetForTesting.java
@@ -96,6 +96,11 @@ class _EntityFacetForTesting implements EntityFacet {
throw _Exceptions.unsupportedOperation();
}
+ @Override
+ public Object versionOf(Object pojo) {
+ return _Exceptions.unsupportedOperation();
+ }
+
@Override
public boolean isProxyEnhancement(final Method method) {
throw _Exceptions.unsupportedOperation();
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
new file mode 100644
index 0000000000..1f77da06ec
--- /dev/null
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
@@ -0,0 +1,124 @@
+package org.apache.causeway.viewer.graphql.viewer.source;
+
+import graphql.Scalars;
+import graphql.schema.GraphQLFieldDefinition;
+import graphql.schema.GraphQLList;
+import graphql.schema.GraphQLObjectType;
+
+import graphql.schema.GraphQLTypeReference;
+
+import lombok.Getter;
+import lombok.val;
+
+import org.apache.causeway.applib.services.metamodel.BeanSort;
+import org.apache.causeway.core.metamodel.spec.ObjectSpecification;
+import org.apache.causeway.core.metamodel.spec.feature.MixedIn;
+import org.apache.causeway.core.metamodel.spec.feature.OneToManyAssociation;
+import org.apache.causeway.core.metamodel.spec.feature.OneToOneAssociation;
+
+import static graphql.schema.GraphQLFieldDefinition.newFieldDefinition;
+import static graphql.schema.GraphQLNonNull.nonNull;
+import static graphql.schema.GraphQLObjectType.newObject;
+
+/**
+ * A wrapper around {@link ObjectSpecification}
+ */
+public class GqlvObjectSpec {
+
+ private final ObjectSpecification objectSpec;
+
+ public String getLogicalTypeNameSanitized() {
+ val logicalTypeName = objectSpec.getLogicalTypeName();
+ return _LogicalTypeName.sanitized(logicalTypeName);
+ }
+
+ public BeanSort getBeanSort() {
+ return objectSpec.getBeanSort();
+ }
+
+ @Getter private final GraphQLObjectType.Builder objectTypeBuilder;
+
+ @Getter private final GraphQLObjectType metaType;
+
+ static GqlvObjectSpec gqlv(final ObjectSpecification objectSpec) {
+ return new GqlvObjectSpec(objectSpec);
+ }
+
+ GqlvObjectSpec(final ObjectSpecification objectSpec) {
+ this.objectSpec = objectSpec;
+ this.objectTypeBuilder = newObject().name(getLogicalTypeNameSanitized());
+ this.metaType = _GraphQLObjectType.create(getLogicalTypeNameSanitized(), getBeanSort());
+ }
+
+
+ void addFields() {
+ objectSpec.streamProperties(MixedIn.INCLUDED)
+ .forEach(this::addField);
+ }
+
+ private void addField(OneToOneAssociation otoa) {
+ ObjectSpecification fieldObjectSpecification = otoa.getElementType();
+ BeanSort beanSort = fieldObjectSpecification.getBeanSort();
+ switch (beanSort) {
+
+ case VIEW_MODEL:
+ case ENTITY:
+
+ String logicalTypeNameOfField = fieldObjectSpecification.getLogicalTypeName();
+
+ GraphQLFieldDefinition.Builder fieldBuilder = newFieldDefinition()
+ .name(otoa.getId())
+ .type(otoa.isOptional()
+ ? GraphQLTypeReference.typeRef(
+ _LogicalTypeName.sanitized(logicalTypeNameOfField))
+ : nonNull(GraphQLTypeReference.typeRef(
+ _LogicalTypeName.sanitized(logicalTypeNameOfField))));
+ getObjectTypeBuilder().field(fieldBuilder);
+
+ break;
+
+ case VALUE:
+
+ // todo: map ...
+
+ GraphQLFieldDefinition.Builder valueBuilder = newFieldDefinition()
+ .name(otoa.getId())
+ .type(otoa.isOptional()
+ ? Scalars.GraphQLString
+ : nonNull(Scalars.GraphQLString));
+ getObjectTypeBuilder().field(valueBuilder);
+
+ break;
+
+ }
+ }
+
+ void addCollections() {
+ objectSpec.streamCollections(MixedIn.INCLUDED).forEach(this::addCollection);
+ }
+
+ private void addCollection(OneToManyAssociation otom) {
+
+ ObjectSpecification elementType = otom.getElementType();
+ BeanSort beanSort = elementType.getBeanSort();
+ switch (beanSort) {
+
+ case VIEW_MODEL:
+ case ENTITY:
+ String logicalTypeNameOfField = elementType.getLogicalTypeName();
+ GraphQLFieldDefinition.Builder fieldBuilder = newFieldDefinition()
+ .name(otom.getId())
+ .type(GraphQLList.list(GraphQLTypeReference.typeRef(
+ _LogicalTypeName.sanitized(logicalTypeNameOfField))));
+ objectTypeBuilder.field(fieldBuilder);
+ break;
+
+ case VALUE:
+ GraphQLFieldDefinition.Builder valueBuilder = newFieldDefinition()
+ .name(otom.getId())
+ .type(GraphQLList.list(TypeMapper.typeFor(elementType.getCorrespondingClass())));
+ objectTypeBuilder.field(valueBuilder);
+ break;
+ }
+ }
+}
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQlSourceForCauseway.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQlSourceForCauseway.java
index 47a717d99a..3dc550fa9c 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQlSourceForCauseway.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQlSourceForCauseway.java
@@ -30,6 +30,7 @@ import javax.annotation.PostConstruct;
import javax.inject.Inject;
import org.apache.causeway.applib.id.HasLogicalType;
+
import org.apache.causeway.core.metamodel.spec.ObjectSpecification;
import org.springframework.graphql.execution.GraphQlSource;
@@ -43,6 +44,7 @@ import org.apache.causeway.core.metamodel.specloader.SpecificationLoader;
import graphql.GraphQL;
import graphql.Scalars;
+import graphql.execution.instrumentation.tracing.TracingInstrumentation;
import graphql.schema.DataFetcher;
import graphql.schema.GraphQLCodeRegistry;
import graphql.schema.GraphQLObjectType;
@@ -87,46 +89,15 @@ public class GraphQlSourceForCauseway implements GraphQlSource {
throw new IllegalStateException("Metamodel is not fully introspected");
}
- val queryBuilder = newObject().name("Query");
- GraphQLCodeRegistry.Builder codeRegistryBuilder = GraphQLCodeRegistry.newCodeRegistry();
+ final GraphQLObjectType.Builder queryBuilder = newObject().name("Query");
+ final GraphQLCodeRegistry.Builder codeRegistryBuilder = GraphQLCodeRegistry.newCodeRegistry();
Set<GraphQLType> graphQLObjectTypes = new HashSet<>();
specificationLoader.snapshotSpecifications()
- .distinct((a, b) -> a.getLogicalTypeName().equals(b.getLogicalTypeName()))
- .sorted(Comparator.comparing(HasLogicalType::getLogicalTypeName))
- .forEach(objectSpecification -> {
-
- val logicalTypeName = objectSpecification.getLogicalTypeName();
- String logicalTypeNameSanitized = _Utils.logicalTypeNameSanitized(logicalTypeName);
-
- switch (objectSpecification.getBeanSort()) {
-
- case ABSTRACT:
- case VIEW_MODEL: // @DomainObject(nature=VIEW_MODEL)
- case ENTITY: // @DomainObject(nature=ENTITY)
-
- // TODO: App interface should mapp to gql interfaces?
- objectTypeFactory
- .objectTypeFromObjectSpecification(objectSpecification, graphQLObjectTypes, codeRegistryBuilder);
-
- break;
-
- case MANAGED_BEAN_CONTRIBUTING: //@DomainService
-
- queryFieldFactory
- .queryFieldFromObjectSpecification(queryBuilder, codeRegistryBuilder, objectSpecification);
- break;
-
- case MANAGED_BEAN_NOT_CONTRIBUTING: // a @Service or @Component ... ignore
- case MIXIN:
- case VALUE:
- case COLLECTION:
- case VETOED:
- case UNKNOWN:
- break;
- }
- });
+ .distinct((a, b) -> a.getLogicalTypeName().equals(b.getLogicalTypeName()))
+ .sorted(Comparator.comparing(HasLogicalType::getLogicalTypeName))
+ .forEach(objectSpec -> handleObjectSpec(objectSpec, graphQLObjectTypes, queryBuilder, codeRegistryBuilder));
val query_numServices = newFieldDefinition()
.name("numServices")
@@ -137,13 +108,12 @@ public class GraphQlSourceForCauseway implements GraphQlSource {
.field(query_numServices)
.build();
-
val codeRegistry = codeRegistryBuilder
- .dataFetcher(coordinates(query.getName(), query_numServices.getName()),
+ .dataFetcher(
+ coordinates(query.getName(), query_numServices.getName()),
(DataFetcher<Object>) environment -> this.serviceRegistry.streamRegisteredBeans().count())
.build();
-
return GraphQLSchema.newSchema()
.query(query)
.additionalTypes(graphQLObjectTypes)
@@ -151,4 +121,34 @@ public class GraphQlSourceForCauseway implements GraphQlSource {
.build();
}
+ private void handleObjectSpec(
+ final ObjectSpecification objectSpec,
+ final Set<GraphQLType> graphQLObjectTypes,
+ final GraphQLObjectType.Builder queryBuilder, final GraphQLCodeRegistry.Builder codeRegistryBuilder) {
+ switch (objectSpec.getBeanSort()) {
+
+ case ABSTRACT:
+ case VIEW_MODEL: // @DomainObject(nature=VIEW_MODEL)
+ case ENTITY: // @DomainObject(nature=ENTITY)
+
+ // TODO: App interface should map to gql interfaces?
+ objectTypeFactory.objectTypeFromObjectSpecification(objectSpec, graphQLObjectTypes, codeRegistryBuilder);
+
+ break;
+
+ case MANAGED_BEAN_CONTRIBUTING: //@DomainService
+
+ queryFieldFactory
+ .queryFieldFromObjectSpecification(queryBuilder, codeRegistryBuilder, objectSpec);
+ break;
+
+ case MANAGED_BEAN_NOT_CONTRIBUTING: // a @Service or @Component ... ignore
+ case MIXIN:
+ case VALUE:
+ case COLLECTION:
+ case VETOED:
+ case UNKNOWN:
+ break;
+ }
+ }
}
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
index b1f6983e2e..919fc90df4 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
@@ -32,6 +32,8 @@ import javax.inject.Inject;
import org.apache.causeway.core.metamodel.objectmanager.ObjectManager;
+import org.apache.causeway.core.metamodel.spec.feature.ObjectAction;
+
import org.springframework.stereotype.Component;
import org.apache.causeway.applib.services.bookmark.BookmarkService;
@@ -43,9 +45,6 @@ import org.apache.causeway.core.metamodel.spec.feature.MixedIn;
import org.apache.causeway.core.metamodel.spec.feature.ObjectAssociation;
import org.apache.causeway.core.metamodel.specloader.SpecificationLoader;
-import static org.apache.causeway.viewer.graphql.viewer.source._Utils.metaTypeName;
-import static org.apache.causeway.viewer.graphql.viewer.source._Utils.mutatorsTypeName;
-
import graphql.Scalars;
import graphql.schema.DataFetcher;
import graphql.schema.FieldCoordinates;
@@ -55,54 +54,73 @@ import graphql.schema.GraphQLFieldDefinition;
import graphql.schema.GraphQLInputObjectField;
import graphql.schema.GraphQLInputObjectType;
import graphql.schema.GraphQLInputType;
-import graphql.schema.GraphQLList;
import graphql.schema.GraphQLObjectType;
import graphql.schema.GraphQLOutputType;
import graphql.schema.GraphQLType;
-import graphql.schema.GraphQLTypeReference;
+
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.RequiredArgsConstructor;
+import lombok.experimental.UtilityClass;
import lombok.val;
@Component
@RequiredArgsConstructor(onConstructor_ = {@Inject})
public class ObjectTypeFactory {
+ final static String GQL_INPUTTYPE_PREFIX = "_gql_input__";
+ final static String GQL_MUTATTIONS_FIELDNAME = "_gql_mutations";
private final BookmarkService bookmarkService;
private final SpecificationLoader specificationLoader;
private final ObjectManager objectManager;
- private static GraphQLFieldDefinition idField = newFieldDefinition()
- .name("id").type(nonNull(Scalars.GraphQLString)).build();
+ static String mutatorsTypeName(final String logicalTypeNameSanitized){
+ return logicalTypeNameSanitized + "__DomainObject_mutators";
+ }
- private static GraphQLFieldDefinition logicalTypeNameField = newFieldDefinition()
- .name("logicalTypeName").type(nonNull(Scalars.GraphQLString)).build();
+ static String metaTypeName(final String logicalTypeNameSanitized){
+ return logicalTypeNameSanitized + "__DomainObject_meta";
+ }
- private static GraphQLFieldDefinition versionField = newFieldDefinition()
- .name("version").type(Scalars.GraphQLString).build();
+ @UtilityClass
+ static class Fields {
+ static GraphQLFieldDefinition id =
+ newFieldDefinition()
+ .name("id")
+ .type(nonNull(Scalars.GraphQLString))
+ .build();
+ static GraphQLFieldDefinition logicalTypeName =
+ newFieldDefinition()
+ .name("logicalTypeName")
+ .type(nonNull(Scalars.GraphQLString))
+ .build();
+ static GraphQLFieldDefinition version =
+ newFieldDefinition()
+ .name("version")
+ .type(Scalars.GraphQLString).build();
+ }
public void objectTypeFromObjectSpecification(
- final ObjectSpecification objectSpecification,
+ final ObjectSpecification objectSpec,
final Set<GraphQLType> graphQLObjectTypes,
final GraphQLCodeRegistry.Builder codeRegistryBuilder) {
- val logicalTypeName = objectSpecification.getLogicalTypeName();
- String logicalTypeNameSanitized = _Utils.logicalTypeNameSanitized(logicalTypeName);
-
- GraphQLObjectType.Builder objectTypeBuilder = newObject().name(logicalTypeNameSanitized);
+ val gqlvObjectSpec = GqlvObjectSpec.gqlv(objectSpec);
// create meta field type
- BeanSort objectSpecificationBeanSort = objectSpecification.getBeanSort();
- GraphQLObjectType metaType =
- createAndRegisterMetaType(logicalTypeNameSanitized, objectSpecificationBeanSort, graphQLObjectTypes);
+ BeanSort objectSpecificationBeanSort = objectSpec.getBeanSort();
+ final String logicalTypeNameSanitized = gqlvObjectSpec.getLogicalTypeNameSanitized();
+
+ GraphQLObjectType metaType = _GraphQLObjectType.create(logicalTypeNameSanitized, objectSpecificationBeanSort);
+
+ addTypeIfNotAlreadyPresent(graphQLObjectTypes, metaType, logicalTypeNameSanitized);
// add meta field
- GraphQLFieldDefinition gql_meta = newFieldDefinition().name("_gql_meta").type(metaType).build();
- objectTypeBuilder.field(gql_meta);
+ val _gql_meta_Field = newFieldDefinition().name("_gql_meta").type(metaType).build();
+ gqlvObjectSpec.getObjectTypeBuilder().field(_gql_meta_Field);
// create input type
- String inputTypeName = _Utils.GQL_INPUTTYPE_PREFIX + logicalTypeNameSanitized;
+ String inputTypeName = GQL_INPUTTYPE_PREFIX + gqlvObjectSpec.getLogicalTypeNameSanitized();
GraphQLInputObjectType.Builder inputTypeBuilder = newInputObject().name(inputTypeName);
inputTypeBuilder
.field(GraphQLInputObjectField.newInputObjectField()
@@ -113,28 +131,28 @@ public class ObjectTypeFactory {
addTypeIfNotAlreadyPresent(graphQLObjectTypes, inputType, inputTypeName);
// add fields
- addFields(objectSpecification, objectTypeBuilder);
+ gqlvObjectSpec.addFields();
// add collections
- addCollections(objectSpecification, objectTypeBuilder);
+ gqlvObjectSpec.addCollections();
// add actions
MutatorsDataForEntity mutatorsDataForEntity =
- addActions(logicalTypeNameSanitized, objectSpecification, objectTypeBuilder, graphQLObjectTypes);
+ addActions(gqlvObjectSpec.getLogicalTypeNameSanitized(), objectSpec, gqlvObjectSpec.getObjectTypeBuilder(), graphQLObjectTypes);
// build and register object type
- GraphQLObjectType graphQLObjectType = objectTypeBuilder.build();
- addTypeIfNotAlreadyPresent(graphQLObjectTypes, graphQLObjectType, logicalTypeNameSanitized);
+ GraphQLObjectType graphQLObjectType = gqlvObjectSpec.getObjectTypeBuilder().build();
+ addTypeIfNotAlreadyPresent(graphQLObjectTypes, graphQLObjectType, gqlvObjectSpec.getLogicalTypeNameSanitized());
// create and register data fetchers
createAndRegisterDataFetchersForMetaData(
- codeRegistryBuilder, objectSpecificationBeanSort, metaType, gql_meta, graphQLObjectType);
- if (mutatorsDataForEntity!=null) createAndRegisterDataFetchersForMutators(
- codeRegistryBuilder, objectSpecificationBeanSort, mutatorsDataForEntity, graphQLObjectType);
- createAndRegisterDataFetchersForField(objectSpecification, codeRegistryBuilder, graphQLObjectType);
- createAndRegisterDataFetchersForCollection(objectSpecification, codeRegistryBuilder, graphQLObjectType);
-
- return;
+ codeRegistryBuilder, objectSpecificationBeanSort, metaType, _gql_meta_Field, graphQLObjectType);
+ if (mutatorsDataForEntity!=null) {
+ createAndRegisterDataFetchersForMutators(
+ codeRegistryBuilder, objectSpecificationBeanSort, mutatorsDataForEntity, graphQLObjectType);
+ }
+ createAndRegisterDataFetchersForField(objectSpec, codeRegistryBuilder, graphQLObjectType);
+ createAndRegisterDataFetchersForCollection(objectSpec, codeRegistryBuilder, graphQLObjectType);
}
private void createAndRegisterDataFetchersForMutators(
@@ -177,50 +195,6 @@ public class ObjectTypeFactory {
}
}
- void addFields(
- final ObjectSpecification objectSpecification,
- final GraphQLObjectType.Builder objectTypeBuilder) {
-
- objectSpecification.streamProperties(MixedIn.INCLUDED)
- .forEach(otoa -> {
-
- ObjectSpecification fieldObjectSpecification = otoa.getElementType();
- BeanSort beanSort = fieldObjectSpecification.getBeanSort();
- switch (beanSort) {
-
- case VIEW_MODEL:
- case ENTITY:
-
- String logicalTypeNameOfField = fieldObjectSpecification.getLogicalTypeName();
-
- GraphQLFieldDefinition.Builder fieldBuilder = newFieldDefinition()
- .name(otoa.getId())
- .type(otoa.isOptional()
- ? GraphQLTypeReference.typeRef(
- _Utils.logicalTypeNameSanitized(logicalTypeNameOfField))
- : nonNull(GraphQLTypeReference.typeRef(
- _Utils.logicalTypeNameSanitized(logicalTypeNameOfField))));
- objectTypeBuilder.field(fieldBuilder);
-
- break;
-
- case VALUE:
-
- // todo: map ...
-
- GraphQLFieldDefinition.Builder valueBuilder = newFieldDefinition()
- .name(otoa.getId())
- .type(otoa.isOptional()
- ? Scalars.GraphQLString
- : nonNull(Scalars.GraphQLString));
- objectTypeBuilder.field(valueBuilder);
-
- break;
-
- }
- });
- }
-
void createAndRegisterDataFetchersForField(
final ObjectSpecification objectSpecification,
final GraphQLCodeRegistry.Builder codeRegistryBuilder,
@@ -233,43 +207,6 @@ public class ObjectTypeFactory {
});
}
- void addCollections(
- final ObjectSpecification objectSpecification,
- final GraphQLObjectType.Builder objectTypeBuilder) {
-
- objectSpecification.streamCollections(MixedIn.INCLUDED).forEach(otom -> {
-
- ObjectSpecification elementType = otom.getElementType();
- BeanSort beanSort = elementType.getBeanSort();
- switch (beanSort) {
-
- case VIEW_MODEL:
- case ENTITY:
-
- String logicalTypeNameOfField = elementType.getLogicalTypeName();
- GraphQLFieldDefinition.Builder fieldBuilder = newFieldDefinition()
- .name(otom.getId())
- .type(GraphQLList.list(GraphQLTypeReference.typeRef(
- _Utils.logicalTypeNameSanitized(logicalTypeNameOfField))));
- objectTypeBuilder.field(fieldBuilder);
-
- break;
-
- case VALUE:
-
- GraphQLFieldDefinition.Builder valueBuilder = newFieldDefinition()
- .name(otom.getId())
- .type(GraphQLList.list(TypeMapper.typeFor(elementType.getCorrespondingClass())));
- objectTypeBuilder.field(valueBuilder);
-
- break;
-
- }
-
- });
-
- }
-
void createAndRegisterDataFetchersForCollection(
final ObjectSpecification objectSpecification,
final GraphQLCodeRegistry.Builder codeRegistryBuilder,
@@ -287,67 +224,23 @@ public class ObjectTypeFactory {
final GraphQLObjectType.Builder objectTypeBuilder,
final Set<GraphQLType> graphQLObjectTypes) {
- String mutatorsTypeName = mutatorsTypeName(logicalTypeNameSanitized);
- GraphQLObjectType.Builder mutatorsTypeBuilder = newObject().name(mutatorsTypeName);
- final List<GraphQLFieldDefinition> mutatorsTypeFields = new ArrayList<>();
+ MutatorManager result = mutatorManager(logicalTypeNameSanitized);
objectSpecification.streamActions(ActionScope.PRODUCTION, MixedIn.INCLUDED)
- .forEach(objectAction -> {
-
- if (objectAction.getSemantics().isSafeInNature()) {
-
- String fieldName = objectAction.getId();
- GraphQLFieldDefinition.Builder builder = newFieldDefinition()
- .name(fieldName)
- .type((GraphQLOutputType) TypeMapper.typeForObjectAction(objectAction));
- if (objectAction.getParameters().isNotEmpty()) {
- builder.arguments(objectAction.getParameters().stream()
- .map(objectActionParameter -> GraphQLArgument.newArgument()
- .name(objectActionParameter.getId())
- .type(objectActionParameter.isOptional()
- ? TypeMapper.inputTypeFor(objectActionParameter)
- : nonNull(TypeMapper.inputTypeFor(objectActionParameter)))
- .build())
- .collect(Collectors.toList()));
- }
- objectTypeBuilder.field(builder);
-
- } else {
-
- String fieldName = objectAction.getId();
- GraphQLFieldDefinition.Builder builder = newFieldDefinition()
- .name(fieldName)
- .type((GraphQLOutputType) TypeMapper.typeForObjectAction(objectAction));
- if (objectAction.getParameters().isNotEmpty()) {
- builder.arguments(objectAction.getParameters().stream()
- .map(objectActionParameter -> GraphQLArgument.newArgument()
- .name(objectActionParameter.getId())
- .type(objectActionParameter.isOptional()
- ? TypeMapper.inputTypeFor(objectActionParameter)
- : nonNull(TypeMapper.inputTypeFor(objectActionParameter)))
- .build())
- .collect(Collectors.toList()));
- }
-
- GraphQLFieldDefinition fieldDefinition = builder.build();
- mutatorsTypeBuilder.field(fieldDefinition);
- mutatorsTypeFields.add(fieldDefinition);
-
- }
+ .forEach(objectAction ->
+ addAction(objectAction, objectTypeBuilder, result.mutatorsTypeBuilder, result.mutatorsTypeFields)
+ );
-
- });
-
- if (!mutatorsTypeFields.isEmpty()){
- GraphQLObjectType mutatorsType = mutatorsTypeBuilder.build();
- addTypeIfNotAlreadyPresent(graphQLObjectTypes, mutatorsType, mutatorsTypeName);
+ if (!result.mutatorsTypeFields.isEmpty()){
+ GraphQLObjectType mutatorsType = result.mutatorsTypeBuilder.build();
+ addTypeIfNotAlreadyPresent(graphQLObjectTypes, mutatorsType, result.mutatorsTypeName);
GraphQLFieldDefinition gql_mutations = newFieldDefinition()
- .name(_Utils.GQL_MUTATTIONS_FIELDNAME)
+ .name(GQL_MUTATTIONS_FIELDNAME)
.type(mutatorsType)
.build();
objectTypeBuilder.field(gql_mutations);
- return new MutatorsDataForEntity(mutatorsType, mutatorsTypeFields);
+ return new MutatorsDataForEntity(mutatorsType, result.mutatorsTypeFields);
// // I think we have to create and register data fetcher for mutations here, but we can't since we have no objectTypeYet
// codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(graphQLTypeReference, gql_mutations), new DataFetcher<Object>() {
@@ -376,6 +269,69 @@ public class ObjectTypeFactory {
}
+ private static MutatorManager mutatorManager(String logicalTypeNameSanitized) {
+ val mutatorsTypeName = mutatorsTypeName(logicalTypeNameSanitized);
+ GraphQLObjectType.Builder mutatorsTypeBuilder = newObject().name(mutatorsTypeName);
+ final List<GraphQLFieldDefinition> mutatorsTypeFields = new ArrayList<>();
+ MutatorManager result = new MutatorManager(mutatorsTypeName, mutatorsTypeBuilder, mutatorsTypeFields);
+ return result;
+ }
+
+ private static class MutatorManager {
+ public final String mutatorsTypeName;
+ public final GraphQLObjectType.Builder mutatorsTypeBuilder;
+ public final List<GraphQLFieldDefinition> mutatorsTypeFields;
+
+ public MutatorManager(String mutatorsTypeName, GraphQLObjectType.Builder mutatorsTypeBuilder, List<GraphQLFieldDefinition> mutatorsTypeFields) {
+ this.mutatorsTypeName = mutatorsTypeName;
+ this.mutatorsTypeBuilder = mutatorsTypeBuilder;
+ this.mutatorsTypeFields = mutatorsTypeFields;
+ }
+ }
+
+ private static void addAction(ObjectAction objectAction, GraphQLObjectType.Builder objectTypeBuilder, GraphQLObjectType.Builder mutatorsTypeBuilder, List<GraphQLFieldDefinition> mutatorsTypeFields) {
+ if (objectAction.getSemantics().isSafeInNature()) {
+
+ String fieldName = objectAction.getId();
+ GraphQLFieldDefinition.Builder builder = newFieldDefinition()
+ .name(fieldName)
+ .type((GraphQLOutputType) TypeMapper.typeForObjectAction(objectAction));
+ if (objectAction.getParameters().isNotEmpty()) {
+ builder.arguments(objectAction.getParameters().stream()
+ .map(objectActionParameter -> GraphQLArgument.newArgument()
+ .name(objectActionParameter.getId())
+ .type(objectActionParameter.isOptional()
+ ? TypeMapper.inputTypeFor(objectActionParameter)
+ : nonNull(TypeMapper.inputTypeFor(objectActionParameter)))
+ .build())
+ .collect(Collectors.toList()));
+ }
+ objectTypeBuilder.field(builder);
+
+ } else {
+
+ String fieldName = objectAction.getId();
+ GraphQLFieldDefinition.Builder builder = newFieldDefinition()
+ .name(fieldName)
+ .type((GraphQLOutputType) TypeMapper.typeForObjectAction(objectAction));
+ if (objectAction.getParameters().isNotEmpty()) {
+ builder.arguments(objectAction.getParameters().stream()
+ .map(objectActionParameter -> GraphQLArgument.newArgument()
+ .name(objectActionParameter.getId())
+ .type(objectActionParameter.isOptional()
+ ? TypeMapper.inputTypeFor(objectActionParameter)
+ : nonNull(TypeMapper.inputTypeFor(objectActionParameter)))
+ .build())
+ .collect(Collectors.toList()));
+ }
+
+ GraphQLFieldDefinition fieldDefinition = builder.build();
+ mutatorsTypeBuilder.field(fieldDefinition);
+ mutatorsTypeFields.add(fieldDefinition);
+
+ }
+ }
+
@Data
@AllArgsConstructor
class MutatorsDataForEntity {
@@ -426,23 +382,6 @@ public class ObjectTypeFactory {
}
- GraphQLObjectType createAndRegisterMetaType(
- final String logicalTypeNameSanitized,
- final BeanSort objectSpecificationBeanSort,
- final Set<GraphQLType> graphQLObjectTypes) {
-
- String metaTypeName = metaTypeName(logicalTypeNameSanitized);
- GraphQLObjectType.Builder metaTypeBuilder = newObject().name(metaTypeName);
- metaTypeBuilder.field(idField);
- metaTypeBuilder.field(logicalTypeNameField);
- if (objectSpecificationBeanSort == BeanSort.ENTITY) {
- metaTypeBuilder.field(versionField);
- }
- GraphQLObjectType metaType = metaTypeBuilder.build();
- addTypeIfNotAlreadyPresent(graphQLObjectTypes, metaType, logicalTypeNameSanitized);
- return metaType;
- }
-
GraphQLObjectType createAndRegisterMutatorsType(
final String logicalTypeNameSanitized,
final BeanSort objectSpecificationBeanSort,
@@ -469,18 +408,18 @@ public class ObjectTypeFactory {
.orElse(null); //TODO: is this correct ?
});
- codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(metaType, idField), (DataFetcher<Object>) environment -> {
+ codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(metaType, Fields.id), (DataFetcher<Object>) environment -> {
GqlMeta gqlMeta = environment.getSource();
return gqlMeta.id();
});
- codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(metaType, logicalTypeNameField), (DataFetcher<Object>) environment -> {
+ codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(metaType, Fields.logicalTypeName), (DataFetcher<Object>) environment -> {
GqlMeta gqlMeta = environment.getSource();
return gqlMeta.logicalTypeName();
});
if (objectSpecificationBeanSort == BeanSort.ENTITY) {
- codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(metaType, versionField), (DataFetcher<Object>) environment -> {
+ codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(metaType, Fields.version), (DataFetcher<Object>) environment -> {
GqlMeta gqlMeta = environment.getSource();
return gqlMeta.version();
});
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/QueryFieldFactory.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/QueryFieldFactory.java
index 6488f09124..a49452f383 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/QueryFieldFactory.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/QueryFieldFactory.java
@@ -65,7 +65,7 @@ public class QueryFieldFactory {
final ObjectSpecification objectSpecification) {
val logicalTypeName = objectSpecification.getLogicalTypeName();
- String logicalTypeNameSanitized = _Utils.logicalTypeNameSanitized(logicalTypeName);
+ String logicalTypeNameSanitized = _LogicalTypeName.sanitized(logicalTypeName);
serviceRegistry.lookupBeanById(logicalTypeName)
.ifPresent(service -> {
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/TypeMapper.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/TypeMapper.java
index 210b334fc1..cdf79bc6d5 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/TypeMapper.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/TypeMapper.java
@@ -61,7 +61,7 @@ public class TypeMapper {
case ENTITY:
case VIEW_MODEL:
- return GraphQLTypeReference.typeRef(_Utils.GQL_INPUTTYPE_PREFIX + _Utils.logicalTypeNameSanitized(elementType.getLogicalTypeName()));
+ return GraphQLTypeReference.typeRef(ObjectTypeFactory.GQL_INPUTTYPE_PREFIX + _LogicalTypeName.sanitized(elementType.getLogicalTypeName()));
case VALUE:
return (GraphQLInputType) typeFor(elementType.getCorrespondingClass());
@@ -101,7 +101,7 @@ public class TypeMapper {
case ABSTRACT:
case ENTITY:
case VIEW_MODEL:
- return GraphQLTypeReference.typeRef(_Utils.logicalTypeNameSanitized(objectSpecification.getLogicalTypeName()));
+ return GraphQLTypeReference.typeRef(_LogicalTypeName.sanitized(objectSpecification.getLogicalTypeName()));
case VALUE:
return typeFor(objectSpecification.getCorrespondingClass());
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/_Utils.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/_GraphQLObjectType.java
similarity index 51%
copy from incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/_Utils.java
copy to incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/_GraphQLObjectType.java
index a54c58336b..2d85503012 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/_Utils.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/_GraphQLObjectType.java
@@ -18,21 +18,24 @@
*/
package org.apache.causeway.viewer.graphql.viewer.source;
-final class _Utils {
+import graphql.schema.GraphQLObjectType;
- final static String GQL_INPUTTYPE_PREFIX = "_gql_input__";
- final static String GQL_MUTATTIONS_FIELDNAME = "_gql_mutations";
+import lombok.experimental.UtilityClass;
- static String metaTypeName(final String logicalTypeNameSanitized){
- return logicalTypeNameSanitized + "__DomainObject_meta";
- }
+import org.apache.causeway.applib.services.metamodel.BeanSort;
- static String mutatorsTypeName(final String logicalTypeNameSanitized){
- return logicalTypeNameSanitized + "__DomainObject_mutators";
- }
+import static graphql.schema.GraphQLObjectType.newObject;
- static String logicalTypeNameSanitized(final String logicalTypeName) {
- return logicalTypeName.replace('.', '_');
+@UtilityClass
+final class _GraphQLObjectType {
+ static GraphQLObjectType create(String logicalTypeNameSanitized, BeanSort objectSpecificationBeanSort) {
+ String metaTypeName = ObjectTypeFactory.metaTypeName(logicalTypeNameSanitized);
+ GraphQLObjectType.Builder metaTypeBuilder = newObject().name(metaTypeName);
+ metaTypeBuilder.field(ObjectTypeFactory.Fields.id);
+ metaTypeBuilder.field(ObjectTypeFactory.Fields.logicalTypeName);
+ if (objectSpecificationBeanSort == BeanSort.ENTITY) {
+ metaTypeBuilder.field(ObjectTypeFactory.Fields.version);
+ }
+ return metaTypeBuilder.build();
}
-
}
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/_Utils.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/_LogicalTypeName.java
similarity index 60%
rename from incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/_Utils.java
rename to incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/_LogicalTypeName.java
index a54c58336b..fee3851003 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/_Utils.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/_LogicalTypeName.java
@@ -18,21 +18,11 @@
*/
package org.apache.causeway.viewer.graphql.viewer.source;
-final class _Utils {
+import lombok.experimental.UtilityClass;
- final static String GQL_INPUTTYPE_PREFIX = "_gql_input__";
- final static String GQL_MUTATTIONS_FIELDNAME = "_gql_mutations";
-
- static String metaTypeName(final String logicalTypeNameSanitized){
- return logicalTypeNameSanitized + "__DomainObject_meta";
- }
-
- static String mutatorsTypeName(final String logicalTypeNameSanitized){
- return logicalTypeNameSanitized + "__DomainObject_mutators";
+@UtilityClass
+final class _LogicalTypeName {
+ static String sanitized(final String name) {
+ return name.replace('.', '_');
}
-
- static String logicalTypeNameSanitized(final String logicalTypeName) {
- return logicalTypeName.replace('.', '_');
- }
-
}
(causeway) 09/23: CAUSEWAY-3676: uses EntityFacet to obtain version of GQLMeta
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit 0326b755cf19647521f607ebbe0746c5670c030e
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Thu Jan 18 19:13:46 2024 +0000
CAUSEWAY-3676: uses EntityFacet to obtain version of GQLMeta
---
.../viewer/graphql/viewer/source/GQLMeta.java | 19 +++++++++++++++----
.../graphql/viewer/source/ObjectTypeFactory.java | 16 ++++++----------
2 files changed, 21 insertions(+), 14 deletions(-)
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GQLMeta.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GQLMeta.java
index 81ab30f536..508af3e0c9 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GQLMeta.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GQLMeta.java
@@ -20,14 +20,20 @@ package org.apache.causeway.viewer.graphql.viewer.source;
import org.apache.causeway.applib.services.bookmark.Bookmark;
import org.apache.causeway.applib.services.bookmark.BookmarkService;
+import org.apache.causeway.core.metamodel.facets.object.entity.EntityFacet;
+import org.apache.causeway.core.metamodel.objectmanager.ObjectManager;
import lombok.Data;
+import java.util.Objects;
+import java.util.Optional;
+
@Data
public class GQLMeta {
private final Bookmark bookmark;
private final BookmarkService bookmarkService;
+ private final ObjectManager objectManager;
public String logicalTypeName(){
return bookmark.getLogicalTypeName();
@@ -39,10 +45,15 @@ public class GQLMeta {
public String version(){
Object domainObject = bookmarkService.lookup(bookmark).orElse(null);
- if (domainObject == null) return null;
-
- // TODO: implement; we would like to be this independent of the persistence mechanism
- return null;
+ if (domainObject == null) {
+ return null;
+ }
+ EntityFacet entityFacet = objectManager.adapt(domainObject).getSpecification().getFacet(EntityFacet.class);
+ return Optional.ofNullable(entityFacet)
+ .map(x -> x.versionOf(domainObject))
+ .filter(Objects::nonNull)
+ .map(Object::toString)
+ .orElse(null);
}
}
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
index 82469262c8..172fe20914 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
@@ -30,6 +30,8 @@ import java.util.stream.Collectors;
import javax.inject.Inject;
+import org.apache.causeway.core.metamodel.objectmanager.ObjectManager;
+
import org.springframework.stereotype.Component;
import org.apache.causeway.applib.services.bookmark.Bookmark;
@@ -70,6 +72,7 @@ public class ObjectTypeFactory {
private final BookmarkService bookmarkService;
private final SpecificationLoader specificationLoader;
+ private final ObjectManager objectManager;
private static GraphQLFieldDefinition idField = newFieldDefinition()
.name("id").type(nonNull(Scalars.GraphQLString)).build();
@@ -462,31 +465,24 @@ public class ObjectTypeFactory {
final GraphQLObjectType graphQLObjectType) {
codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(graphQLObjectType, gql_meta), (DataFetcher<Object>) environment -> {
-
- Bookmark bookmark = bookmarkService.bookmarkFor(environment.getSource()).orElse(null);
- if (bookmark == null) return null; //TODO: is this correct ?
- return new GQLMeta(bookmark, bookmarkService);
+ return bookmarkService.bookmarkFor(environment.getSource())
+ .map(bookmark -> new GQLMeta(bookmark, bookmarkService, objectManager))
+ .orElse(null); //TODO: is this correct ?
});
codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(metaType, idField), (DataFetcher<Object>) environment -> {
-
GQLMeta gqlMeta = environment.getSource();
-
return gqlMeta.id();
});
codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(metaType, logicalTypeNameField), (DataFetcher<Object>) environment -> {
-
GQLMeta gqlMeta = environment.getSource();
-
return gqlMeta.logicalTypeName();
});
if (objectSpecificationBeanSort == BeanSort.ENTITY) {
codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(metaType, versionField), (DataFetcher<Object>) environment -> {
-
GQLMeta gqlMeta = environment.getSource();
-
return gqlMeta.version();
});
(causeway) 10/23: CAUSEWAY-3676: renames GQLMeta to GqlMeta
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit 7c84bb809b69bbfd26cce92b1c723d20b0f13484
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Thu Jan 18 19:14:04 2024 +0000
CAUSEWAY-3676: renames GQLMeta to GqlMeta
---
.../graphql/viewer/source/{GQLMeta.java => GqlMeta.java} | 2 +-
.../viewer/graphql/viewer/source/ObjectTypeFactory.java | 11 +++++------
2 files changed, 6 insertions(+), 7 deletions(-)
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GQLMeta.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlMeta.java
similarity index 98%
rename from incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GQLMeta.java
rename to incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlMeta.java
index 508af3e0c9..4a464fb620 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GQLMeta.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlMeta.java
@@ -29,7 +29,7 @@ import java.util.Objects;
import java.util.Optional;
@Data
-public class GQLMeta {
+public class GqlMeta {
private final Bookmark bookmark;
private final BookmarkService bookmarkService;
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
index 172fe20914..55b43e5780 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
@@ -34,7 +34,6 @@ import org.apache.causeway.core.metamodel.objectmanager.ObjectManager;
import org.springframework.stereotype.Component;
-import org.apache.causeway.applib.services.bookmark.Bookmark;
import org.apache.causeway.applib.services.bookmark.BookmarkService;
import org.apache.causeway.applib.services.metamodel.BeanSort;
import org.apache.causeway.core.metamodel.object.ManagedObject;
@@ -366,7 +365,7 @@ public class ObjectTypeFactory {
// @Override
// public Object get(DataFetchingEnvironment environment) throws Exception {
//
-// GQLMeta gqlMeta = environment.getSource();
+// GqlMeta gqlMeta = environment.getSource();
//
// return gqlMeta.id();
// }
@@ -466,23 +465,23 @@ public class ObjectTypeFactory {
codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(graphQLObjectType, gql_meta), (DataFetcher<Object>) environment -> {
return bookmarkService.bookmarkFor(environment.getSource())
- .map(bookmark -> new GQLMeta(bookmark, bookmarkService, objectManager))
+ .map(bookmark -> new GqlMeta(bookmark, bookmarkService, objectManager))
.orElse(null); //TODO: is this correct ?
});
codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(metaType, idField), (DataFetcher<Object>) environment -> {
- GQLMeta gqlMeta = environment.getSource();
+ GqlMeta gqlMeta = environment.getSource();
return gqlMeta.id();
});
codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(metaType, logicalTypeNameField), (DataFetcher<Object>) environment -> {
- GQLMeta gqlMeta = environment.getSource();
+ GqlMeta gqlMeta = environment.getSource();
return gqlMeta.logicalTypeName();
});
if (objectSpecificationBeanSort == BeanSort.ENTITY) {
codeRegistryBuilder.dataFetcher(FieldCoordinates.coordinates(metaType, versionField), (DataFetcher<Object>) environment -> {
- GQLMeta gqlMeta = environment.getSource();
+ GqlMeta gqlMeta = environment.getSource();
return gqlMeta.version();
});
(causeway) 14/23: CAUSEWAY-3676: introduces GraphQLTypeRegistry
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit d5ea89dada2fb574b78a5e27413aaea90ceb05f1
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Fri Jan 19 11:25:23 2024 +0000
CAUSEWAY-3676: introduces GraphQLTypeRegistry
---
.../integration/GraphQlSourceForCauseway.java | 13 +-
.../graphql/viewer/source/GraphQLTypeRegistry.java | 135 +++++++++++++++++++++
.../graphql/viewer/source/ObjectTypeFactory.java | 82 ++-----------
3 files changed, 149 insertions(+), 81 deletions(-)
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/integration/GraphQlSourceForCauseway.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/integration/GraphQlSourceForCauseway.java
index 2e697b6a5b..536b72c2e2 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/integration/GraphQlSourceForCauseway.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/integration/GraphQlSourceForCauseway.java
@@ -33,8 +33,7 @@ import org.apache.causeway.applib.id.HasLogicalType;
import org.apache.causeway.core.metamodel.spec.ObjectSpecification;
-import org.apache.causeway.viewer.graphql.viewer.integration.AsyncExecutionStrategyResolvingWithinInteraction;
-
+import org.apache.causeway.viewer.graphql.viewer.source.GraphQLTypeRegistry;
import org.apache.causeway.viewer.graphql.viewer.source.ObjectTypeFactory;
import org.apache.causeway.viewer.graphql.viewer.source.QueryFieldFactory;
@@ -68,6 +67,7 @@ public class GraphQlSourceForCauseway implements GraphQlSource {
private final AsyncExecutionStrategyResolvingWithinInteraction executionStrategy;
private final ObjectTypeFactory objectTypeFactory;
private final QueryFieldFactory queryFieldFactory;
+ private final GraphQLTypeRegistry graphQLTypeRegistry;
@PostConstruct
public void init() {
@@ -96,12 +96,10 @@ public class GraphQlSourceForCauseway implements GraphQlSource {
final GraphQLObjectType.Builder queryBuilder = newObject().name("Query");
final GraphQLCodeRegistry.Builder codeRegistryBuilder = GraphQLCodeRegistry.newCodeRegistry();
- Set<GraphQLType> graphQLObjectTypes = new HashSet<>();
-
specificationLoader.snapshotSpecifications()
.distinct((a, b) -> a.getLogicalTypeName().equals(b.getLogicalTypeName()))
.sorted(Comparator.comparing(HasLogicalType::getLogicalTypeName))
- .forEach(objectSpec -> handleObjectSpec(objectSpec, graphQLObjectTypes, queryBuilder, codeRegistryBuilder));
+ .forEach(objectSpec -> handleObjectSpec(objectSpec, queryBuilder, codeRegistryBuilder));
val query_numServices = newFieldDefinition()
.name("numServices")
@@ -120,14 +118,13 @@ public class GraphQlSourceForCauseway implements GraphQlSource {
return GraphQLSchema.newSchema()
.query(query)
- .additionalTypes(graphQLObjectTypes)
+ .additionalTypes(graphQLTypeRegistry.getGraphQLObjectTypes())
.codeRegistry(codeRegistry)
.build();
}
private void handleObjectSpec(
final ObjectSpecification objectSpec,
- final Set<GraphQLType> graphQLObjectTypes,
final GraphQLObjectType.Builder queryBuilder,
final GraphQLCodeRegistry.Builder codeRegistryBuilder
) {
@@ -139,7 +136,7 @@ public class GraphQlSourceForCauseway implements GraphQlSource {
case ENTITY: // @DomainObject(nature=ENTITY)
// TODO: App interface should map to gql interfaces?
- objectTypeFactory.objectTypeFromObjectSpecification(objectSpec, graphQLObjectTypes, codeRegistryBuilder);
+ objectTypeFactory.objectTypeFromObjectSpecification(objectSpec, codeRegistryBuilder);
break;
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQLTypeRegistry.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQLTypeRegistry.java
new file mode 100644
index 0000000000..a5fb72e23d
--- /dev/null
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQLTypeRegistry.java
@@ -0,0 +1,135 @@
+package org.apache.causeway.viewer.graphql.viewer.source;
+
+import graphql.schema.GraphQLInputObjectType;
+import graphql.schema.GraphQLNamedType;
+import graphql.schema.GraphQLObjectType;
+import graphql.schema.GraphQLType;
+
+import lombok.extern.log4j.Log4j2;
+
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.Set;
+
+import org.springframework.stereotype.Component;
+
+@Component
+@Log4j2
+public class GraphQLTypeRegistry {
+
+
+ Set<GraphQLType> graphQLObjectTypes = new HashSet<>();
+
+ public Set<GraphQLType> getGraphQLObjectTypes() {
+ return Collections.unmodifiableSet(graphQLObjectTypes);
+ }
+
+
+ void addTypeIfNotAlreadyPresent(
+ final GraphQLType typeToAdd,
+ final String logicalTypeName) {
+
+ if (typeToAdd instanceof GraphQLObjectType) {
+ addTypeIfNotAlreadyPresent((GraphQLObjectType) typeToAdd, logicalTypeName);
+ return;
+ }
+
+ if (typeToAdd instanceof GraphQLInputObjectType) {
+ addTypeIfNotAlreadyPresent((GraphQLInputObjectType) typeToAdd, logicalTypeName);
+ return;
+ }
+
+ // TODO: none of these types yet handled
+ // GraphQLTypeReference
+ // GraphQLScalarType
+ // GraphQLCompositeType
+ // GraphQLUnionType
+ // GraphQLEnumType
+ // GraphQLInterfaceType
+ // GraphQLList
+ // GraphQLNonNull
+ log.warn("GraphQLType {} not yet implemented", typeToAdd.getClass().getName());
+ }
+
+ void addTypeIfNotAlreadyPresent(
+ final GraphQLInputObjectType typeToAdd,
+ final String logicalTypeName) {
+ if (isPresent(typeToAdd, GraphQLInputObjectType.class)){
+ // For now we just log and skip
+ log.info("GraphQLInputObjectType for {} already present", logicalTypeName);
+ return;
+ }
+ graphQLObjectTypes.add(typeToAdd);
+ }
+
+ void addTypeIfNotAlreadyPresent(
+ final GraphQLObjectType typeToAdd,
+ final String logicalTypeName){
+
+ if (isPresent(typeToAdd, GraphQLObjectType.class)){
+ // For now we just log and skip
+ log.info("GraphQLObjectType for {} already present", logicalTypeName);
+ return;
+ }
+ graphQLObjectTypes.add(typeToAdd);
+ }
+
+
+ public void addTypeIfNotAlreadyPresent(final GraphQLType typeToAdd) {
+
+ if (typeToAdd instanceof GraphQLObjectType) {
+ addTypeIfNotAlreadyPresent((GraphQLObjectType) typeToAdd);
+ return;
+ }
+
+ if (typeToAdd instanceof GraphQLInputObjectType) {
+ addTypeIfNotAlreadyPresent((GraphQLInputObjectType) typeToAdd);
+ return;
+ }
+
+ // TODO: none of these types yet handled
+ // GraphQLTypeReference
+ // GraphQLScalarType
+ // GraphQLCompositeType
+ // GraphQLUnionType
+ // GraphQLEnumType
+ // GraphQLInterfaceType
+ // GraphQLList
+ // GraphQLNonNull
+ log.warn("GraphQLType {} not yet implemented", typeToAdd.getClass().getName());
+ }
+
+ void addTypeIfNotAlreadyPresent(final GraphQLObjectType typeToAdd){
+ if (isPresent(typeToAdd, GraphQLObjectType.class)){
+ // For now we just log and skip
+ log.info("GraphQLObjectType for {} already present", typeToAdd.getName());
+ return;
+ }
+ add(typeToAdd);
+ }
+
+
+ void addTypeIfNotAlreadyPresent(final GraphQLInputObjectType typeToAdd) {
+ if (isPresent(typeToAdd, GraphQLInputObjectType.class)){
+ // For now we just log and skip
+ log.info("GraphQLInputObjectType for {} already present", typeToAdd.getName());
+ return;
+ }
+ add(typeToAdd);
+ }
+
+ private boolean isPresent(
+ final GraphQLNamedType typeToAdd,
+ final Class<? extends GraphQLNamedType> cls) {
+ return graphQLObjectTypes.stream()
+ .filter(o -> o.getClass().isAssignableFrom(cls))
+ .map(cls::cast)
+ .anyMatch(ot -> ot.getName().equals(typeToAdd.getName()));
+ }
+
+
+ private void add(GraphQLType typeToAdd) {
+ graphQLObjectTypes.add(typeToAdd);
+ }
+
+}
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
index 4490daf6c9..0810a15e90 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
@@ -54,7 +54,6 @@ import graphql.schema.GraphQLFieldDefinition;
import graphql.schema.GraphQLInputObjectField;
import graphql.schema.GraphQLInputObjectType;
import graphql.schema.GraphQLInputType;
-import graphql.schema.GraphQLNamedType;
import graphql.schema.GraphQLObjectType;
import graphql.schema.GraphQLOutputType;
import graphql.schema.GraphQLType;
@@ -63,7 +62,6 @@ import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.RequiredArgsConstructor;
import lombok.experimental.UtilityClass;
-import lombok.extern.java.Log;
import lombok.extern.log4j.Log4j2;
import lombok.val;
@@ -73,10 +71,11 @@ import lombok.val;
public class ObjectTypeFactory {
final static String GQL_INPUTTYPE_PREFIX = "_gql_input__";
- final static String GQL_MUTATTIONS_FIELDNAME = "_gql_mutations";
+ final static String GQL_MUTATIONS_FIELDNAME = "_gql_mutations";
private final BookmarkService bookmarkService;
private final SpecificationLoader specificationLoader;
private final ObjectManager objectManager;
+ private final GraphQLTypeRegistry graphQLTypeRegistry;
static String mutatorsTypeName(final String logicalTypeNameSanitized){
return logicalTypeNameSanitized + "__DomainObject_mutators";
@@ -106,7 +105,6 @@ public class ObjectTypeFactory {
public void objectTypeFromObjectSpecification(
final ObjectSpecification objectSpec,
- final Set<GraphQLType> graphQLObjectTypes,
final GraphQLCodeRegistry.Builder codeRegistryBuilder) {
val gqlvObjectSpec = new GqlvObjectSpec(objectSpec);
@@ -117,7 +115,7 @@ public class ObjectTypeFactory {
GraphQLObjectType metaType = gqlvObjectSpec.getMetaType();
- addTypeIfNotAlreadyPresent(graphQLObjectTypes, metaType, logicalTypeNameSanitized);
+ graphQLTypeRegistry.addTypeIfNotAlreadyPresent(metaType, logicalTypeNameSanitized);
// add meta field
val _gql_meta_Field = newFieldDefinition().name("_gql_meta").type(metaType).build();
@@ -133,7 +131,7 @@ public class ObjectTypeFactory {
.build());
GraphQLInputType inputType = inputTypeBuilder.build();
- addTypeIfNotAlreadyPresent(graphQLObjectTypes, inputType, inputTypeName);
+ graphQLTypeRegistry.addTypeIfNotAlreadyPresent(inputType, inputTypeName);
// add fields
gqlvObjectSpec.addFields();
@@ -143,11 +141,11 @@ public class ObjectTypeFactory {
// add actions
MutatorsDataForEntity mutatorsDataForEntity =
- addActions(gqlvObjectSpec.getLogicalTypeNameSanitized(), objectSpec, gqlvObjectSpec.getObjectTypeBuilder(), graphQLObjectTypes);
+ addActions(gqlvObjectSpec.getLogicalTypeNameSanitized(), objectSpec, gqlvObjectSpec.getObjectTypeBuilder());
// build and register object type
GraphQLObjectType graphQLObjectType = gqlvObjectSpec.getObjectTypeBuilder().build();
- addTypeIfNotAlreadyPresent(graphQLObjectTypes, graphQLObjectType, gqlvObjectSpec.getLogicalTypeNameSanitized());
+ graphQLTypeRegistry.addTypeIfNotAlreadyPresent(graphQLObjectType, gqlvObjectSpec.getLogicalTypeNameSanitized());
// create and register data fetchers
createAndRegisterDataFetchersForMetaData(
@@ -168,67 +166,6 @@ public class ObjectTypeFactory {
}
- void addTypeIfNotAlreadyPresent(
- final Set<GraphQLType> graphQLObjectTypes,
- final GraphQLType typeToAdd,
- final String logicalTypeName) {
-
- if (typeToAdd instanceof GraphQLObjectType) {
- addTypeIfNotAlreadyPresent(graphQLObjectTypes, (GraphQLObjectType) typeToAdd, logicalTypeName);
- return;
- }
-
- if (typeToAdd instanceof GraphQLInputObjectType) {
- addTypeIfNotAlreadyPresent(graphQLObjectTypes, (GraphQLInputObjectType) typeToAdd, logicalTypeName);
- return;
- }
-
- // TODO: none of these types yet handled
- // GraphQLTypeReference
- // GraphQLScalarType
- // GraphQLCompositeType
- // GraphQLUnionType
- // GraphQLEnumType
- // GraphQLInterfaceType
- // GraphQLList
- // GraphQLNonNull
- log.warn("GraphQLType {} not yet implemented", typeToAdd.getClass().getName());
- }
-
- private static void addTypeIfNotAlreadyPresent(
- final Set<GraphQLType> graphQLObjectTypes,
- final GraphQLInputObjectType typeToAdd,
- final String logicalTypeName) {
- if (isPresent(graphQLObjectTypes, typeToAdd, GraphQLInputObjectType.class)){
- // For now we just log and skip
- log.info("GraphQLInputObjectType for {} already present", logicalTypeName);
- return;
- }
- graphQLObjectTypes.add(typeToAdd);
- }
-
- void addTypeIfNotAlreadyPresent(
- final Set<GraphQLType> graphQLObjectTypes,
- final GraphQLObjectType typeToAdd,
- final String logicalTypeName){
-
- if (isPresent(graphQLObjectTypes, typeToAdd, GraphQLObjectType.class)){
- // For now we just log and skip
- log.info("GraphQLObjectType for {} already present", logicalTypeName);
- return;
- }
- graphQLObjectTypes.add(typeToAdd);
- }
-
- private static boolean isPresent(
- final Set<GraphQLType> graphQLObjectTypes,
- final GraphQLNamedType typeToAdd,
- final Class<? extends GraphQLNamedType> cls) {
- return graphQLObjectTypes.stream()
- .filter(o -> o.getClass().isAssignableFrom(cls))
- .map(cls::cast)
- .anyMatch(ot -> ot.getName().equals(typeToAdd.getName()));
- }
void createAndRegisterDataFetchersForField(
final ObjectSpecification objectSpecification,
@@ -256,8 +193,7 @@ public class ObjectTypeFactory {
MutatorsDataForEntity addActions(
final String logicalTypeNameSanitized,
final ObjectSpecification objectSpecification,
- final GraphQLObjectType.Builder objectTypeBuilder,
- final Set<GraphQLType> graphQLObjectTypes) {
+ final GraphQLObjectType.Builder objectTypeBuilder) {
MutatorManager result = mutatorManager(logicalTypeNameSanitized);
@@ -268,9 +204,9 @@ public class ObjectTypeFactory {
if (!result.mutatorsTypeFields.isEmpty()){
GraphQLObjectType mutatorsType = result.mutatorsTypeBuilder.build();
- addTypeIfNotAlreadyPresent(graphQLObjectTypes, mutatorsType, result.mutatorsTypeName);
+ graphQLTypeRegistry.addTypeIfNotAlreadyPresent(mutatorsType, result.mutatorsTypeName);
GraphQLFieldDefinition gql_mutations = newFieldDefinition()
- .name(GQL_MUTATTIONS_FIELDNAME)
+ .name(GQL_MUTATIONS_FIELDNAME)
.type(mutatorsType)
.build();
objectTypeBuilder.field(gql_mutations);
(causeway) 16/23: CAUSEWAY-3676: removes unused overload
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit 8137c9a6e1b289471ff2dea8867998aeae8a9157
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Fri Jan 19 11:28:11 2024 +0000
CAUSEWAY-3676: removes unused overload
---
.../graphql/viewer/source/GraphQLTypeRegistry.java | 25 ----------------------
.../graphql/viewer/source/ObjectTypeFactory.java | 2 +-
2 files changed, 1 insertion(+), 26 deletions(-)
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQLTypeRegistry.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQLTypeRegistry.java
index fda75e3252..cfd507e57b 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQLTypeRegistry.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GraphQLTypeRegistry.java
@@ -25,31 +25,6 @@ public class GraphQLTypeRegistry {
}
- void addTypeIfNotAlreadyPresent(
- final GraphQLType typeToAdd,
- final String logicalTypeName) {
-
- if (typeToAdd instanceof GraphQLObjectType) {
- addTypeIfNotAlreadyPresent((GraphQLObjectType) typeToAdd);
- return;
- }
-
- if (typeToAdd instanceof GraphQLInputObjectType) {
- addTypeIfNotAlreadyPresent((GraphQLInputObjectType) typeToAdd);
- return;
- }
-
- // TODO: none of these types yet handled
- // GraphQLTypeReference
- // GraphQLScalarType
- // GraphQLCompositeType
- // GraphQLUnionType
- // GraphQLEnumType
- // GraphQLInterfaceType
- // GraphQLList
- // GraphQLNonNull
- log.warn("GraphQLType {} not yet implemented", typeToAdd.getClass().getName());
- }
void addTypeIfNotAlreadyPresent(
final GraphQLInputObjectType typeToAdd,
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
index 0810a15e90..e6adec3a55 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
@@ -131,7 +131,7 @@ public class ObjectTypeFactory {
.build());
GraphQLInputType inputType = inputTypeBuilder.build();
- graphQLTypeRegistry.addTypeIfNotAlreadyPresent(inputType, inputTypeName);
+ graphQLTypeRegistry.addTypeIfNotAlreadyPresent(inputType);
// add fields
gqlvObjectSpec.addFields();
(causeway) 18/23: CAUSEWAY-3676: trivial
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit c5e6b05d50a17196e6e9f77ffc6f416b3e867f5d
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Fri Jan 19 11:37:19 2024 +0000
CAUSEWAY-3676: trivial
---
.../causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java | 7 +++----
.../causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java | 2 ++
2 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
index adec308cd5..6a6a80de08 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
@@ -52,14 +52,13 @@ public class GqlvObjectSpec {
}
private void addField(OneToOneAssociation otoa) {
- ObjectSpecification fieldObjectSpecification = otoa.getElementType();
- BeanSort beanSort = fieldObjectSpecification.getBeanSort();
- switch (beanSort) {
+ ObjectSpecification otoaObjectSpec = otoa.getElementType();
+ switch (otoaObjectSpec.getBeanSort()) {
case VIEW_MODEL:
case ENTITY:
- String logicalTypeNameOfField = fieldObjectSpecification.getLogicalTypeName();
+ String logicalTypeNameOfField = otoaObjectSpec.getLogicalTypeName();
GraphQLFieldDefinition.Builder fieldBuilder = newFieldDefinition()
.name(otoa.getId())
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
index 38cbc372fd..31344fe9e9 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
@@ -120,6 +120,7 @@ public class ObjectTypeFactory {
val _gql_meta_Field = newFieldDefinition().name("_gql_meta").type(metaType).build();
gqlvObjectSpec.getObjectTypeBuilder().field(_gql_meta_Field);
+
// create input type
String inputTypeName = GQL_INPUTTYPE_PREFIX + gqlvObjectSpec.getLogicalTypeNameSanitized();
GraphQLInputObjectType.Builder inputTypeBuilder = newInputObject().name(inputTypeName);
@@ -146,6 +147,7 @@ public class ObjectTypeFactory {
GraphQLObjectType graphQLObjectType = gqlvObjectSpec.getObjectTypeBuilder().build();
graphQLTypeRegistry.addTypeIfNotAlreadyPresent(graphQLObjectType, gqlvObjectSpec.getLogicalTypeNameSanitized());
+
// create and register data fetchers
createAndRegisterDataFetchersForMetaData(
codeRegistryBuilder, objectSpecificationBeanSort, metaType, _gql_meta_Field, graphQLObjectType);
(causeway) 21/23: CAUSEWAY-3676: inlines utility method
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit eecbd42622179c1bd59d0759186c2c4f4820df66
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Fri Jan 19 11:46:54 2024 +0000
CAUSEWAY-3676: inlines utility method
---
.../graphql/viewer/source/GqlvObjectSpec.java | 11 +++++-
.../graphql/viewer/source/ObjectTypeFactory.java | 1 +
.../graphql/viewer/source/_GraphQLObjectType.java | 41 ----------------------
3 files changed, 11 insertions(+), 42 deletions(-)
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
index d2c6712342..32c2140932 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
@@ -42,7 +42,16 @@ public class GqlvObjectSpec {
public GqlvObjectSpec(final ObjectSpecification objectSpec) {
this.objectSpec = objectSpec;
this.gqlObjectTypeBuilder = newObject().name(getLogicalTypeNameSanitized());
- this.gqlObjectType = _GraphQLObjectType.create(getLogicalTypeNameSanitized(), getBeanSort());
+ String logicalTypeNameSanitized = getLogicalTypeNameSanitized();
+ BeanSort objectSpecificationBeanSort = getBeanSort();
+ String metaTypeName = ObjectTypeFactory.metaTypeName(logicalTypeNameSanitized);
+ GraphQLObjectType.Builder metaTypeBuilder = newObject().name(metaTypeName);
+ metaTypeBuilder.field(ObjectTypeFactory.Fields.id);
+ metaTypeBuilder.field(ObjectTypeFactory.Fields.logicalTypeName);
+ if (objectSpecificationBeanSort == BeanSort.ENTITY) {
+ metaTypeBuilder.field(ObjectTypeFactory.Fields.version);
+ }
+ this.gqlObjectType = metaTypeBuilder.build();
}
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
index 779bb518f0..dd388eaf38 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
@@ -113,6 +113,7 @@ public class ObjectTypeFactory {
BeanSort objectSpecificationBeanSort = gqlvObjectSpec.getBeanSort();
GraphQLObjectType metaType = gqlvObjectSpec.getGqlObjectType();
+
// add meta field
val _gql_meta_Field = newFieldDefinition().name("_gql_meta").type(metaType).build();
gqlvObjectSpec.getGqlObjectTypeBuilder().field(_gql_meta_Field);
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/_GraphQLObjectType.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/_GraphQLObjectType.java
deleted file mode 100644
index 2d85503012..0000000000
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/_GraphQLObjectType.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * 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.
- */
-package org.apache.causeway.viewer.graphql.viewer.source;
-
-import graphql.schema.GraphQLObjectType;
-
-import lombok.experimental.UtilityClass;
-
-import org.apache.causeway.applib.services.metamodel.BeanSort;
-
-import static graphql.schema.GraphQLObjectType.newObject;
-
-@UtilityClass
-final class _GraphQLObjectType {
- static GraphQLObjectType create(String logicalTypeNameSanitized, BeanSort objectSpecificationBeanSort) {
- String metaTypeName = ObjectTypeFactory.metaTypeName(logicalTypeNameSanitized);
- GraphQLObjectType.Builder metaTypeBuilder = newObject().name(metaTypeName);
- metaTypeBuilder.field(ObjectTypeFactory.Fields.id);
- metaTypeBuilder.field(ObjectTypeFactory.Fields.logicalTypeName);
- if (objectSpecificationBeanSort == BeanSort.ENTITY) {
- metaTypeBuilder.field(ObjectTypeFactory.Fields.version);
- }
- return metaTypeBuilder.build();
- }
-}
(causeway) 22/23: CAUSEWAY-3676: inlines vars obtained from gqlvObjectSpec
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
danhaywood pushed a commit to branch CAUSEWAY-3676
in repository https://gitbox.apache.org/repos/asf/causeway.git
commit 5ab45882813ea3e4c9ab2671e21b1fc30540f9cc
Author: danhaywood <da...@haywood-associates.co.uk>
AuthorDate: Fri Jan 19 11:51:22 2024 +0000
CAUSEWAY-3676: inlines vars obtained from gqlvObjectSpec
---
.../viewer/graphql/viewer/source/GqlvObjectSpec.java | 13 ++++++-------
.../viewer/graphql/viewer/source/ObjectTypeFactory.java | 14 +++++---------
2 files changed, 11 insertions(+), 16 deletions(-)
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
index 32c2140932..2079bb682a 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/GqlvObjectSpec.java
@@ -36,22 +36,21 @@ public class GqlvObjectSpec {
return objectSpec.getBeanSort();
}
+ @Getter private final GraphQLObjectType metaType;
@Getter private final GraphQLObjectType.Builder gqlObjectTypeBuilder;
- @Getter private final GraphQLObjectType gqlObjectType;
public GqlvObjectSpec(final ObjectSpecification objectSpec) {
this.objectSpec = objectSpec;
this.gqlObjectTypeBuilder = newObject().name(getLogicalTypeNameSanitized());
- String logicalTypeNameSanitized = getLogicalTypeNameSanitized();
- BeanSort objectSpecificationBeanSort = getBeanSort();
- String metaTypeName = ObjectTypeFactory.metaTypeName(logicalTypeNameSanitized);
- GraphQLObjectType.Builder metaTypeBuilder = newObject().name(metaTypeName);
+
+ val metaTypeBuilder = newObject().name(getLogicalTypeNameSanitized() + "__DomainObject_meta");
metaTypeBuilder.field(ObjectTypeFactory.Fields.id);
metaTypeBuilder.field(ObjectTypeFactory.Fields.logicalTypeName);
- if (objectSpecificationBeanSort == BeanSort.ENTITY) {
+ if (getBeanSort() == BeanSort.ENTITY) {
metaTypeBuilder.field(ObjectTypeFactory.Fields.version);
}
- this.gqlObjectType = metaTypeBuilder.build();
+
+ this.metaType = metaTypeBuilder.build();
}
diff --git a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
index dd388eaf38..503a6fd4fd 100644
--- a/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
+++ b/incubator/viewers/graphql/viewer/src/main/java/org/apache/causeway/viewer/graphql/viewer/source/ObjectTypeFactory.java
@@ -72,6 +72,7 @@ public class ObjectTypeFactory {
final static String GQL_INPUTTYPE_PREFIX = "_gql_input__";
final static String GQL_MUTATIONS_FIELDNAME = "_gql_mutations";
+
private final BookmarkService bookmarkService;
private final SpecificationLoader specificationLoader;
private final ObjectManager objectManager;
@@ -81,10 +82,6 @@ public class ObjectTypeFactory {
return logicalTypeNameSanitized + "__DomainObject_mutators";
}
- static String metaTypeName(final String logicalTypeNameSanitized){
- return logicalTypeNameSanitized + "__DomainObject_meta";
- }
-
@UtilityClass
static class Fields {
static GraphQLFieldDefinition id =
@@ -110,15 +107,14 @@ public class ObjectTypeFactory {
val gqlvObjectSpec = new GqlvObjectSpec(objectSpec);
// create meta field type
- BeanSort objectSpecificationBeanSort = gqlvObjectSpec.getBeanSort();
- GraphQLObjectType metaType = gqlvObjectSpec.getGqlObjectType();
+ GraphQLObjectType metaType = gqlvObjectSpec.getMetaType();
// add meta field
val _gql_meta_Field = newFieldDefinition().name("_gql_meta").type(metaType).build();
gqlvObjectSpec.getGqlObjectTypeBuilder().field(_gql_meta_Field);
- graphQLTypeRegistry.addTypeIfNotAlreadyPresent(gqlvObjectSpec.getGqlObjectType());
+ graphQLTypeRegistry.addTypeIfNotAlreadyPresent(gqlvObjectSpec.getMetaType());
@@ -151,10 +147,10 @@ public class ObjectTypeFactory {
// create and register data fetchers
createAndRegisterDataFetchersForMetaData(
- codeRegistryBuilder, objectSpecificationBeanSort, metaType, _gql_meta_Field, graphQLObjectType);
+ codeRegistryBuilder, gqlvObjectSpec.getBeanSort(), gqlvObjectSpec.getMetaType(), _gql_meta_Field, graphQLObjectType);
if (mutatorsDataForEntity!=null) {
createAndRegisterDataFetchersForMutators(
- codeRegistryBuilder, objectSpecificationBeanSort, mutatorsDataForEntity, graphQLObjectType);
+ codeRegistryBuilder, gqlvObjectSpec.getBeanSort(), mutatorsDataForEntity, graphQLObjectType);
}
createAndRegisterDataFetchersForField(objectSpec, codeRegistryBuilder, graphQLObjectType);
createAndRegisterDataFetchersForCollection(objectSpec, codeRegistryBuilder, graphQLObjectType);