Re: Challenge: Build a Color-Coded Log Viewer for Phix/Euphoria (Inspired by chat.exw)

new topic     » goto parent     » topic index » view thread      » older message » newer message

Update... There are more edge cases than I expected. Testing is slow going as a result. Progress continues. But... slower. All of the edge cases revolve around bringing the viewer online while the client is running. (simulating attaching to an already running process) Or the opposite, taking the viewer down while the logging client is running. It might be better to write it native to Phix/Euphoria. The viewer concept seems to be working, though. Yay!

What works well is if you already have the viewer running before starting logs. Or, if you never start the viewer while logs are being written. Anything in between is luck and timing.

The trick to solving this will likely be one of these things:

  1. Switch to UDP.
  2. Async calls in the client with very fast timeouts (50 or maybe 100 ms).
  3. Less than real-time log viewing.
  4. Multiple viewer retries until the logger takes a break from chatter.
  5. Live with the limitation and document start/stop the viewer before logging starts.


UDP is a very fast and easy approach. It's perfect for this kind of app. But I have hopes that the viewer might be able to evolve into a remote debugger. UDP is not well suited for that.

Async also solves some of the problems, but it would need a logging dll for Euphoria... I think. Right now, such a dll is optional for Euphoria/Phix as the logger can be written natively. IIRC threads aren't possible in Euphoria. So async seems not likey. Phix does have threads... I think.

OK, that's my update.

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu