[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-3936":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":16,"subscribersCount":16,"size":16,"stars1d":16,"stars7d":17,"stars30d":18,"stars90d":16,"forks30d":16,"starsTrendScore":17,"compositeScore":19,"rankGlobal":10,"rankLanguage":10,"license":10,"archived":20,"fork":20,"defaultBranch":21,"hasWiki":22,"hasPages":22,"topics":23,"createdAt":10,"pushedAt":10,"updatedAt":24,"readmeContent":25,"aiSummary":26,"trendingCount":16,"starSnapshotCount":16,"syncStatus":15,"lastSyncTime":27,"discoverSource":28},3936,"Hystrix","Netflix\u002FHystrix","Netflix","Hystrix is a latency and fault tolerance library designed to isolate points of access to remote systems, services and 3rd party libraries, stop cascading failure and enable resilience in complex distributed systems where failure is inevitable.","",null,"Java",24456,4699,1637,2,0,1,7,45,false,"master",true,[],"2026-06-12 02:00:56","\u003Cimg src=\"https:\u002F\u002Fnetflix.github.io\u002FHystrix\u002Fimages\u002Fhystrix-logo-tagline-850.png\">\n\n# Hystrix: Latency and Fault Tolerance for Distributed Systems\n\n[![NetflixOSS Lifecycle](https:\u002F\u002Fimg.shields.io\u002Fosslifecycle\u002FNetflix\u002Fhystrix.svg)]()\n[![][travis img]][travis]\n[![][maven img]][maven]\n[![][license img]][license]\n\n# Hystrix Status\nHystrix is no longer in active development, and is currently in maintenance mode.\n\nHystrix (at version 1.5.18) is stable enough to meet the needs of Netflix for our existing applications. Meanwhile, our focus has shifted towards more adaptive implementations that react to an application’s real time performance rather than pre-configured settings (for example, through [adaptive concurrency limits](https:\u002F\u002Fmedium.com\u002F@NetflixTechBlog\u002Fperformance-under-load-3e6fa9a60581)). For the cases where something like Hystrix makes sense, we intend to continue using Hystrix for existing applications, and to leverage open and active projects like [resilience4j](https:\u002F\u002Fgithub.com\u002Fresilience4j\u002Fresilience4j) for new internal projects. We are beginning to recommend others do the same.\n\nNetflix Hystrix is now officially in maintenance mode, with the following expectations to the greater community: \nNetflix will no longer actively review issues, merge pull-requests, and release new versions of Hystrix. \nWe have made a final release of Hystrix (1.5.18) per [issue 1891](https:\u002F\u002Fgithub.com\u002FNetflix\u002FHystrix\u002Fissues\u002F1891) so that the latest version in Maven Central is aligned with the last known stable version used internally at Netflix (1.5.11). \nIf members of the community are interested in taking ownership of Hystrix and moving it back into active mode, please reach out to hystrixoss@googlegroups.com.\n\nHystrix has served Netflix and the community well over the years, and the transition to maintenance mode is in no way an indication that the concepts and ideas from Hystrix are no longer valuable. On the contrary, Hystrix has inspired many great ideas and projects. We thank everyone at Netflix, and in the greater community, for all the contributions made to Hystrix over the years.\n\n## Introduction\n\nHystrix is a latency and fault tolerance library designed to isolate points of access to remote systems, services and 3rd party libraries, stop cascading failure and enable resilience in complex distributed systems where failure is inevitable.\n\n## Full Documentation\n\nSee the [Wiki](https:\u002F\u002Fgithub.com\u002FNetflix\u002FHystrix\u002Fwiki\u002F) for full documentation, examples, operational details and other information.\n\nSee the [Javadoc](http:\u002F\u002Fnetflix.github.com\u002FHystrix\u002Fjavadoc) for the API.\n\n## Communication\n\n- Google Group: [HystrixOSS](http:\u002F\u002Fgroups.google.com\u002Fd\u002Fforum\u002Fhystrixoss)\n- Twitter: [@HystrixOSS](http:\u002F\u002Ftwitter.com\u002FHystrixOSS)\n- [GitHub Issues](https:\u002F\u002Fgithub.com\u002FNetflix\u002FHystrix\u002Fissues)\n\n## What does it do?\n\n#### 1) Latency and Fault Tolerance\n\nStop cascading failures. Fallbacks and graceful degradation. Fail fast and rapid recovery. \n\nThread and semaphore isolation with circuit breakers. \n\n#### 2) Realtime Operations\n\nRealtime monitoring and configuration changes. Watch service and property changes take effect immediately as they spread across a fleet. \n\nBe alerted, make decisions, affect change and see results in seconds. \n\n#### 3) Concurrency\n\nParallel execution. Concurrency aware request caching. Automated batching through request collapsing.\n\n## Hello World!\n\nCode to be isolated is wrapped inside the run() method of a HystrixCommand similar to the following:\n\n```java\npublic class CommandHelloWorld extends HystrixCommand\u003CString> {\n\n    private final String name;\n\n    public CommandHelloWorld(String name) {\n        super(HystrixCommandGroupKey.Factory.asKey(\"ExampleGroup\"));\n        this.name = name;\n    }\n\n    @Override\n    protected String run() {\n        return \"Hello \" + name + \"!\";\n    }\n}\n```\n\nThis command could be used like this:\n\n```java\nString s = new CommandHelloWorld(\"Bob\").execute();\nFuture\u003CString> s = new CommandHelloWorld(\"Bob\").queue();\nObservable\u003CString> s = new CommandHelloWorld(\"Bob\").observe();\n```\n\nMore examples and information can be found in the [How To Use](https:\u002F\u002Fgithub.com\u002FNetflix\u002FHystrix\u002Fwiki\u002FHow-To-Use) section.\n\nExample source code can be found in the [hystrix-examples](https:\u002F\u002Fgithub.com\u002FNetflix\u002FHystrix\u002Ftree\u002Fmaster\u002Fhystrix-examples\u002Fsrc\u002Fmain\u002Fjava\u002Fcom\u002Fnetflix\u002Fhystrix\u002Fexamples) module.\n\n## Binaries\n\nBinaries and dependency information for Maven, Ivy, Gradle and others can be found at [http:\u002F\u002Fsearch.maven.org](http:\u002F\u002Fsearch.maven.org\u002F#search%7Cga%7C1%7Cg%3A%22com.netflix.hystrix%22%20AND%20a%3A%22hystrix-core%22).\n\nChange history and version numbers => [CHANGELOG.md](https:\u002F\u002Fgithub.com\u002FNetflix\u002FHystrix\u002Fblob\u002Fmaster\u002FCHANGELOG.md)\n\nExample for Maven:\n\n```xml\n\u003Cdependency>\n    \u003CgroupId>com.netflix.hystrix\u003C\u002FgroupId>\n    \u003CartifactId>hystrix-core\u003C\u002FartifactId>\n    \u003Cversion>x.y.z\u003C\u002Fversion>\n\u003C\u002Fdependency>\n```\nand for Ivy:\n\n```xml\n\u003Cdependency org=\"com.netflix.hystrix\" name=\"hystrix-core\" rev=\"x.y.z\" \u002F>\n```\n\nIf you need to download the jars instead of using a build system, create a Maven pom file like this with the desired version:\n\n```xml\n\u003C?xml version=\"1.0\"?>\n\u003Cproject xmlns=\"http:\u002F\u002Fmaven.apache.org\u002FPOM\u002F4.0.0\" xmlns:xsi=\"http:\u002F\u002Fwww.w3.org\u002F2001\u002FXMLSchema-instance\" xsi:schemaLocation=\"http:\u002F\u002Fmaven.apache.org\u002FPOM\u002F4.0.0 http:\u002F\u002Fmaven.apache.org\u002Fxsd\u002Fmaven-4.0.0.xsd\">\n\t\u003CmodelVersion>4.0.0\u003C\u002FmodelVersion>\n\t\u003CgroupId>com.netflix.hystrix.download\u003C\u002FgroupId>\n\t\u003CartifactId>hystrix-download\u003C\u002FartifactId>\n\t\u003Cversion>1.0-SNAPSHOT\u003C\u002Fversion>\n\t\u003Cname>Simple POM to download hystrix-core and dependencies\u003C\u002Fname>\n\t\u003Curl>http:\u002F\u002Fgithub.com\u002FNetflix\u002FHystrix\u003C\u002Furl>\n\t\u003Cdependencies>\n\t\t\u003Cdependency>\n\t\t\t\u003CgroupId>com.netflix.hystrix\u003C\u002FgroupId>\n\t\t\t\u003CartifactId>hystrix-core\u003C\u002FartifactId>\n\t\t\t\u003Cversion>x.y.z\u003C\u002Fversion>\n\t\t\t\u003Cscope\u002F>\n\t\t\u003C\u002Fdependency>\n\t\u003C\u002Fdependencies>\n\u003C\u002Fproject>\n```\n\nThen execute:\n\n```\nmvn -f download-hystrix-pom.xml dependency:copy-dependencies\n```\n\nIt will download hystrix-core-*.jar and its dependencies into .\u002Ftarget\u002Fdependency\u002F.\n\nYou need Java 6 or later.\n\n## Build\n\nTo build:\n\n```\n$ git clone git@github.com:Netflix\u002FHystrix.git\n$ cd Hystrix\u002F\n$ .\u002Fgradlew build\n```\n\nFurther details on building can be found on the [Getting Started](https:\u002F\u002Fgithub.com\u002FNetflix\u002FHystrix\u002Fwiki\u002FGetting-Started) page of the wiki.\n\n## Run Demo\n\nTo run a [demo app](https:\u002F\u002Fgithub.com\u002FNetflix\u002FHystrix\u002Ftree\u002Fmaster\u002Fhystrix-examples\u002Fsrc\u002Fmain\u002Fjava\u002Fcom\u002Fnetflix\u002Fhystrix\u002Fexamples\u002Fdemo\u002FHystrixCommandDemo.java) do the following:\n\n```\n$ git clone git@github.com:Netflix\u002FHystrix.git\n$ cd Hystrix\u002F\n.\u002Fgradlew runDemo\n```\n\nYou will see output similar to the following:\n\n```\nRequest => GetUserAccountCommand[SUCCESS][8ms], GetPaymentInformationCommand[SUCCESS][20ms], GetUserAccountCommand[SUCCESS, RESPONSE_FROM_CACHE][0ms]x2, GetOrderCommand[SUCCESS][101ms], CreditCardCommand[SUCCESS][1075ms]\nRequest => GetUserAccountCommand[FAILURE, FALLBACK_SUCCESS][2ms], GetPaymentInformationCommand[SUCCESS][22ms], GetUserAccountCommand[FAILURE, FALLBACK_SUCCESS, RESPONSE_FROM_CACHE][0ms]x2, GetOrderCommand[SUCCESS][130ms], CreditCardCommand[SUCCESS][1050ms]\nRequest => GetUserAccountCommand[FAILURE, FALLBACK_SUCCESS][4ms], GetPaymentInformationCommand[SUCCESS][19ms], GetUserAccountCommand[FAILURE, FALLBACK_SUCCESS, RESPONSE_FROM_CACHE][0ms]x2, GetOrderCommand[SUCCESS][145ms], CreditCardCommand[SUCCESS][1301ms]\nRequest => GetUserAccountCommand[SUCCESS][4ms], GetPaymentInformationCommand[SUCCESS][11ms], GetUserAccountCommand[SUCCESS, RESPONSE_FROM_CACHE][0ms]x2, GetOrderCommand[SUCCESS][93ms], CreditCardCommand[SUCCESS][1409ms]\n\n#####################################################################################\n# CreditCardCommand: Requests: 17 Errors: 0 (0%)   Mean: 1171 75th: 1391 90th: 1470 99th: 1486 \n# GetOrderCommand: Requests: 21 Errors: 0 (0%)   Mean: 100 75th: 144 90th: 207 99th: 230 \n# GetUserAccountCommand: Requests: 21 Errors: 4 (19%)   Mean: 8 75th: 11 90th: 46 99th: 51 \n# GetPaymentInformationCommand: Requests: 21 Errors: 0 (0%)   Mean: 18 75th: 21 90th: 24 99th: 25 \n#####################################################################################\n\nRequest => GetUserAccountCommand[SUCCESS][10ms], GetPaymentInformationCommand[SUCCESS][16ms], GetUserAccountCommand[SUCCESS, RESPONSE_FROM_CACHE][0ms]x2, GetOrderCommand[SUCCESS][51ms], CreditCardCommand[SUCCESS][922ms]\nRequest => GetUserAccountCommand[SUCCESS][12ms], GetPaymentInformationCommand[SUCCESS][12ms], GetUserAccountCommand[SUCCESS, RESPONSE_FROM_CACHE][0ms]x2, GetOrderCommand[SUCCESS][68ms], CreditCardCommand[SUCCESS][1257ms]\nRequest => GetUserAccountCommand[SUCCESS][10ms], GetPaymentInformationCommand[SUCCESS][11ms], GetUserAccountCommand[SUCCESS, RESPONSE_FROM_CACHE][0ms]x2, GetOrderCommand[SUCCESS][78ms], CreditCardCommand[SUCCESS][1295ms]\nRequest => GetUserAccountCommand[FAILURE, FALLBACK_SUCCESS][6ms], GetPaymentInformationCommand[SUCCESS][11ms], GetUserAccountCommand[FAILURE, FALLBACK_SUCCESS, RESPONSE_FROM_CACHE][0ms]x2, GetOrderCommand[SUCCESS][153ms], CreditCardCommand[SUCCESS][1321ms]\n```\n\nThis demo simulates 4 different [HystrixCommand](https:\u002F\u002Fgithub.com\u002FNetflix\u002FHystrix\u002Ftree\u002Fmaster\u002Fhystrix-core\u002Fsrc\u002Fmain\u002Fjava\u002Fcom\u002Fnetflix\u002Fhystrix\u002FHystrixCommand.java) implementations with failures, latency, timeouts and duplicate calls in a multi-threaded environment.\n\nIt logs the results of [HystrixRequestLog](https:\u002F\u002Fgithub.com\u002FNetflix\u002FHystrix\u002Ftree\u002Fmaster\u002Fhystrix-core\u002Fsrc\u002Fmain\u002Fjava\u002Fcom\u002Fnetflix\u002Fhystrix\u002FHystrixRequestLog.java) and metrics from [HystrixCommandMetrics](https:\u002F\u002Fgithub.com\u002FNetflix\u002FHystrix\u002Ftree\u002Fmaster\u002Fhystrix-core\u002Fsrc\u002Fmain\u002Fjava\u002Fcom\u002Fnetflix\u002Fhystrix\u002FHystrixCommandMetrics.java).\n\n## Dashboard\n\nThe hystrix-dashboard component of this project has been deprecated and moved to [Netflix-Skunkworks\u002Fhystrix-dashboard](https:\u002F\u002Fgithub.com\u002FNetflix-Skunkworks\u002Fhystrix-dashboard). Please see the README there for more details including important security considerations.\n\n\n## Bugs and Feedback\n\nFor bugs, questions and discussions please use the [GitHub Issues](https:\u002F\u002Fgithub.com\u002FNetflix\u002FHystrix\u002Fissues).\n\n \n## LICENSE\n\nCopyright 2013 Netflix, Inc.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n\u003Chttp:\u002F\u002Fwww.apache.org\u002Flicenses\u002FLICENSE-2.0>\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n\n\n[travis]:https:\u002F\u002Ftravis-ci.org\u002FNetflix\u002FHystrix\n[travis img]:https:\u002F\u002Ftravis-ci.org\u002FNetflix\u002FHystrix.svg?branch=master\n\n[maven]:http:\u002F\u002Fsearch.maven.org\u002F#search|gav|1|g:\"com.netflix.hystrix\"%20AND%20a:\"hystrix-core\"\n[maven img]:https:\u002F\u002Fmaven-badges.herokuapp.com\u002Fmaven-central\u002Fcom.netflix.hystrix\u002Fhystrix-core\u002Fbadge.svg\n\n[release]:https:\u002F\u002Fgithub.com\u002Fnetflix\u002Fhystrix\u002Freleases\n[release img]:https:\u002F\u002Fimg.shields.io\u002Fgithub\u002Frelease\u002Fnetflix\u002Fhystrix.svg\n\n[license]:LICENSE-2.0.txt\n[license img]:https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FLicense-Apache%202-blue.svg\n\n","Hystrix 是一个用于延迟和容错的库，旨在隔离对远程系统、服务和第三方库的访问点，防止级联故障，并在复杂的分布式系统中实现弹性。其核心功能包括线程池隔离、断路器模式、降级策略等，通过这些机制有效提升了系统的稳定性和可用性。适用于微服务架构下需要处理高并发请求及外部依赖不稳定性的场景，如电商平台、在线支付系统等。尽管 Hystrix 目前已进入维护模式，但其设计理念和技术实践依然对构建健壮的服务具有重要参考价值。","2026-06-11 02:57:16","top_language"]