Skip to content

Conversation

@neo4j-team-graphql
Copy link
Collaborator

@neo4j-team-graphql neo4j-team-graphql commented Jan 24, 2023

This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to 4.0.0, this PR will be updated.

⚠️⚠️⚠️⚠️⚠️⚠️

4.0.0 is currently in pre mode so this branch has prereleases rather than normal releases. If you want to exit prereleases, run changeset pre exit on 4.0.0.

⚠️⚠️⚠️⚠️⚠️⚠️

Releases

@neo4j/[email protected]

Major Changes

  • #3062 ea1bae3c3 Thanks @mjfwebb! - The deprecated @callback directive has been removed. Any remaining usages of @callback should be replaced with @populatedBy. See https://github.com/neo4j/graphql/blob/dev/docs/modules/ROOT/pages/guides/v4-migration/index.adoc#callback-renamed-to-populatedby for more information.

  • #3013 0fb2592b4 Thanks @darrellwarde! - Remove aggregation fields for relationships to a single node (non-List relationships) - these serve no functional utility

  • #2863 c9ee9e757 Thanks @darrellwarde! - Support for Neo4j database 4.3 has been dropped. Please use the current Neo4j 5 release, or the LTS 4.4 release.

  • #2996 4a78e7a8d Thanks @mjfwebb! - Aliased properties are now automatically escaped using backticks. If you were using backticks in the property argument of your @alias directives, these should now be removed.

  • #2834 8d3aff007 Thanks @a-alle! - Deprecated @node directive arguments label and additionalLabels have been removed. Please use the labels argument.

  • #3671 b3951fa81 Thanks @darrellwarde! - Remove nodes and relationships from the public API of the Neo4jGraphQL class.

  • #3628 2167c9ac1 Thanks @darrellwarde! - Specifying Cypher query options to be used is now cypherQueryOptions instead of just queryOptions, and each option accepts a simple string rather than an enum.

  • #3242 29d68ad51 Thanks @angrykoala! - Escape properties and relationships if needed, using | and & as part of the label is no longer supported

  • #3105 395e12f14 Thanks @mjfwebb! - skipValidateTypeDefs has been removed. Please use startupValidation instead. See https://neo4j.com/docs/graphql-manual/current/guides/v4-migration/#startup-validation

  • #3043 15a7f0418 Thanks @mjfwebb! - It was possible to define schemas with types that have multiple relationship fields connected by the same type of relationships. Instances of this scenario are now detected during schema generation and an error is thrown so developers are informed to remedy the type definitions.

    An example of what is now considered invalid with these checks:

    type Team {
        player1: Person! @relationship(type: "PLAYS_IN", direction: IN)
        player2: Person! @relationship(type: "PLAYS_IN", direction: IN)
        backupPlayers: [Person!]! @relationship(type: "PLAYS_IN", direction: IN)
    }
    
    type Person {
        teams: [Team!]! @relationship(type: "PLAYS_IN", direction: OUT)
    }

    For more information about this change and how to disable this validation please see the 4.0.0 migration guide

  • #2818 93b9d806b Thanks @a-alle! - Removed deprecated argument plural from @node directive. Please use the @plural directive instead.

  • #3670 d4aea32c6 Thanks @darrellwarde! - Removal of the following exports: Neo4jGraphQLAuthenticationError, Neo4jGraphQLForbiddenError, EventMeta, Neo4jGraphQLAuthPlugin and RelationField. This are either redundant, or internals which shouldn't have been exported.

  • #3679 5ea18136e Thanks @darrellwarde! - Remove unused DeleteInfo, GraphQLSortArg, GraphQLOptionsArg and GraphQLWhereArg type exports.

  • #3673 aa11d5251 Thanks @darrellwarde! - Programmatic toggling of debug logging is now done using the debug option of the constructor.

  • #3234 f1225baa7 Thanks @angrykoala! - Change subscriptions setup, this requires changes to constructor options passed to Neo4jGraphQL. See https://neo4j.com/docs/graphql-manual/current/guides/v4-migration/#subscriptions-options

    For single instance subscriptions use true:

    const neoSchema = new Neo4jGraphQL({
        typeDefs,
        features: {
            subscriptions: true,
        },
    });

    For any other plugin, pass it features.subscriptions:

    const neoSchema = new Neo4jGraphQL({
        typeDefs,
        features: {
            subscriptions: subscriptionPlugin,
        },
    });
  • #3645 7df67be49 Thanks @darrellwarde! - The minimum version of neo4j-driver is now 5.8.0, please upgrade. The boomkark field in the selection set has been marked as deprecated and will be removed in version 5.0.0 of the library.

  • #2922 7743399d3 Thanks @Liam-Doodson! - The requires argument of the @customResolver directive now accepts a graphql selection set. This means it is now possible to require non-scalar fields such as related types.

  • #2769 e5b53a597 Thanks @angrykoala! - @cypher directive now requires the parameter columnName.

    This requires all cypher queries to be made with a valid alias that must be referred in this new parameter.

    For Example:

    @neo4j/graphql@3

    @cypher(statement: "MATCH (i:Item) WHERE i.public=true RETURN i.name")
    

    @neo4j/graphql@4

    @cypher(statement: "MATCH (i:Item) WHERE i.public=true RETURN i.name as result", columnName: "result")
    
  • #3630 3896544b5 Thanks @darrellwarde! - neo4jDatabaseInfo has been removed from the context. It is our belief that this has little utility in the library. If you regularly use different drivers connected to different versions of Neo4j and require this feature, please raise an issue: https://github.com/neo4j/graphql/issues/new/choose

  • #2944 8f0656b35 Thanks @Liam-Doodson! - Made @relationshipProperties mandatory for relationship property interfaces

  • #3099 c9f35f10c Thanks @mjfwebb! - config.callbacks has been deprecated and replaced with features.populatedBy.callbacks. See https://neo4j.com/docs/graphql-manual/current/guides/v4-migration/#_callback_renamed_to_populatedby for more information.

  • #3687 1ad4328e4 Thanks @darrellwarde! - Validation of type definitions is now configured using the validate boolean option in the constructor, which defaults to true.

  • #2819 2ab3d5212 Thanks @a-alle! - Removed @computed directive. Please use @customResolver instead.

  • #2598 257aa4c97 Thanks @darrellwarde! - Remove all arguments from IExecutableSchemaDefinition apart from typeDefs and resolvers. This is to simplify the API and to remove any unexpected behaviours from arguments which we blindly pass through.

  • #3653 5b5f08ce7 Thanks @angrykoala! - All labels and field names are escaped in the generated Cypher

  • #3097 9f5a44545 Thanks @mjfwebb! - enableRegex has been removed and replaced with MATCHES filters in the features configuration object. See the migration guide for more information: https://neo4j.com/docs/graphql-manual/current/guides/v4-migration

  • #2955 9f3a9374e Thanks @mjfwebb! - Relationship type strings are now automatically escaped using backticks. If you were using backticks in the type argument of your @relationship directives, these should now be removed to avoid backticks being added into your relationship type labels.

  • #3674 59e369992 Thanks @darrellwarde! - cypherQueryOptions moved into context-only, as a per-request option.

