mirror of
https://github.com/google/nomulus.git
synced 2025-05-19 02:39:34 +02:00
Use Dagger to @Inject DnsQueue everywhere that is feasible
------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=136062053
This commit is contained in:
parent
a13f6aded8
commit
6a738557fb
17 changed files with 47 additions and 15 deletions
|
@ -33,6 +33,7 @@ import google.registry.model.eppoutput.CreateData.DomainCreateData;
|
|||
import google.registry.model.eppoutput.EppOutput;
|
||||
import google.registry.model.eppoutput.Result;
|
||||
import google.registry.model.poll.PollMessage;
|
||||
import javax.inject.Inject;
|
||||
import org.joda.time.DateTime;
|
||||
|
||||
/** An EPP flow that creates or allocates a new domain resource. */
|
||||
|
@ -41,6 +42,8 @@ public abstract class DomainCreateOrAllocateFlow
|
|||
|
||||
protected boolean isAnchorTenantViaExtension;
|
||||
|
||||
@Inject DnsQueue dnsQueue;
|
||||
|
||||
@Override
|
||||
protected final void initDomainCreateFlow() {
|
||||
isAnchorTenantViaExtension =
|
||||
|
@ -85,7 +88,7 @@ public abstract class DomainCreateOrAllocateFlow
|
|||
@Override
|
||||
protected final void enqueueTasks() {
|
||||
if (newResource.shouldPublishToDns()) {
|
||||
DnsQueue.create().addDomainRefreshTask(newResource.getFullyQualifiedDomainName());
|
||||
dnsQueue.addDomainRefreshTask(newResource.getFullyQualifiedDomainName());
|
||||
}
|
||||
enqueueLordnTaskIfNeeded();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue