Updated to new format.
Added publish and destroy methods.