cleanup and add riemann controller