Split database adapter into interface and implementation.