137 Commits

Author SHA1 Message Date
Ivan Vazhenin
4edac226fc fix 2024-02-23 18:18:57 +03:00
Suhas Deshpande
d6bd7c5a66 add tests around mbTile SQKM calculation 2020-07-09 17:24:38 -07:00
Suhas
df57126f97 collect stats for tif files (#106)
* collect stats for mbtiles

related to https://github.com/mapbox/tilesets-api-team/issues/259
2020-07-08 09:23:05 -07:00
jingsam
0ecc36fc47 ensure scheme in metadata table always be tms 2019-05-09 18:02:38 +08:00
Hannes Junnila
7fd30ff9ff Override scheme from MBtiles metadata 2019-05-09 16:00:14 +08:00
Hannes Junnila
eb07aa81d6 Use 'xyz' as scheme in metadata
As getTile swaps the z-coordinate from tms to xyz
2019-05-09 16:00:14 +08:00
jingsam
681f4cca31 fix: fix path.join 2019-04-15 15:37:02 +08:00
jingsam
4ebeb21911 Add path.join so that pkg could auto detect assets (#80)
* Add path.join so that pkg could auto detect assets

* Delete require utils
2018-08-06 11:16:09 -07:00
jingsam
9e9a1ebbb9 Support sqlite mode flags (#73)
* Update mbtiles.js

* some reading

* remove seemingly unused/dead code

* core api functionality

* test note

* grids

* remove index test

* add tilelive example

* vNext

* follow sqlite3 URI filenames

* add mode test

* add mode test

* fix ci

* fix ci

* Update mbtiles.js

* follow sqlite3 URI filenames

* add mode test

* add mode test

* fix ci

* fix ci

* Update readme on mode flags
2018-03-27 11:23:48 -04:00
Dane Springmeyer
7ba7985794 remove seemingly unused/dead code 2017-08-22 17:48:05 -07:00
Kai
021331c4be updated to namespaced modules 2017-02-02 13:43:28 -08:00
Andrew Pendleton
405d987716 Ditch inflateSync in favor of plain inflate; test iteration order; add d3-queue dep 2016-04-14 18:49:34 -04:00
Andrew Pendleton
4474634452 Improve error handling for geocoderDataIterator 2016-04-14 13:32:38 -04:00
Andrew Pendleton
b6ef79d7dc I give up: setImmediate for every callback 2016-04-04 13:16:52 -04:00
Andrew Pendleton
b37655577f Increase the frequency of calling setImmediate in the geocoderDataIterator function 2016-04-04 10:49:34 -04:00
Andrew Pendleton
11b6381c4f Another attempt at avoiding overflowing the callstack on geocoderDataIterator: every tenth time we call a callback, call it via setImmediate to reset the stack 2016-04-01 01:16:01 -04:00
Andrew Pendleton
3967adcb4a Avoid callstack loop by making sure only one geocoder data iterator buffer-flush operation is happening at once 2016-03-30 01:10:20 -04:00
Andrew Pendleton
aac15a8f81 Ditch geocoderDataForEach (it's a memory hog) and instead go with an async iterator method with an internal buffer, implemented around sqlite limits, to give caller more control over reads 2016-03-17 17:55:34 -04:00
Andrew Pendleton
3c7f5c8462 And infrastructure for iterating over geocoder data 2016-03-05 17:12:17 -05:00
Young Hahn
86ba2021fd Handle missing table errors gracefully in getGeocoderData 2015-10-29 15:39:04 -04:00
Ryan Clark
5e8f1375f5 error handling in async loop 2015-01-05 10:32:10 -05:00
Will White
9ce7d7381e Detect null or non-buffer tile. 2014-11-18 12:55:58 -05:00
Tom Lee
9e0c85b03c fix error when mbtiles path contains a space
root cause is that qs.parse() unescapes URL components while url.parse() does not.
https://groups.google.com/forum/#!topic/nodejs/8P7GZqBw0xg
http://nodejs.org/api/querystring.html#querystring_querystring_unescape
2014-11-12 18:58:27 -05:00
Young Hahn
59a6360035 Add readable ZXYStream and createZXYStream method. Refs #42. 2014-10-29 17:11:59 -04:00
Young Hahn
e44cd8b3ef Clear caches once -- at the beginning of the commit -- so more writes can be queued behind it. 2014-09-30 11:54:24 -04:00
Young Hahn
a375ae1df0 Add locking to mbtiles commits -- sqlite3 doesn't allow concurrent transactions. 2014-09-30 11:52:04 -04:00
Young Hahn
99e1f03739 Update to tiletype 0.1.x 2014-08-20 07:45:15 -04:00
Young Hahn
45ea450d01 Use tiletype for detecting content-type headers. 2014-05-18 11:50:18 -04:00
Young Hahn
0ed1500ac1 Robustify geocoder indexing of legacy MBTiles sources. 2014-01-21 23:55:30 -05:00
Young Hahn
f324b4d0b5 Move score to underscore'd property. 2013-12-13 04:16:44 -05:00
Young Hahn
da8cc54128 Update getIndexableDocs for geojson handling in carmen. 2013-12-13 03:31:50 -05:00
Young Hahn
51c598ddac Add support for geocoder api (carmen dev). 2013-12-05 15:00:17 -05:00
Young Hahn
9868c9aca4 Load schema at require time and use transactions. 2013-12-05 14:57:53 -05:00
Young Hahn
a0f5c5ee6b Refactor writing into external write API. 2013-07-18 09:09:14 -04:00
Young Hahn
c8c1a5cb72 Match center interpolation logic of previous code. 2013-07-12 13:53:31 -04:00
Young Hahn
9277a98b5e Fix bad join. 2013-07-12 13:39:14 -04:00
Young Hahn
fe2caf155f Properly handle arrays as candidates for json key. 2013-07-12 13:22:33 -04:00
Young Hahn
46f0b33bc8 Add support for nested json metadata. 2013-07-12 05:41:31 -04:00
Young Hahn
f6ff8735b2 Style cleanup. 2013-07-12 05:29:03 -04:00
Young Hahn
906d6a444d Remove Step, underscore dependencies from main module. 2013-07-12 05:25:03 -04:00
Young Hahn
4cf1dcc173 Switch tests to mocha. 2013-07-12 04:22:00 -04:00
Young Hahn
7320870ff3 Fix early initialization of _schema attribute. 2012-11-07 12:56:21 -05:00
Will White
342f582c21 Be less strict when reading metadata.
If the metadata table or the requested field is
missing return null and allow the caller handle it.
2012-08-16 09:29:32 -04:00
Young Hahn
c8e817517c Merge branch 'nodupe' 2012-04-30 18:43:19 -04:00
Young Hahn
ff5b8f7a9b Run clearCaches synchronously to prevent _commit from erroring out when called prior to startWriting completing. 2012-04-30 13:06:46 -04:00
Young Hahn
3cc112ce6c Remove putDuplicate*. 2012-04-30 02:11:13 -04:00
Young Hahn
84c5fba64f Cleanup putTile/Grid and ensure zlib.deflate has completed before callback in putGrid. 2012-04-30 02:09:47 -04:00
Dane Springmeyer
f4dd13bcb3 add putDuplicateGrid 2012-04-29 13:34:37 -04:00
Dane Springmeyer
3507ac4a07 ensure keys are strings before inserting into sqlite - closes #20 2012-04-20 14:40:17 -07:00
Young Hahn
c6c1a3f20e try/catch around JSON parse in #getGrid. 2012-04-04 23:34:07 -04:00