Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I second this.

On our backend we have a main service in Python and a few micro-services in Node. All of the JSON data flying between these services has JSON Schema definitions.

We've built some express.js and wsgi middleware so that for a given route you can specify "Requests to this endpoint should follow schema {} responses from this endpoint should follow schema {}." Our middleware then validates all requests and responses against these schema. This works really well for us.



That sounds nice. At my shop we have all of that except the live validation, and schemas almost inevitably fall behind.

What happens when the validation fails? Also, which end does the validation, providers or consumers?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: