Closed vh closed 4 years ago
Just added benchmark https://github.com/tlivings/enjoi/pull/4
Have you seen the results for themis?
It's not just raw performance I was going for with enjoi, but rather hapi compatibility.
That being said, I'll likely switch out non hapi code to use more traditional json-schema validation unless I knock out 100% compatibility soon.
Although looking at it - it seems quite fast.
Ahh, ok. You mean that it is needed to implement some missing enjoi keywords support to be able to switch out?
No, enjoi is missing json-schema keywords - it doesn't yet do a perfect conversion from json-schena to Joi.
But the reason I wrote enjoi was to provide not only fast (at the time I had used tv4 which felt slow) validation, but schemas that were compatible with Hapi (which uses Joi for validation).
For this to be more acceptable, I will need to consider writing custom validator function from swaggerize-hapi
instead of using joi
schemas. That might be fine, but I'll need to play with it some first.
It seems is-my-json-valid can be good alternative to enjoi. It is superfast in comparison with the others validators (https://github.com/Muscula/json-schema-benchmark). What do you think about this?