Commit graph

8 commits

Author SHA1 Message Date
mcilwain
f8b4c9eddb Add extensible custom logic to domain application create flow
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=140656367
2016-12-06 11:52:46 -05:00
jianglai
99c16dc345 Make domain pricing customizable
By refactoring TldSpecificLogicProxy (and renaming it to DomainPricingLogic) into
a FlowScope object that is injected into each flow, we can further inject a
DomainPricingCustomLogic into the pricer, which has hooks into each pricing
calls, e. g. getCreatePrice(), getRenewPrice(), etc.

The benefit of these customization hooks is that methods like getCreatePrice()
get called in multiple flows, such as DomainAllocateFlow,
DomainApplicationCreateFlow, and DomainCreateFlow. By customizing the return
value of getCreatePrice() itself, all of its callers gets the amended price.

This CL only includes the basic infrastructure needed, with no actual hooks
placed into each flow.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=140616990
2016-12-06 11:52:46 -05:00
jianglai
b35ac10b7e Add extensible custom logic to the domain delete flow
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=140534389
2016-12-06 11:52:46 -05:00
jianglai
9a616ccd7f Add extensible custom logic to the domain renew flow
This also adds a TODO in DomainCheckFlow to document the fact that as-of date is not overridden when passed to the custom logic.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=140031318
2016-11-28 11:32:47 -05:00
jianglai
998dae33ec Add extensible custom logic to the domain update flow
This also adds beforeValidation hook to DomainCreateCustomFlow.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=139828346
2016-11-28 11:28:16 -05:00
jianglai
2d85ec9aa3 Add extensible custom logic to the domain info flow
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=139584129
2016-11-28 11:26:42 -05:00
mcilwain
a343648b34 Add extensible custom logic to the domain check flow
This also fixes up a hook on the domain create flow custom logic to use a single
parameter, which is the general pattern we want to use going forward. It also
establishes a pattern for custom logic being able to add extensions.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=139362230
2016-11-16 17:06:43 -05:00
mcilwain
4d2e0941f3 Add a custom logic framework to provide pluggable extensibility
To add additional logic for flow code, write custom classes that extend the existing custom logic classes (of which DomainCreateFlowCustomLogic is the first provided example), along with a class that extends CustomLogicFactory to provide instances of the new custom logic classes. Then configure the fully qualified class name of your new custom logic factory in ConfigModule.provideCustomLogicFactoryClass().

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=139221577
2016-11-15 15:19:32 -05:00