Update project structure

This commit is contained in:
ruscalworld 2023-06-20 16:36:41 +03:00
parent 8e8753da68
commit 0045d53a51
No known key found for this signature in database
GPG key ID: FDF13F4478EC3C36
8 changed files with 20 additions and 8 deletions

View file

@ -4,7 +4,14 @@ import io.prometheus.client.Collector;
import io.prometheus.client.Counter;
import io.prometheus.client.SimpleCollector;
import ru.ruscalworld.fabricexporter.config.MainConfig;
import ru.ruscalworld.fabricexporter.metrics.*;
import ru.ruscalworld.fabricexporter.metrics.Metric;
import ru.ruscalworld.fabricexporter.metrics.spark.MillisPerTick;
import ru.ruscalworld.fabricexporter.metrics.spark.SparkMetric;
import ru.ruscalworld.fabricexporter.metrics.spark.TicksPerSecond;
import ru.ruscalworld.fabricexporter.metrics.world.Entities;
import ru.ruscalworld.fabricexporter.metrics.world.LoadedChunks;
import ru.ruscalworld.fabricexporter.metrics.world.OnlinePlayers;
import ru.ruscalworld.fabricexporter.metrics.world.TotalLoadedChunks;
import java.util.ArrayList;
import java.util.HashMap;

View file

@ -1,4 +1,4 @@
package ru.ruscalworld.fabricexporter.metrics;
package ru.ruscalworld.fabricexporter.metrics.spark;
import me.lucko.spark.api.statistic.StatisticWindow;
import me.lucko.spark.api.statistic.misc.DoubleAverageInfo;

View file

@ -1,7 +1,8 @@
package ru.ruscalworld.fabricexporter.metrics;
package ru.ruscalworld.fabricexporter.metrics.spark;
import me.lucko.spark.api.Spark;
import me.lucko.spark.api.SparkProvider;
import ru.ruscalworld.fabricexporter.metrics.Metric;
public abstract class SparkMetric extends Metric {
public SparkMetric(String name, String help, String... labels) {

View file

@ -1,4 +1,4 @@
package ru.ruscalworld.fabricexporter.metrics;
package ru.ruscalworld.fabricexporter.metrics.spark;
import me.lucko.spark.api.statistic.StatisticWindow;
import me.lucko.spark.api.statistic.types.DoubleStatistic;

View file

@ -1,4 +1,4 @@
package ru.ruscalworld.fabricexporter.metrics;
package ru.ruscalworld.fabricexporter.metrics.world;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityType;
@ -7,6 +7,7 @@ import net.minecraft.server.world.ServerWorld;
import net.minecraft.util.Identifier;
import net.minecraft.util.TypeFilter;
import ru.ruscalworld.fabricexporter.FabricExporter;
import ru.ruscalworld.fabricexporter.metrics.Metric;
import ru.ruscalworld.fabricexporter.util.TextUtil;
import java.util.HashMap;

View file

@ -1,7 +1,8 @@
package ru.ruscalworld.fabricexporter.metrics;
package ru.ruscalworld.fabricexporter.metrics.world;
import net.minecraft.server.world.ServerWorld;
import ru.ruscalworld.fabricexporter.FabricExporter;
import ru.ruscalworld.fabricexporter.metrics.Metric;
import ru.ruscalworld.fabricexporter.util.TextUtil;
public class LoadedChunks extends Metric {

View file

@ -1,7 +1,8 @@
package ru.ruscalworld.fabricexporter.metrics;
package ru.ruscalworld.fabricexporter.metrics.world;
import net.minecraft.server.world.ServerWorld;
import ru.ruscalworld.fabricexporter.FabricExporter;
import ru.ruscalworld.fabricexporter.metrics.Metric;
import ru.ruscalworld.fabricexporter.util.TextUtil;
public class OnlinePlayers extends Metric {

View file

@ -1,7 +1,8 @@
package ru.ruscalworld.fabricexporter.metrics;
package ru.ruscalworld.fabricexporter.metrics.world;
import net.minecraft.server.world.ServerWorld;
import ru.ruscalworld.fabricexporter.FabricExporter;
import ru.ruscalworld.fabricexporter.metrics.Metric;
import ru.ruscalworld.fabricexporter.util.TextUtil;
public class TotalLoadedChunks extends Metric {