move module infrastructure to a separate modules