Created
April 7, 2013 09:59
-
-
Save schovi/5329853 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
http delete localhost:9200/cities | |
http post localhost:9200/cities <<< '{ | |
"settings" : { | |
"number_of_shards": 2, | |
"number_of_replicas": 0, | |
"index.refresh_interval": "1s" | |
}, | |
"mappings": { | |
"city": { | |
"properties": { | |
"id": {"type": "integer"}, | |
"name": {"type": "string"}, | |
"location": { | |
"type": "geo_shape", | |
"tree": "quadtree", | |
"precision": "2km" | |
} | |
} | |
} | |
} | |
}' | |
http localhost:9200/cities/_refresh | |
http post localhost:9200/cities/city/508357 <<< '{ | |
"id": "508357", | |
"name": "Kostelní Vydří", | |
"location": { | |
"type": "polygon", | |
"coordinates": [[ | |
[49.12333812908341, 15.39212244016403], | |
[49.12296145088681, 15.392964833034664], | |
[49.12438962471685, 15.394620992758712], | |
[49.12121756728319, 15.399095584293988], | |
[49.119658710604156, 15.40293925023206], | |
[49.118553745930825, 15.403855740333071], | |
[49.11839194109606, 15.404782616252684], | |
[49.116903340980805, 15.406298454124329], | |
[49.11660207369808, 15.406972137920617], | |
[49.115957523206966, 15.406417710904767], | |
[49.11583606801249, 15.406628441808719], | |
[49.11547584765932, 15.406142652167741], | |
[49.11505166658413, 15.406816942722529], | |
[49.11403296161248, 15.406356959586647], | |
[49.11385455105951, 15.407689266445564], | |
[49.11461972859984, 15.407942842379672], | |
[49.1147009267759, 15.41050677949312], | |
[49.11375412706526, 15.413028413689679], | |
[49.11374417890079, 15.413701297080681], | |
[49.113243367930274, 15.416245738031712], | |
[49.11310543559404, 15.4165079955294], | |
[49.11246126255394, 15.416836144943165], | |
[49.1127368819854, 15.417089368696251], | |
[49.11281248526538, 15.417755998944724], | |
[49.11303686507632, 15.41817558477682], | |
[49.11353431956209, 15.417971810665145], | |
[49.11379392144747, 15.418203088928005], | |
[49.11391482024969, 15.418007550364486], | |
[49.11388912451314, 15.418420721680109], | |
[49.11406610330746, 15.417942510078392], | |
[49.11414738567612, 15.418029292492362], | |
[49.114056129015125, 15.418554245711016], | |
[49.11418792027521, 15.418500207495134], | |
[49.114345558750486, 15.419079434078647], | |
[49.11456422079164, 15.419204163599606], | |
[49.11494816347082, 15.418721475077955], | |
[49.11528060186323, 15.41879570930613], | |
[49.115261303043305, 15.418555439098185], | |
[49.11544507559096, 15.418549964848264], | |
[49.115519592876204, 15.418871871816853], | |
[49.11593947693429, 15.41858792253538], | |
[49.11607905645756, 15.418755211724667], | |
[49.116206578197314, 15.418527491898843], | |
[49.11618313575333, 15.41762898036739], | |
[49.11685375397509, 15.418089302659979], | |
[49.1166707264876, 15.41859118536916], | |
[49.117858220944534, 15.419045068123209], | |
[49.11901043907138, 15.419862502535974], | |
[49.11854302703524, 15.421370001601813], | |
[49.11911865941716, 15.421806928835762], | |
[49.119613899840026, 15.421423427179132], | |
[49.12013478346514, 15.421797818613769], | |
[49.12027157744665, 15.421411230951366], | |
[49.12089906728652, 15.421263094244056], | |
[49.12100875135497, 15.421628645605116], | |
[49.120679499408524, 15.421581255035242], | |
[49.120299449365596, 15.421847046768546], | |
[49.12018305555992, 15.421691782069074], | |
[49.11979581528551, 15.422040656278787], | |
[49.119874468668826, 15.422350078896363], | |
[49.119588691403884, 15.422217850187538], | |
[49.119554008725075, 15.422530879802617], | |
[49.119434987351596, 15.422548124919238], | |
[49.119419653477046, 15.422150534640943], | |
[49.11926425696487, 15.42197475631005], | |
[49.11898042110563, 15.42221807594541], | |
[49.11897427848495, 15.421907794842854], | |
[49.118714779487085, 15.421594177234871], | |
[49.11854231900391, 15.421866560953346], | |
[49.118584503920566, 15.422187698742254], | |
[49.1176467311344, 15.423920553026552], | |
[49.11994096201414, 15.425714007465515], | |
[49.1218825976044, 15.426866260228051], | |
[49.119013549230225, 15.428580469292081], | |
[49.11641819513864, 15.431323527797415], | |
[49.11573783605904, 15.431341942989993], | |
[49.114252467431655, 15.430414520549798], | |
[49.11261868724161, 15.430058738082488], | |
[49.11141727485246, 15.434357893183407], | |
[49.11045649554567, 15.441935287368137], | |
[49.109516182671875, 15.446206626543551], | |
[49.10922097849505, 15.446390749664236], | |
[49.10913544392214, 15.445889853368353], | |
[49.10881393723651, 15.445834919834398], | |
[49.10874084214815, 15.44597470351139], | |
[49.108970501013204, 15.446574447566146], | |
[49.10852004047683, 15.446819426393565], | |
[49.1080611006886, 15.446239291158994], | |
[49.107108372255084, 15.446072405476782], | |
[49.10687077399713, 15.446434741166108], | |
[49.10707495744415, 15.4468056103661], | |
[49.10699449542192, 15.447322166695889], | |
[49.10663115025919, 15.44738800154401], | |
[49.106592112822135, 15.447161704990181], | |
[49.10683272027499, 15.446751608481733], | |
[49.106672579134404, 15.446264794133816], | |
[49.1064627222708, 15.446650742621644], | |
[49.10620719224484, 15.4460716366921], | |
[49.10573598744155, 15.44616829224591], | |
[49.1056198823994, 15.446562790672012], | |
[49.10571777006775, 15.44670705814656], | |
[49.10592298156318, 15.446581861304889], | |
[49.10604182245305, 15.447197208172856], | |
[49.106350836163614, 15.446800449342032], | |
[49.1064714136728, 15.446940720274636], | |
[49.106407278360535, 15.447432940442022], | |
[49.10595697831619, 15.447551590331475], | |
[49.10491852009334, 15.447388969630559], | |
[49.104852263964396, 15.447180091507462], | |
[49.105033379443725, 15.446513900808299], | |
[49.104699619285874, 15.446707477725408], | |
[49.10525820855034, 15.444061383944273], | |
[49.10519962851318, 15.443842228530794], | |
[49.10356596092878, 15.442633885420948], | |
[49.10314361150143, 15.442033835496197], | |
[49.10381645272213, 15.435022646021759], | |
[49.10282457382244, 15.434392646199262], | |
[49.102176716356475, 15.434547712431211], | |
[49.100312384188015, 15.437959591301297], | |
[49.09992632845274, 15.434352224859948], | |
[49.09929619464592, 15.435704474995475], | |
[49.09858069129201, 15.434704732672898], | |
[49.099087036421444, 15.43374345360027], | |
[49.09687922196459, 15.432285962031518], | |
[49.098076271238554, 15.4279464680803], | |
[49.09268022971892, 15.425509645036772], | |
[49.093952025176065, 15.424098071905233], | |
[49.09505796799795, 15.422331392973298], | |
[49.096189405439766, 15.419248519681714], | |
[49.09634237927474, 15.418252320038558], | |
[49.096581182659, 15.417717885945715], | |
[49.09764011859121, 15.416333796038227], | |
[49.099158350264396, 15.415008403583057], | |
[49.10140484964048, 15.412018080760392], | |
[49.10252298053049, 15.410987138809705], | |
[49.103370185738825, 15.409809767478476], | |
[49.10493080970263, 15.408449211036945], | |
[49.10655218534176, 15.405447475211307], | |
[49.107556848284, 15.40412250094166], | |
[49.107815425923704, 15.402663918546592], | |
[49.108864648477294, 15.399511627236818], | |
[49.1091935532525, 15.397522180093837], | |
[49.1103362508816, 15.394595026310421], | |
[49.110792070659556, 15.3930209157218], | |
[49.11226223368054, 15.390528254503067], | |
[49.11408750735223, 15.389228983129822], | |
[49.11465896367025, 15.388303247237738], | |
[49.11556755406972, 15.387802649527732], | |
[49.11621666352541, 15.387014407297974], | |
[49.116928651551135, 15.38655203011232], | |
[49.11895107497307, 15.386536432546785], | |
[49.119758175889544, 15.387264421968945], | |
[49.122591435520796, 15.38810362222633], | |
[49.122992094365095, 15.39153263927694], | |
[49.12333812908341, 15.39212244016403] | |
]] | |
} | |
}' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment