From bfe4ecb2dba210e265bf6395d0c25a5ba70cf9ff Mon Sep 17 00:00:00 2001 From: Diego Pacheco Date: Mon, 2 May 2016 20:01:21 -0300 Subject: [PATCH] add right lib and added jquery --- hystrix-dashboard/build.gradle | 2 +- hystrix-dashboard/src/main/webapp/index.html | 17 +++++++++++++++++ 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/hystrix-dashboard/build.gradle b/hystrix-dashboard/build.gradle index b44ee7c17..a4e45b0cd 100644 --- a/hystrix-dashboard/build.gradle +++ b/hystrix-dashboard/build.gradle @@ -6,7 +6,7 @@ dependencies { compile 'org.apache.httpcomponents:httpclient:4.2.1' compile 'log4j:log4j:1.2.17' compile 'org.slf4j:slf4j-log4j12:1.7.0' - compile 'com.squareup.retrofit:retrofit:2.0.2' + compile 'com.squareup.retrofit:retrofit:2.0.0-beta2' compile 'com.squareup.retrofit2:converter-simplexml:2.0.2' compile 'com.squareup.retrofit2:converter-jackson:2.0.2' testCompile 'junit:junit:4.12' diff --git a/hystrix-dashboard/src/main/webapp/index.html b/hystrix-dashboard/src/main/webapp/index.html index 1a4ea9ea3..38e7698d9 100644 --- a/hystrix-dashboard/src/main/webapp/index.html +++ b/hystrix-dashboard/src/main/webapp/index.html @@ -46,6 +46,22 @@ } }); }); + + $.get( "http://127.0.0.1:8080/eureka/v2/apps", function( data ) { + $.each(data, function(i, item){ + $('#eurekaApp').append($("") + .attr("value",item.name) + .text(item.name)); + + $('#repos').bind('change',function(item){ + var $this = $(this), + $value = $this.val(); + $('#eurekaApp').text($value) + }); + + }); + }); + @@ -57,6 +73,7 @@

Hystrix Dashboard

+

Cluster via Turbine (default cluster): http://turbine-hostname:port/turbine.stream