This class should be moved to an internal package