About this project

Tile38 is an open-source (MIT licensed) in-memory geolocation data store, spatial index, and realtime geofencing server. It supports a variety of object types including lat/lon points, bounding boxes, XYZ tiles, Geohashes, QuadKeys, and GeoJSON. Key features include: - Spatial index with search methods such as Nearby, Within, and Intersects - Realtime geofencing through webhooks or pub/sub channels - Support for multiple protocols: HTTP, websockets, telnet, and Redis RESP - Server responses in RESP or JSON format - Full command line interface (tile38-cli) - Leader/follower replication - In-memory database with disk persistence - Prometheus metrics export The system consists of three components: tile38-server (the server), tile38-cli (command line interface), and tile38-benchmark (server benchmark tool). Tile38 can be deployed via pre-built binaries for OSX, Linux, FreeBSD, and Windows, Docker, or Homebrew on macOS. The codebase is written entirely in Go and supports both 32-bit and 64-bit systems. Search capabilities include filtering by field values (WHERE), object ID matching (MATCH), cursor-based iteration, field exclusion (NOFIELDS), and result limiting (LIMIT). WHERE expressions support regex matching using Go's re2 engine. Geofencing allows any standard search to be converted into a geofence monitor by adding the FENCE keyword. The server notifies clients in realtime when objects enter, exit, or cross boundaries, with detection types including inside, outside, enter, exit, and cross. Geofence notifications can be delivered via webhooks or pub/sub channels. Fields are extra data attached to objects, stored as double precision floating point values with no limit on the number of fields per object. Tile38 has dedicated client libraries for Go, Node.js, Python, TypeScript, Rust, Swift, and Java, as well as compatibility with most Redis client libraries due to its native RESP protocol support.