Minor Changes

  • #3661 ce84c47cc Thanks @darrellwarde! - The evaluation of authorization rules is now supported when using the Neo4j GraphQL Library as a Federation Subgraph.

@neo4j/[email protected]

Major Changes

  • #2834 8d3aff007 Thanks @a-alle! - Deprecated @node directive arguments label and additionalLabels have been removed. Please use the labels argument.

@neo4j/[email protected]

Major Changes

  • #3673 aa11d5251 Thanks @darrellwarde! - Programmatic toggling of debug logging is now done using the debug option of the constructor.

  • #3645 7df67be49 Thanks @darrellwarde! - The minimum version of neo4j-driver is now 5.8.0, please upgrade. The boomkark field in the selection set has been marked as deprecated and will be removed in version 5.0.0 of the library.

  • #3671 b3951fa81 Thanks @darrellwarde! - Remove nodes from the public API of the OGM class.

  • #3687 1ad4328e4 Thanks @darrellwarde! - Validation of type definitions is now configured using the validate boolean option in the constructor, which defaults to true.

  • #2598 257aa4c97 Thanks @darrellwarde! - Remove all arguments from IExecutableSchemaDefinition apart from typeDefs and resolvers. This is to simplify the API and to remove any unexpected behaviours from arguments which we blindly pass through.

  • #3674 59e369992 Thanks @darrellwarde! - cypherQueryOptions moved into context-only, as a per-request option.

