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

adds events to go sdk, changelog #397

Merged
merged 3 commits into from
May 25, 2023
Merged

adds events to go sdk, changelog #397

merged 3 commits into from
May 25, 2023

Conversation

andrewpmartinez
Copy link
Member

@andrewpmartinez andrewpmartinez commented May 16, 2023

Example of using the new events.

ztx, err := ziti.NewContext(cfg)

serviceAddedChan := make(chan *rest_model.ServiceDetail, 1)

serviceAddedRemover := ztx.Events().AddServiceAddedListener(func(detail *rest_model.ServiceDetail) {
	serviceAddedChan <- detail
})

Tests are in the edge repo...as there is a circular dependency trying to run controllers for integration tests here. See draft PR here: openziti/edge#1501

@andrewpmartinez andrewpmartinez force-pushed the add.auth.events branch 3 times, most recently from de7f74f to b7da4ec Compare May 24, 2023 14:10
@andrewpmartinez andrewpmartinez changed the title adds new event emitting interface to SDK contexts adds events to go sdk, changelog May 24, 2023
- fixes an issue where MFA callback could forever stall the SDK
@andrewpmartinez andrewpmartinez marked this pull request as ready for review May 24, 2023 17:40
@andrewpmartinez andrewpmartinez requested a review from a team as a code owner May 24, 2023 17:40
CHANGELOG.md Outdated Show resolved Hide resolved
ziti/ziti.go Outdated Show resolved Hide resolved
@andrewpmartinez andrewpmartinez requested a review from a team May 24, 2023 19:01
Copy link
Member

@plorenz plorenz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't love the kataras events library any more. I prefer something more type safe and with clearer concurrency. You do have type safe high level apis, so it doesn't matter from the consumer side.

@andrewpmartinez andrewpmartinez merged commit 321b41c into main May 25, 2023
6 checks passed
@andrewpmartinez andrewpmartinez deleted the add.auth.events branch May 25, 2023 17:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants