{"id":13451764,"url":"https://github.com/google/guice","last_synced_at":"2025-09-09T20:44:51.381Z","repository":{"id":37678132,"uuid":"20275545","full_name":"google/guice","owner":"google","description":"Guice (pronounced 'juice') is a lightweight dependency injection framework for Java 11 and above, brought to you by Google.","archived":false,"fork":false,"pushed_at":"2025-08-14T09:35:51.000Z","size":125307,"stargazers_count":12666,"open_issues_count":355,"forks_count":1678,"subscribers_count":518,"default_branch":"master","last_synced_at":"2025-09-03T08:18:58.837Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://github.com/google/guice","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/google.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"COPYING","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,"zenodo":null}},"created_at":"2014-05-28T23:18:53.000Z","updated_at":"2025-09-03T07:49:41.000Z","dependencies_parsed_at":"2023-10-14T16:07:49.595Z","dependency_job_id":"bf2041a7-5a45-4627-b7ad-4750d48eab14","html_url":"https://github.com/google/guice","commit_stats":{"total_commits":2045,"total_committers":118,"mean_commits":17.33050847457627,"dds":0.7975550122249389,"last_synced_commit":"552f30e2ee04e893aadb0502f2c68a53e3e9d1b7"},"previous_names":[],"tags_count":37,"template":false,"template_full_name":null,"purl":"pkg:github/google/guice","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/google%2Fguice","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/google%2Fguice/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/google%2Fguice/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/google%2Fguice/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/google","download_url":"https://codeload.github.com/google/guice/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/google%2Fguice/sbom","scorecard":{"id":437165,"data":{"date":"2025-08-11","repo":{"name":"github.com/google/guice","commit":"c6839995f3b9585c28d47ef828c4c7264eb5e4a3"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":5.9,"checks":[{"name":"Maintained","score":1,"reason":"2 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 1","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"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":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","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":"Code-Review","score":1,"reason":"Found 4/29 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":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/ci.yml:1","Info: no jobLevel write permissions found"],"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":"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":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: COPYING:0","Info: FSF or OSI recognized license: Apache License 2.0: COPYING:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Pinned-Dependencies","score":10,"reason":"all dependencies are pinned","details":["Info:   5 out of   5 GitHub-owned GitHubAction dependencies pinned"],"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":"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":"Branch-Protection","score":-1,"reason":"internal error: error during branchesHandler.setup: internal error: githubv4.Query: Resource not accessible by integration","details":null,"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":"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":"Security-Policy","score":10,"reason":"security policy file detected","details":["Info: security policy file detected: github.com/google/.github/SECURITY.md:1","Info: Found linked content: github.com/google/.github/SECURITY.md:1","Info: Found disclosure, vulnerability, and/or timelines in security policy: github.com/google/.github/SECURITY.md:1","Info: Found text in security policy: github.com/google/.github/SECURITY.md:1"],"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":"Fuzzing","score":10,"reason":"project is fuzzed","details":["Info: OSSFuzz integration found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 26 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"}},{"name":"Vulnerabilities","score":8,"reason":"2 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-5mg8-w23w-74h3","Warn: Project is vulnerable to: GHSA-7g45-4rm6-3mm3"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-19T04:57:32.684Z","repository_id":37678132,"created_at":"2025-08-19T04:57:32.684Z","updated_at":"2025-08-19T04:57:32.684Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":273579170,"owners_count":25131094,"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","status":"online","status_checked_at":"2025-09-04T02:00:08.968Z","response_time":61,"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":[],"created_at":"2024-07-31T07:01:01.727Z","updated_at":"2025-09-09T20:44:51.332Z","avatar_url":"https://github.com/google.png","language":"Java","readme":"Guice\n====\n\n-   **Latest releases:**\n    * **[6.0.0](https://github.com/google/guice/wiki/Guice600) (supports `javax.{inject,servlet,persistence}`, [mostly supports](https://github.com/google/guice/wiki/Guice600#jee-jakarta-transition) `jakarta.inject`)**\n    * **[7.0.0](https://github.com/google/guice/wiki/Guice700) (supports `jakarta.{inject,servlet,persistence}`)**\n    * (6.0.0 \u0026 7.0.0 are equivalent except for their javax/jakarta support.)\n-   **Documentation:**\n    * [User Guide](https://github.com/google/guice/wiki/Motivation),\n    * [6.0.0 javadocs](https://google.github.io/guice/api-docs/6.0.0/javadoc/index.html)\n    * [7.0.0 javadocs](https://google.github.io/guice/api-docs/7.0.0/javadoc/index.html)\n    * [Latest Snapshot javadocs](https://google.github.io/guice/api-docs/latest/javadoc/index.html)\n-   **Continuous Integration:**\n    [![Build Status](https://github.com/google/guice/workflows/continuous-integration/badge.svg)](https://github.com/google/guice/actions)\n-   **Mailing Lists:** [User Mailing List](http://groups.google.com/group/google-guice) \u003cbr/\u003e\n-   **License:** [Apache 2.0](http://www.apache.org/licenses/LICENSE-2.0)\n\nOverview\n====\n\nPut simply, Guice alleviates the need for factories and the use of new in your Java code. Think of Guice's @Inject as the new new. You will still need to write factories in some cases, but your code will not depend directly on them. Your code will be easier to change, unit test and reuse in other contexts.\n\nGuice embraces Java's type safe nature. You might think of Guice as filling in missing features for core Java. Ideally, the language itself would provide most of the same features, but until such a language comes along, we have Guice.\n\nGuice helps you design better APIs, and the Guice API itself sets a good example. Guice is not a kitchen sink. We justify each feature with at least three use cases. When in doubt, we leave it out. We build general functionality which enables you to extend Guice rather than adding every feature to the core framework.\n\nGuice aims to make development and debugging easier and faster, not harder and slower. In that vein, Guice steers clear of surprises and magic. You should be able to understand code with or without tools, though tools can make things even easier. When errors do occur, Guice goes the extra mile to generate helpful messages.\n\nFor an introduction to Guice and a comparison to new and the factory pattern, see [Bob Lee's video presentation](https://www.youtube.com/watch?v=hBVJbzAagfs). After that, check out our [user's guide](https://github.com/google/guice/wiki/Motivation).\n\nWe've been running Guice in mission critical applications since 2006, and now you can, too. We hope you enjoy it as much as we do.\n\n\nInstallation Instructions\n====\nGuice Core (Maven)\n```xml\n\u003cdependency\u003e\n  \u003cgroupId\u003ecom.google.inject\u003c/groupId\u003e\n  \u003cartifactId\u003eguice\u003c/artifactId\u003e\n  \u003c!-- {version} can be 6.0.0, 7.0.0, etc. --\u003e\n  \u003cversion\u003e{version}\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\nGuice Extension (Maven)\n```xml\n\u003cdependency\u003e\n  \u003cgroupId\u003ecom.google.inject.extensions\u003c/groupId\u003e\n  \u003c!-- {extension-name} can be one of: assistedinject, dagger-adapter,\n       grapher, jmx, jndi, persist, spring, testlib or throwingproviders --\u003e\n  \u003cartifactId\u003eguice-{extension-name}\u003c/artifactId\u003e\n  \u003c!-- {version} must match the guice core version. --\u003e\n  \u003cversion\u003e{version}\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\nSee [Maven Central](https://central.sonatype.com/artifact/com.google.inject/guice/) for more details, including snippets for other build systems such as Gradle, Ivy, sbt, and more.\n\n---\n[![jolt award](https://user-images.githubusercontent.com/1885701/52603534-0d620380-2e1c-11e9-8cd5-95f0e141fcb0.png)](http://www.drdobbs.com/tools/winners-of-the-18th-jolt-product-excelle/207600666?pgno=6)\n","funding_links":[],"categories":["Java","Projects","Java (78)","三、架构与框架（支撑大型应用）","General","Libraries","Solutions","dependency list","项目","I. Development","IoC","Dependency Injection"],"sub_categories":["Dependency Injection","2. 依赖注入（DI）","依赖注入","6. Useful libraries"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgoogle%2Fguice","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgoogle%2Fguice","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgoogle%2Fguice/lists"}