mirror of
https://github.com/google/nomulus
synced 2026-09-19 06:32:00 +00:00
Convert poll-message-related classes to use SQL as well (#1050)
* Convert poll-message-related classes to use SQL as well Two relatively complex parts. The first is that we needed a small refactor on the AckPollMessagesCommand because we could theoretically be acking more poll messages than the Datastore transaction size boundary. This means that the normal flow of "gather the poll messages from the DB into one collection, then act on it" needs to be changed to a more functional flow. The second is that acking the poll message (deleting it in most cases) reduces the number of remaining poll messages in SQL but not in Datastore, since in Datastore the deletion does not take effect until after the transaction is over.
This commit is contained in:
@@ -510,14 +510,14 @@ class google.registry.model.poll.PendingActionNotificationResponse$NameOrId {
|
||||
}
|
||||
class google.registry.model.poll.PollMessage {
|
||||
@Id java.lang.Long id;
|
||||
@Parent com.googlecode.objectify.Key<google.registry.model.reporting.HistoryEntry> parent;
|
||||
@Parent com.googlecode.objectify.Key<? extends google.registry.model.reporting.HistoryEntry> parent;
|
||||
java.lang.String clientId;
|
||||
java.lang.String msg;
|
||||
org.joda.time.DateTime eventTime;
|
||||
}
|
||||
class google.registry.model.poll.PollMessage$Autorenew {
|
||||
@Id java.lang.Long id;
|
||||
@Parent com.googlecode.objectify.Key<google.registry.model.reporting.HistoryEntry> parent;
|
||||
@Parent com.googlecode.objectify.Key<? extends google.registry.model.reporting.HistoryEntry> parent;
|
||||
java.lang.String clientId;
|
||||
java.lang.String msg;
|
||||
java.lang.String targetId;
|
||||
@@ -526,7 +526,7 @@ class google.registry.model.poll.PollMessage$Autorenew {
|
||||
}
|
||||
class google.registry.model.poll.PollMessage$OneTime {
|
||||
@Id java.lang.Long id;
|
||||
@Parent com.googlecode.objectify.Key<google.registry.model.reporting.HistoryEntry> parent;
|
||||
@Parent com.googlecode.objectify.Key<? extends google.registry.model.reporting.HistoryEntry> parent;
|
||||
java.lang.String clientId;
|
||||
java.lang.String msg;
|
||||
java.util.List<google.registry.model.poll.PendingActionNotificationResponse$ContactPendingActionNotificationResponse> contactPendingActionNotificationResponses;
|
||||
|
||||
Reference in New Issue
Block a user