Azure / Azure/data-api-builder

[Feature:] Support additional `UUID` format specifiers

Offen
#2,066 1 Kommentar 1 Reaktion 0 zugewiesene Personen Auf GitHub ansehen
enhancement graphql triage
Vorherrschende Sprache
C#
Sterne
1.5k
Forks
370
Ø Merge
3 T. 22 Std.
Gemergte PRs (30 T.)
9

Beschreibung

### What happened?

## Dotnet
https://learn.microsoft.com/en-us/dotnet/api/system.guid.parse?view=net-6.0#system-guid-parse(system-string):~:text=to%20a%20Guid-,Remarks,Expand%20table,-Specifier

## GraphQL
Explanation: https://chillicream.com/docs/hotchocolate/v12/defining-a-schema/scalars#uuid-type

> Uuid Type
>
> The `Uuid` scalar supports the following serialization formats.
>
> | Specifier | Format |
> | ----------- | -------------------------------------------------------------------- |
> | N (default) | 00000000000000000000000000000000 |
> | D | 00000000-0000-0000-0000-000000000000 |
> | B | {00000000-0000-0000-0000-000000000000} |
> | P | (00000000-0000-0000-0000-000000000000) |
> | X | {0x00000000,0x0000,0x0000,{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00}} |
>
> The `UuidType` will always return the value in the specified format. In case it is used as an input type, it will first try to parse the result in the specified format. If the parsing does not succeed, it will try to parse the value in other formats.
Source: https://github.com/ChilliCream/graphql-platform/blob/main/website/src/docs/hotchocolate/v12/defining-a-schema/scalars.md?plain=1

## Steps to implement:
- Ensure Stored procedure param support
- GraphQL variable, filter, and input type support
- parse from GraphQL/dotnet format specifier to uuid type supported by external database MSSQL/ PG / MySQL, CosmosDB
- update supportedtypes tests and GraphQLStoredprocedureBuilder tests and engine code.

### Version

main

### What database are you using?

Azure SQL

### What hosting model are you using?

_No response_

### Which API approach are you accessing DAB through?

GraphQL

### Relevant log output

_No response_

### Code of Conduct

- [X] I agree to follow this project's Code of Conduct

Beitragsleitfaden

Beitragsleitfaden öffnen

Rechercherichtung

Beginnen Sie mit den im Issue genannten supportedtypes-Tests und GraphQLStoredprocedureBuilder-Tests und verfolgen Sie anschließend den zugehörigen Engine-Code für Stored-Procedure-Parameter, GraphQL-Variablen, Filter und Input-Typen. Vergleichen Sie die referenzierten .NET- und GraphQL-UUID-Formate mit dem Verhalten von Azure SQL; abgeschlossen ist die Arbeit, wenn die Formate über diese Pfade hinweg funktionieren und die aktualisierten Tests bestehen.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
csharp, graphql, sql
Bereich
api, backend, database
Issue-Typ
Feature
Schwierigkeit
5/5
Geschätzter Aufwand
Über eine Woche
Aktivitätsstatus
Veraltet
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
28/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.