Commit Graph

41 Commits

Author SHA1 Message Date
Alex Roitman 5da63881c6 Adjust commands.json 2019-04-25 14:22:25 -07:00
Alex Roitman d3350c033f Add session timeout description to commands.json 2019-04-24 13:26:25 -07:00
Alex Roitman 7177a6468f Add TIMEOUT description to the commands.json 2019-04-24 12:08:07 -07:00
Alex Roitman d179a8f2a3 Forgot to add POINT to commands.json 2019-02-10 14:56:11 -08:00
Alex Roitman a3b17258c9 Add command description 2019-02-08 13:57:48 -08:00
Alex Roitman 2a544f2d2c Add command stubs for new commands. Fix typos. 2018-12-28 15:00:13 -08:00
tidwall 6257ddba78 Faster point in polygon / GeoJSON updates
The big change is that the GeoJSON package has been completely
rewritten to fix a few of geometry calculation bugs, increase
performance, and to better follow the GeoJSON spec RFC 7946.

GeoJSON updates

- A LineString now requires at least two points.
- All json members, even foreign, now persist with the object.
- The bbox member persists too but is no longer used for geometry
  calculations. This is change in behavior. Previously Tile38 would
  treat the bbox as the object's physical rectangle.
- Corrections to geometry intersects and within calculations.

Faster spatial queries

- The performance of Point-in-polygon and object intersect operations
  are greatly improved for complex polygons and line strings. It went
  from O(n) to roughly O(log n).
- The same for all collection types with many children, including
  FeatureCollection, GeometryCollection, MultiPoint, MultiLineString,
  and MultiPolygon.

Codebase changes

- The pkg directory has been renamed to internal
- The GeoJSON internal package has been moved to a seperate repo at
  https://github.com/tidwall/geojson. It's now vendored.

