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

timeouts on invocations like call_function and eval #55

Open
andrieshiemstra opened this issue Dec 17, 2021 · 2 comments
Open

timeouts on invocations like call_function and eval #55

andrieshiemstra opened this issue Dec 17, 2021 · 2 comments

Comments

@andrieshiemstra
Copy link
Member

for theduke/quickjs-rs#4

i think i want to impl this a bit broader (basicly in all public methods of JSRealmAdapter) so you can allways recover from endless loops and such...

Also i want to reimpl timeouts for get_promise_result (which was removed because it was difficult to impl with Futures)

@andrieshiemstra
Copy link
Member Author

i'm guessing i should give all loop methods in JSRuntimeFacade a timeout: Option<Duration>

this should set a thread_local var which is used by the interupt handler

@andrieshiemstra andrieshiemstra added this to the 0.7 milestone Dec 22, 2021
@andrieshiemstra andrieshiemstra modified the milestones: 0.7, 0.8 Jan 2, 2022
@andrieshiemstra
Copy link
Member Author

andrieshiemstra commented Jan 2, 2022

moving this to next milestone

i need to figure out for myself if i want a global-ish timeout for all tasks added to the event loop or if i want fine-grained controll over setting a timeout per job...

API wise i also want to think about timeouts on promise (fail promises if not fullfilled after x secs and such)

i also want to do some research on whether or not other engines like spidermonkey have a interrupt handler mechanic (if not this will be a quickjs-only thing)

@andrieshiemstra andrieshiemstra removed this from the 0.8 milestone Jul 16, 2022
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

No branches or pull requests

1 participant