Skip to content

Instantly share code, notes, and snippets.

@karussell
karussell / price.md
Last active March 14, 2024 10:18
hetzner pricing for 256GB RAM servers and beyond
name CPU 256GB-price max GB max-price price/1GB CPU Passmark Benchmark
SB (auction) Xeon® E5-1650 v3 Hexa-Core ~60€ 256 ~60€ 0.23 10413 (single: 2123)
SB (auction) Xeon W-2145 8-Core ~100€ 256 ~100€ 0.39 18057 (single: 2610)
AX161 EPYC™ 7502P 32-Core Zen2 267€ 1024 727€ 0.71-1.04 48995 (single: 1894)
AX162-R EPYC™ 9454P 48-Core Zen4 249€ 1152 663€ 0.58-0.97 96088 (single: 2979)
PX93 Xeon W-2295 18-Core 267€ 512 463€ 0.9 -1.04 31484 (single: 2673)
DX152 2*Xeon SP Silver 10-Core 268€ 768 492€ 0.640-1.07 19256*2
DX153 2*Xeon Silver 4410Y 12-Core 405€ 1024 73
@karussell
karussell / elasticsearch-import-data
Last active October 30, 2023 16:14
ElasticSearch from SQL DB
Why is there no such DataImportHandler thing in ElasticSearch? Uhm, well ... but because:
1. You should really consider your own scripts
(be it jvm based, perl, ruby, php, nodejs/javascript)
to feed ElasticSearch via bulk indexing:
http://www.elasticsearch.org/guide/reference/java-api/bulk.html
2. There are two projects doing it already:
* http://code.google.com/p/sql-to-nosql-importer/
* https://github.com/Aconex/scrutineer (keeps DB in synch with ES or solr!)
// for more than 4K locations or for slow network you need to gzip the body
OkHttpClient client = new OkHttpClient();
client.setConnectTimeout(20, TimeUnit.SECONDS);
client.setReadTimeout(20, TimeUnit.SECONDS);
client.interceptors().add(new GzipRequestInterceptor());
....

For an overview of which tags are used. See this issue for the discussion.

Nodes:

Tag Used Description
barrier Yes depending on the vehicle the tag is used to change access
crossing soon crossing=* and level_crossing=railway is stored in crossing
crossing:markings soon stored in crossing
fords Yes stored in road_environment
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Received: from CIATMB2.CIAT.CGIARAD.ORG ([fe80::3d36:2c21:c794:d6a6]) by
CIATHUB2.CIAT.CGIARAD.ORG ([198.93.225.118]) with mapi id 14.03.0158.001;
Sun, 26 Jan 2014 20:23:41 -0500
From: "Jarvis, Andrew (CIAT-CCAFS)" <redacted>
To: Peter Karich <redacted>
Hi peter,
Apologies for delay getting back to you. Your proposed use is fine, so tak=
@karussell
karussell / index.html
Last active May 2, 2022 00:02
Test UI to show roads from GraphHopper vector tiles endpoint https://github.com/graphhopper/graphhopper/tree/experimental-mvt
<!DOCTYPE html>
<html>
<head>
<title>Leaflet.VectorGrid Points Example</title>
<meta charset="utf-8"/>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="https://unpkg.com/leaflet@1.4.0/dist/leaflet.css"/>
</head>
<body style='margin:0'>
@karussell
karussell / ReadGHFile.java
Last active January 19, 2022 15:05
read header entries of any file from GraphHopper without dependencies
import java.io.RandomAccessFile;
class ReadGHFile {
public static void main(String[] args) throws Exception {
String name = args[0];
RandomAccessFile raFile = new RandomAccessFile(name, "r");
raFile.seek(0);
if (raFile.length() == 0) throw new IllegalArgumentException("empty file " + name);