public static List<MetricsPacket.Builder> toMetricsPackets(String jsonString) {
        List<MetricsPacket.Builder> packets = new ArrayList<>();
        var mapper = objectMapper();
        try (JsonParser jp = mapper.createParser(jsonString)) {
            while (jp.nextToken() != null) {
                YamasJsonModel jsonModel = jp.readValueAs(YamasJsonModel.class);
                packets.add(toMetricsPacketBuilder(jsonModel));
            }
            return packets;
        } catch (IOException e) {
            log.log(WARNING, "Could not create metrics packet from string:\n" + jsonString, e);
            return List.of();
        }
    }
Converts the given json formatted string to a list of metrics packet builders.
Note that this method returns an empty list if an IOException occurs,
and logs a warning as a side effect.
metrics-proxy/src/main/java/ai/vespa/metricsproxy/metric/model/json/YamasJsonUtil.java