Increased chunk size
authorJeroen van der Heijden <jeroen@cesbit.com>
Wed, 19 Jan 2022 12:36:13 +0000 (13:36 +0100)
committerJeroen van der Heijden <jeroen@cesbit.com>
Wed, 19 Jan 2022 12:36:13 +0000 (13:36 +0100)
include/siri/db/shard.h
include/siri/version.h
src/siri/db/shard.c

index 97e38dab2eb0fdcfa19596b5b1a9be12fe01e103..7bc65950d7f013ada2cfcd42a4c13904dffe6510 100644 (file)
@@ -47,7 +47,6 @@ siridb_shard_t * siridb_shard_create(
         uint8_t tp,
         siridb_shard_t * replacing);
 uint64_t siridb_shard_duration_from_interval(siridb_t * siridb, uint64_t interval);
-uint64_t siridb_shard_interval_from_duration(uint64_t duration);
 int siridb_shard_cexpr_cb(
         siridb_shard_view_t * vshard,
         cexpr_condition_t * cond);
index 7915f2cfa6936a41ba1c2dfaee595696bbf7f1f2..3e8d3e30fa947c1f94210331224be0a862569988 100644 (file)
@@ -6,7 +6,7 @@
 
 #define SIRIDB_VERSION_MAJOR 2
 #define SIRIDB_VERSION_MINOR 0
-#define SIRIDB_VERSION_PATCH 45
+#define SIRIDB_VERSION_PATCH 46
 
 /*
  * Use SIRIDB_VERSION_PRE_RELEASE for alpha release versions.
@@ -15,7 +15,7 @@
  * Note that debian alpha packages should use versions like this:
  *   2.0.34-0alpha0
  */
-#define SIRIDB_VERSION_PRE_RELEASE ""
+#define SIRIDB_VERSION_PRE_RELEASE "-alpha-0"
 
 #ifndef NDEBUG
 #define SIRIDB_VERSION_BUILD_RELEASE "+debug"
index fc1dbd2c009f0136e98bf81d0247fe751941e783..d2e7b937ea605bd4b883f42e386ae6c895444885 100644 (file)
@@ -87,7 +87,7 @@
  *
  * Max 65535 since uint16_t is used to store this value
  */
-#define DEFAULT_MAX_CHUNK_SZ_NUM 800
+#define DEFAULT_MAX_CHUNK_SZ_NUM 1200
 #define DEFAULT_MAX_CHUNK_SZ_LOG 128
 
 static const siridb_shard_flags_repr_t flags_map[SHARD_STATUS_SIZE] = {
@@ -168,11 +168,6 @@ uint64_t siridb_shard_duration_from_interval(siridb_t * siridb, uint64_t interva
     return (x + 1) * hour;
 }
 
-uint64_t siridb_shard_interval_from_duration(uint64_t duration)
-{
-    return duration / OPTIMAL_POINTS_PER_SHARD;;
-}
-
 int siridb_shard_migrate(
         siridb_t * siridb,
         uint64_t shard_id,