GNUnet  0.10.x
datastore.h
Go to the documentation of this file.
1 /*
2  This file is part of GNUnet
3  Copyright (C) 2004, 2005, 2006, 2007, 2009 GNUnet e.V.
4 
5  GNUnet is free software: you can redistribute it and/or modify it
6  under the terms of the GNU Affero General Public License as published
7  by the Free Software Foundation, either version 3 of the License,
8  or (at your option) any later version.
9 
10  GNUnet is distributed in the hope that it will be useful, but
11  WITHOUT ANY WARRANTY; without even the implied warranty of
12  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  Affero General Public License for more details.
14 
15  You should have received a copy of the GNU Affero General Public License
16  along with this program. If not, see <http://www.gnu.org/licenses/>.
17 
18  SPDX-License-Identifier: AGPL3.0-or-later
19 */
20 
27 #ifndef DATASTORE_H
28 #define DATASTORE_H
29 
30 
31 #include "gnunet_util_lib.h"
32 
34 
40 {
45 
50 
55 };
56 
57 
65 {
70 
75 
81 
82 };
83 
84 
91 {
96 
100  int32_t rid GNUNET_PACKED;
101 
102 };
103 
104 
110 {
115 
119  uint32_t type GNUNET_PACKED;
120 
124  uint64_t next_uid GNUNET_PACKED;
125 
129  uint32_t random GNUNET_PACKED;
130 
135 
136 };
137 
138 
144 {
149 
153  uint32_t type GNUNET_PACKED;
154 
158  uint64_t next_uid GNUNET_PACKED;
159 
163  uint32_t random GNUNET_PACKED;
164 
165 };
166 
167 
173 {
178 
182  uint32_t type GNUNET_PACKED;
183 
187  uint64_t next_uid GNUNET_PACKED;
188 
189 };
190 
191 
197 {
205 
209  uint32_t rid GNUNET_PACKED;
210 
214  uint32_t size GNUNET_PACKED;
215 
219  uint32_t type GNUNET_PACKED;
220 
224  uint32_t priority GNUNET_PACKED;
225 
230 
235 
240 
247  uint64_t uid;
248 
253 
257  struct GNUNET_HashCode key;
258 
259 };
261 
262 
263 
264 #endif
static struct GNUNET_TIME_Absolute min_expiration
Minimum time that content should have to not be discarded instantly (time stamp of any content that w...
static char * expiration
Credential TTL.
uint32_t entries
Number of items to reserve.
Definition: datastore.h:49
Message from datastore service informing client about the current size of the datastore.
Definition: datastore.h:39
Message from datastore client informing service that the remainder of the reserved bytes can now be r...
Definition: datastore.h:90
static unsigned int replication
Message to the datastore service asking about specific content.
Definition: datastore.h:109
Message to the datastore service asking about zero anonymity content.
Definition: datastore.h:172
Time for absolute time used by GNUnet, in microseconds and in network byte order. ...
#define GNUNET_NETWORK_STRUCT_BEGIN
Define as empty, GNUNET_PACKED should suffice, but this won&#39;t work on W32.
Message to the datastore service asking about specific content.
Definition: datastore.h:143
uint16_t status
See PRISM_STATUS_*-constants.
A 512-bit hashcode.
Message transmitting content from or to the datastore service.
Definition: datastore.h:196
struct GNUNET_HashCode key
The key used in the DHT.
static unsigned int size
Size of the "table".
Definition: peer.c:67
#define GNUNET_NETWORK_STRUCT_END
Define as empty, GNUNET_PACKED should suffice, but this won&#39;t work on W32;.
uint64_t uid
Unique ID for the content (can be used for UPDATE); can be zero for remove (which indicates that the ...
Definition: datastore.h:247
#define GNUNET_PACKED
gcc-ism to get packed structs.
Message from datastore service informing client about the success or failure of a requested operation...
Definition: datastore.h:64
struct GNUNET_MessageHeader header
Type is GNUNET_MESSAGE_TYPE_DATASTORE_RESERVE.
Definition: datastore.h:44
enum GNUNET_TESTBED_UnderlayLinkModelType type
the type of this model
Header for all communications.
static unsigned int anonymity
static unsigned long long reserved
How much space have we currently reserved?
uint64_t amount
Number of bytes to reserve.
Definition: datastore.h:54