api: add graceful shutdown, bump project to Go 1.3+