We are excited to announce that Event Store 4.1.1 has just been released! It is available for the following operating systems:
This release comes with two major bug fixes.
Affected OS: All OSes
Necessary Conditions:
Symptoms:
The node will exit with an error similar to the following in the logs:
ReadIndex is corrupted...
EventStore.Core.Exceptions.CorruptIndexException: Error while loading IndexMap.
EventStore.Core.Exceptions.CorruptIndexException: Item index for midpoint 8856062 (2147483525) > Item index for midpoint 8856063 (-2147483526)
at EventStore.Core.Index.PTable.CacheMidpointsAndVerifyHash(Int32 depth, Boolean skipIndexVerify)
Impact:
There are two options to prevent this error from occuring:
Affected OS: Windows only
Symptoms:
The node will exit with an error similar to the following in the logs:
Error in TableIndex.ReadOffQueue
System.UnauthorizedAccessException: Access to the path '\path\to\index\indexmap' is denied.
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.File.InternalDelete(String path, Boolean checkHost)
at EventStore.Core.Index.IndexMap.SaveToFile(String filename)
This issue occurs when the Read-Only attribute is set on the indexmap file.
Impact:
PTable merges of index entries that map to scavenged chunks in the database are much slower than merging index entries mapping to non-scavenged chunks by a factor of approximately 10x. The main overhead is due to the time taken to verify if an index entry is still present in the scavenged chunk file. This check is not necessary for non-scavenged chunks because all the entries are still present.
We have made some performance improvements in this area where a user can choose to trade off some memory for speed gains and reduced disk pressure during merges. Our tests show speed gains of around 8x.
You can estimate the maximum amount of additional memory (in GB) you will need with the following formula:
Avg. number of events per chunk file / 40000
For example, with 200000 events per chunk file, the maximum amount of memory required will be 5GB.
This feature is not enabled by default. You can enable it by adding OptimizeIndexMerge: true to your config or adding –optimize-index-merge to your command line arguments.
This allows custom implementation of node discovery by implementing the IEndPointDiscoverer
interface (for example, to obtain IP endpoints from consul or text files). The method Create(ConnectionSettings connectionSettings, IEndPointDiscoverer endPointDiscoverer, string connectionName)
has been added to EventStoreConnection
.
SetQueueTimeoutTo(TimeSpan timeout)
in ConnectionSettingsBuilder
This allows the client to apply backpressure during an overload when the operations queue is full and many operations are waiting to be processed. An OperationExpiredException
exception will be thrown if an operation stays in the queue for longer than the timeout set.
By default, no exception will be thrown (as in previous versions) unless SetQueueTimeoutTo
is called on the builder.
Thanks to bartelink for contributing this feature!
Add KeepDiscovering()
to your ClusterSettingsBuilder
Add PreferSlaveNode()
to your ConnectionSettingsBuilder
or ClusterSettingsBuilder
to prefer doing operations on slave nodes. This also requires adding PerformOnAnyNode()
on the ConnectionSettingsBuilder
Thanks to Salgat for contributing this feature!