[PIR-994] - Fixed encoding issue with Metadata domain save, by recovering old code and fixing issue in ByteArrayInputStream creation
Merge pull request #1482 from webdetails/PIR-994

[PIR-994] - Fixed encoding issue with Metadata domain save, by recoverin...