New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: enable field exclusion for the json protocol #4807
Conversation
WASM Query Engine file Size
|
CodSpeed Performance ReportMerging #4807 will degrade performances by 5.29%Comparing Summary
Benchmarks breakdown
|
✅ WASM query-engine performance won't change substantially (1.001x)Full benchmark report
After changes in 8eed76c |
Counterpart to prisma/prisma-engines#4807 Can be used standalone or combined with `include`, allows to exclude the fields that normally would be included by default. Available in all methods that return actual database records. It is not useable together with `select` and attempt to do so would cause type check and validation error. When using together with result extensions, excluded dependency of a computed field will be queried from a DB, but will not be returned to the end user, unless computed field is exlucded as well (see "exclude with extensions" tests in this PR). This behaviour is equivalent to what we do if depenency of a computed field is not mentioned in explicit `select`. TODO: - [ ] preview feature - [ ] validation of non-existing fields in exclude Close prisma/team-orm#1080 Close #5042
Counterpart to prisma/prisma-engines#4807 Can be used standalone or combined with `include`, allows to exclude the fields that normally would be included by default. Available in all methods that return actual database records. It is not useable together with `select` and attempt to do so would cause type check and validation error. When using together with result extensions, excluded dependency of a computed field will be queried from a DB, but will not be returned to the end user, unless computed field is exlucded as well (see "exclude with extensions" tests in this PR). This behaviour is equivalent to what we do if depenency of a computed field is not mentioned in explicit `select`. TODO: - [ ] preview feature - [ ] validation of non-existing fields in exclude Close prisma/team-orm#1080 Close #5042
7e648d2
to
9ed8975
Compare
Which should only be used internally anyway, right? |
Yes, correct. External clients can technically still use GraphQL, but our client only uses the JSON protocol. |
query-engine/core-tests/tests/query_validation_tests/unkown_selection_field.expected.json
Show resolved
Hide resolved
...ne/core-tests/tests/query_validation_tests/selection_contains_no_truthy_values.expected.json
Show resolved
Hide resolved
Counterpart to prisma/prisma-engines#4807 Can be used standalone or combined with `include`, allows to exclude the fields that normally would be included by default. Available in all methods that return actual database records. It is not useable together with `select` and attempt to do so would cause type check and validation error. When using together with result extensions, excluded dependency of a computed field will be queried from a DB, but will not be returned to the end user, unless computed field is exlucded as well (see "exclude with extensions" tests in this PR). This behaviour is equivalent to what we do if depenency of a computed field is not mentioned in explicit `select`. TODO: - [ ] preview feature - [ ] validation of non-existing fields in exclude Close prisma/team-orm#1080 Close #5042
46c1653
to
8eed76c
Compare
Counterpart to prisma/prisma-engines#4807 Can be used standalone or combined with `include`, allows to exclude the fields that normally would be included by default. Available in all methods that return actual database records. It is not useable together with `select` and attempt to do so would cause type check and validation error. When using together with result extensions, excluded dependency of a computed field will be queried from a DB, but will not be returned to the end user, unless computed field is exlucded as well (see "exclude with extensions" tests in this PR). This behaviour is equivalent to what we do if depenency of a computed field is not mentioned in explicit `select`. TODO: - [ ] preview feature - [ ] validation of non-existing fields in exclude Close prisma/team-orm#1080 Close #5042
Counterpart to prisma/prisma-engines#4807 Can be used standalone or combined with `include`, allows to exclude the fields that normally would be included by default. Available in all methods that return actual database records. It is not useable together with `select` and attempt to do so would cause type check and validation error. When using together with result extensions, excluded dependency of a computed field will be queried from a DB, but will not be returned to the end user, unless computed field is exlucded as well (see "exclude with extensions" tests in this PR). This behaviour is equivalent to what we do if depenency of a computed field is not mentioned in explicit `select`. Close prisma/team-orm#1080
Counterpart to prisma/prisma-engines#4807 Can be used standalone or combined with `include`, allows to exclude the fields that normally would be included by default. Available in all methods that return actual database records. It is not useable together with `select` and attempt to do so would cause type check and validation error. When using together with result extensions, excluded dependency of a computed field will be queried from a DB, but will not be returned to the end user, unless computed field is exlucded as well (see "exclude with extensions" tests in this PR). This behaviour is equivalent to what we do if depenency of a computed field is not mentioned in explicit `select`. Close prisma/team-orm#1080
Overview
closes https://github.com/prisma/team-orm/issues/1079
Note: Field exclusion cannot be done for the GraphQL protocol.