{"id":37020434,"url":"https://github.com/opencharles/mention-notifications-ejb","last_synced_at":"2026-01-14T02:18:34.607Z","repository":{"id":57716818,"uuid":"75550705","full_name":"opencharles/mention-notifications-ejb","owner":"opencharles","description":"A timer EJB jar that reads and posts Github notifications","archived":true,"fork":false,"pushed_at":"2017-11-24T19:54:16.000Z","size":82,"stargazers_count":5,"open_issues_count":2,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-08-04T09:47:25.479Z","etag":null,"topics":["ejb","fetching-notifications","notifications","ping","webhooks"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/opencharles.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}},"created_at":"2016-12-04T16:51:45.000Z","updated_at":"2023-01-28T14:51:47.000Z","dependencies_parsed_at":"2022-09-26T21:40:20.679Z","dependency_job_id":null,"html_url":"https://github.com/opencharles/mention-notifications-ejb","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"purl":"pkg:github/opencharles/mention-notifications-ejb","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opencharles%2Fmention-notifications-ejb","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opencharles%2Fmention-notifications-ejb/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opencharles%2Fmention-notifications-ejb/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opencharles%2Fmention-notifications-ejb/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/opencharles","download_url":"https://codeload.github.com/opencharles/mention-notifications-ejb/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/opencharles%2Fmention-notifications-ejb/sbom","scorecard":{"id":708988,"data":{"date":"2025-08-11","repo":{"name":"github.com/opencharles/mention-notifications-ejb","commit":"65782e6cacef29eeec530d7ad1df78d2b1f45a8e"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.4,"checks":[{"name":"Maintained","score":0,"reason":"project is archived","details":["Warn: Repository is archived."],"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Code-Review","score":1,"reason":"Found 4/28 approved changesets -- score normalized to 1","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: BSD 3-Clause \"New\" or \"Revised\" License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Vulnerabilities","score":4,"reason":"6 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-2qrg-x229-3v8q","Warn: Project is vulnerable to: GHSA-65fg-84f6-3jq3","Warn: Project is vulnerable to: GHSA-f7vh-qwp3-x37m","Warn: Project is vulnerable to: GHSA-fp5r-v3w9-4333","Warn: Project is vulnerable to: GHSA-w9p3-5cr8-m3jj","Warn: Project is vulnerable to: GHSA-j288-q9x7-2f5v"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 6 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-22T07:35:44.707Z","repository_id":57716818,"created_at":"2025-08-22T07:35:44.707Z","updated_at":"2025-08-22T07:35:44.707Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28408711,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T01:52:23.358Z","status":"online","status_checked_at":"2026-01-14T02:00:06.678Z","response_time":107,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["ejb","fetching-notifications","notifications","ping","webhooks"],"created_at":"2026-01-14T02:18:34.044Z","updated_at":"2026-01-14T02:18:34.596Z","avatar_url":"https://github.com/opencharles.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# mention-notifications-ejb\n\n[![DevOps By Rultor.com](http://www.rultor.com/b/opencharles/mention-notifications-ejb)](http://www.rultor.com/p/opencharles/mention-notifications-ejb)\n[![We recommend IntelliJ IDEA](http://amihaiemil.github.io/images/intellij-idea-recommend.svg)](https://www.jetbrains.com/idea/)\n[![Build Status](https://travis-ci.org/opencharles/mention-notifications-ejb.svg?branch=master)](https://travis-ci.org/opencharles/mention-notifications-ejb)\n[![Coverage Status](https://coveralls.io/repos/github/opencharles/mention-notifications-ejb/badge.svg?branch=master)](https://coveralls.io/github/opencharles/mention-notifications-ejb?branch=master)\n\nAn EJB that reads and posts Github mention notifications.\n\nMore specifically, it checks for the logged-in user's notifications of type \"mention\" and posts them to a specified REST endpoint in **simplified format**. Only the ``repoFullName`` and ``issueNumber`` are sent - the receiver then has to implement the look-up logic in order to find and handle the proper mentioning comment. \n\nOther info returned by the Github API in a Notification object would be rather useless payload since it consists mostly of links that the receiver can build on its own knowing the repo name and issue number.\n\n## The main use\nThe use of such a checker would be together with a Github bot account; naturally, the bot has to act upon received notifications. The bot implementation would have a rest POST endpoint to receive the notifications sent by this checker.\n\n## How I use it\nI use this in one of my projects so far and will probably use it again with others. It was initially a part of said repository but I decided to pull it out and make it reusable.\n\nBTW, I implement all the Github interaction using [this](https://github.com/jcabi/jcabi-github/) awesome library. Check it out, it also offers a mock version of the API so you can unit test your code instantly.\n\nWhy not [Github WebHooks](https://developer.github.com/webhooks/)?\nA few reasons:\n- When I first wrote it I didn't even know about the webhooks and when I had it written I decided that I'd rather have the checker configurable (you can configure this EJB to check at any interval of minutes) and extendable - a class can easely be added to also handle other type of notifications.\n- I don't want the users of my bot to have to configure their repos and setup the hooks.\n- Smaller load, since this checker only sends the required info.\n\n## Deployment\nThis is designed as a single ejb jar, to be deployed on a single server so for this, take the \u003ca href=\"https://oss.sonatype.org/service/local/repositories/releases/content/com/amihaiemil/web/mention-notifications-ejb/2.0.0/mention-notifications-ejb-2.0.0-jar-with-dependencies.jar\"\u003efat\u003c/a\u003e\njar.\n\n**It should work on any webserver** (e.g. Glassfish, Jboss, Payara, WebSphere even), it doesn't rely on proprietary property files or dubious assembly xml files. I spin it inside a Glassfish.\n\nIf, for any reason you want to include it in your ``.war`` and you are using Maven, you can use the dependency\n\nBut **keep in mind** the following: if you deploy your package on multiple nodes, make sure to **specify different check intervals**. It doesn't make sense to have more checkers spinning, each fetching notifications from Github at the same time.\n\n```\n\u003cdependency\u003e\n    \u003cgroupId\u003ecom.amihaiemil.web\u003c/groupId\u003e\n    \u003cartifactId\u003emention-notifications-ejb\u003c/artifactId\u003e\n    \u003cversion\u003e2.0.0\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\nYou will need to set the following system properties. **Pay a lot of attention while configuring these, since everything relies on them**.\nIt can check and send the notifications of more accounds. You just have to specify all the tokens and endpoints in the github.auth.tokens and post.endpoints respectively (separated by ``;``).\n\n## EJB notifications checker sys props\n\u003ctable\u003e\n  \u003ctr\u003e\n    \u003cth\u003eName\u003c/th\u003e\u003cth\u003eValue\u003c/th\u003e\u003cth\u003eDescription\u003c/th\u003e\n  \u003c/tr\u003e\n  \u003ctr\u003e\n    \u003ctd\u003echecks.interval.minutes\u003c/td\u003e\n    \u003ctd\u003einteger\u003c/td\u003e\n    \u003ctd\u003e\u003cb\u003eOptional\u003c/b\u003e. Minutes that should \u003cbr\u003e pass between checks. Defaults to 2.\u003c/td\u003e\n  \u003c/tr\u003e\n  \u003ctr\u003e\n    \u003ctd\u003epost.endpoints\u003c/td\u003e\n    \u003ctd\u003e**path/to/post/resource**/\u003c/td\u003e\n    \u003ctd\u003e\u003cb\u003eMantadory\u003c/b\u003e. Rest endpoints \u003cbr\u003ewhere the found notifications should be sent for handling.\u003c/td\u003e\n  \u003c/tr\u003e\n  \u003ctr\u003e\n    \u003ctd\u003egithub.auth.tokens\u003c/td\u003e\n    \u003ctd\u003estring\u003c/td\u003e\n    \u003ctd\u003e\u003cb\u003eMantadory\u003c/b\u003e. Github agents' access tokens. They should have limited permissions, access to read the notifications is enough.\u003c/td\u003e\n  \u003c/tr\u003e\n  \u003ctr\u003e\n    \u003ctd\u003eLOG_ROOT\u003c/td\u003e\n    \u003ctd\u003estring\u003c/td\u003e\n    \u003ctd\u003e\u003cb\u003eOptional\u003c/b\u003e. Place where the log files will be stored. Defaults to . (dot)\u003c/td\u003e\n  \u003c/tr\u003e\n\u003c/table\u003e\n\n## Contributors wanted\nRead [this](http://www.amihaiemil.com/2016/12/30/becoming-a-contributor.html) post for more details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopencharles%2Fmention-notifications-ejb","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fopencharles%2Fmention-notifications-ejb","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopencharles%2Fmention-notifications-ejb/lists"}