Patch Changes

[email protected]

Patch Changes

[email protected]

Patch Changes

@neo4j/[email protected]

Patch Changes

[email protected]

Patch Changes

@neo4j/[email protected]

Patch Changes

@neo4j-team-graphql
Copy link
Collaborator Author

neo4j-team-graphql commented Jan 24, 2023

Performance Report

No Performance Changes

Show Full Table
name dbHits old dbHits time (ms) old time (ms) maxRows
aggregations.TopLevelAggregate 3403 3403 42 68 1134
aggregations.NestedAggregation 13514 13514 120 178 2174
aggregations.AggregationWithWhere 10942 10942 87 100 2174
aggregations.NestedCountFromMovieToActors 8694 8694 94 104 2174
aggregations.NestedCountFromActorsToMovie 8900 8900 89 142 2174
aggregations.DeeplyNestedCount 10054408 10054408 5674 6677 2008534
batch-create.BatchCreate 3600 3600 116 114 600
connect.createAndConnect 12419 12419 445 454 3003
connections.Connection 13042 13042 140 252 2174
connections.NestedConnection 33883 33883 235 186 4516
connections.ConnectionWithSort 2277 2277 89 101 1040
connections.ConnectionWithSortAndCypher 14278 14278 122 167 2174
create.SimpleMutation 6 6 47 60 1
cypher-directive.TopLevelMutationDirective 1135 1135 199 98 1134
delete.SimpleDelete 18361 18361 346 310 1040
delete.NestedDeleteInUpdate 16779 16779 196 217 2040
query.SimpleQuery 14120 14120 118 165 2174
query.QueryWhere 8670 8658 48 53 2164
query.SimpleQueryWithNestedWhere 8841 8829 74 90 2164
query.Nested 10084290 10084290 12234 13128 2008534
query.NestedWithFilter 37172 37172 178 221 4511
query.OrFilterOnRelationships 35270 37317 395 291 1442
query.OrFilterOnRelationshipsAndNested 29746 30988 272 405 1442
query.QueryWithNestedIn 12386 12335 69 74 1228
query.NestedConnectionWhere 8794 8794 112 93 2174
query.DeeplyNestedConnectionWhere 8886 8898 106 107 2174
query.DeeplyNestedWithRelationshipFilters 6251 6251 154 481 1134
query.DeeplyNestedWithRelationshipSingleFilters 15438 15438 110 156 2174
query.Fulltext 96 96 34 38 16
query.FulltextWithNestedQuery 571 571 54 61 84
sorting.SortMultipleTypes 2493 2493 97 93 1040
sorting.SortMultipleTypesWithCypherWithCypher 13444 13407 122 141 2174
sorting.SortOnNestedFields 13042 13042 146 113 2174
sorting.SortDeeplyNestedFields 38965 38965 373 251 4516
sorting.SortWithTopLevelCypher 14120 14120 70 82 2174
unions.SimpleUnionQuery 321 321 84 90 35
unions.SimpleUnionQueryWithMissingFields 293 293 94 87 35
unions.NestedUnion 398553 398553 363 391 33033
unions.NestedUnionWithMissingFields 372527 372527 368 331 33033
update.NestedUpdate 2119 2119 54 62 1040

Old Schema Generation: 41.739s
Schema Generation: 42.555s

@neo4j-team-graphql neo4j-team-graphql force-pushed the changeset-release/4.0.0 branch 6 times, most recently from 6a3a1e3 to 2323e3d Compare January 30, 2023 18:08
@neo4j-team-graphql neo4j-team-graphql force-pushed the changeset-release/4.0.0 branch 5 times, most recently from 569641b to 27b232d Compare February 3, 2023 17:32
@neo4j-team-graphql
Copy link
Collaborator Author

