google-nomulus/java/google/registry/tools
cgoldfeder 5098b03af4 DeReference the codebase
This change replaces all Ref objects in the code with Key objects. These are
stored in datastore as the same object (raw datastore keys), so this is not
a model change.

Our best practices doc says to use Keys not Refs because:
 * The .get() method obscures what's actually going on
   - Much harder to visually audit the code for datastore loads
   - Hard to distinguish Ref<T> get()'s from Optional get()'s and Supplier get()'s
 * Implicit ofy().load() offers much less control
   - Antipattern for ultimate goal of making Ofy injectable
   - Can't control cache use or batch loading without making ofy() explicit anyway
 * Serialization behavior is surprising and could be quite dangerous/incorrect
   - Can lead to serialization errors. If it actually worked "as intended",
     it would lead to a Ref<> on a serialized object being replaced upon
     deserialization with a stale copy of the old value, which could potentially
     break all kinds of transactional expectations
 * Having both Ref<T> and Key<T> introduces extra boilerplate everywhere
   - E.g. helper methods all need to have Ref and Key overloads, or you need to
     call .key() to get the Key<T> for every Ref<T> you want to pass in
   - Creating a Ref<T> is more cumbersome, since it doesn't have all the create()
     overloads that Key<T> has, only create(Key<T>) and create(Entity) - no way to
     create directly from kind+ID/name, raw Key, websafe key string, etc.

