SONAR-5056 Fix performance issue when converting new rule to old rule