RicoSuter/NJsonSchema

System.ObsoleteAttribute on properties

Open

#1031 aperta il 3 lug 2019

Vedi su GitHub
 (3 commenti) (0 reazioni) (0 assegnatari)C# (550 fork)github user discovery
help wantedproject: NJsonSchema.Generationtype: bug

Metriche repository

Star
 (1578 star)
Metriche merge PR
 (Nessuna PR mergiata in 30 g)

Descrizione

We would like to prepare users of our API to a change regarding one model.

AFAICT, OpenAPI v3 added support for deprecation on property level (https://github.com/OAI/OpenAPI-Specification/issues/701, https://github.com/OAI/OpenAPI-Specification/issues/524).

As it seems, currently neither aspNetCoreToOpenApi nor openApiToCSharpClient support deprecation of a single property in a model (the generated spec / code is not affected by the attribute).

Should setting ignoreObsoleteProperties to true cause the property to be omitted from the generated spec?

Guida contributor