Repository: brooklyn-docs Updated Branches: refs/heads/master 4e997d5c2 -> c3d5e1bfd
Add docs for Scheduled and PeriodicEffectorPolicy Project: http://git-wip-us.apache.org/repos/asf/brooklyn-docs/repo Commit: http://git-wip-us.apache.org/repos/asf/brooklyn-docs/commit/91484a67 Tree: http://git-wip-us.apache.org/repos/asf/brooklyn-docs/tree/91484a67 Diff: http://git-wip-us.apache.org/repos/asf/brooklyn-docs/diff/91484a67 Branch: refs/heads/master Commit: 91484a67e416242797b604e01b6d1c6da48ba8bd Parents: 4e997d5 Author: Duncan Godwin <[email protected]> Authored: Thu Sep 14 14:41:40 2017 +0100 Committer: Duncan Godwin <[email protected]> Committed: Thu Sep 14 16:48:48 2017 +0100 ---------------------------------------------------------------------- guide/blueprints/policies.md | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/brooklyn-docs/blob/91484a67/guide/blueprints/policies.md ---------------------------------------------------------------------- diff --git a/guide/blueprints/policies.md b/guide/blueprints/policies.md index 517b3b2..f305770 100644 --- a/guide/blueprints/policies.md +++ b/guide/blueprints/policies.md @@ -100,6 +100,39 @@ The ConnectionFailureDetector is an HA policy for monitoring an http connection, ### Optimization Policies +#### PeriodicEffector Policy + +- org.apache.brooklyn.policy.action.PeriodicEffectorPolicy + +The `PeriodicEffectorPolicy` calls an effector with a set of arguments at a specified time and date. The following example +calls a `resize` effector to resize a cluster up to 10 members at 8am and then down to 1 member at 6pm. + + - type: org.apache.brooklyn.policy.action.PeriodicEffectorPolicy + brooklyn.config: + effector: resize + args: + desiredSize: 10 + period: 1 day + time: 08:00:00 + - type: org.apache.brooklyn.policy.action.PeriodicEffectorPolicy + brooklyn.config: + effector: resize + args: + desiredSize: 1 + period: 1 day + time: 18:00:00 + +#### ScheduledEffector Policy + +- org.apache.brooklyn.policy.action.ScheduledEffectorPolicy + +The `ScheduledEffectorPolicy` calls an effector after a specified interval has expired. The interval can be triggered from a sensor, `SERVICE_UP` by default. +The following example calls a `backup` effector every night at midnight. + + - type: org.apache.brooklyn.policy.action.ScheduledEffectorPolicy + brooklyn.config: + effector: backup + time: 00:00:00 #### FollowTheSun Policy
