Spring Boot GraphQL Tutorial #18 - Input Validation (Method 1 - Bean)

Pubblicato il: 19 settembre 2020
sul canale di: Philip Starritt
8,293
53

There are two ways of validating your graphql input types, via Directives or manually validating the input type in your resolver. In this episode we focus on the more old-school approach and put the JSR-303 bean validation annotations on our pojos. In a following tutorial, we will look at graphql-java-extended-validation which will allow us to remove all java bean validation annotations, and instead place the annotations directly on the schema. Pretty cool.

As graphql-java-extended-validation is still under active development and first stable release was 2 days ago (17 September 2020) I will provide tutorials on both validation methods .



There are always multiple ways of solving problems and normally neither are wrong. So its good to list all options. In the end, we pick what we find the most beneficial and efficient :)



In the next video we look at graphql-java-extended-validation and how we can validation with graphql schema directives instead of java annotations. That way we keep our pojos clean.

Thanks!
Philip

Spring Boot GraphQL: https://github.com/graphql-java-kicks...

Java GraphQL Extended Validation: https://github.com/graphql-java/graph...


In questa pagina del sito puoi guardare il video online Spring Boot GraphQL Tutorial #18 - Input Validation (Method 1 - Bean) della durata di ore minuti seconda in buona qualità , che l'utente ha caricato Philip Starritt 19 settembre 2020, condividi il link con amici e conoscenti, su youtube questo video è già stato visto 8,293 volte e gli è piaciuto 53 spettatori. Buona visione!