aboutsummaryrefslogtreecommitdiffstats
path: root/spec/support
diff options
context:
space:
mode:
authorTeddy Wing2017-12-19 12:00:19 +0100
committerLuc Donnet2017-12-21 15:32:42 +0100
commitd9f3af834a06a6d4e73c083440926983ac5e2cfa (patch)
treed1f30049630d35adddbb36a20dd12df1b195b1ef /spec/support
parent7f9a61d5823bd6611351fcc6dce79a2159976b34 (diff)
downloadchouette-core-d9f3af834a06a6d4e73c083440926983ac5e2cfa.tar.bz2
Change `compliance_{controls,checks}` `control_attributes` to JSON
Make these columns JSON fields again. Do this because of bugs trying to validate types with `hstore_accessor` (https://github.com/devmynd/hstore_accessor/issues/78). With a JSON field, types are preserved and we don't have to deal with casting back and forth. Previously we had converted to Hstore because the Java IEV application used an older ORM version (maybe Hibernate) that didn't support the Postgres JSON type. Because of the validation problems with Hstore, the Java application has been updated to support JSON fields. Thanks to this Stack Overflow post from 'a_horse_with_no_name' that describes how to convert from Hstore to JSON types in Postgres: https://stackoverflow.com/questions/33732529/postgres-how-to-convert-hstore-to-json-datatypes#comment55234342_33732529 Converting in this direction seems to me to be much safer because we're not losing type information. All the values should be hashes of strings, which should convert without issue into JSON. Refs #5316
Diffstat (limited to 'spec/support')
0 files changed, 0 insertions, 0 deletions