chiark / gitweb /
cryptsetup: accept both "read-only" and "readonly" spellings
[elogind.git] / src / journal / journal-file.h
index f52ee8c538459fce23924c6ed4006cb463a0c0f2..cdbc8e41f615e9989e00e0ed0746ff15e30776dc 100644 (file)
@@ -33,6 +33,7 @@
 #include "journal-def.h"
 #include "util.h"
 #include "mmap-cache.h"
+#include "hashmap.h"
 
 typedef struct JournalMetrics {
         uint64_t max_use;
@@ -64,6 +65,8 @@ typedef struct JournalFile {
         JournalMetrics metrics;
         MMapCache *mmap;
 
+        Hashmap *chain_cache;
+
 #ifdef HAVE_XZ
         void *compress_buffer;
         uint64_t compress_buffer_size;
@@ -155,6 +158,9 @@ int journal_file_append_entry(JournalFile *f, const dual_timestamp *ts, const st
 int journal_file_find_data_object(JournalFile *f, const void *data, uint64_t size, Object **ret, uint64_t *offset);
 int journal_file_find_data_object_with_hash(JournalFile *f, const void *data, uint64_t size, uint64_t hash, Object **ret, uint64_t *offset);
 
+int journal_file_find_field_object(JournalFile *f, const void *field, uint64_t size, Object **ret, uint64_t *offset);
+int journal_file_find_field_object_with_hash(JournalFile *f, const void *field, uint64_t size, uint64_t hash, Object **ret, uint64_t *offset);
+
 int journal_file_next_entry(JournalFile *f, Object *o, uint64_t p, direction_t direction, Object **ret, uint64_t *offset);
 int journal_file_skip_entry(JournalFile *f, Object *o, uint64_t p, int64_t skip, Object **ret, uint64_t *offset);