what's for the spring-cloud-turbine clusterNameExpression config mean? -


when used spring-cloud-turbine configured turbine

turbine:   clusternameexpression: new string("default")   appconfig: crm,hystrix 

i don't know what's clusternameexpression mean

when started turbine server, log is

just added , starting handler tuple: streaminghandler_b9a27bea-5fda-4d0f-bfb9-3f2cd23f8066 2015-07-17 11:44:56.535  info 989 --- [nio-8555-exec-2] c.n.turbine.data.aggdatafromcluster      : per handler dispacher started for: streaminghandler_8d325fd3-bfa4-483f-809b-c7172483ad18 2015-07-17 11:44:56.535  info 989 --- [nio-8555-exec-1] c.n.turbine.data.aggdatafromcluster      : per handler dispacher started for: streaminghandler_b9a27bea-5fda-4d0f-bfb9-3f2cd23f8066 2015-07-17 11:44:56.536  info 989 --- [nio-8555-exec-1] c.n.t.monitor.cluster.clustermonitor     : event handlers cluster monitor: [staticlistener_for_aggregator, streaminghandler_b9a27bea-5fda-4d0f-bfb9-3f2cd23f8066, streaminghandler_8d325fd3-bfa4-483f-809b-c7172483ad18] 2015-07-17 11:44:56.536  info 989 --- [nio-8555-exec-2] c.n.t.monitor.cluster.clustermonitor     : event handlers cluster monitor: [staticlistener_for_aggregator, streaminghandler_b9a27bea-5fda-4d0f-bfb9-3f2cd23f8066, streaminghandler_8d325fd3-bfa4-483f-809b-c7172483ad18] 2015-07-17 11:44:56.536  info 989 --- [nio-8555-exec-1] c.n.t.monitor.cluster.clustermonitor     : starting cluster monitor default_agg 2015-07-17 11:44:56.536  info 989 --- [nio-8555-exec-2] c.n.t.monitor.cluster.clustermonitor     : starting cluster monitor default_agg 2015-07-17 11:44:59.157  info 989 --- [        timer-0] o.s.c.n.turbine.eurekainstancediscovery  : fetching instance list apps: [crm, hystrix] 2015-07-17 11:44:59.157  info 989 --- [        timer-0] o.s.c.n.turbine.eurekainstancediscovery  : fetching instances app: crm 2015-07-17 11:44:59.157  info 989 --- [        timer-0] o.s.c.n.turbine.eurekainstancediscovery  : received instance list app: crm, size=3 2015-07-17 11:44:59.208  info 989 --- [        timer-0] o.s.c.n.turbine.eurekainstancediscovery  : fetching instances app: hystrix 2015-07-17 11:44:59.208  info 989 --- [        timer-0] o.s.c.n.turbine.eurekainstancediscovery  : received instance list app: hystrix, size=2 2015-07-17 11:44:59.208  info 989 --- [        timer-0] c.n.t.discovery.instanceobservable       : retrieved hosts instancediscovery: 5 2015-07-17 11:44:59.208  info 989 --- [        timer-0] c.n.t.discovery.instanceobservable       : found hosts have been terminated: 0 2015-07-17 11:44:59.208  info 989 --- [        timer-0] c.n.t.discovery.instanceobservable       : hosts up:2, hosts down: 0 2015-07-17 11:44:59.220  info 989 --- [        timer-0] c.n.t.monitor.instance.instancemonitor   : url host: http://127.0.0.1:8111/hystrix.stream default 2015-07-17 11:44:59.220  info 989 --- [        timer-0] c.n.t.handler.turbinedatadispatcher      :   added , starting handler tuple: default_agg_aggclustereventhandler 2015-07-17 11:44:59.220  info 989 --- [        timer-0] c.n.turbine.data.aggdatafromcluster      : per handler dispacher started for: default_agg_aggclustereventhandler 2015-07-17 11:44:59.221  info 989 --- [        timer-0] c.n.t.monitor.instance.instancemonitor   : url host: http://localhost:8010/hystrix.stream default 2015-07-17 11:45:59.157  info 989 --- [        timer-0] o.s.c.n.turbine.eurekainstancediscovery  : fetching instance list apps: [crm, hystrix] 2015-07-17 11:45:59.157  info 989 --- [        timer-0] o.s.c.n.turbine.eurekainstancediscovery  : fetching instances app: crm 2015-07-17 11:45:59.157  info 989 --- [        timer-0] o.s.c.n.turbine.eurekainstancediscovery  : received instance list app: crm, size=3 2015-07-17 11:45:59.157  info 989 --- [        timer-0] o.s.c.n.turbine.eurekainstancediscovery  : fetching instances app: hystrix 2015-07-17 11:45:59.157  info 989 --- [        timer-0] o.s.c.n.turbine.eurekainstancediscovery  : received instance list app: hystrix, size=2 2015-07-17 11:45:59.157  info 989 --- [        timer-0] c.n.t.discovery.instanceobservable       : retrieved hosts instancediscovery: 5 2015-07-17 11:45:59.157  info 989 --- [        timer-0] c.n.t.discovery.instanceobservable       : found hosts have been terminated: 0 2015-07-17 11:45:59.158  info 989 --- [        timer-0] c.n.t.discovery.instanceobservable       : hosts up:2, hosts down: 0 2015-07-17 11:46:02.629 error 989 --- [nio-8555-exec-2] c.n.t.s.turbinestreamingconnection       : got exception when writing response stream 

i started two same service different ports,but turbine monitor only hanldes default one;

how can configure turbine hanlde services?.

i chinese, i'm sorry english poor

please see documentation: http://projects.spring.io/spring-cloud/docs/1.0.1/spring-cloud.html#_turbine

clusternameexpression spring expression language expression name of cluster instanceinfo. default appname. wouldn't change clusternameexpression.

you need set turbine.aggregator.clusterconfig=crm,hystrix

you need add cluster name clusterconfig in turbine url /turbine.stream?cluster=<clustername>.


Comments