kopia lustrzana https://github.com/onthegomap/planetiler
Porównaj commity
11 Commity
87353886f4
...
af1852217c
Autor | SHA1 | Data |
---|---|---|
Michael Barry | af1852217c | |
dependabot[bot] | 32f941f1b1 | |
dependabot[bot] | ef6fc85691 | |
Michael Barry | f69882addb | |
dependabot[bot] | 6c41c388f4 | |
dependabot[bot] | 689abb5ad7 | |
dependabot[bot] | da9d03c85d | |
dependabot[bot] | 1871e230ac | |
Mike Barry | 48c4f60ad8 | |
Mike Barry | a33f3b8327 | |
Mike Barry | b38b8b37a1 |
|
@ -30,7 +30,7 @@
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
<artifactId>maven-assembly-plugin</artifactId>
|
<artifactId>maven-assembly-plugin</artifactId>
|
||||||
<version>3.6.0</version>
|
<version>3.7.1</version>
|
||||||
<!-- for with-deps assembly descriptor -->
|
<!-- for with-deps assembly descriptor -->
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<dependency>
|
<dependency>
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<geotools.version>30.1</geotools.version>
|
<geotools.version>31.0</geotools.version>
|
||||||
<log4j.version>2.23.1</log4j.version>
|
<log4j.version>2.23.1</log4j.version>
|
||||||
<prometheus.version>0.16.0</prometheus.version>
|
<prometheus.version>0.16.0</prometheus.version>
|
||||||
<protobuf.version>3.25.3</protobuf.version>
|
<protobuf.version>3.25.3</protobuf.version>
|
||||||
|
|
|
@ -6,6 +6,8 @@ import com.onthegomap.planetiler.geo.GeoUtils;
|
||||||
import com.onthegomap.planetiler.geo.GeometryException;
|
import com.onthegomap.planetiler.geo.GeometryException;
|
||||||
import com.onthegomap.planetiler.geo.GeometryType;
|
import com.onthegomap.planetiler.geo.GeometryType;
|
||||||
import com.onthegomap.planetiler.reader.SourceFeature;
|
import com.onthegomap.planetiler.reader.SourceFeature;
|
||||||
|
import com.onthegomap.planetiler.reader.osm.OsmElement;
|
||||||
|
import com.onthegomap.planetiler.reader.osm.OsmSourceFeature;
|
||||||
import com.onthegomap.planetiler.render.FeatureRenderer;
|
import com.onthegomap.planetiler.render.FeatureRenderer;
|
||||||
import com.onthegomap.planetiler.stats.Stats;
|
import com.onthegomap.planetiler.stats.Stats;
|
||||||
import com.onthegomap.planetiler.util.CacheByZoom;
|
import com.onthegomap.planetiler.util.CacheByZoom;
|
||||||
|
@ -59,7 +61,7 @@ public class FeatureCollector implements Iterable<FeatureCollector.Feature> {
|
||||||
* @return a feature that can be configured further.
|
* @return a feature that can be configured further.
|
||||||
*/
|
*/
|
||||||
public Feature geometry(String layer, Geometry geometry) {
|
public Feature geometry(String layer, Geometry geometry) {
|
||||||
Feature feature = new Feature(layer, geometry, source.id());
|
Feature feature = new Feature(layer, geometry, source);
|
||||||
output.add(feature);
|
output.add(feature);
|
||||||
return feature;
|
return feature;
|
||||||
}
|
}
|
||||||
|
@ -81,7 +83,7 @@ public class FeatureCollector implements Iterable<FeatureCollector.Feature> {
|
||||||
return geometry(layer, source.worldGeometry());
|
return geometry(layer, source.worldGeometry());
|
||||||
} catch (GeometryException e) {
|
} catch (GeometryException e) {
|
||||||
e.log(stats, "feature_point", "Error getting point geometry for " + source.id());
|
e.log(stats, "feature_point", "Error getting point geometry for " + source.id());
|
||||||
return new Feature(layer, EMPTY_GEOM, source.id());
|
return new Feature(layer, EMPTY_GEOM, source);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -101,7 +103,7 @@ public class FeatureCollector implements Iterable<FeatureCollector.Feature> {
|
||||||
return geometry(layer, source.line());
|
return geometry(layer, source.line());
|
||||||
} catch (GeometryException e) {
|
} catch (GeometryException e) {
|
||||||
e.log(stats, "feature_line", "Error constructing line for " + source.id());
|
e.log(stats, "feature_line", "Error constructing line for " + source.id());
|
||||||
return new Feature(layer, EMPTY_GEOM, source.id());
|
return new Feature(layer, EMPTY_GEOM, source);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -121,7 +123,7 @@ public class FeatureCollector implements Iterable<FeatureCollector.Feature> {
|
||||||
return geometry(layer, source.polygon());
|
return geometry(layer, source.polygon());
|
||||||
} catch (GeometryException e) {
|
} catch (GeometryException e) {
|
||||||
e.log(stats, "feature_polygon", "Error constructing polygon for " + source.id());
|
e.log(stats, "feature_polygon", "Error constructing polygon for " + source.id());
|
||||||
return new Feature(layer, EMPTY_GEOM, source.id());
|
return new Feature(layer, EMPTY_GEOM, source);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -136,7 +138,7 @@ public class FeatureCollector implements Iterable<FeatureCollector.Feature> {
|
||||||
return geometry(layer, source.centroid());
|
return geometry(layer, source.centroid());
|
||||||
} catch (GeometryException e) {
|
} catch (GeometryException e) {
|
||||||
e.log(stats, "feature_centroid", "Error getting centroid for " + source.id());
|
e.log(stats, "feature_centroid", "Error getting centroid for " + source.id());
|
||||||
return new Feature(layer, EMPTY_GEOM, source.id());
|
return new Feature(layer, EMPTY_GEOM, source);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -153,7 +155,7 @@ public class FeatureCollector implements Iterable<FeatureCollector.Feature> {
|
||||||
return geometry(layer, source.centroidIfConvex());
|
return geometry(layer, source.centroidIfConvex());
|
||||||
} catch (GeometryException e) {
|
} catch (GeometryException e) {
|
||||||
e.log(stats, "feature_centroid_if_convex", "Error constructing centroid if convex for " + source.id());
|
e.log(stats, "feature_centroid_if_convex", "Error constructing centroid if convex for " + source.id());
|
||||||
return new Feature(layer, EMPTY_GEOM, source.id());
|
return new Feature(layer, EMPTY_GEOM, source);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -169,7 +171,7 @@ public class FeatureCollector implements Iterable<FeatureCollector.Feature> {
|
||||||
return geometry(layer, source.pointOnSurface());
|
return geometry(layer, source.pointOnSurface());
|
||||||
} catch (GeometryException e) {
|
} catch (GeometryException e) {
|
||||||
e.log(stats, "feature_point_on_surface", "Error constructing point on surface for " + source.id());
|
e.log(stats, "feature_point_on_surface", "Error constructing point on surface for " + source.id());
|
||||||
return new Feature(layer, EMPTY_GEOM, source.id());
|
return new Feature(layer, EMPTY_GEOM, source);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -191,7 +193,7 @@ public class FeatureCollector implements Iterable<FeatureCollector.Feature> {
|
||||||
return geometry(layer, source.innermostPoint(tolerance));
|
return geometry(layer, source.innermostPoint(tolerance));
|
||||||
} catch (GeometryException e) {
|
} catch (GeometryException e) {
|
||||||
e.log(stats, "feature_innermost_point", "Error constructing innermost point for " + source.id());
|
e.log(stats, "feature_innermost_point", "Error constructing innermost point for " + source.id());
|
||||||
return new Feature(layer, EMPTY_GEOM, source.id());
|
return new Feature(layer, EMPTY_GEOM, source);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -275,11 +277,21 @@ public class FeatureCollector implements Iterable<FeatureCollector.Feature> {
|
||||||
|
|
||||||
private String numPointsAttr = null;
|
private String numPointsAttr = null;
|
||||||
|
|
||||||
private Feature(String layer, Geometry geom, long id) {
|
private Feature(String layer, Geometry geom, SourceFeature source) {
|
||||||
this.layer = layer;
|
this.layer = layer;
|
||||||
this.geom = geom;
|
this.geom = geom;
|
||||||
this.geometryType = GeometryType.typeOf(geom);
|
this.geometryType = GeometryType.typeOf(geom);
|
||||||
this.id = id;
|
if (source instanceof OsmSourceFeature osmSourceFeature) {
|
||||||
|
long osmId = osmSourceFeature.originalElement().id();
|
||||||
|
this.id = switch (osmSourceFeature.originalElement()) {
|
||||||
|
case OsmElement.Node node -> node.id() * 3;
|
||||||
|
case OsmElement.Way way -> way.id() * 3 + 1;
|
||||||
|
case OsmElement.Relation relation -> relation.id() * 3 + 2;
|
||||||
|
default -> osmId;
|
||||||
|
};
|
||||||
|
} else {
|
||||||
|
this.id = source.id();
|
||||||
|
}
|
||||||
if (geometryType == GeometryType.POINT) {
|
if (geometryType == GeometryType.POINT) {
|
||||||
minPixelSizeAtMaxZoom = 0;
|
minPixelSizeAtMaxZoom = 0;
|
||||||
defaultMinPixelSize = 0;
|
defaultMinPixelSize = 0;
|
||||||
|
|
|
@ -266,6 +266,7 @@ public class TileArchiveWriter {
|
||||||
boolean lastIsFill = false;
|
boolean lastIsFill = false;
|
||||||
List<TileSizeStats.LayerStats> lastLayerStats = null;
|
List<TileSizeStats.LayerStats> lastLayerStats = null;
|
||||||
boolean skipFilled = config.skipFilledTiles();
|
boolean skipFilled = config.skipFilledTiles();
|
||||||
|
var layerStatsSerializer = TileSizeStats.newThreadLocalSerializer();
|
||||||
|
|
||||||
var tileStatsUpdater = tileStats.threadLocalUpdater();
|
var tileStatsUpdater = tileStats.threadLocalUpdater();
|
||||||
var layerAttrStatsUpdater = layerAttrStats.handlerForThread();
|
var layerAttrStatsUpdater = layerAttrStats.handlerForThread();
|
||||||
|
@ -320,7 +321,7 @@ public class TileArchiveWriter {
|
||||||
if ((!skipFilled || !lastIsFill) && bytes != null) {
|
if ((!skipFilled || !lastIsFill) && bytes != null) {
|
||||||
tileStatsUpdater.recordTile(tileFeatures.tileCoord(), bytes.length, layerStats);
|
tileStatsUpdater.recordTile(tileFeatures.tileCoord(), bytes.length, layerStats);
|
||||||
List<String> layerStatsRows = config.outputLayerStats() ?
|
List<String> layerStatsRows = config.outputLayerStats() ?
|
||||||
TileSizeStats.formatOutputRows(tileFeatures.tileCoord(), bytes.length, layerStats) :
|
layerStatsSerializer.formatOutputRows(tileFeatures.tileCoord(), bytes.length, layerStats) :
|
||||||
List.of();
|
List.of();
|
||||||
result.add(
|
result.add(
|
||||||
new TileEncodingResult(
|
new TileEncodingResult(
|
||||||
|
|
|
@ -38,7 +38,7 @@ import vector_tile.VectorTileProto;
|
||||||
* Utilities for extracting tile and layer size summaries from encoded vector tiles.
|
* Utilities for extracting tile and layer size summaries from encoded vector tiles.
|
||||||
* <p>
|
* <p>
|
||||||
* {@link #computeTileStats(VectorTileProto.Tile)} extracts statistics about each layer in a tile and
|
* {@link #computeTileStats(VectorTileProto.Tile)} extracts statistics about each layer in a tile and
|
||||||
* {@link #formatOutputRows(TileCoord, int, List)} formats them as row of a TSV file to write.
|
* {@link TsvSerializer} formats them as row of a TSV file to write.
|
||||||
* <p>
|
* <p>
|
||||||
* To generate a tsv.gz file with stats for each tile, you can add {@code --output-layerstats} option when generating an
|
* To generate a tsv.gz file with stats for each tile, you can add {@code --output-layerstats} option when generating an
|
||||||
* archive, or run the following an existing archive:
|
* archive, or run the following an existing archive:
|
||||||
|
@ -52,13 +52,11 @@ import vector_tile.VectorTileProto;
|
||||||
public class TileSizeStats {
|
public class TileSizeStats {
|
||||||
|
|
||||||
private static final int BATCH_SIZE = 1_000;
|
private static final int BATCH_SIZE = 1_000;
|
||||||
private static final CsvMapper MAPPER = new CsvMapper();
|
private static final CsvSchema SCHEMA = new CsvMapper()
|
||||||
private static final CsvSchema SCHEMA = MAPPER
|
|
||||||
.schemaFor(OutputRow.class)
|
.schemaFor(OutputRow.class)
|
||||||
.withoutHeader()
|
.withoutHeader()
|
||||||
.withColumnSeparator('\t')
|
.withColumnSeparator('\t')
|
||||||
.withLineSeparator("\n");
|
.withLineSeparator("\n");
|
||||||
private static final ObjectWriter WRITER = MAPPER.writer(SCHEMA);
|
|
||||||
|
|
||||||
/** Returns the default path that a layerstats file should go relative to an existing archive. */
|
/** Returns the default path that a layerstats file should go relative to an existing archive. */
|
||||||
public static Path getDefaultLayerstatsPath(Path archive) {
|
public static Path getDefaultLayerstatsPath(Path archive) {
|
||||||
|
@ -120,6 +118,7 @@ public class TileSizeStats {
|
||||||
List<LayerStats> layerStats = null;
|
List<LayerStats> layerStats = null;
|
||||||
|
|
||||||
var updater = tileStats.threadLocalUpdater();
|
var updater = tileStats.threadLocalUpdater();
|
||||||
|
var layerStatsSerializer = TileSizeStats.newThreadLocalSerializer();
|
||||||
for (var batch : prev) {
|
for (var batch : prev) {
|
||||||
List<String> lines = new ArrayList<>(batch.tiles.size());
|
List<String> lines = new ArrayList<>(batch.tiles.size());
|
||||||
for (var tile : batch.tiles) {
|
for (var tile : batch.tiles) {
|
||||||
|
@ -130,7 +129,7 @@ public class TileSizeStats {
|
||||||
layerStats = computeTileStats(decoded);
|
layerStats = computeTileStats(decoded);
|
||||||
}
|
}
|
||||||
updater.recordTile(tile.coord(), zipped.length, layerStats);
|
updater.recordTile(tile.coord(), zipped.length, layerStats);
|
||||||
lines.addAll(TileSizeStats.formatOutputRows(tile.coord(), zipped.length, layerStats));
|
lines.addAll(layerStatsSerializer.formatOutputRows(tile.coord(), zipped.length, layerStats));
|
||||||
}
|
}
|
||||||
batch.stats.complete(lines);
|
batch.stats.complete(lines);
|
||||||
}
|
}
|
||||||
|
@ -161,28 +160,32 @@ public class TileSizeStats {
|
||||||
stats.printSummary();
|
stats.printSummary();
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Returns the TSV rows to output for all the layers in a tile. */
|
/** Returns a {@link TsvSerializer} that can be used by a single thread to convert to CSV rows. */
|
||||||
public static List<String> formatOutputRows(TileCoord tileCoord, int archivedBytes, List<LayerStats> layerStats)
|
public static TsvSerializer newThreadLocalSerializer() {
|
||||||
throws IOException {
|
// CsvMapper is not entirely thread safe, and can end up with a BufferRecycler memory leak when writeValueAsString
|
||||||
int hilbert = tileCoord.hilbertEncoded();
|
// is called billions of times from multiple threads, so we generate a new instance per serializing thread
|
||||||
List<String> result = new ArrayList<>(layerStats.size());
|
ObjectWriter writer = new CsvMapper().writer(SCHEMA);
|
||||||
for (var layer : layerStats) {
|
return (tileCoord, archivedBytes, layerStats) -> {
|
||||||
result.add(lineToString(new OutputRow(
|
int hilbert = tileCoord.hilbertEncoded();
|
||||||
tileCoord.z(),
|
List<String> result = new ArrayList<>(layerStats.size());
|
||||||
tileCoord.x(),
|
for (var layer : layerStats) {
|
||||||
tileCoord.y(),
|
result.add(writer.writeValueAsString(new OutputRow(
|
||||||
hilbert,
|
tileCoord.z(),
|
||||||
archivedBytes,
|
tileCoord.x(),
|
||||||
layer.layer,
|
tileCoord.y(),
|
||||||
layer.layerBytes,
|
hilbert,
|
||||||
layer.layerFeatures,
|
archivedBytes,
|
||||||
layer.layerGeometries,
|
layer.layer,
|
||||||
layer.layerAttrBytes,
|
layer.layerBytes,
|
||||||
layer.layerAttrKeys,
|
layer.layerFeatures,
|
||||||
layer.layerAttrValues
|
layer.layerGeometries,
|
||||||
)));
|
layer.layerAttrBytes,
|
||||||
}
|
layer.layerAttrKeys,
|
||||||
return result;
|
layer.layerAttrValues
|
||||||
|
)));
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -195,11 +198,6 @@ public class TileSizeStats {
|
||||||
StandardOpenOption.WRITE, StandardOpenOption.TRUNCATE_EXISTING, StandardOpenOption.CREATE))));
|
StandardOpenOption.WRITE, StandardOpenOption.TRUNCATE_EXISTING, StandardOpenOption.CREATE))));
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Returns {@code output} encoded as a TSV row string. */
|
|
||||||
public static String lineToString(OutputRow output) throws IOException {
|
|
||||||
return WRITER.writeValueAsString(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
/** Returns the header row for the output TSV file. */
|
/** Returns the header row for the output TSV file. */
|
||||||
public static String headerRow() {
|
public static String headerRow() {
|
||||||
return String.join(
|
return String.join(
|
||||||
|
@ -240,6 +238,14 @@ public class TileSizeStats {
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@FunctionalInterface
|
||||||
|
public interface TsvSerializer {
|
||||||
|
|
||||||
|
/** Returns the TSV rows to output for all the layers in a tile. */
|
||||||
|
List<String> formatOutputRows(TileCoord tileCoord, int archivedBytes, List<LayerStats> layerStats)
|
||||||
|
throws IOException;
|
||||||
|
}
|
||||||
|
|
||||||
/** Model for the data contained in each row in the TSV. */
|
/** Model for the data contained in each row in the TSV. */
|
||||||
@JsonPropertyOrder({
|
@JsonPropertyOrder({
|
||||||
"z",
|
"z",
|
||||||
|
|
|
@ -875,7 +875,7 @@ class PlanetilerTests {
|
||||||
feature(newPoint(128, 128), Map.of(
|
feature(newPoint(128, 128), Map.of(
|
||||||
"attr", "value",
|
"attr", "value",
|
||||||
"name", "name value"
|
"name", "name value"
|
||||||
))
|
)).withId(3)
|
||||||
)
|
)
|
||||||
), results.tiles);
|
), results.tiles);
|
||||||
}
|
}
|
||||||
|
@ -964,7 +964,7 @@ class PlanetilerTests {
|
||||||
feature(newLineString(128, 128, 192, 192), Map.of(
|
feature(newLineString(128, 128, 192, 192), Map.of(
|
||||||
"attr", "value",
|
"attr", "value",
|
||||||
"name", "name value"
|
"name", "name value"
|
||||||
))
|
)).withId(3 * 3 + 1)
|
||||||
)
|
)
|
||||||
), results.tiles);
|
), results.tiles);
|
||||||
}
|
}
|
||||||
|
@ -1089,7 +1089,7 @@ class PlanetilerTests {
|
||||||
"attr", "value",
|
"attr", "value",
|
||||||
"name", "name value",
|
"name", "name value",
|
||||||
"relname", "rel name"
|
"relname", "rel name"
|
||||||
))
|
)).withId(17 * 3 + 2)
|
||||||
)
|
)
|
||||||
), results.tiles);
|
), results.tiles);
|
||||||
}
|
}
|
||||||
|
|
|
@ -279,7 +279,9 @@ public class TestUtils {
|
||||||
case UNKNOWN -> throw new IllegalArgumentException("cannot decompress \"UNKNOWN\"");
|
case UNKNOWN -> throw new IllegalArgumentException("cannot decompress \"UNKNOWN\"");
|
||||||
};
|
};
|
||||||
var decoded = VectorTile.decode(bytes).stream()
|
var decoded = VectorTile.decode(bytes).stream()
|
||||||
.map(feature -> feature(decodeSilently(feature.geometry()), feature.layer(), feature.attrs())).toList();
|
.map(
|
||||||
|
feature -> feature(decodeSilently(feature.geometry()), feature.layer(), feature.attrs()).withId(feature.id()))
|
||||||
|
.toList();
|
||||||
tiles.put(tile.coord(), decoded);
|
tiles.put(tile.coord(), decoded);
|
||||||
}
|
}
|
||||||
return tiles;
|
return tiles;
|
||||||
|
@ -467,12 +469,21 @@ public class TestUtils {
|
||||||
public record ComparableFeature(
|
public record ComparableFeature(
|
||||||
GeometryComparision geometry,
|
GeometryComparision geometry,
|
||||||
String layer,
|
String layer,
|
||||||
Map<String, Object> attrs
|
Map<String, Object> attrs,
|
||||||
|
Long id
|
||||||
) {
|
) {
|
||||||
|
ComparableFeature(
|
||||||
|
GeometryComparision geometry,
|
||||||
|
String layer,
|
||||||
|
Map<String, Object> attrs
|
||||||
|
) {
|
||||||
|
this(geometry, layer, attrs, null);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean equals(Object o) {
|
public boolean equals(Object o) {
|
||||||
return o == this || (o instanceof ComparableFeature other &&
|
return o == this || (o instanceof ComparableFeature other &&
|
||||||
|
(id == null || other.id == null || id.equals(other.id)) &&
|
||||||
geometry.equals(other.geometry) &&
|
geometry.equals(other.geometry) &&
|
||||||
attrs.equals(other.attrs) &&
|
attrs.equals(other.attrs) &&
|
||||||
(layer == null || other.layer == null || Objects.equals(layer, other.layer)));
|
(layer == null || other.layer == null || Objects.equals(layer, other.layer)));
|
||||||
|
@ -484,6 +495,10 @@ public class TestUtils {
|
||||||
result = 31 * result + attrs.hashCode();
|
result = 31 * result + attrs.hashCode();
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ComparableFeature withId(long id) {
|
||||||
|
return new ComparableFeature(geometry, layer, attrs, id);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static ComparableFeature feature(Geometry geom, String layer, Map<String, Object> attrs) {
|
public static ComparableFeature feature(Geometry geom, String layer, Map<String, Object> attrs) {
|
||||||
|
|
|
@ -37,7 +37,7 @@ class TileSizeStatsTest {
|
||||||
assertEquals(2, entry1.layerAttrKeys());
|
assertEquals(2, entry1.layerAttrKeys());
|
||||||
assertEquals(2, entry1.layerAttrValues());
|
assertEquals(2, entry1.layerAttrValues());
|
||||||
|
|
||||||
var formatted = TileSizeStats.formatOutputRows(TileCoord.ofXYZ(1, 2, 3), 999, stats);
|
var formatted = TileSizeStats.newThreadLocalSerializer().formatOutputRows(TileCoord.ofXYZ(1, 2, 3), 999, stats);
|
||||||
assertEquals(
|
assertEquals(
|
||||||
"""
|
"""
|
||||||
z x y hilbert archived_tile_bytes layer layer_bytes layer_features layer_geometries layer_attr_bytes layer_attr_keys layer_attr_values
|
z x y hilbert archived_tile_bytes layer layer_bytes layer_features layer_geometries layer_attr_bytes layer_attr_keys layer_attr_values
|
||||||
|
@ -86,7 +86,7 @@ class TileSizeStatsTest {
|
||||||
assertEquals("b", entry2.layer());
|
assertEquals("b", entry2.layer());
|
||||||
assertEquals(1, entry2.layerFeatures());
|
assertEquals(1, entry2.layerFeatures());
|
||||||
|
|
||||||
var formatted = TileSizeStats.formatOutputRows(TileCoord.ofXYZ(1, 2, 3), 999, stats);
|
var formatted = TileSizeStats.newThreadLocalSerializer().formatOutputRows(TileCoord.ofXYZ(1, 2, 3), 999, stats);
|
||||||
assertEquals(
|
assertEquals(
|
||||||
"""
|
"""
|
||||||
z x y hilbert archived_tile_bytes layer layer_bytes layer_features layer_geometries layer_attr_bytes layer_attr_keys layer_attr_values
|
z x y hilbert archived_tile_bytes layer layer_bytes layer_features layer_geometries layer_attr_bytes layer_attr_keys layer_attr_values
|
||||||
|
|
|
@ -89,7 +89,7 @@
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
<artifactId>maven-assembly-plugin</artifactId>
|
<artifactId>maven-assembly-plugin</artifactId>
|
||||||
<version>3.6.0</version>
|
<version>3.7.1</version>
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.onthegomap.planetiler</groupId>
|
<groupId>com.onthegomap.planetiler</groupId>
|
||||||
|
|
8
pom.xml
8
pom.xml
|
@ -284,7 +284,7 @@
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>com.google.cloud.tools</groupId>
|
<groupId>com.google.cloud.tools</groupId>
|
||||||
<artifactId>jib-maven-plugin</artifactId>
|
<artifactId>jib-maven-plugin</artifactId>
|
||||||
<version>3.4.1</version>
|
<version>3.4.2</version>
|
||||||
<configuration>
|
<configuration>
|
||||||
<skip>true</skip>
|
<skip>true</skip>
|
||||||
</configuration>
|
</configuration>
|
||||||
|
@ -328,12 +328,12 @@
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.sonarsource.scanner.maven</groupId>
|
<groupId>org.sonarsource.scanner.maven</groupId>
|
||||||
<artifactId>sonar-maven-plugin</artifactId>
|
<artifactId>sonar-maven-plugin</artifactId>
|
||||||
<version>3.10.0.2594</version>
|
<version>3.11.0.3922</version>
|
||||||
</plugin>
|
</plugin>
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.jacoco</groupId>
|
<groupId>org.jacoco</groupId>
|
||||||
<artifactId>jacoco-maven-plugin</artifactId>
|
<artifactId>jacoco-maven-plugin</artifactId>
|
||||||
<version>0.8.11</version>
|
<version>0.8.12</version>
|
||||||
</plugin>
|
</plugin>
|
||||||
</plugins>
|
</plugins>
|
||||||
</pluginManagement>
|
</pluginManagement>
|
||||||
|
@ -394,7 +394,7 @@
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
<artifactId>maven-gpg-plugin</artifactId>
|
<artifactId>maven-gpg-plugin</artifactId>
|
||||||
<version>3.2.1</version>
|
<version>3.2.2</version>
|
||||||
<executions>
|
<executions>
|
||||||
<execution>
|
<execution>
|
||||||
<id>sign-artifacts</id>
|
<id>sign-artifacts</id>
|
||||||
|
|
Ładowanie…
Reference in New Issue