[
https://issues.apache.org/jira/browse/SLIDER-768?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Steve Loughran resolved SLIDER-768.
-----------------------------------
Resolution: Fixed
I'm going to close this as fixed, though I can see lots of future work here.
{{application/live/liveness}} now returns an instance of
{{ApplicationLivenessInformation}}
which looks like
{code}
{
"allRequestsSatisfied": true,
"requestsOutstanding": 0
}
{code}
The slider REST client class can fetch and deserialize this
The same information is also passed back in the cluster status JSON under the
`liveness` clause.
{code}
{
"version": "1.0",
"name": "testupdatecluster",
"type": "agent",
"state": 3,
"createTime": 1422895870347,
"updateTime": 0,
"originConfigurationPath":
"file:/Users/stevel/.slider/cluster/testupdatecluster/snapshot",
"generatedConfigurationPath":
"file:/Users/stevel/.slider/cluster/testupdatecluster/generated",
"dataPath": "file:/Users/stevel/.slider/cluster/testupdatecluster/database",
"options": {
},
"info": {
"info.am.container.id": "container_1422895860741_0001_01_000001",
"info.am.rpc.port": "1024",
"info.am.attempt.id": "appattempt_1422895860741_0001_000001",
"yarn.memory": "8192",
"info.am.web.port": "1025",
"info.am.web.url": "http://stevel.local:1025/",
"info.am.app.id": "application_1422895860741_0001",
"yarn.vcores": "1",
"info.am.hostname": "stevel.local",
"status.application.build.info": "Slider Core-0.62.0-SNAPSHOT Built
against commit# bbd09a2926 on Java 1.7.0_67 by stevel",
"status.hadoop.build.info": "2.6.0",
"status.hadoop.deployed.info": "release-2.6.0
@18e43357c8f927c0695f1e9522859d6a",
"live.time": "2 Feb 2015 16:51:10 GMT",
"live.time.millis": "1422895870347",
"create.time": "2 Feb 2015 16:51:10 GMT",
"create.time.millis": "1422895870347",
"containers.at.am-restart": "0",
"status.time": "2 Feb 2015 16:51:11 GMT",
"status.time.millis": "1422895871004"
},
"statistics": {
"slider-appmaster": {
"containers.unknown.completed": 0,
"containers.start.started": 0,
"containers.live": 1,
"containers.start.failed": 0,
"containers.failed": 0,
"containers.completed": 0,
"containers.surplus": 0
},
"hbase-master": {
"containers.start.started": 0,
"containers.live": 0,
"containers.start.failed": 0,
"containers.active.requests": 0,
"containers.failed": 0,
"containers.completed": 0,
"containers.desired": 1,
"containers.requested": 0
}
},
"instances": {
"slider-appmaster": [
"container_1422895860741_0001_01_000001"
]
},
"roles": {
"slider-appmaster": {
"site.global.security_enabled": "false",
"yarn.memory": "1024",
"site.fs.default.name": "file:///",
"yarn.vcores": "1",
"zookeeper.hosts": "localhost",
"site.fs.defaultFS": "file:///",
"env.MALLOC_ARENA_MAX": "4",
"zookeeper.path": "/services/slider/users/stevel/testupdatecluster",
"jvm.heapsize": "256M",
"yarn.component.instances": "1",
"zookeeper.quorum": "localhost:62819",
"application.def":
"file:/private/var/folders/57/xyts0qt105z1f1k0twk6rd8m0000gq/T/junit6589478645151042153/testpkg/appdef_1.zip",
"role.actual.instances": "1",
"role.requested.instances": "0",
"role.releasing.instances": "0",
"role.failed.instances": "0",
"role.failed.starting.instances": "0"
},
"hbase-master": {
"site.fs.defaultFS": "file:///",
"site.global.security_enabled": "false",
"yarn.role.priority": "2",
"site.fs.default.name": "file:///",
"env.MALLOC_ARENA_MAX": "4",
"zookeeper.path": "/services/slider/users/stevel/testupdatecluster",
"yarn.component.instances": "1",
"agent.conf":
"file:/Users/stevel/Projects/Hortonworks/Projects/slider/slider-core/target/agent_minicluster_testbase/agentconf.zip",
"zookeeper.quorum": "localhost:62819",
"zookeeper.hosts": "localhost",
"application.def":
"file:/private/var/folders/57/xyts0qt105z1f1k0twk6rd8m0000gq/T/junit6589478645151042153/testpkg/appdef_1.zip",
"app.name": "HBASE",
"role.actual.instances": "0",
"role.requested.instances": "0",
"role.releasing.instances": "0",
"role.failed.instances": "0",
"role.failed.starting.instances": "0"
}
},
"clientProperties": {
},
"status": {
"live": {
"slider-appmaster": {
"container_1422895860741_0001_01_000001": {
"name": "container_1422895860741_0001_01_000001",
"role": "slider-appmaster",
"roleId": 0,
"createTime": 1422895870372,
"startTime": 1422895870372,
"released": false,
"host": "stevel.local",
"state": 0,
"exitCode": 0,
"command": "",
"diagnostics": ""
}
}
}
},
"liveness": {
"allRequestsSatisfied": true,
"requestsOutstanding": 0
}
}
{code}
The AM is also publishing that outstanding request counter as a Codahale
counter to whatever is monitoring it : JMX, Ganglia, graphite (this is
experimental; if it works we can switch all app state counters to be metrics.
> API to indicate when all component instances are launched
> ---------------------------------------------------------
>
> Key: SLIDER-768
> URL: https://issues.apache.org/jira/browse/SLIDER-768
> Project: Slider
> Issue Type: Improvement
> Components: appmaster
> Affects Versions: Slider 0.50, Slider 0.60
> Reporter: Lee Yang
> Assignee: Steve Loughran
> Priority: Minor
> Fix For: Slider 0.70
>
> Original Estimate: 2h
> Remaining Estimate: 2h
>
> Currently, we are querying the Slider AppMaster's "componentinstancedata" API
> in order to get the list of containers/hosts/ports of components launched by
> Slider.
> When launching a large number of components, this API can report back with an
> incomplete list of containers/hosts/ports. Currently, we have to compare
> this list with the number of requested components.
> Ideally, we would like to have some indication of "all components started"
> (either in a separate API, or as part of this existing api).
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)