diff options
author | Dan Goodliffe <dan@randomdan.homeip.net> | 2025-08-23 19:26:59 +0100 |
---|---|---|
committer | Dan Goodliffe <dan@randomdan.homeip.net> | 2025-08-25 16:02:44 +0100 |
commit | e30cbf9fef8922abef4cc44ad8628d4eef5d28a9 (patch) | |
tree | fce01562e2743bda9b0095ec2b7fd08ed77e9e38 /src/ingestor.hpp | |
parent | a84be46d879ad3bde0e4a0890ef1108bf5e10b0b (diff) | |
download | webstat-e30cbf9fef8922abef4cc44ad8628d4eef5d28a9.tar.bz2 webstat-e30cbf9fef8922abef4cc44ad8628d4eef5d28a9.tar.xz webstat-e30cbf9fef8922abef4cc44ad8628d4eef5d28a9.zip |
Track existing entities, don't attempt reinsert
This is an ever growing set, but in theory should be finite, and is only
4bytes per entity.
Diffstat (limited to 'src/ingestor.hpp')
-rw-r--r-- | src/ingestor.hpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/ingestor.hpp b/src/ingestor.hpp index 53ba81f..458b941 100644 --- a/src/ingestor.hpp +++ b/src/ingestor.hpp @@ -4,6 +4,7 @@ #include <c++11Helpers.h> #include <connection_fwd.h> #include <cstdio> +#include <flat_set> #include <scn/scan.h> namespace WebStat { @@ -39,6 +40,7 @@ namespace WebStat { private: template<typename... T> size_t storeEntities(const std::tuple<T...> &) const; + mutable std::flat_set<Crc32Value> existingEntities; uint32_t hostnameId; DB::ConnectionPtr dbconn; }; |