[Bug]: OneOf Directive is missed in Schema

Aperta
#3,889 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 7 giorni

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
53/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
csharp, graphql, postgresql
Ambito
api, databases

Direzione di ricerca

Start by comparing GraphQL schema generation in version 2.1.5 with the earlier 1.6+ behavior described in the issue, focusing on how OneOf input types are represented. Reproduce with a PostgreSQL configuration containing a OneOf input type and inspect the generated schema. Done when the schema includes @oneOf on those input types.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

bug triage
What happened?

Description :
The generated GraphQL schema is missing the @oneOf directive in the latest version of DAB. This functionality was working correctly in earlier versions (1.6+), where the schema correctly exposed OneOf input objects with the @oneOf directive.

Expected Behavior :
When generating the GraphQL schema, input objects configured as OneOf types should include the @oneOf directive in the schema output.

Actual Behavior:
The generated schema does not include the @oneOf directive

Impact :
GraphQL clients cannot discover OneOf semantics through schema introspection.
Schema does not accurately represent the intended input validation rules.
Potential interoperability issues with tooling that relies on the @oneOf directive.

Steps to Reproduce :
Configure an input type that should behave as a OneOf input.
Generate or inspect the GraphQL schema.
Observe that the @oneOf directive is not present on the input type.

Environment
Product: Data API Builder (DAB)
Previous Working Version: 1.6+
Current Version: Latest
Database: PostgreSQL
GraphQL Endpoint: Enabled

Additional Context

This behavior seems to be a regression introduced in a recent release. The same configuration generated schemas with the @oneOf directive in DAB 1.6+, but the directive is no longer emitted in the latest version

Version

2.1.5

What database are you using?

PostgreSQL

What hosting model are you using?

Static Web Apps (SWA), Container Apps

Which API approach are you accessing DAB through?

GraphQL

Relevant log output

Code of Conduct
  • I agree to follow this project's Code of Conduct
Lingua principale
C#
Stelle
1.5k
Fork
380
Merge medio
5g 11h
PR unite (30g)
4

Preparare l'ambiente

Apri in Codespaces

Avvia il container di sviluppo del progetto nel browser, con il tuo account GitHub.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di Azure/data-api-builder

Tutte le issue di Azure/data-api-builder

Issue simili

Altre issue su C#

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.