CLDIDE-2106 Moved code that is duplicated to utility class