Refactoring, start work on interface for remote procedure calls