make metadata storage pluggable

When I created sql statements for derby, i changed the type to SMALLINT in order to make it work with the tutorial on the druid website. The tutorial uses 1 or 0 to indicate boolean but derby doesn't accept it as a boolean