Merge pull request #98 from afrjorge/CDF-255

[CDF-255] cherry-pick from master & 5-trunk into core-refactor