Fixed most of issues with parsing service config
Implemented partial test for json parsing.