neo4j-team-graphql commented Feb 3, 2023

Performance Report

No Performance Changes

Show Full Table
name dbHits old dbHits time (ms) old time (ms) maxRows
aggregations.TopLevelAggregate 3403 3403 35 41 1134
aggregations.NestedAggregation 16553 16553 72 91 2174
aggregations.AggregationWithWhere 11979 11979 43 56 2174
aggregations.AggregationWhereWithinNestedRelationships 22116987 22116987 3384 3559 2008534
aggregations.AggregationWhereWithinNestedConnections 22116987 22116987 3305 3328 2008534
aggregations.NestedCountFromMovieToActors 9734 9734 43 57 2174
aggregations.NestedCountFromActorsToMovie 9937 9937 57 52 2174
aggregations.DeeplyNestedCount 13070331 13070331 5000 5308 2008534
batch-create.BatchCreate 4200 4200 151 150 600
batch-create.BatchCreateSmall 77 77 95 89 11
connect.createAndConnect 14424 14424 164 223 3003
connections.Connection 14082 14082 63 76 2174
connections.NestedConnection 45470 45466 157 139 4516
connections.ConnectionWithSort 3284 3284 65 72 1040
connections.ConnectionWithSortAndCypher 16325 16325 96 155 2174
create.SimpleMutation 7 7 57 78 1
cypher-directive.TopLevelMutationDirective 1135 1135 35 100 1134
delete.SimpleDelete 19401 19401 240 370 1040
delete.NestedDeleteInUpdate 19198 19198 193 179 1051
2925.SingleRelationshipFilter 6468 6468 43 46 1040
2925.NestedSingleRelationshipFilter 22900 22900 87 127 2174
2925.SingleRelationshipRequiredFilter 5201 5201 60 45 1040
2925.NestedSingleRelationshipRequiredFilter 9361 9361 66 65 1040
query.SimpleQuery 3121 3121 23 23 1040
query.SimpleQueryWithRelationship 16162 16162 44 49 2174
query.QueryWhere 9711 9716 38 48 2166
query.SimpleQueryWithNestedWhere 9889 9894 51 77 2166
query.Nested 10096041 10096041 11066 11207 2008534
query.NestedWithFilter 10074401 10074401 11099 10971 2004000
query.OrFilterOnRelationships 43505 43521 245 233 2130
query.OrFilterOnRelationshipsAndNested 37850 36564 227 267 2130
query.QueryWithNestedIn 13459 14243 56 89 1235
query.NestedConnectionWhere 9834 9834 60 85 2174
query.DeeplyNestedConnectionWhere 10019 10020 117 101 2174
query.DeeplyNestedWithRelationshipFilters 19314 19212 162 158 1658
query.NestedWithRelationshipSingleFilters 3881 3881 292 213 1134
query.Fulltext 80 80 31 38 16
query.FulltextWithNestedQuery 587 587 44 70 84
sorting.SortMultipleTypes 3515 3515 65 86 1040
sorting.SortMultipleTypesWithCypherWithCypher 14492 14473 89 111 2174
sorting.SortOnNestedFields 14082 14082 47 55 2174
sorting.SortDeeplyNestedFields 43198 43198 89 100 4516
sorting.SortWithTopLevelCypher 16162 16162 53 56 2174
unions.SimpleUnionQuery 321 321 61 67 35
unions.SimpleUnionQueryWithMissingFields 293 293 59 65 35
unions.NestedUnion 410637 410637 353 354 33033
unions.NestedUnionWithMissingFields 384611 384611 268 389 33033
update.NestedUpdate 16143 16143 99 111 2002

Old Schema Generation: 46.523s
Schema Generation: 46.846s
Old Subgraph Schema Generation: 57.687s
Subgraph Schema Generation: 57.749s

