Skip to content
Snippets Groups Projects
Commit d5411ecd authored by Josh Brooks's avatar Josh Brooks
Browse files

Add partition clear thread to client runner

parent 8c7c8c3a
No related branches found
No related tags found
1 merge request!23Release
......@@ -186,6 +186,8 @@ func OpenClient(storageDir string, password []byte, parameters params.Network) (
parameters: parameters,
}
c.runner.Add(c.storage.Partition().ClearMessages())
return c, nil
}
......
......@@ -12,6 +12,7 @@ import (
"gitlab.com/elixxir/client/interfaces/message"
"gitlab.com/elixxir/client/storage"
"gitlab.com/xx_network/primitives/id"
"gitlab.com/xx_network/primitives/netTime"
"time"
)
......@@ -80,9 +81,9 @@ func (p Partitioner) HandlePartition(sender *id.ID, _ message.EncryptionType,
// Handle the message ID
messageID := p.session.Conversations().Get(sender).
ProcessReceivedMessageID(fm.GetID())
storeageTimestamp := netTime.Now()
return p.session.Partition().AddFirst(sender, fm.GetType(),
messageID, fm.GetPart(), fm.GetNumParts(), fm.GetTimestamp(),
messageID, fm.GetPart(), fm.GetNumParts(), fm.GetTimestamp(), storeageTimestamp,
fm.GetSizedContents(), relationshipFingerprint)
} else {
// If it is a subsequent message part, handle it as so
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment