Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • 02:45
    duartejc opened #513
  • Dec 09 18:45
    mudit3774 commented #511
  • Dec 08 14:28
    pdrum opened #512
  • Dec 04 18:28
    mudit3774 commented #511
  • Dec 04 18:27
    mudit3774 commented #511
  • Nov 28 17:46

    tidwall on master

    Update changelog (compare)

  • Nov 28 17:43

    tidwall on 1.19.2

    (compare)

  • Nov 28 17:42

    tidwall on master

    1.19.2 (compare)

  • Nov 28 17:13

    tidwall on master

    Fixes a false negative for inte… (compare)

  • Nov 28 13:34
    tidwall commented #511
  • Nov 28 12:57
    tidwall commented #250
  • Nov 28 09:26
    garry-9590 commented #511
  • Nov 28 08:28
    garry-9590 opened #511
  • Nov 26 12:10
    naveenchlsn commented #250
  • Nov 26 12:09
    naveenchlsn commented #250
  • Nov 25 17:56
    tidwall commented #510
  • Nov 22 07:48
    zhangyonguu opened #510
  • Nov 18 22:22

    tidwall on 1.19.1

    (compare)

  • Nov 18 22:22

    tidwall on master

    1.19.1 (compare)

  • Nov 18 18:04

    tidwall on master

    Ensure build passes on test (compare)

Josh Baker
@tidwall
@m1ome 👍 porting the geobuf library sounds like a fun.
Pavel Makarenko
@m1ome
@tidwall i will provide additional .proto i don’t port a geobuf, beacuse they use proto v2 and need’s a lot of addition to support RFC of GeoJSON
Josh Baker
@tidwall
@m1ome will it still be compatible with geobuf?
Pavel Makarenko
@m1ome
@tidwall you wanna keep compatible version to use node.js library?
@tidwall i mean, all can use any .proto file to implement what they want and i can provide node.js/js library
Josh Baker
@tidwall
@m1ome I think it might be nice to keep compatibility with geobuf format. As long as a user can pass the same geobuf blobs to Tile38 as they would to services that utilize the JS version, I'm good.
Pavel Makarenko
@m1ome
@tidwall i can provide a node.js/js library for it :)
Josh Baker
@tidwall
@m1ome Do you mean a node.js client library?
Pavel Makarenko
@m1ome
@tidwall yes
Josh Baker
@tidwall
@m1ome :+1:
Pavel Makarenko
@m1ome
@tidwall i tried .proto file from geobuf (node.js version) and it’s kinda messy
Pavel Makarenko
@m1ome
@tidwall and if we starting to change proto file we loose compatability :(
Josh Baker
@tidwall
@m1ome what do you suggest?
Pavel Makarenko
@m1ome
@tidwall bad thing about “geobuf” is:
JSON -> PROTOBUF -> JSON conversion
it’s useless if you wanna provide speed and compact protocol
i mean i will provide JSON to PROTOBUF conversion, but you can manually do this in your application using .proto file
It’s quite simple
Josh Baker
@tidwall
@m1ome I agree that we shouldn't touch JSON in the processes. It could just go straight from geobuf to the native object format that Tile38 uses today. And vice versa.
Pavel Makarenko
@m1ome
Yeah with a small interface :)
And that’s a main idea
I will prepare JSON Pack/Unpack function also for a external use
Josh Baker
@tidwall
@m1ome I think we're on the same page. :+1:
Pavel Makarenko
@m1ome
@tidwall wonderful :)
Josh Baker
@tidwall
Tile38 2.0 pre-alpha benchmarks tidwall/tile38#171
Agustin Bacigalup
@redraw
Hi! hey. promising project. I've seen latest Redis versions support spatial queries, however, concerning tile38, is it like a modified Redis with extended geo features written in Go? Is it built on top of Redis?
Josh Baker
@tidwall
Hi Agustin. It's not built on Redis. Totally custom code base. It only shares the same network protocol making it easy to use most popular Redis clients.
Agustin Bacigalup
@redraw
Great
Justin Lowery
@umpc
Hi @tidwall. I hope you’re doing well. How is Tile38 version 2 coming along?
Josh Baker
@tidwall
Hi @umpc. All is well and I'm sorry 2.0 is taking so long. The progress is slow at the moment with most of the effort going towards data structures that support new spheroid calculations. There's a few low hanging features that will improve performance which I may introduce into the codebase prior to 2.0.
Justin Lowery
@umpc
@tidwall I’m patient for it. It seems to be worth the wait!
I understand deciding on the scope and experimenting first before going public with it.
Josh Baker
@tidwall
@umpc Thanks for your patience. I do think it'll worth the wait. :smile:
Josh Baker
@tidwall
@/all Tile38 v1.9.1 is now available!
Justin Lowery
@umpc

