Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support to get channel lifecycle status #1415

Closed
deanna-lad opened this issue May 11, 2022 · 0 comments · Fixed by #1420
Closed

Add support to get channel lifecycle status #1415

deanna-lad opened this issue May 11, 2022 · 0 comments · Fixed by #1420
Assignees
Labels
enhancement New feature or improved functionality.

Comments

@deanna-lad
Copy link

deanna-lad commented May 11, 2022

Add support to get channel lifecycle status

Channel lifecycle status is described at [Channel status / REST / [Docs]|https://ably.com/docs/rest/channel-status#metadata-rest]

It is currently possible to retrieve channel lifecycle status in ably-go by using REST.Request and marshalling the result into a slice of empty interface.

Example:

result, _ := restClient.Request("get", "/channels/test").Pages(context.Background())

result.Next(ctx)

var items []interface{}
if err := result.Items(&items); err != nil {
	fmt.Println(err)
}

fmt.Printf("%+v\n", items)
// [map[channelId:test name:test status:map[isActive:true occupancy:map[metrics:map[connections:1 presenceConnections:1 presenceMembers:1 presenceSubscribers:1 publishers:1 subscribers:1]]]]]

Out of Scope
Realtime subscription to Channel Lifecycle Events. This ticket is only for supporting REST client ‘Get’.

Please see this /~https://github.com/ably/docs/pull/1415for more details

┆Issue is synchronized with this Jira Story by Unito

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or improved functionality.
Development

Successfully merging a pull request may close this issue.

4 participants