@neo4j-team-graphql neo4j-team-graphql force-pushed the changeset-release/4.0.0 branch 4 times, most recently from ad51cad to 7326d7a Compare February 13, 2023 08:56
@neo4j-team-graphql neo4j-team-graphql force-pushed the changeset-release/4.0.0 branch 8 times, most recently from 960ea00 to 36d7c87 Compare March 13, 2023 10:39
@neo4j-team-graphql neo4j-team-graphql force-pushed the changeset-release/4.0.0 branch 4 times, most recently from 3b062ba to 12b6591 Compare March 24, 2023 14:17
@neo4j-team-graphql neo4j-team-graphql force-pushed the changeset-release/4.0.0 branch 19 times, most recently from 64b3690 to b58e80f Compare July 18, 2023 12:41
@neo4j-team-graphql neo4j-team-graphql force-pushed the changeset-release/4.0.0 branch 7 times, most recently from dbe916f to f606963 Compare July 19, 2023 15:19
@neo4j-team-graphql neo4j-team-graphql force-pushed the changeset-release/4.0.0 branch from f606963 to 9de533e Compare July 19, 2023 15:23
@darrellwarde darrellwarde merged commit 94e0676 into 4.0.0 Jul 19, 2023
darrellwarde added a commit that referenced this pull request Sep 1, 2023
* Merging content for restructuring of docs (#3087)

* test

* update

* more rearranging and merging of content

* resolving conflict

* conflict solving

* new attempt to solve conflicts

* Update dependency webpack to v5.76.1

* Update dependency react-router-dom to v6.9.0

* Update dependency lint-staged to v13.2.0

* Update dependency ws to v8.13.0

* resolving conflicts

* new attempt to solve conflicts

* new attempt to solve conflicts

* fixing content nav with pages that were missing

* further adjustments after review

* merging mathematical operators into update

* Fix yarn.lock

* undoing the accidental deletion of the neo4jgraphql.adoc page

* reviewing indexing of links after restructuring of the manual

* fix yarn

* Fix lockfile

* Fix yarn.lock

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Darrell Warde <[email protected]>

* Move subscriptions to features instead of plugins

* Tests on default subscriptions

* Update subscription docs with default example

* Add migration guide on subscriptions

* Update v4-migration.adoc

* Update class names for subscription plugins

* Update TestSubscriptionPlugin in tests

* Fix apollo e2e tests

* Apply suggestions from code review

Co-authored-by: Lidia Zuin <[email protected]>

* Rename several references from plugins to mechanisms

* Update docs/modules/ROOT/pages/subscriptions/mechanisms.adoc

Co-authored-by: Lidia Zuin <[email protected]>

* Fix escaping for relationships

* Fix cypher builder tests

* fix: use gql from graphql-tag in place of old apollo-server gql export

* Update import of gql

* rm unused import

* Remove tests against 4.3 database (#3346)

* Remove tests against 4.3 database

* Fix yarn.lock

* Fix broken Subscriptions test

* Fix property escaping in MERGE operation

* Update fluffy-suns-invite.md

* make temporary set-up to test validation rules

* field category aid

* add tests for existing graphql rule: KnownDirectiveArgument

* add support for fulltext directive in DirectiveArgumentOfCorrectType

* Remove the `@auth` directive (#3579)

* Remove `@auth` code and related tests

* Remove deprecated tests

* Remove `@auth` from final tests

* Tweaks to get tests passing

* Fix missing predicates in nested projection

* Update TCK tests following changes to authorization

* Remove commented block

* Remove redundant Subscriptions tests

* Fix unit tests

* Fix tests

* Add fulltext tests back in which were unrelated to auth

* Better Cypher Builder usage

* Fix broken tests on `4.0.0` (#3593)

* add tests and improve validation run temporary set-up

* pass extra definitions to validation

* extend DirectiveArgumentOfCorrectType to static directives - problematic

* adds rule to validate directive argument values. To be refactored

* Fix sort tck test

* Remove `Neo4jDatabaseInfo` from the public context (#3630)

* Remove Neo4j version check for point translation

* Remove Neo4j database info from public API

* Remove unneeded export, add changeset

* Fix import

* Remove req and request from our context type (#3629)

* Simpler configuration of Cypher query options (#3628)

* Perform major dependency upgrades breaking Node version (#3602)

* Perform major dependency upgrades breaking Node version

* Update OGM snapshots with new inputs and outputs

* Update cypher builder dependency to 1.0.0

* Address additional linting errors on `4.0.0` (#3654)

* Address additional linting errors on `4.0.0`

* Fix issue

* Authorization support for Apollo Federation (#3661)

* Add initial Federation authorization

* Add E2E tests

* Update Federation E2E tests to work without port

* Test type level authorization

* Add changeset

* Update TCK tests

* Skip Federation tests for GraphQL 15

* Remove auth plugin and all references (#3662)

* Remove auth plugin and all references

* Add missing dependency

* Remove auth from content nav

* Use modern driver API and bump version requirements (#3645)

* Bump driver

* In progress changes to driver usage

* Remove DriverWithSessionConfig

* Remove `getContextValuesWithBookmarks`

* Fix typo

* Fix tests

* Remove unused req from performance tests

* Remove unused variables

* Remove deprecated options

* Fix tests

* Mark bookmark fields as deprecated

* Add changeset

* Update OGM snapshots

* Un-deprecate `fulltext` argument, add descriptions for different functionality (#3669)

* Un-deprecate `fulltext` argument, add descriptions for different functionality

* Update snapshot

* Assessment and grouping of all library exports (#3670)

* Assessment and grouping of all library exports

* Add changeset

* Fix test import

* Fix doc blocks

* Simplify the programmatic toggle for debug logging (#3673)

* Simplify the programmatic toggle for debug logging

* Move Toolbox database selection

* Remove unused exports now defined in OGM (#3679)

* Remove `nodes` and `relationships` from the library's public API (#3671)

* Remove `nodes` and `relationships` from the library's public API

* Fix bad merge

* Cypher query options only settable in the context (#3674)

* Cypher query options only settable in the context

* Remove unused export

* Remove reference from troubleshooting guide

* `apoc.util.validate` to `apoc.util.validatePredicate` (#3672)

* Update math operators to use `apoc.util.validatePredicate`

* Relationship validation string using `apoc.util.validatePredicate`

* `createUpdateAndParams` array functions using `apoc.util.validatePredicate`

* `translateUpdate` to use `apoc.util.validatePredicate`, and combine the conditions for less calls

* Remove prodedure checks

* Testing to see if session is causing failures

* Add null checks to validations, only add division rule if needed

* Update packages/graphql/tests/integration/math.int.test.ts

Co-authored-by: MacondoExpress <[email protected]>

---------

Co-authored-by: MacondoExpress <[email protected]>

* Strongly type `context` field in OGM (#3690)

* Strongly type `context` field in OGM

* Fix schema tests

* Validation configuration changes (#3687)

* Miscellaneous test fix

* Missing custom resolvers to warn instead of throw

* Unified validate option, removal of library config object

* Docs updates

* Add changeset

* Update docs

* Add a bit about `startupValidation`

* Remove `neo4jValidateGraphQLDocument` (#3691)

* Subscriptions Engine (#3688)

* Changes subscription mechanism to engine

* Miscellaneous fixes

* Add migration step

* Docs remnants

* Fix linting and tests

* Update examples

* EngineAMQP to AMQPEngine

* Much better naming for subscriptions engine

* Update nine-poems-retire.md

* Re-lock

* Fix version of AMQP engine

* Version Packages (beta) (#2774)

* adds directive combination rules

* adds jwt directives validation rule

* Remove docs (#3696)

* Remove docs

* Remove references

* adds more validation rules and tests, id in progress

* finish all validations except customResolver, add tests, refactoring todo

* refactor into generic rules w/ specialized validation functions

* remove comments

* tidy up code

* improve relationship validation, start updating tests

* merge 4.0.0

* update tests

* attempt fix ts error

* fix global id inherited alias

* remove comments

* refactor relationship validation

* refactor invalid directive combinations

* remove unused imports

* update validation on getSubgraphSchema

* make valid-object-type rule work

* fix reviewdog on tests

* Version Packages (beta) (#3734)

* Schema model refactoring (#3689)

* Add directive annotations (#3615)

* feat: add alias directive annotation

* feat: add queryOptions directive annotation

* feat: parse Kind.INT and Kind.Float into JS numbers

* feat: add default directive annotation

* feat: add coalesce directive annotation

* feat: add customResolver annotation

* feat: add ID directive annotation

* refactor: use makeDirectiveNode in key-annotation tests

* feat: add mutation directive annotation

* feat: add plural directive annotation

* feat: add filterable directive annotation

* feat: add fulltext directive annotation

* feat: add node directive annotation

* feat: add populatedBy directive annotation

* feat: add query directive annotation

* feat: add private directive annotation

* feat: add relationshipProperties annotation

* feat: add selectable directive annotation

* feat: add settable directive annotation

* feat: add timestamp directive annotation

* feat: add unique directive annotation

* feat: add subscription directive annotation

* feat: add jwt-claim directive annotation

* feat: add jwt-payload directive annotation

* feat: add directives to Annotation

---------

Co-authored-by: MacondoExpress <[email protected]>

* Schema model re-design (#3596)

* initial refactor of the schema model

* add unit tests for schema model Attributes

* include initial design for the GraphQL models

* add Attribute tests, improve Attribute models

* merge schema model changes with authorization changes

* fix relationship-field parsing on schema model

* organise parser folder

* Add missing GraphQL models to the Schema Models

* change Schema Model test to showcase how to dynamically get EntityModels from relationships

* improve coverage on the Attribute Models

* add more tests to the ConcreteEntityModel

* Apply suggestions from code review

Co-authored-by: angrykoala <[email protected]>

* lint fixes

* rename graphql-models to model-adapters

* remove @relationshipProperties annotation as it is implicit within the Relationship class

* remove code duplicity around leadingUnderscores utility and test it

* parseArguments of directive using default values, add Schema Model tests for annotations and relationships

* remove not necessary node directive

* polishing

* add license header

* Update packages/graphql/src/schema-model/parser/parse-arguments.ts

* add graphqlDefaultValue to Attribute

* remove the graphqlDefault logic

* add comment on the PluralAnnotation

---------

Co-authored-by: Michael Webb <[email protected]>
Co-authored-by: angrykoala <[email protected]>

* address review

* make additional definitions mandatory on validations

* improve error check

* improve validation tests

* Update logical filters in aggregation queries

* Introspector to produce `@mutation` instead of `@exclude` (#3743)

* fix: remove unnecessary readonly (#3735)

* chore(deps): update dependency eslint-config-prettier to v8.10.0

* chore(deps): update dependency jest-extended to v4.0.1

* Introspector to produce `@mutation` instead of `@exclude`

---------

Co-authored-by: Thomas Wiss <[email protected]>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* Update logical operators on field aggregations outside of node/edge

* Update aggregation implicit and filter

* cypherParams added to new context type, and fields can be directly referred to (#3758)

* cypherParams added to new context type, and fields can be directly referred to

* Resolve all possible label references

* Address PR comments

* code review changes

* fix tests after code review changes

* Fix default logical operators in aggregation filters

* refactor: add types to assertArgumentType

* Add integration test

* fix toolbox error

* Stronger typings for context (#3779)

* Pass info into Executor rather than putting in context

* Typings for fulltext in current context

* Remove unused context entries

* Remove some unneeded context references

* Add context types

* Switch to new context typings

* Remove legacy Context type

* improve valid-directive-combination to check inherited directives as well

* remove resolutions

* fix fulltext missing type

* change id autogenerate default value, remove errors from make-augmented-schema and update tests

* add scaffold directive definition for type dependant directives

* conditionally run directiveArgumentOfCorrectType rule on auth directives

* adjust tests and invalid directive combination matrix

* fix RENAMED_DIRECTIVE_OR_TYPE regex

* remove faulty export

* Reduction in types accepted for type definitions (#3592)

* Refined normalization of user type definitions

* Remove unused type

* Wrap current behaviour with new lifecycle naming

* Fix linting error

* Delete unused tests

* Fix test typings

* Update Neo4jGraphQL.ts

* Correct default access mode for `@cypher` (#3792)

* chore(deps): update dependency eslint to v8.47.0

* Toolbox: Ensure no additional commas are added to the editor value (#3784)

* `@cypher` default access mode to match operation

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Michael Webb <[email protected]>

* Schema model improvements (#3794)

* change isListOf to includeLists flag

* clean up AttributeAdapter

* remove type guards for type

* polish

* use assertionOptions rather than flag

* fix assertions

* add isList argument to the relationship to differentiate between 1..1 or 1..n

* polish

* Move the `limit` argument of `@queryOptions` to `@limit` (#3809)

* Move the `limit` argument of `@queryOptions` to `@limit`

* Update translate-read.ts

* changes from review

* use a lambda instead of Fn.bind

* Improved typings for Subscriptions context and authorization (#3810)

* Improved typings for Subscriptions context and authorization

* Single type for common context fields

* Fix typings so it works without connectionParams

* Fix possible undefined

* Address PR comments

* Rename context interface

* add rule for directives on root type fields

* change queryOptions with limit

* chore: fix linting issues

* Remove references to global authentication (#3815)

* Version Packages (beta) (#3757)

* fix cypher with authorization on root type fields tests

* do not allow directives on interface fields except for relationshipProperties

* remove  rule as directives on intreface fields are no longer possible

* add comments

* disallow unique directive on relationshipProperties explicitly, since interface rule is gone

* improve error messages on root types fields

* remove interface inheritance from validate relationship directive rule

* remove interface inheritance from validate directive combination rule

* Breaking changes to the `@id` directive (#3823)

* Break `@id` `global` argument out into `@relayId`

* Remove arguments from `@id`

* Add changeset

* Address first PR comments

* Switch back to default name for constraints

* Fix directive description

* Remove automatic constraint for `@id`

* Fix typo

* Fix tests

* fix interface field directives tests

* fix id directive rule

* remove interface inheritance from @id validation

* move some tests to validateDocument

* fix some tests with interface inheritance

* Revert "fix some tests with interface inheritance"

This reverts commit 09069f8.

* Revert "remove interface inheritance from @id validation"

This reverts commit 29f5f85.

* Revert "fix interface field directives tests"

This reverts commit 2f0aafc.

* Revert "remove interface inheritance from validate directive combination rule"

This reverts commit 6b3175d.

* Revert "remove interface inheritance from validate relationship directive rule"

This reverts commit ae12676.

* Revert "disallow unique directive on relationshipProperties explicitly, since interface rule is gone"

This reverts commit 4c8b9e8.

* Revert "remove  rule as directives on intreface fields are no longer possible"

This reverts commit 0897e82.

* rename globalId to relayId

* refactor relationship validation to use inheritance utils

* improve directive combination to not run when < 2 directives

* allow directives on interface fields

* update tests

* Remove definitions for `@exclude`, `@readonly` and `@writeonly` (#3857)

* Change `@subscription` `operations` argument to be `events` (#3858)

* `@subscription` `operations` to `events`

* Add changeset

* Missed some usages

* Fix tests

* Rolls back TypeScript to 5.1.6 (#3867)

* update rules with object and interface extensions

* update jwt directives rule to consider extensions

* update relationshipProperties rule to consider extensions

* update relayId rule to consider extensions

* add tests on all rules for extensions

* fix skip test

* fix missing directives

* improve jwt directives rule to check for adding jwt on extension as last thing

* Fix: `cypherParams` in context now work as expected when using OGM (#3830)

* Fix: `cypherParams` in context now work as expected when using OGM

* Remove jwt and token from OGM context types

* Change test to use cypherParams

* Update typing

* improve jwt directives rule to use context document

* refactor jwt directives rule

* Fix README

* Remove unused import

---------

Co-authored-by: MacondoExpress <[email protected]>
Co-authored-by: Darrell Warde <[email protected]>
Co-authored-by: Lidia Zuin <[email protected]>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Darrell Warde <[email protected]>
Co-authored-by: Michael Webb <[email protected]>
Co-authored-by: a-alle <[email protected]>
Co-authored-by: Alle <[email protected]>
Co-authored-by: MacondoExpress <[email protected]>
Co-authored-by: Neo4j Team GraphQL <[email protected]>
Co-authored-by: Michael Webb <[email protected]>
Co-authored-by: Thomas Wiss <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants