Client updating

We have a log feed in our Gateway that may process separate entries as fast as 10/sec for short periods. Currently they get sent to a file…all that works…If I want the clients to display a real-time feed of these messages in a rolling list or some such thing, how do I get the information to the clients? If I place each log entry in a tag (in the gateway script) and use a client tag change script, will the 10 per minute bursts be too fast and cause the clients to miss some messages? Or is there another way to do this?

I would try putting the log information into a database rather than a file. That way you can easily make a window that runs a simple SQL query to get the data.

That was my first consideration however we have gotten into 2 tight spots doing that.

  1. An error caused a flood of log messages into the database, we always attempt to avoid this condition, but it does happen from time to time. If we flood messages into an ascii file, the impact on the system proper is isolated

  2. Customers often ask to take a look at the logs and export them for their own use but are usually unwilling to dig into an SQL database but nobody has a problem copying some ascii files around.

We have been logging to ascii files for about 15 years. We moved to database logging for a year and gave it a fair shake. It was convenient but it created more problems than it solved.

Ok, no problem. If you use files it shouldn’t be a problem saving the information every 10 seconds like that. You can use:system.file.readFileAsStringro read the file into the client. Python also has some really good file functions to read line by line.

So sort of keep the file open as read only in the clients and chase the information being written into it? I’ll try it and see if I have any issues if I bump into the EOF, but barring that, it sounds like a good starting point…Thanks.