tile38/internal/server
tidwall 9998e03f6f Optimization for non-cross geofence detection
This commit fixes a performance issue with the algorithm that
determines with geofences are potential candidates for
notifications following a SET operation.

Details

Prior to commit b471873 (10 commits ago) there was a bug where
the "cross" detection was not firing in all cases. This happened
because when looking for candidates for "cross" due to a SET
operation, only the geofences that overlapped the previous
position of the object and the geofences that overlapped the new
position where searched. But, in fac, all of the geofences that
overlapped the union rectangle of the old and new position should
have been searched.

That commit fixed the problem by searching a union rect of the
old and new positions. While this is an accurate solution, it
caused a slowdown on systems that have big/wild position changes
that might cross a huge number of geofences, even when those
geofences did not need actually need "cross" detection.

The fix

With this commit the geofences that have a "cross" detection
are stored in a seperated tree from those that do not. This
allows for a hybrid of the functionality prior and post b471873.

Fixes #583
2020-10-23 09:51:27 -07:00
..
aof.go Optimization for non-cross geofence detection 2020-10-23 09:51:27 -07:00
aofmigrate.go Code cleanup 2019-10-30 10:17:59 -07:00
aofshrink.go Fixed panic on AOFSHRINK 2019-11-17 07:25:25 -07:00
atomic.go Removed unused atomics 2018-11-23 01:39:04 -07:00
atomic_test.go Replaced net package with evio 2018-10-28 15:51:47 -07:00
bson.go Replaced net package with evio 2018-10-28 15:51:47 -07:00
checksum.go Code cleanup 2019-10-30 10:17:59 -07:00
client.go Code cleanup 2019-10-30 10:17:59 -07:00
config.go Code cleanup 2019-10-30 10:17:59 -07:00
crud.go Optimization for non-cross geofence detection 2020-10-23 09:51:27 -07:00
dev.go Code cleanup 2019-10-30 10:17:59 -07:00
expire.go Code cleanup 2019-10-30 10:17:59 -07:00
expression.go Code cleanup 2019-10-30 10:17:59 -07:00
fence.go Fix crash in fenceMatchRoam causing an index out of range panic 2020-06-18 15:43:18 +02:00
follow.go Fix a concurrent write/read on the server conn map 2020-03-20 16:47:13 -07:00
hooks.go Optimization for non-cross geofence detection 2020-10-23 09:51:27 -07:00
json.go Code cleanup 2019-10-30 10:17:59 -07:00
json_test.go Code cleanup 2019-10-30 10:17:59 -07:00
keys.go Code cleanup 2019-10-30 10:17:59 -07:00
live.go Added MONITOR command 2020-08-12 12:38:52 -07:00
monitor.go Added MONITOR command 2020-08-12 12:38:52 -07:00
output.go Code cleanup 2019-10-30 10:17:59 -07:00
pubsub.go Code cleanup 2019-10-30 10:17:59 -07:00
readonly.go Code cleanup 2019-10-30 10:17:59 -07:00
respconn.go Replaced net package with evio 2018-10-28 15:51:47 -07:00
scan.go Code cleanup 2019-10-30 10:17:59 -07:00
scanner.go Hotfix for previous commit 2020-07-04 10:35:07 -07:00
scripts.go Added MONITOR command 2020-08-12 12:38:52 -07:00
search.go Fixed a missing faraway event for roaming geofences 2020-03-22 11:54:56 -07:00
server.go Optimization for non-cross geofence detection 2020-10-23 09:51:27 -07:00
stats.go Code cleanup 2019-10-30 10:17:59 -07:00
stats_cpu.go Fix go vet error in stats_cpu.go for non-linux/darwin builds 2019-10-28 22:39:27 -03:00
stats_cpu_darlin.go Code cleanup 2019-10-30 10:17:59 -07:00
test.go Match geometry indexing to server config 2020-03-25 15:35:31 -07:00
token.go Limit geohash precision to 12 2020-08-12 10:58:49 -07:00
token_test.go Replaced net package with evio 2018-10-28 15:51:47 -07:00