Benchmark for Clojure validation libraries.
Following libraries are benchmarked:
[com.roomkey/annotate "1.0.1"]
)[com.velisco/herbert "0.7.0"]
)[prismatic/schema "1.1.5"]
)[org.clojure/clojure "1.9.0-alpha15"]
)[com.taoensso/truss "1.4.0"]
)Test | annotate | herbert | schema | spec | truss |
---|---|---|---|---|---|
[:associative-collections :invalid] | 48.957 | 21.254 | 13.156 | 3.023 | 1.000 |
[:associative-collections :valid] | 34.815 | 28.704 | 6.192 | 4.122 | 1.000 |
[:atomic-values :invalid] | 11.877 | 8.815 | 1.211 | 1.039 | 1.000 |
[:atomic-values :valid] | 1.099 | 6.748 | 1.155 | 1.058 | 1.000 |
[:custom-predicate :invalid] | 5.968 | 6.497 | 1.811 | 1.000 | 1.156 |
[:custom-predicate :valid] | 4.282 | 14.031 | 1.202 | 1.000 | 1.107 |
[:nil-allowed :invalid] | 26.090 | 23.027 | 1.972 | 1.129 | 1.000 |
[:nil-allowed :valid] | 3.873 | 7.684 | 1.830 | 1.138 | 1.000 |
[:sequential-collections :invalid] | 16.596 | 11.654 | 2.516 | 1.119 | 1.000 |
[:sequential-collections :valid] | 7.487 | 12.314 | 1.668 | 1.311 | 1.000 |