{"id":24432258,"url":"https://github.com/ssubedir/goriffin","last_synced_at":"2025-10-24T05:19:31.268Z","repository":{"id":107269065,"uuid":"261330333","full_name":"ssubedir/goriffin","owner":"ssubedir","description":"Heartbeat Monitor developed in go","archived":false,"fork":false,"pushed_at":"2020-06-10T03:16:00.000Z","size":36,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-20T15:47:37.883Z","etag":null,"topics":["background-jobs","background-service","go","golang","gorutines","grpc-go","heartbeat","protocol-buffers","rest-api"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ssubedir.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-05-05T00:58:12.000Z","updated_at":"2022-05-06T19:23:29.000Z","dependencies_parsed_at":null,"dependency_job_id":"236748ea-888e-4105-b233-d695dc5a9ef3","html_url":"https://github.com/ssubedir/goriffin","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ssubedir%2Fgoriffin","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ssubedir%2Fgoriffin/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ssubedir%2Fgoriffin/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ssubedir%2Fgoriffin/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ssubedir","download_url":"https://codeload.github.com/ssubedir/goriffin/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243475366,"owners_count":20296712,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["background-jobs","background-service","go","golang","gorutines","grpc-go","heartbeat","protocol-buffers","rest-api"],"created_at":"2025-01-20T15:36:28.099Z","updated_at":"2025-10-24T05:19:26.225Z","avatar_url":"https://github.com/ssubedir.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\u003cimg src=\"https://i.imgur.com/s74yXT7.png\" width=\"400\"\u003e\u003c/p\u003e\n\u003cp align=\"center\"\u003e\n\u003ca href=\"https://github.com/ssubedir/goriffin/actions\"\u003e\u003cimg src=\"https://github.com/ssubedir/goriffin/workflows/Go/badge.svg\" alt=\"Build Test\"\u003e\u003c/a\u003e\n\u003ca href=\"https://goreportcard.com/report/github.com/ssubedir/goriffin\"\u003e\u003cimg src=\"https://goreportcard.com/badge/github.com/ssubedir/goriffin\" alt=\"Latest Stable Version\"\u003e\u003c/a\u003e\n\u003ca href=\"https://github.com/ssubedir/goriffin/blob/master/LICENSE\"\u003e\u003cimg src=\"https://poser.pugx.org/laravel/framework/license.svg\" alt=\"License\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n# About Goriffin\nGoriffin is written in go, a heartbeat surveillance program. Goriffin is packed with goriffin API and the goriffin background processor. The API is used to configure the services being monitored and the background processor checks the services periodically and reports the status of that same services to a Mongo db\n\n## Getting Started\n\nThese instructions will get you a copy of the project up and run the service on your local machine.See deployment for notes on how to deploy the project on a live system.\n\n### Prerequisites\n\nYou will need to install go version go1.11 +\n\n### Download\n\nUse git clone to get your local copy \n```\ngit clone https://github.com/ssubedir/goriffin\n```\n\n## Deployment\n\nUse the go build command to build each components \n\n### Build Project\n\nBuild Goriffin API\n```\ngo build -v cmd/goriffin/goriffin.go \n```\nBuild Goriffin background processor\n```\ngo build -v cmd/background/goriffin_background.go \n```\n### Deploy\n\nBefore you run Goriffin create .env file with the following Environmental Variables\n\n```\n# MongoDB info\nDB0_USER=username\nDB0_PASSWORD=password\nDB0_CLUSTER=address/cluster\n\n  \n#Database\nDB_DBNAME= database name\nSERVICES_HEARTBEAT=collection name\nHEARTBEAT_HTTP=collection name\n\n \n# Number of workers for the background processing \nWORKER_COUNT=16\n\n#Goriffin Api port\nAPI_PORT=9000\n#Goriffin background processor grpc port\nGRPC_PORT=9092\n```\n## Goriffin Api\n\n### Sattus of Background Processor \n```\nGET localhost:API_PORT/status\n```\nReturns the status of the background goriffin processor by making gRPC request\n\n### Fetch all services\n```\nGET localhost:API_PORT/services\n```\nReturns all the services that are being monitored.\n\n```\n// Response\n{\n\t\"status\": true,\n  \"time\": \"2020-05-04 23:39:50.8786948 -0400 EDT\"\n}\n```\n\n### Fetch a service\n```\nGET localhost:API_PORT/service\n```\n```\n// Example request template\n{\n\t \"host\":\"example.com\",\n\t \"stype\":\"http\"\n}\n```\n\nReturns a single service.\n\n```\n// Response\n{\n\t\"host\":\"example.com\",\n\t\"name\":\"example\",\n\t\"stype\":\"http\",\n\t\"accepted_status\":{\n\t\t\"200\":true\n\t\t},\n\t\"frequency\":30,\n\t\"request_method\":\"GET\",\n\t\"request_payload\":\"\",\n\t\"request_headers\":[[\"Key\",\"Value\"]]\n}\n```\n### Add a service\n```\nPOST localhost:API_PORT/service\n```\n```\n// Example request template\n{\n\t\"host\":\"example.com\",\n\t\"name\":\"example\",\n\t\"stype\":\"http\",\n\t\"accepted_status\":{\n\t\t\"200\":true\n\t\t},\n\t\"frequency\":30,\n\t\"request_method\":\"GET\",\n\t\"request_payload\":\"\",\n\t\"request_headers\":[[\"Key\",\"Value\"]]\n}\n```\n\n\nReturns the the added service\n```\n// Response\n{\n\t\"host\":\"example.com\",\n\t\"name\":\"example\",\n\t\"stype\":\"http\",\n\t\"accepted_status\":{\n\t\t\"200\":true\n\t\t},\n\t\"frequency\":30,\n\t\"request_method\":\"GET\",\n\t\"request_payload\":\"\",\n\t\"request_headers\":[[\"Key\",\"Value\"]]\n}\n\n```\n\n### Remove a service\n```\nDELETE localhost:API_PORT/service\n```\n```\n// Example request template\n{\n\t \"host\":\"example.com\",\n\t \"stype\":\"http\"\n}\n```\n\nReturns the status of the action\n\n```\n// Response\n{\n\t\"host\": \"example.com\"\n\t\"status\": true\n}\n\n```\n\n\n\n\n## Built With\n\n* [GO](https://golang.org/) - Programming language\n\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE.md](https://github.com/ssubedir/goriffin/blob/master/LICENSE) file for details\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fssubedir%2Fgoriffin","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fssubedir%2Fgoriffin","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fssubedir%2Fgoriffin/lists"}