Integrate DBGATEWAY

- fix SIGSEGV with osstream.str(). need std::string(ost.str()) to make a copy
- add try..catch calling dbgateway APIs
- add SIGSEGV signal handling