Fixing REGISTRY-2305 - Refactored to remove deprecated CarbonContext API methods