Same as the koya project
The result of http://node1:1025/ws/v1/slider/publisher/exports
is
{
- exports:
{
- servers:
{
- description: "servers",
- updated: 1433177762880,
- updatedTime: "Mon Jun 01 09:56:02 PDT 2015",
- entries: { },
- empty: true
},
- container_log_dirs:
{
- description: "container_log_dirs",
- updated: 1433177762881,
- updatedTime: "Mon Jun 01 09:56:02 PDT 2015",
- entries: { },
- empty: true
},
- container_work_dirs:
{
- description: "container_work_dirs",
- updated: 1433177762881,
- updatedTime: "Mon Jun 01 09:56:02 PDT 2015",
- entries: { },
- empty: true
}
}
}
As you can see all entries are empty, and you have to manually attach the
name to get the value
For example you have to call
http://node1:1025/ws/v1/slider/publisher/exports/servers to get
{
- description: "servers",
- updated: 1433177762880,
- updatedTime: "Mon Jun 01 09:56:02 PDT 2015",
- entries:
{
- org.apache.kafka.broker:
[
-
{
- value: "node23:56579",
- containerId: "container_1432861905779_0057_01_000004",
- tag: "2",
- level: "component",
- updatedTime: "Mon Jun 01 09:56:02 PDT 2015"
},
-
{
- value: "node20:44118",
- containerId: "container_1432861905779_0057_01_000002",
- tag: "1",
- level: "component",
- updatedTime: "Mon Jun 01 09:56:02 PDT 2015"
},
-
{
- value: "node24:34387",
- containerId: "container_1432861905779_0057_01_000003",
- tag: "3",
- level: "component",
- updatedTime: "Mon Jun 01 09:56:02 PDT 2015"
}
]
},
- empty: false
}
It's not a bug, but it's nice to have everything in
*ws/v1/slider/publisher/exports
*so that user can just view the value directly from AM UI
On Tue, Jun 2, 2015 at 9:40 AM, Gour Saha <[email protected]> wrote:
> It is REST style uri, so if you append the uri path with the export group
> name you will get the info you are looking for.
>
> If that does not answer your question, can you give an example response
> that you are expecting to see?
>
> -Gour
>
> > On Jun 2, 2015, at 8:33 AM, "[email protected]" <[email protected]> wrote:
> >
> > I've noticed the http://hostname/ws/v1/slider/publisher/exports/
> > <http://c6401.ambari.apache.org:1025/ws/v1/slider/publisher/exports/>
> only
> > gives you the list of export values, but within each one the entries
> block
> > are empty. Is it ok have them all embedded in one response so that you
> can
> > get all information directly from slider AM UI.
> >
> > On Mon, Jun 1, 2015 at 12:35 PM, Jean-Baptiste Note <[email protected]>
> > wrote:
> >
> >> Thanks Gour,
> >>
> >> Indeed it does help; because I can see a way to combine these to avoid
> >> polling.
> >> By monitoring the ZK registry and doing CURL whenever there's a child
> >> change in the registry it looks I can reliably track changes in the
> export
> >> group, so this is perfect.
> >> I'll let you know how implementation goes :)
> >>
> >> Kind regards,
> >> JB
> >>
>