Please look out for higher memory usage for datasets using complex
shapes. A complex shape is one that has 64 or more points. For these
shapes it's expected that there will be increase of least 54 bytes per
point.
2018-10-13 04:30:48 -07:00
Josh Baker 7e9871bb69 Refactor project layout
Move internal and support packages to pkg directory
2018-04-19 08:43:32 -07:00
Alex Roitman 9ffca9aa10 Tests and commands.json for WHEREEVAL. 2018-02-15 16:42:07 -08:00
Josh Baker 89662d9c89 update FSET args 2017-11-16 18:19:07 -07:00
Alex Roitman 2a5e760cee Update commands.json for new fset 2017-11-10 14:58:51 -08:00
Alex Roitman abffd5ce74 Lua (#226)
* Typos
2017-10-05 15:03:50 -07:00
Alex Roitman bfa4bbe237 Lua (#225)
* Add periodic pruning of the lua state pool
2017-10-05 14:13:02 -07:00
Alex Roitman b55300b729 Lua scripting feature. (#224)
* Start on lua scripting

* Implement evalsha, script load, script exists, and script flush

* Type conversions from lua to resp/json.
Refactor to make luastate and luascripts persistent in the controller.

* Change controller.command and all underlying commands to return resp.Value.
Serialize only during the ouput.

* First stab at tile38 call from lua

* Change tile38 into tile38.call in Lua

* Property return errors from scripts

* Minor refactoring.  No locking on script run

* Cleanup/refactoring

* Create a pool of 5 lua states, allow for more as needed. Refactor.

* Use safe map for scripts.  Add a limit for max number of lua states.  Refactor.

* Refactor

* Refactor script commands into atomic, read-only, and non-atomic classes.
Proper locking for all three classes.
Add tests for scripts

* More tests for scripts

* Properly escape newlines in lua-produced errors

* Better test for readonly failure

* Correctly convert ok/err messages between lua and resp.
Add pcall, sha1hex, error_reply, status_reply functions to tile38 namespace in lua.

* Add pcall test. Change writeErr to work with string argument

* Make sure eval/evalsha never attempt to write AOF

* Add eval-set and eval-get to benchmarks

* Fix eval benchmark tests, add more

* Improve benchmarks

* Optimizations and refactoring.

* Add lua memtest

* Typo

* Add dependency

* golint fixes

* gofmt fixes

* Add scripting commands to the core/commands.json

* Use ARGV for args inside lua
2017-10-05 08:20:40 -07:00
Alex Roitman 1e4b635e19 Add tests for WHEREIN. Add WHEREIN to the commands.json 2017-08-24 10:57:07 -07:00
Josh Baker 9fb312b3cc updated docs, fixes #117 2017-01-13 09:04:09 -07:00
w1n2k 44a596b12b Added DISTANCE to command generation 2017-01-10 21:03:09 +03:00
Josh Baker d3164f8bb9 fixed error in command documentation
The COMMANDS keyword was incorrectly documentated as COMMAND.

Thanks to @juanpabloaj for discovering this. closes #117
2017-01-07 09:10:06 -07:00
Josh Baker 34ae007700 1.7.0 2016-12-29 11:54:35 -07:00
Josh Baker bafb1823b3 Metadata for Webhooks
Added the `META name value` keyword to the SETHOOK command.

Allows for adding metadata to a webhook. For example:

    SETHOOK myhook http://endpoint/ META m1 12 META m2 13 NEARBY ...

Would result in notification that contain the "meta" element, which is
represented like:

    "meta":{"m1":"12","m2":"13"}

Thanks for the suggestion @amorskoy

closed #105
2016-12-29 08:50:54 -07:00
Josh Baker 73fd3cf7de Added PDEL command
PDEL key pattern

Removes all objects where the id matches the pattern

Thanks to @GameFreedom for the suggestion. closes #104
2016-12-29 07:53:01 -07:00
Josh Baker dad63f9b1f removed value from EX command 2016-10-03 13:39:55 -07:00
Josh Baker 46072f614f added [NX|XX] to SET, fixes #60 2016-10-03 08:31:13 -07:00
Josh Baker 89cfedeb08 added PDELHOOKS 2016-09-11 19:28:54 -07:00
Josh Baker 5d48c99612 updated SEARCH documentation 2016-09-09 08:43:44 -07:00
Josh Baker 1d427c849f Added BOUNDS command
It's now possible to get the combined minimum bounding rectangle for all
objects in a key by issuing the command "BOUNDS key".
2016-08-19 08:33:58 -07:00
Josh Baker e766dd75ae added EXPIRES, PERSISTS, TTL, and EX keyword 2016-07-15 13:06:11 -07:00
Josh Baker b08c686c64 SEARCH command 2016-07-12 21:11:02 -06:00
Josh Baker 75adea6a9c scan order asc/desc 2016-07-12 13:18:16 -06:00
Josh Baker fbe19564b9 added string type 2016-07-10 13:23:50 -07:00
Josh Baker d0fd48b813 added ROAM keyword to help 2016-05-24 15:58:52 -07:00
Josh Baker 2449fd495d added OUTPUT to commands 2016-04-13 12:28:44 -07:00
Josh Baker 6561fcec30 typo in command docs 2016-04-12 18:47:57 -07:00
Josh Baker 03a3c1642c updated commands 2016-04-02 14:43:46 -07:00
Josh Baker cdc2bbee73 fence detect option 2016-04-01 12:46:39 -07:00
Josh Baker 6e9ae37707 added webhook commands 2016-03-20 08:41:59 -07:00
Josh Baker 8faeceac8e updated command syntax 2016-03-15 18:21:56 -07:00
Josh Baker 857f8cb155 typo 2016-03-13 18:31:59 -07:00
Josh Baker a1abccc6fd updated config summary 2016-03-08 05:32:39 -07:00
Josh Baker 73ea8b8ee4 authentication resolves #3 2016-03-07 17:38:59 -07:00
Josh Baker 4fc58f7f5c first commit 2016-03-04 16:08:16 -07:00