Moved key serialization from data provider to data viewers.