diff --git a/core/src/main/java/google/registry/config/RegistryConfig.java b/core/src/main/java/google/registry/config/RegistryConfig.java
index 6d277e85f..f29ebc770 100644
--- a/core/src/main/java/google/registry/config/RegistryConfig.java
+++ b/core/src/main/java/google/registry/config/RegistryConfig.java
@@ -143,15 +143,15 @@ public final class RegistryConfig {
}
/**
- * Returns the roid suffix to be used for the roids of all contacts and hosts. E.g. a value of
- * "ROID" would end up creating roids that look like "ABC123-ROID".
+ * Returns the roid suffix to be used for the roids of all hosts. E.g. a value of "ROID" would
+ * end up creating roids that look like "ABC123-ROID".
*
* @see
* Extensible Provisioning Protocol (EPP) Repository Identifiers
*/
@Provides
- @Config("contactAndHostRoidSuffix")
- public static String provideContactAndHostRoidSuffix(RegistryConfigSettings config) {
+ @Config("hostRoidSuffix")
+ public static String provideHostRoidSuffix(RegistryConfigSettings config) {
return config.registryPolicy.contactAndHostRoidSuffix;
}
@@ -1024,18 +1024,6 @@ public final class RegistryConfig {
return Duration.standardSeconds(config.monitoring.writeIntervalSeconds);
}
- /**
- * The global automatic transfer length for contacts. After this amount of time has elapsed, the
- * transfer is automatically approved.
- *
- * @see google.registry.flows.contact.ContactTransferRequestFlow
- */
- @Provides
- @Config("contactAutomaticTransferLength")
- public static Duration provideContactAutomaticTransferLength(RegistryConfigSettings config) {
- return Duration.standardDays(config.registryPolicy.contactAutomaticTransferDays);
- }
-
/**
* Returns the maximum number of entities that can be checked at one time in an EPP check flow.
*/
@@ -1623,15 +1611,11 @@ public final class RegistryConfig {
return CONFIG_SETTINGS.get().hibernate.jdbcFetchSize;
}
- /** Returns the roid suffix to be used for the roids of all contacts and hosts. */
- public static String getContactAndHostRoidSuffix() {
+ /** Returns the roid suffix to be used for the roids of all hosts. */
+ public static String getHostRoidSuffix() {
return CONFIG_SETTINGS.get().registryPolicy.contactAndHostRoidSuffix;
}
- /** Returns the global automatic transfer length for contacts. */
- public static Duration getContactAutomaticTransferLength() {
- return Duration.standardDays(CONFIG_SETTINGS.get().registryPolicy.contactAutomaticTransferDays);
- }
/** A discount for all sunrise domain creates, between 0.0 (no discount) and 1.0 (free). */
public static double getSunriseDomainCreateDiscount() {
diff --git a/core/src/main/java/google/registry/config/RegistryConfigSettings.java b/core/src/main/java/google/registry/config/RegistryConfigSettings.java
index 28bf48d0e..368878eb7 100644
--- a/core/src/main/java/google/registry/config/RegistryConfigSettings.java
+++ b/core/src/main/java/google/registry/config/RegistryConfigSettings.java
@@ -86,7 +86,6 @@ public class RegistryConfigSettings {
public String productName;
public String customLogicFactoryClass;
public String dnsCountQueryCoordinatorClass;
- public int contactAutomaticTransferDays;
public String greetingServerId;
public List registrarChangesNotificationEmailAddresses;
public String defaultRegistrarWhoisServer;
diff --git a/core/src/main/java/google/registry/config/files/default-config.yaml b/core/src/main/java/google/registry/config/files/default-config.yaml
index 14cccf340..5e737a377 100644
--- a/core/src/main/java/google/registry/config/files/default-config.yaml
+++ b/core/src/main/java/google/registry/config/files/default-config.yaml
@@ -63,9 +63,6 @@ registryPolicy:
# See reporting/icann/DnsCountQueryCoordinator.java
dnsCountQueryCoordinatorClass: google.registry.reporting.icann.DummyDnsCountQueryCoordinator
- # Length of time after which contact transfers automatically conclude.
- contactAutomaticTransferDays: 5
-
# Server ID used in the 'svID' element of an EPP 'greeting'.
greetingServerId: Nomulus Registry
diff --git a/core/src/main/java/google/registry/flows/host/HostCreateFlow.java b/core/src/main/java/google/registry/flows/host/HostCreateFlow.java
index aba7acb6d..1644148bd 100644
--- a/core/src/main/java/google/registry/flows/host/HostCreateFlow.java
+++ b/core/src/main/java/google/registry/flows/host/HostCreateFlow.java
@@ -87,7 +87,7 @@ public final class HostCreateFlow implements MutatingFlow {
@Inject EppResponse.Builder responseBuilder;
@Inject
- @Config("contactAndHostRoidSuffix")
+ @Config("hostRoidSuffix")
String roidSuffix;
@Inject
diff --git a/core/src/main/java/google/registry/tools/CreateDomainCommand.java b/core/src/main/java/google/registry/tools/CreateDomainCommand.java
index 66664bd8f..101e50177 100644
--- a/core/src/main/java/google/registry/tools/CreateDomainCommand.java
+++ b/core/src/main/java/google/registry/tools/CreateDomainCommand.java
@@ -85,9 +85,6 @@ final class CreateDomainCommand extends CreateOrUpdateDomainCommand {
"domain", domain,
"period", period,
"nameservers", nameservers,
- "registrant", registrant,
- "admins", admins,
- "techs", techs,
"password", password,
"currency", currency,
"price", cost,
diff --git a/core/src/main/java/google/registry/tools/CreateOrUpdateDomainCommand.java b/core/src/main/java/google/registry/tools/CreateOrUpdateDomainCommand.java
index 70ba1f852..3f0f84604 100644
--- a/core/src/main/java/google/registry/tools/CreateOrUpdateDomainCommand.java
+++ b/core/src/main/java/google/registry/tools/CreateOrUpdateDomainCommand.java
@@ -21,7 +21,6 @@ import com.beust.jcommander.Parameter;
import com.google.common.base.Joiner;
import com.google.common.collect.ImmutableSet;
import google.registry.tools.params.NameserversParameter;
-import google.registry.tools.params.StringListParameter;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.List;
@@ -47,24 +46,6 @@ abstract class CreateOrUpdateDomainCommand extends MutatingEppToolCommand {
validateWith = NameserversParameter.class)
Set nameservers = new HashSet<>();
- @Parameter(
- names = {"-r", "--registrant"},
- description = "Domain registrant."
- )
- String registrant;
-
- @Parameter(
- names = {"-a", "--admins"},
- description = "Comma-separated list of admin contacts.",
- listConverter = StringListParameter.class)
- List admins = new ArrayList<>();
-
- @Parameter(
- names = {"-t", "--techs"},
- description = "Comma-separated list of technical contacts.",
- listConverter = StringListParameter.class)
- List techs = new ArrayList<>();
-
@Parameter(
names = {"-p", "--password"},
description = "Password."
diff --git a/core/src/main/java/google/registry/tools/UpdateDomainCommand.java b/core/src/main/java/google/registry/tools/UpdateDomainCommand.java
index 0336d01c0..e9474c8f7 100644
--- a/core/src/main/java/google/registry/tools/UpdateDomainCommand.java
+++ b/core/src/main/java/google/registry/tools/UpdateDomainCommand.java
@@ -15,11 +15,9 @@
package google.registry.tools;
import static com.google.common.base.Preconditions.checkArgument;
-import static com.google.common.collect.ImmutableSet.toImmutableSet;
import static google.registry.model.domain.rgp.GracePeriodStatus.AUTO_RENEW;
import static google.registry.model.eppcommon.StatusValue.PENDING_DELETE;
import static google.registry.model.eppcommon.StatusValue.SERVER_UPDATE_PROHIBITED;
-import static google.registry.persistence.transaction.TransactionManagerFactory.tm;
import static java.util.function.Predicate.isEqual;
import com.beust.jcommander.Parameter;
@@ -30,7 +28,6 @@ import com.google.common.collect.Sets;
import com.google.common.flogger.FluentLogger;
import com.google.template.soy.data.SoyMapData;
import google.registry.flows.ResourceFlowUtils;
-import google.registry.model.domain.DesignatedContact;
import google.registry.model.domain.Domain;
import google.registry.model.domain.GracePeriodBase;
import google.registry.model.eppcommon.StatusValue;
@@ -66,15 +63,6 @@ final class UpdateDomainCommand extends CreateOrUpdateDomainCommand {
validateWith = NameserversParameter.class)
private Set addNameservers = new HashSet<>();
- // TODO(b/184067241): enforce only one of each type of contact
- @Parameter(
- names = "--add_admins",
- description = "Admins to add. Cannot be set if --admins is set.")
- private List addAdmins = new ArrayList<>();
-
- @Parameter(names = "--add_techs", description = "Techs to add. Cannot be set if --techs is set.")
- private List addTechs = new ArrayList<>();
-
@Parameter(
names = "--add_statuses",
description = "Statuses to add. Cannot be set if --statuses is set."
@@ -97,18 +85,6 @@ final class UpdateDomainCommand extends CreateOrUpdateDomainCommand {
validateWith = NameserversParameter.class)
private Set removeNameservers = new HashSet<>();
- @Parameter(
- names = "--remove_admins",
- description = "Admins to remove. Cannot be set if --admins is set."
- )
- private List removeAdmins = new ArrayList<>();
-
- @Parameter(
- names = "--remove_techs",
- description = "Techs to remove. Cannot be set if --techs is set."
- )
- private List removeTechs = new ArrayList<>();
-
@Parameter(
names = "--remove_statuses",
description = "Statuses to remove. Cannot be set if --statuses is set."
@@ -154,16 +130,6 @@ final class UpdateDomainCommand extends CreateOrUpdateDomainCommand {
} else {
checkArgument(addNameservers.size() <= 13, "You can add at most 13 nameservers.");
}
- if (!admins.isEmpty()) {
- checkArgument(
- addAdmins.isEmpty() && removeAdmins.isEmpty(),
- "If you provide the admins flag, you cannot use the add_admins and remove_admins flags.");
- }
- if (!techs.isEmpty()) {
- checkArgument(
- addTechs.isEmpty() && removeTechs.isEmpty(),
- "If you provide the techs flag, you cannot use the add_techs and remove_techs flags.");
- }
if (!statuses.isEmpty()) {
checkArgument(
addStatuses.isEmpty() && removeStatuses.isEmpty(),
@@ -197,16 +163,12 @@ final class UpdateDomainCommand extends CreateOrUpdateDomainCommand {
domainName);
// Use TreeSets so that the results are always in the same order (this makes testing easier).
- Set addAdminsThisDomain = new TreeSet<>(addAdmins);
- Set removeAdminsThisDomain = new TreeSet<>(removeAdmins);
- Set addTechsThisDomain = new TreeSet<>(addTechs);
- Set removeTechsThisDomain = new TreeSet<>(removeTechs);
Set addNameserversThisDomain = new TreeSet<>(addNameservers);
Set removeNameserversThisDomain = new TreeSet<>(removeNameservers);
Set addStatusesThisDomain = new TreeSet<>(addStatuses);
Set removeStatusesThisDomain = new TreeSet<>(removeStatuses);
- if (!nameservers.isEmpty() || !admins.isEmpty() || !techs.isEmpty() || !statuses.isEmpty()) {
+ if (!nameservers.isEmpty() || !statuses.isEmpty()) {
if (!nameservers.isEmpty()) {
ImmutableSortedSet existingNameservers = domain.loadNameserverHostNames();
populateAddRemoveLists(
@@ -223,27 +185,7 @@ final class UpdateDomainCommand extends CreateOrUpdateDomainCommand {
"The resulting nameservers count for domain %s would be more than 13",
domainName);
}
- if (!admins.isEmpty() || !techs.isEmpty()) {
- ImmutableSet existingAdmins =
- getContactsOfType(domain, DesignatedContact.Type.ADMIN);
- ImmutableSet existingTechs =
- getContactsOfType(domain, DesignatedContact.Type.TECH);
- if (!admins.isEmpty()) {
- populateAddRemoveLists(
- ImmutableSet.copyOf(admins),
- existingAdmins,
- addAdminsThisDomain,
- removeAdminsThisDomain);
- }
- if (!techs.isEmpty()) {
- populateAddRemoveLists(
- ImmutableSet.copyOf(techs),
- existingTechs,
- addTechsThisDomain,
- removeTechsThisDomain);
- }
- }
if (!statuses.isEmpty()) {
Set currentStatusValues = new HashSet<>();
for (StatusValue statusValue : domain.getStatusValues()) {
@@ -259,17 +201,13 @@ final class UpdateDomainCommand extends CreateOrUpdateDomainCommand {
boolean add =
(!addNameserversThisDomain.isEmpty()
- || !addAdminsThisDomain.isEmpty()
- || !addTechsThisDomain.isEmpty()
|| !addStatusesThisDomain.isEmpty());
boolean remove =
(!removeNameserversThisDomain.isEmpty()
- || !removeAdminsThisDomain.isEmpty()
- || !removeTechsThisDomain.isEmpty()
|| !removeStatusesThisDomain.isEmpty());
- boolean change = (registrant != null || password != null);
+ boolean change = password != null;
boolean secDns =
(!addDsRecords.isEmpty()
|| !removeDsRecords.isEmpty()
@@ -297,16 +235,11 @@ final class UpdateDomainCommand extends CreateOrUpdateDomainCommand {
"domain", domainName,
"add", add,
"addNameservers", addNameserversThisDomain,
- "addAdmins", addAdminsThisDomain,
- "addTechs", addTechsThisDomain,
"addStatuses", addStatusesThisDomain,
"remove", remove,
"removeNameservers", removeNameserversThisDomain,
- "removeAdmins", removeAdminsThisDomain,
- "removeTechs", removeTechsThisDomain,
"removeStatuses", removeStatusesThisDomain,
"change", change,
- "registrant", registrant,
"password", password,
"secdns", secDns,
"addDsRecords", DsRecord.convertToSoy(addDsRecords),
@@ -337,13 +270,4 @@ final class UpdateDomainCommand extends CreateOrUpdateDomainCommand {
addSet.addAll(Sets.difference(targetSet, oldSet));
removeSet.addAll(Sets.difference(oldSet, targetSet));
}
-
- ImmutableSet getContactsOfType(Domain domain, final DesignatedContact.Type contactType) {
- return tm().transact(
- () ->
- domain.getContacts().stream()
- .filter(contact -> contact.getType().equals(contactType))
- .map(contact -> tm().loadByKey(contact.getContactKey()).getContactId())
- .collect(toImmutableSet()));
- }
}
diff --git a/core/src/main/resources/google/registry/tools/soy/DomainUpdate.soy b/core/src/main/resources/google/registry/tools/soy/DomainUpdate.soy
index 12970bae5..7436c95d9 100644
--- a/core/src/main/resources/google/registry/tools/soy/DomainUpdate.soy
+++ b/core/src/main/resources/google/registry/tools/soy/DomainUpdate.soy
@@ -20,16 +20,11 @@
{@param domain: string}
{@param add: bool}
{@param addNameservers: list}
- {@param addAdmins: list}
- {@param addTechs: list}
{@param addStatuses: list}
{@param remove: bool}
{@param removeNameservers: list}
- {@param removeAdmins: list}
- {@param removeTechs: list}
{@param removeStatuses: list}
{@param change: bool}
- {@param? registrant: string|null}
{@param? password: string|null}
{@param secdns: bool}
{@param addDsRecords: list<[keyTag:int, alg:int, digestType:int, digest:string]>}
@@ -54,12 +49,6 @@
{/for}
{/if}
- {for $admin in $addAdmins}
- {$admin}
- {/for}
- {for $tech in $addTechs}
- {$tech}
- {/for}
{for $status in $addStatuses}
{/for}
@@ -74,12 +63,6 @@
{/for}
{/if}
- {for $admin in $removeAdmins}
- {$admin}
- {/for}
- {for $tech in $removeTechs}
- {$tech}
- {/for}
{for $status in $removeStatuses}
{/for}
@@ -87,9 +70,6 @@
{/if}
{if $change}
- {if $registrant}
- {$registrant}
- {/if}
{if $password}
{$password}
diff --git a/core/src/test/java/google/registry/model/domain/DomainSqlTest.java b/core/src/test/java/google/registry/model/domain/DomainSqlTest.java
index 4662a38bf..260f5a356 100644
--- a/core/src/test/java/google/registry/model/domain/DomainSqlTest.java
+++ b/core/src/test/java/google/registry/model/domain/DomainSqlTest.java
@@ -36,7 +36,6 @@ import com.google.common.collect.ImmutableSortedMap;
import com.google.common.collect.Sets;
import google.registry.model.billing.BillingBase.RenewalPriceBehavior;
import google.registry.model.contact.Contact;
-import google.registry.model.domain.DesignatedContact.Type;
import google.registry.model.domain.fee.FeeQueryCommandExtensionItem.CommandName;
import google.registry.model.domain.launch.LaunchNotice;
import google.registry.model.domain.rgp.GracePeriodStatus;
@@ -53,7 +52,6 @@ import google.registry.persistence.transaction.JpaTestExtensions.JpaIntegrationW
import google.registry.testing.FakeClock;
import google.registry.util.SerializeUtils;
import java.util.Arrays;
-import java.util.Optional;
import org.joda.money.CurrencyUnit;
import org.joda.money.Money;
import org.joda.time.DateTime;
@@ -71,12 +69,8 @@ public class DomainSqlTest {
new JpaTestExtensions.Builder().withClock(fakeClock).buildIntegrationWithCoverageExtension();
private Domain domain;
- private Optional> contactKey;
- private VKey contact2Key;
private VKey host1VKey;
private Host host;
- private Contact contact;
- private Contact contact2;
private AllocationToken allocationToken;
@BeforeEach
@@ -84,9 +78,6 @@ public class DomainSqlTest {
saveRegistrar("registrar1");
saveRegistrar("registrar2");
saveRegistrar("registrar3");
- contactKey = Optional.of(createKey(Contact.class, "contact_id1"));
- contact2Key = createKey(Contact.class, "contact_id2");
-
host1VKey = createKey(Host.class, "host1");
domain =
@@ -106,8 +97,6 @@ public class DomainSqlTest {
StatusValue.SERVER_UPDATE_PROHIBITED,
StatusValue.SERVER_RENEW_PROHIBITED,
StatusValue.SERVER_HOLD))
- .setRegistrant(contactKey)
- .setContacts(ImmutableSet.of(DesignatedContact.create(Type.ADMIN, contact2Key)))
.setSubordinateHosts(ImmutableSet.of("ns1.example.com"))
.setPersistedCurrentSponsorRegistrarId("registrar3")
.setRegistrationExpirationTime(fakeClock.nowUtc().plusYears(1))
@@ -128,8 +117,6 @@ public class DomainSqlTest {
.setCreationRegistrarId("registrar1")
.setPersistedCurrentSponsorRegistrarId("registrar2")
.build();
- contact = makeContact("contact_id1");
- contact2 = makeContact("contact_id2");
allocationToken =
new AllocationToken.Builder()
@@ -168,7 +155,7 @@ public class DomainSqlTest {
@Test
void testHostForeignKeyConstraints() {
// Persist the domain without the associated host object.
- assertThrowForeignKeyViolation(() -> persistResources(contact, contact2, domain));
+ assertThrowForeignKeyViolation(() -> persistResources(domain));
}
@Test
@@ -357,7 +344,7 @@ public class DomainSqlTest {
@Test
void testSerializable() {
createTld("com");
- persistResources(contact, contact2, domain, host);
+ persistResources(domain, host);
Domain persisted = tm().transact(() -> tm().loadByEntity(domain));
assertThat(SerializeUtils.serializeDeserialize(persisted)).isEqualTo(persisted);
}
@@ -365,7 +352,7 @@ public class DomainSqlTest {
@Test
void testUpdates() {
createTld("com");
- persistResources(contact, contact2, domain, host);
+ persistResources(domain, host);
domain = domain.asBuilder().setNameservers(ImmutableSet.of()).build();
persistResource(domain);
assertAboutImmutableObjects()
@@ -384,7 +371,7 @@ public class DomainSqlTest {
private void persistDomain() {
createTld("com");
- persistResources(contact, contact2, domain, host);
+ persistResources(domain, host);
}
private VKey createKey(Class clazz, String key) {
diff --git a/core/src/test/java/google/registry/model/domain/DomainTest.java b/core/src/test/java/google/registry/model/domain/DomainTest.java
index 896abdea1..01083ab68 100644
--- a/core/src/test/java/google/registry/model/domain/DomainTest.java
+++ b/core/src/test/java/google/registry/model/domain/DomainTest.java
@@ -23,7 +23,6 @@ import static google.registry.model.domain.token.AllocationToken.TokenType.SINGL
import static google.registry.testing.DatabaseHelper.cloneAndSetAutoTimestamps;
import static google.registry.testing.DatabaseHelper.createTld;
import static google.registry.testing.DatabaseHelper.newHost;
-import static google.registry.testing.DatabaseHelper.persistActiveContact;
import static google.registry.testing.DatabaseHelper.persistActiveDomain;
import static google.registry.testing.DatabaseHelper.persistActiveHost;
import static google.registry.testing.DatabaseHelper.persistResource;
@@ -49,8 +48,6 @@ import google.registry.model.billing.BillingBase.Flag;
import google.registry.model.billing.BillingBase.Reason;
import google.registry.model.billing.BillingEvent;
import google.registry.model.billing.BillingRecurrence;
-import google.registry.model.contact.Contact;
-import google.registry.model.domain.DesignatedContact.Type;
import google.registry.model.domain.fee.FeeQueryCommandExtensionItem.CommandName;
import google.registry.model.domain.launch.LaunchNotice;
import google.registry.model.domain.rgp.GracePeriodStatus;
@@ -91,7 +88,6 @@ public class DomainTest {
private VKey oneTimeBillKey;
private VKey recurrenceBillKey;
private DomainHistory domainHistory;
- private VKey contact1Key, contact2Key;
@BeforeEach
void setUp() {
@@ -102,8 +98,6 @@ public class DomainTest {
createTld("com");
domain = persistActiveDomain("example.com");
VKey hostKey = persistActiveHost("ns1.example.com").createVKey();
- contact1Key = persistActiveContact("contact_id1").createVKey();
- contact2Key = persistActiveContact("contact_id1").createVKey();
domainHistory =
persistResource(
new DomainHistory.Builder()
@@ -185,7 +179,6 @@ public class DomainTest {
StatusValue.SERVER_UPDATE_PROHIBITED,
StatusValue.SERVER_RENEW_PROHIBITED,
StatusValue.SERVER_HOLD))
- .setRegistrant(Optional.of(contact1Key))
.setNameservers(ImmutableSet.of(hostKey))
.setSubordinateHosts(ImmutableSet.of("ns1.example.com"))
.setPersistedCurrentSponsorRegistrarId("NewRegistrar")
@@ -1015,51 +1008,6 @@ public class DomainTest {
}
}
- @Test
- void testContactFields() {
- VKey contact3Key = persistActiveContact("contact_id3").createVKey();
- VKey contact4Key = persistActiveContact("contact_id4").createVKey();
-
- // Set all of the contacts.
- domain.setContactFields(
- ImmutableSet.of(
- DesignatedContact.create(Type.REGISTRANT, contact1Key),
- DesignatedContact.create(Type.ADMIN, contact2Key),
- DesignatedContact.create(Type.BILLING, contact3Key),
- DesignatedContact.create(Type.TECH, contact4Key)),
- true);
- assertThat(domain.getRegistrant()).hasValue(contact1Key);
- assertThat(domain.getAdminContact()).hasValue(contact2Key);
- assertThat(domain.getBillingContact()).hasValue(contact3Key);
- assertThat(domain.getTechContact()).hasValue(contact4Key);
-
- // Make sure everything gets nulled out.
- domain.setContactFields(ImmutableSet.of(), true);
- assertThat(domain.getRegistrant()).isEmpty();
- assertThat(domain.getAdminContact()).isEmpty();
- assertThat(domain.getBillingContact()).isEmpty();
- assertThat(domain.getTechContact()).isEmpty();
-
- // Make sure that changes don't affect the registrant unless requested.
- domain.setContactFields(
- ImmutableSet.of(
- DesignatedContact.create(Type.REGISTRANT, contact1Key),
- DesignatedContact.create(Type.ADMIN, contact2Key),
- DesignatedContact.create(Type.BILLING, contact3Key),
- DesignatedContact.create(Type.TECH, contact4Key)),
- false);
- assertThat(domain.getRegistrant()).isEmpty();
- assertThat(domain.getAdminContact()).hasValue(contact2Key);
- assertThat(domain.getBillingContact()).hasValue(contact3Key);
- assertThat(domain.getTechContact()).hasValue(contact4Key);
- domain = domain.asBuilder().setRegistrant(Optional.of(contact1Key)).build();
- domain.setContactFields(ImmutableSet.of(), false);
- assertThat(domain.getRegistrant()).hasValue(contact1Key);
- assertThat(domain.getAdminContact()).isEmpty();
- assertThat(domain.getBillingContact()).isEmpty();
- assertThat(domain.getTechContact()).isEmpty();
- }
-
@Test
void testFail_currentBulkTokenWrongTokenType() {
AllocationToken allocationToken =
diff --git a/core/src/test/java/google/registry/rdap/RdapDomainActionTest.java b/core/src/test/java/google/registry/rdap/RdapDomainActionTest.java
index 1c665bf7f..651bd9c29 100644
--- a/core/src/test/java/google/registry/rdap/RdapDomainActionTest.java
+++ b/core/src/test/java/google/registry/rdap/RdapDomainActionTest.java
@@ -76,7 +76,7 @@ class RdapDomainActionTest extends RdapActionBaseTestCase {
makeAndPersistHost(
"ns2.cat.lol", "bad:f00d:cafe:0:0:0:15:beef", clock.nowUtc().minusYears(2));
persistResource(
- makeDomain("cat.lol", null, null, null, host1, host2, registrarLol)
+ makeDomain("cat.lol", host1, host2, registrarLol)
.asBuilder()
.setCreationTimeForTest(clock.nowUtc().minusYears(3))
.setCreationRegistrarId("TheRegistrar")
@@ -88,7 +88,7 @@ class RdapDomainActionTest extends RdapActionBaseTestCase {
"ns2.dodo.lol", "bad:f00d:cafe:0:0:0:15:beef", clock.nowUtc().minusYears(2));
Domain domainDeleted =
persistResource(
- makeDomain("dodo.lol", null, null, null, host1, hostDodo2, registrarLol)
+ makeDomain("dodo.lol", host1, hostDodo2, registrarLol)
.asBuilder()
.setCreationTimeForTest(clock.nowUtc().minusYears(3))
.setCreationRegistrarId("TheRegistrar")
@@ -100,7 +100,7 @@ class RdapDomainActionTest extends RdapActionBaseTestCase {
persistResource(makeRegistrar("idnregistrar", "IDN Registrar", Registrar.State.ACTIVE));
persistResources(makeRegistrarPocs(registrarIdn));
persistResource(
- makeDomain("cat.みんな", null, null, null, host1, host2, registrarIdn)
+ makeDomain("cat.みんな", host1, host2, registrarIdn)
.asBuilder()
.setCreationTimeForTest(clock.nowUtc().minusYears(3))
.setCreationRegistrarId("TheRegistrar")
@@ -113,7 +113,7 @@ class RdapDomainActionTest extends RdapActionBaseTestCase {
makeRegistrar("1tldregistrar", "Multilevel Registrar", Registrar.State.ACTIVE));
persistResources(makeRegistrarPocs(registrar1Tld));
persistResource(
- makeDomain("cat.1.tld", null, null, null, host1, host2, registrar1Tld)
+ makeDomain("cat.1.tld", host1, host2, registrar1Tld)
.asBuilder()
.setCreationTimeForTest(clock.nowUtc().minusYears(3))
.setCreationRegistrarId("TheRegistrar")
diff --git a/core/src/test/java/google/registry/rdap/RdapDomainSearchActionTest.java b/core/src/test/java/google/registry/rdap/RdapDomainSearchActionTest.java
index 36ddf1d1d..41ebef2bc 100644
--- a/core/src/test/java/google/registry/rdap/RdapDomainSearchActionTest.java
+++ b/core/src/test/java/google/registry/rdap/RdapDomainSearchActionTest.java
@@ -137,7 +137,7 @@ class RdapDomainSearchActionTest extends RdapSearchActionTestCase= 1; i--) {
String domainName = String.format("domain%d.lol", i);
Domain.Builder builder =
- makeDomain(domainName, null, null, null, null, null, registrar)
+ makeDomain(domainName, null, null, registrar)
.asBuilder()
.setNameservers(hostKeys)
.setCreationTimeForTest(clock.nowUtc().minusYears(3))
diff --git a/core/src/test/java/google/registry/rdap/RdapEntityActionTest.java b/core/src/test/java/google/registry/rdap/RdapEntityActionTest.java
index 28e55ed92..105ff2401 100644
--- a/core/src/test/java/google/registry/rdap/RdapEntityActionTest.java
+++ b/core/src/test/java/google/registry/rdap/RdapEntityActionTest.java
@@ -54,7 +54,7 @@ class RdapEntityActionTest extends RdapActionBaseTestCase {
persistResources(makeRegistrarPocs(registrarLol));
Host host1 = persistResource(makeHost("ns1.cat.lol", "1.2.3.4"));
Host host2 = persistResource(makeHost("ns2.cat.lol", "bad:f00d:cafe:0:0:0:15:beef"));
- persistResource(makeDomain("cat.lol", null, null, null, host1, host2, registrarLol));
+ persistResource(makeDomain("cat.lol", host1, host2, registrarLol));
// xn--q9jyb4c
createTld("xn--q9jyb4c");
Registrar registrarIdn = persistResource(
diff --git a/core/src/test/java/google/registry/rdap/RdapJsonFormatterTest.java b/core/src/test/java/google/registry/rdap/RdapJsonFormatterTest.java
index 896e0befe..8151d213f 100644
--- a/core/src/test/java/google/registry/rdap/RdapJsonFormatterTest.java
+++ b/core/src/test/java/google/registry/rdap/RdapJsonFormatterTest.java
@@ -114,9 +114,7 @@ class RdapJsonFormatterTest {
"ns5.cat.みんな", null, null, clock.nowUtc().minusYears(5), "unicoderegistrar");
// Create an unused domain that references hostBoth and hostNoAddresses so that
// they will have "associated" (ie, StatusValue.LINKED) status.
- Domain dog =
- persistResource(
- makeDomain("dog.みんな", null, null, null, hostBoth, hostNoAddresses, registrar));
+ Domain dog = persistResource(makeDomain("dog.みんな", hostBoth, hostNoAddresses, registrar));
hostSuperordinatePendingTransfer =
persistResource(
makeAndPersistHost(
@@ -142,14 +140,14 @@ class RdapJsonFormatterTest {
.build());
domainFull =
persistResource(
- makeDomain("cat.みんな", null, null, null, hostIpv4, hostIpv6, registrar)
+ makeDomain("cat.みんな", hostIpv4, hostIpv6, registrar)
.asBuilder()
.setCreationTimeForTest(clock.nowUtc().minusMonths(4))
.setLastEppUpdateTime(clock.nowUtc().minusMonths(3))
.build());
domainNoNameserversNoTransfers =
persistResource(
- makeDomain("fish.みんな", null, null, null, null, null, registrar)
+ makeDomain("fish.みんな", null, null, registrar)
.asBuilder()
.setCreationTimeForTest(clock.nowUtc())
.setLastEppUpdateTime(null)
diff --git a/core/src/test/java/google/registry/rdap/RdapNameserverSearchActionTest.java b/core/src/test/java/google/registry/rdap/RdapNameserverSearchActionTest.java
index 6175ef0ee..3d49f862b 100644
--- a/core/src/test/java/google/registry/rdap/RdapNameserverSearchActionTest.java
+++ b/core/src/test/java/google/registry/rdap/RdapNameserverSearchActionTest.java
@@ -131,7 +131,7 @@ class RdapNameserverSearchActionTest extends RdapSearchActionTestCase"), null);
- }
-
- public static Contact makeContact(
- String id, String name, @Nullable String email, @Nullable Registrar registrar) {
- return makeContact(
- id, name, email, ImmutableList.of("123 Example Boulevard