added license headers
fixed NPE for header map
enabled CORS
set process id for output messages