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

Support Logging before Infinite Loop #220

Open
nechaido opened this issue Apr 12, 2023 · 1 comment
Open

Support Logging before Infinite Loop #220

nechaido opened this issue Apr 12, 2023 · 1 comment

Comments

@nechaido
Copy link
Member

At the moment if the process encounters an infinite loop it is possible to loose console.log output, from the same sync block.

I believe there should be a way to force process.stdout to write everything to he output right now.

@JaoodxD
Copy link

JaoodxD commented Oct 17, 2023

There could be at least two different approaches:

  1. make logging process synchronous;
  2. run logger in separate thread.

First one could cause problems in case of high logging rate.
The second one will increase overhead on communication between threads as logging units (messages) could be potential big in size.

Additionaly we can introduce SharedArrayBuffer as a temporary storage for logging messages to reduce inter-thread communication overhead.
This improvement would also require adding some kind of dispatcher, such as a semaphore, to sync reads and writes.

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

2 participants