move to interfaces for testing