Serverless maps at 1/700 the cost of Google Maps API
71–80 of 118 posts
Re: Serverless maps at 1/700 the cost of Google Maps API
#72Earlier quoted context omitted.
I don't know about "20 tiles per session" That's like, 1 pan or 1 zoom. It might as well be a static map if the users don't actually interact with it.
I would be that's actually a majority of usage in the wild. Sometimes I'll zoom out if I need more context, but I'm not wandering around most embedded gmaps.
Re: Serverless maps at 1/700 the cost of Google Maps API
#73The real meat of this story: > A web application with 50,000 map loads using the Google Maps API will cost $350 per month. > A similar amount of traffic running through a Protomaps CDN install on Cloudflare, with an average of 20 tiles per session, costs fifty cents in Cloudflare Workers request fees. $350 versus $0.50! Who's going to be the first to build a (maybe Google Maps-compatible?) API on top of this and sell…
They are comparing the price using Cloudflare, which although cheap, has poor performance.
I don't know anything about these services or their pricing. Maybe AWS costs about the same as Cloudflare, but it's cheeky to have inconsistent comparisons like this. Ideally, this post/advert would provide the equivalent AWS price also (or provide Cloudflare performance numbers).
Re: Serverless maps at 1/700 the cost of Google Maps API
#74The real meat of this story: > A web application with 50,000 map loads using the Google Maps API will cost $350 per month. > A similar amount of traffic running through a Protomaps CDN install on Cloudflare, with an average of 20 tiles per session, costs fifty cents in Cloudflare Workers request fees. $350 versus $0.50! Who's going to be the first to build a (maybe Google Maps-compatible?) API on top of this and sell…
> Tested in production at scale: On AWS, response times average 100 ms for cache hits, 200 ms for misses. Cloudflare is significantly slower, but is improving as Cloudflare's R2 offering matures. They are comparing the price using Cloudflare, which although cheap, has poor performance. I don't know anything about these services or their pricing. Maybe AWS costs about the same as Cloudflare, but it's cheeky to have in…
Cloudflare R2 latency is tricky to predict and can be anywhere from a few hundred milliseconds to 1s+ in my experience. This is for cache misses, only, of course; cache hits are comparable to AWS. Cloudflare really has every incentive to improve their product so I expect this to be much more competitive in the near future.
Re: Serverless maps at 1/700 the cost of Google Maps API
#75Earlier quoted context omitted.
I would be that's actually a majority of usage in the wild. Sometimes I'll zoom out if I need more context, but I'm not wandering around most embedded gmaps.
My point was if that's truly the dominant use case then the map should be a static image initially and replaced with tiles lazily.
Re: Serverless maps at 1/700 the cost of Google Maps API
#76Unrelated to the actual product: lack of margin on the sides make it an uncomfortable read on mobile.
Re: Serverless maps at 1/700 the cost of Google Maps API
#77Earlier quoted context omitted.
This might be what you’re looking for: https://protomaps.com/docs/pmtiles Looks like protomaps supports up to zoom level 14 for free: https://app.protomaps.com/downloads/small_map
Thanks, but that's the problem, the data downloads they offer are not zoomed enough. So I want to know how to go closer. This presumes you already have tiles.
Re: Serverless maps at 1/700 the cost of Google Maps API
#78Can any of you suggest a nice tutorial or something for rendering maps for self-hosting at much higher zoom levels? Many of these examples are for larger areas where zoom level 10 is sufficient, but I make hobby maps of mountain bike / hiking trails where the displayed area is only ~10km wide at the most with lots of fine detail. Thus, my maps tend to be shown at zoom levels 12-18, which is much higher than any of th…
The individual software components often have alternative with a similar scope. So if you don't like a choice headwaymaps made, browse around.
The data sources are mostly "unique", i.e. everybody downloads from the pages (Geofabrik, Who's On First, etc), so not much to gain here.
Editing styles has some alternatives, but the OpenSource editors are far away from the quality of the Mapbox editor. Maputnik or editing the 1000+ SLOC JSON by hand are the way to go, imo.
Personally I use GeoFabrik to download OSM extracts → osmconvert to extract the smaller bounding box I am interested in → tilemaker to render vector tiles to individual .pbf files I can serve like it's 1999. The bounding box extract is not necessary, but it's much faster if you need to tweak things in tilemaker. Both tilemaker and osmconvert are packaged for at least Debian out of the box, so setup is easy enough. Rendering a decently sized metro area takes Note that adding icons (sprites) or fonts is extra work that comes on top. And while the tools themselves are great, there's still a lot of gluing/plumbing/fitting things together that you'll need to do. If headwaymaps works for you, it's probably the easiest choice.
Re: Serverless maps at 1/700 the cost of Google Maps API
#79The real meat of this story: > A web application with 50,000 map loads using the Google Maps API will cost $350 per month. > A similar amount of traffic running through a Protomaps CDN install on Cloudflare, with an average of 20 tiles per session, costs fifty cents in Cloudflare Workers request fees. $350 versus $0.50! Who's going to be the first to build a (maybe Google Maps-compatible?) API on top of this and sell…
There would be some irony if a 3rd-party monetize off of Google shoulders a compatible-API to their Map service.
Given that's what they did to Java.
Re: Serverless maps at 1/700 the cost of Google Maps API
#80The real meat of this story: > A web application with 50,000 map loads using the Google Maps API will cost $350 per month. > A similar amount of traffic running through a Protomaps CDN install on Cloudflare, with an average of 20 tiles per session, costs fifty cents in Cloudflare Workers request fees. $350 versus $0.50! Who's going to be the first to build a (maybe Google Maps-compatible?) API on top of this and sell…
> $350 versus $0.50! It's not as impressive as you make it sound. The real value of the Maps API is in 1) routing and 2) local business details. These are both hard for anybody else to provide, so Google prices them accordingly. The price for the tiles is just an extension to the overall pricing.
Not sure if there are ready use alternatives, but at least in theory with OSM you could fully control what is being shown. And what not.