{"id":17143060,"url":"https://github.com/debianmaster/test-1111","last_synced_at":"2026-01-04T18:43:07.035Z","repository":{"id":150499362,"uuid":"154811751","full_name":"debianmaster/test-1111","owner":"debianmaster","description":"Generated by the Red Hat Developer Launch (https://developers.redhat.com/launch)","archived":false,"fork":false,"pushed_at":"2018-10-26T09:39:08.000Z","size":32,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-29T14:52:30.231Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"HTML","has_issues":false,"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/debianmaster.png","metadata":{"files":{"readme":"README.adoc","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":"2018-10-26T09:39:01.000Z","updated_at":"2018-10-26T09:39:09.000Z","dependencies_parsed_at":"2023-04-10T01:47:28.259Z","dependency_job_id":null,"html_url":"https://github.com/debianmaster/test-1111","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/debianmaster%2Ftest-1111","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/debianmaster%2Ftest-1111/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/debianmaster%2Ftest-1111/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/debianmaster%2Ftest-1111/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/debianmaster","download_url":"https://codeload.github.com/debianmaster/test-1111/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245241551,"owners_count":20583264,"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":[],"created_at":"2024-10-14T20:33:37.433Z","updated_at":"2026-01-04T18:43:06.984Z","avatar_url":"https://github.com/debianmaster.png","language":"HTML","funding_links":[],"categories":[],"sub_categories":[],"readme":"= Eclipse Vert.x Istio Circuit Breaker mission\n\n== Purpose\nShowcase Istio's Circuit Breaker via a (minimally) instrumented Eclipse Vert.x microservices.\n\n== Prerequisites\n\n* Openshift 3.9 cluster\n* Istio\n* Create a new project/namespace on the cluster. This is where your application will be deployed.\n\nIf you use _istiooc_ launch it with:\n```bash\noc cluster up --istio\n```\n\n```bash\noc login -u system:admin\noc adm policy add-cluster-role-to-user admin developer --as=system:admin\noc login -u developer -p developer\n```\n\n== Environment preparation\n\nCreate a new project/namespace on the cluster. This is where your application will be deployed.\n\n```bash\noc new-project \u003cwhatever valid project name you want\u003e\n```\n\n== Build and deploy the application with the Fabric8 Maven Plugin\n\nExecute the following command to build the project and deploy it to OpenShift:\n```bash\nmvn clean fabric8:deploy -Popenshift\n```\nConfiguration for FMP may be found both in pom.xml and `src/main/fabric8` files/folders.\n\n== Build and deploy the application with the S2I\n\n```bash\nfind . | grep openshiftio | grep application | xargs -n 1 oc apply -f\n\noc new-app --template=vertx-istio-circuit-breaker-greeting -p SOURCE_REPOSITORY_URL=https://github.com/openshiftio-vertx-boosters/vertx-istio-circuit-breaker-booster  -p SOURCE_REPOSITORY_REF=master -p SOURCE_REPOSITORY_DIR=greeting-service\noc new-app --template=vertx-istio-circuit-breaker-name -p SOURCE_REPOSITORY_URL=https://github.com/openshiftio-vertx-boosters/vertx-istio-circuit-breaker-booster  -p SOURCE_REPOSITORY_REF=master -p SOURCE_REPOSITORY_DIR=name-service\n```\n\n\n= Use Cases\n\n== Access the application\n\n* Run the following command to determine the appropriate URL to access our demo. Make sure you access the URL with the\nHTTP scheme. HTTPS is NOT enabled by default:\n+\n```bash\noc create -f rules/gateway.yaml\necho \"http://$(oc get route istio-ingressgateway -o jsonpath='{.spec.host}{\"\\n\"}' -n istio-system)/breaker/greeting\"\n```\n\nOpen the given URL.\n\n== Verify application behavior\n\n1. Click on the \"Start\" button to issue 10 concurrent requests to the name service.\n2. Click on the \"Stop\" button to stop the requests\n3. You can change the number of concurrent requests between 1 and 20.\n4. All calls go through as expected.\n\n\n=== Initial Circuit Breaker configuration\n\n1. Now apply the initial DestinationRule that activates Istio’s Circuit Breaker on the name service, configuring it to\n allow a maximum of 100 concurrent connections.\n\n```bash\noc create -f rules/initial-destination-rule.yaml -n $(oc project -q)\n```\n\n2. You can check that the DestinationRule is properly applied by executing:\n\n```bash\noc get destinationrules.networking.istio.io\n```\n\n3. Try the application again. Since we only make up to 20 concurrent connections, the circuit breaker should not trip.\n\n=== Restrictive Circuit Breaker configuration\n\n1. Now apply a more restrictive DestinationRule, after having remove the initial one:\n\n```bash\noc delete -f rules/initial-destination-rule.yaml\noc create -f rules/restrictive-destination-rule.yaml\n```\n\n2. Try the application again\n\nSince the Circuit Breaker is now configured to only allow one concurrent connection and by default we are sending 10 to\nthe name service, we should now see the Circuit Breaker tripping open. However, experimentally, we observe that this does\nnot happen in a clear-cut fashion: the circuit is not always open. In fact, depending on how fast the server on which the\n application is running, the circuit might not break open at all. The reason for this is that is the name service does\n not do much and thus responds quite fast. This, in turn, leads to not having much concurrency at all.\n\n=== Optional: fault injection\n\nWe could try to increase contention on the name service using Istio’s fault injection behavior by applying a 1-second\ndelay to 50% of the calls to the name service.\n\n1. Create a new `VirtualService` for the name service to inject a processing delay:\n\n```bash\noc create -f rules/name-with-delay.yaml\n```\n\n2. Try the application again\n\nYou should observe that this does not seem to change how often the circuit breaks open. This is due to the fact that\nthe injected delay actually occurs between the services. So, in essence, this only time shifts the requests, only\nincreasing concurrency marginally (due to the fact that only 50% of the requests are delayed). This still does not let\n us observe the circuit breaking open properly.\n\n3. For more comfort, let’s return to the original configuration by deleting the VirtualService we just introduced:\n\n```bash\noc delete -f rules/name-with-delay.yaml\n```\n\n=== Simulate load on the name service\n\nWe need to increase contention on the name service in order to have enough concurrent connections to trip open the\ncircuit breaker. We can accomplish this by simulating load on the name service by asking it to introduce a random\nprocessing time. To accomplish this:\n\n1. Stop the requests (if that wasn’t already the case)\n2. Checking the \"Simulate load\" checkbox\n3. Start the requests.\n\nYou should now observe the circuit breaking open by observing lots of `Hello, Fallback!` messages.\n\n== Undeploy the application\n\n=== With Fabric8 Maven Plugin (FMP)\n\n```bash\nmvn fabric8:undeploy\n```\n\n=== Remove the namespace\nThis will delete the project from the OpenShift cluster.\n\n```bash\noc delete project \u003cyour project name\u003e\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdebianmaster%2Ftest-1111","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdebianmaster%2Ftest-1111","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdebianmaster%2Ftest-1111/lists"}