Minor DB updates
A node can support multiple streams. Unfortunately, an address can't so there might be multiple entries of the same address for different streams. Also, store object types. I think we'll need them later, specially in search for public keys we requested.
This commit is contained in:
@ -1,9 +1,9 @@
|
||||
CREATE TABLE Node (
|
||||
ip BINARY(16) NOT NULL,
|
||||
port INT NOT NULL,
|
||||
services BIGINT NOT NULL,
|
||||
stream BIGINT NOT NULL,
|
||||
services BIGINT NOT NULL,
|
||||
time BIGINT NOT NULL,
|
||||
|
||||
PRIMARY KEY (ip, port)
|
||||
PRIMARY KEY (ip, port, stream)
|
||||
);
|
@ -3,5 +3,6 @@ CREATE TABLE Inventory (
|
||||
stream BIGINT NOT NULL,
|
||||
expires BIGINT NOT NULL,
|
||||
data BLOB NOT NULL,
|
||||
type BIGINT NOT NULL,
|
||||
version INT NOT NULL
|
||||
);
|
Reference in New Issue
Block a user