(Note that Refs are treated specially by Objectify's @Load method and Keys are not;
we don't use that feature, but it is the one advantage Refs have over Keys.)

The direct impetus for this change is that I am trying to audit our use of memcache,
and the implicit .get() calls to datastore were making that very hard.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=131965491
2016-09-02 13:50:20 -04:00
..
javascrap Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
params Add LRP TLD states to Registry and *_tld tools 2016-08-05 20:41:11 -04:00
server DeReference the codebase 2016-09-02 13:50:20 -04:00
soy Rename soy templates to use consistent naming scheme 2016-08-22 14:48:40 -04:00
sql Add --set_current_tld_state to UpdateTldCommand 2016-08-02 19:02:19 -04:00
AllocateDomainCommand.java DeReference the codebase 2016-09-02 13:50:20 -04:00
AppEngineConnection.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
AuctionStatusCommand.java DeReference the codebase 2016-09-02 13:50:20 -04:00
BigqueryCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
BigqueryCommandUtilities.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
BigqueryParameters.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
BUILD Add gtech_tool target to tools BUILD 2016-08-22 14:16:12 -04:00
CanonicalizeLabelsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
CheckSnapshotCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
Command.java Make javadoc <p> style guide compliant 2016-05-18 13:09:01 -04:00
CommandUtilities.java Replace to(Upper|Lower)Case with Ascii.to$1Case 2016-07-19 10:43:38 -04:00
ConfirmingCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
ConvertIdnCommand.java Replace to(Upper|Lower)Case with Ascii.to$1Case 2016-07-19 10:43:38 -04:00
CreateAnchorTenantCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
CreateAuctionCreditsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
CreateContactCommand.java Rename soy templates to use consistent naming scheme 2016-08-22 14:48:40 -04:00
CreateCreditBalanceCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
CreateCreditCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
CreateDomainCommand.java Rename soy templates to use consistent naming scheme 2016-08-22 14:48:40 -04:00
CreateHostCommand.java Add registry_tool host_create command 2016-08-22 14:45:54 -04:00
CreateOrUpdatePremiumListCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
CreateOrUpdateRegistrarCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
CreateOrUpdateReservedListCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
CreateOrUpdateTldCommand.java Fix NPE in registry_tool when creating or updating a TLD with a dns writer 2016-08-15 16:48:20 -04:00
CreatePremiumListCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
CreateRegistrarCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
CreateRegistrarGroupsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
CreateReservedListCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
CreateSandboxTldCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
CreateTldCommand.java Add --set_current_tld_state to UpdateTldCommand 2016-07-21 17:54:41 -04:00
DeleteCreditCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
DeleteDomainCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
DeleteEntityCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
DeleteEppResourceCommand.java DeReference the codebase 2016-09-02 13:50:20 -04:00
DeletePremiumListCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
DeleteReservedListCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
DomainApplicationInfoCommand.java Replace to(Upper|Lower)Case with Ascii.to$1Case 2016-07-19 10:43:38 -04:00
DomainCheckClaimsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
DomainCheckCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
DomainCheckFeeCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
EncryptEscrowDepositCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
EppToolCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
EscrowDepositEncryptor.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
ExecuteEppCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GenerateApplicationsReportCommand.java DeReference the codebase 2016-09-02 13:50:20 -04:00
GenerateAuctionDataCommand.java DeReference the codebase 2016-09-02 13:50:20 -04:00
GenerateDnsReportCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GenerateEscrowDepositCommand.java DeReference the codebase 2016-09-02 13:50:20 -04:00
GenerateLordnCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GenerateZoneFilesCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GetApplicationCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GetApplicationIdsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GetAppliedLabelsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GetClaimsListCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GetContactCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GetDomainCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GetEppResourceCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GetHistoryEntriesCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GetHostCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GetLrpTokenCommand.java Swap id and indexed field in LrpToken 2016-08-15 16:39:03 -04:00
GetRegistrarCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GetResourceByKeyCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GetSchemaCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GetSchemaTreeCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GetTldCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GhostrydeCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
GtechTool.java Add registry_tool host_create command 2016-08-22 14:45:54 -04:00
HashCertificateCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
HelpCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
Injector.java Rename Java packages to use the .google TLD 2016-05-13 20:04:42 -04:00
ListCreditsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
ListCursorsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
ListDomainsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
ListHostsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
ListObjectsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
ListPremiumListsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
ListRegistrarsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
ListReservedListsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
ListTldsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
LoadSnapshotCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
logging.properties mv com/google/domain/registry google/registry 2016-05-13 18:55:08 -04:00
LoggingParameters.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
MakeBillingTablesCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
MutatingCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
MutatingEppToolCommand.java Add a throw-away tool to remove IP addresses of external hosts 2016-05-13 23:17:26 -04:00
package-info.java Rename Java packages to use the .google TLD 2016-05-13 20:04:42 -04:00
PasswordGenerator.java Rename Java packages to use the .google TLD 2016-05-13 20:04:42 -04:00
PendingEscrowCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
PublishDetailReportCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
RandomPasswordGenerator.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
RegistrarActivityReportCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
RegistrarContactCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
RegistryCli.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
RegistryTool.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
RegistryToolComponent.java Add create_domain command to gtech_tool 2016-08-15 16:53:01 -04:00
RegistryToolEnvironment.java Replace to(Upper|Lower)Case with Ascii.to$1Case 2016-07-19 10:43:38 -04:00
RegistryToolModule.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
ResaveEnvironmentEntitiesCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
SendEscrowReportToIcannCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
ServerSideCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
SetupOteCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
UniformRapidSuspensionCommand.java DeReference the codebase 2016-09-02 13:50:20 -04:00
UpdateApplicationStatusCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
UpdateClaimsNoticeCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
UpdateCreditsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
UpdateCursorsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
UpdatePremiumListCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
UpdateRegistrarCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
UpdateReservedListCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
UpdateSandboxTldCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
UpdateServerLocksCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
UpdateSmdCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
UpdateTldCommand.java Add --set_current_tld_state to UpdateTldCommand 2016-07-21 17:54:41 -04:00
UploadClaimsListCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
UserIdProvider.java Rename Java packages to use the .google TLD 2016-05-13 20:04:42 -04:00
ValidateEscrowDepositCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
ValidateLoginCredentialsCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
VerifyOteCommand.java Convert entire project to strict lexicographical import sort ordering 2016-07-13 15:59:53 -04:00
WhoisQueryCommand.java Add WHOIS disclaimer text to ConfigModule 2016-07-21 14:55:38 -04:00