@tidwall Would you happen to know if there is a faster way to check if a point is within an inserted multipolygon than running (*collection).Intersects and passing in the point?

The question is probably wishful thinking, though I’m trying to find the quickest way to group some points by country/state to sort with.

I am currently using https://github.com/busrapidohq/world-countries-boundaries/tree/master/geojson/10m and am getting back under 150 points per second when running the intersect queries in parallel (using the collection package)

I probably just need to lower the resolution, though this seemed slow to the point that I’m doing something inefficiently given how the intersects method works and I figured that I would ask.

Josh Baker
@tidwall
@umpc It's possible that the slowness is due to the complexity of the multipolygon. Testing a single point on a mutlipolygon will perform a point in polygon operation over each polygon until it gets a hit. For a few simple rectangles this will be fast, but for country boundaries, not so much.
Justin Lowery
@umpc
okay. thank you
Josh Baker
@tidwall
Perhaps a better way is to group the points in a reverse lookup like https://gist.github.com/tidwall/b99f633bb567c0fb679f1009347691b0
Justin Lowery
@umpc
that is true, thanks. i am going to reduce memory to just what i am proccessing and will try something like that
Josh Baker
@tidwall

@/all I just pushed some big changes to the master branch that affect concurrency and performance, in a good way.

Before:

PING: 106945.43 requests per second
SET (point): 36893.82 requests per second
SET (rect): 32290.12 requests per second
SET (string): 40745.98 requests per second
GET (point): 61959.93 requests per second
GET (rect): 49814.28 requests per second
GET (string): 70695.00 requests per second
SEARCH (nearby 1km): 28368.35 requests per second
SEARCH (nearby 10km): 19525.70 requests per second
SEARCH (nearby 100km): 2870.19 requests per second

After:

PING: 109488.29 requests per second
SET (point): 39637.93 requests per second
SET (rect): 35838.09 requests per second
SET (string): 44281.98 requests per second
GET (point): 86496.45 requests per second
GET (rect): 80139.81 requests per second
GET (string): 91467.89 requests per second
SEARCH (nearby 1km): 71347.51 requests per second
SEARCH (nearby 10km): 56508.02 requests per second
SEARCH (nearby 100km): 9779.66 requests per second

Testing and feedback is appreciated. Thanks!

Catalin Tudorache
@charlietango592
Hey guys! I have a geofencing related question. I have multiple active static geofences, created with NEARBY and I want to get some info about the triggered geofence when any of them get triggered. All I get when a geofence is triggered is info about the point which triggers the geofence. Has anyone faced the same situation? Thanks
Josh Baker
@tidwall

@charlietango592 Hi Catalin and welcome! Only geofences created with a SETHOOK can provide additional information with each event such as the name of the hook. A geofence that is created without a SETHOOK, just a plain static NEARBY ... FENCE events do not provide any extra information about the origin of the geofence.

Perhaps as a workaround, since you can only have one static geofence per client connection perhaps you can create a unique name for that client/geofence at the application level prior to issuing the NEARBY ... FENCE command to the Tile38 server. Then when consuming the geofence events, modify the each event's JSON payload and add the client/geofence identifier before passing it on.

Though I can see how having an optional tag/identifier for static geofence would be very helpful.
Catalin Tudorache
@charlietango592
Hi Josh!
Thanks for your reply! Actually I'm using the node API and I create multiple geofences
Yup, a tag (or adding custom fields like one can add for points) would be very helpful
Tang
@Toto932700_twitter
Hello guys, i got a question about the match option, can we exclude some pattern or ids ?
SET toto 123abc POINT 1.2 1.2
SET toto 456dce POINT 1.2 1.2
NEARBY toto POINT 1.2 1.2 123
{"ok":true,"objects":[{"id":"123abc","object":{"type":"Point","coordinates":[1.2,1.2]}},{"id":"456dce","object":{"type":"Point","coordinates":[1.2,1.2]}}],"count":2,"cursor":0,"elapsed":"148.979µs"}
a command to do a query that don't match the id 123abc ?
I try this but it does not work
NEARBY toto match !(123abc) POINT 1.2 1.2 123
{"ok":true,"objects":[],"count":0,"cursor":0,"elapsed":"44.404µs"}
Sivatharan
@sivatharan
Hi
can you anyone share me the geofence notify nodejs example for multiple region