mirror of
https://github.com/signalapp/Signal-Server
synced 2026-04-21 00:28:02 +01:00
Drop the old (and now unused!) redis-dispatch module
This commit is contained in:
committed by
Jon Chambers
parent
11829d1f9f
commit
fd5e9ea016
@@ -6,11 +6,16 @@
|
||||
package org.whispersystems.textsecuregcm.subscriptions;
|
||||
|
||||
import java.nio.charset.StandardCharsets;
|
||||
import org.whispersystems.dispatch.util.Util;
|
||||
|
||||
public record ProcessorCustomer(String customerId, SubscriptionProcessor processor) {
|
||||
|
||||
public byte[] toDynamoBytes() {
|
||||
return Util.combine(new byte[]{processor.getId()}, customerId.getBytes(StandardCharsets.UTF_8));
|
||||
final byte[] customerIdBytes = customerId.getBytes(StandardCharsets.UTF_8);
|
||||
final byte[] combinedBytes = new byte[customerIdBytes.length + 1];
|
||||
|
||||
combinedBytes[0] = processor.getId();
|
||||
System.arraycopy(customerIdBytes, 0, combinedBytes, 1, customerIdBytes.length);
|
||||
|
||||
return combinedBytes;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user