Added context type to bucket service. And auto creation of missing buckets