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

Allow downstream projects to import func-e #446

Merged
merged 2 commits into from
Aug 22, 2024
Merged

Allow downstream projects to import func-e #446

merged 2 commits into from
Aug 22, 2024

Conversation

arkodg
Copy link
Contributor

@arkodg arkodg commented Aug 9, 2023

  • Define an api that allows go projects to use func-e as a library

Takes #434 forward

Fixes: #433

@arkodg
Copy link
Contributor Author

arkodg commented Aug 9, 2023

CI is failing due to an unrelated test failing

func TestLastKnownEnvoyAvailableOnAllPlatforms(t *testing.T) {

api/run.go Show resolved Hide resolved
// Wait for run to exit or an explicit stop.
select {
case <-ctx.Done():
return nil
Copy link
Member

Choose a reason for hiding this comment

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

shouldn't we kill the envoy process in this case? (not sure if there's such function in func-e now)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

isn't this done in the called func libs

// At this point, shutdown hooks have run and Envoy is interrupted.
?

Copy link
Member

Choose a reason for hiding this comment

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

ok cool but it seems to me that the code block only reaches when the OS signal was sent. Is there any way to verify that it works as intended? e.g. passing the fake config that runs indefinitely in tests?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

can you point me to some tests in the code base that verify this, that I can peruse here ?

Copy link
Member

Choose a reason for hiding this comment

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

sorry no idea. Could you do that by yourself ?

* Define an api that allows go projects to use func-e as a library

Takes #434 forward

Fixes: #433

Signed-off-by: Arko Dasgupta <[email protected]>
Copy link
Member

@mathetake mathetake left a comment

Choose a reason for hiding this comment

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

YOLO

@arkodg arkodg merged commit c85a098 into master Aug 22, 2024
8 checks passed
@arkodg arkodg deleted the run-api branch August 22, 2024 22:35
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.

Allow downstream projects to programmatically run envoy
2 participants