1
0
mirror of https://github.com/BDDSM/YY.EventLogReaderAssistant.git synced 2024-11-26 18:11:45 +02:00

Уменьшил размер порции обрабатываемых записей для SQLite базы

This commit is contained in:
YPermitin 2020-04-12 00:00:19 +05:00
parent e843ccb91b
commit e5967a9230

View File

@ -24,7 +24,7 @@ namespace YY.EventLogAssistant
private SQLiteConnection _connection;
private List<RowData> _readBuffer;
private long _lastRowId;
private const int _readBufferSize = 10000;
private const int _readBufferSize = 1000;
private long _lastRowNumberFromBuffer;
private long _eventCount = -1;
@ -117,7 +117,7 @@ namespace YY.EventLogAssistant
bufferRowData.TransactionId = reader.GetInt64OrDefault(6);
bufferRowData.Severity = (Severity)reader.GetInt64OrDefault(15);
bufferRowData.Comment = reader.GetStringOrDefault(16);
bufferRowData.Data = reader.GetStringOrDefault(17).FromWIN1251ToUTF8();
bufferRowData.Data = reader.GetStringOrDefault(17).FromWin1251ToUTF8();
bufferRowData.DataPresentation = reader.GetStringOrDefault(18);
bufferRowData.User = _users.Where(i => i.Code == reader.GetInt64OrDefault(7)).FirstOrDefault();
bufferRowData.Computer = _computers.Where(i => i.Code == reader.GetInt64OrDefault(8)).FirstOrDefault();