pub fn to_vec<T>(value: &T) -> Result<Vec<u8>>where T: Serialize,
Serialize a value into a JSONB byte array
Returns an error if serialization fails.