Class: AWSCDK::GameLift::CfnGameSessionQueue::PlayerLatencyPolicyProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::GameLift::CfnGameSessionQueue::PlayerLatencyPolicyProperty
- Defined in:
- game_lift/cfn_game_session_queue.rb
Overview
The queue setting that determines the highest latency allowed for individual players when placing a game session.
When a latency policy is in force, a game session cannot be placed with any fleet in a Region where a player reports latency higher than the cap. Latency policies are only enforced when the placement request contains player latency information.
Instance Attribute Summary collapse
-
#maximum_individual_player_latency_milliseconds ⇒ Numeric?
readonly
The maximum latency value that is allowed for any player, in milliseconds.
-
#policy_duration_seconds ⇒ Numeric?
readonly
The length of time, in seconds, that the policy is enforced while placing a new game session.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(maximum_individual_player_latency_milliseconds: nil, policy_duration_seconds: nil) ⇒ PlayerLatencyPolicyProperty
constructor
A new instance of PlayerLatencyPolicyProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(maximum_individual_player_latency_milliseconds: nil, policy_duration_seconds: nil) ⇒ PlayerLatencyPolicyProperty
Returns a new instance of PlayerLatencyPolicyProperty.
765 766 767 768 769 770 |
# File 'game_lift/cfn_game_session_queue.rb', line 765 def initialize(maximum_individual_player_latency_milliseconds: nil, policy_duration_seconds: nil) @maximum_individual_player_latency_milliseconds = maximum_individual_player_latency_milliseconds Jsii::Type.check_type(@maximum_individual_player_latency_milliseconds, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "maximumIndividualPlayerLatencyMilliseconds") unless @maximum_individual_player_latency_milliseconds.nil? @policy_duration_seconds = policy_duration_seconds Jsii::Type.check_type(@policy_duration_seconds, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "policyDurationSeconds") unless @policy_duration_seconds.nil? end |
Instance Attribute Details
#maximum_individual_player_latency_milliseconds ⇒ Numeric? (readonly)
The maximum latency value that is allowed for any player, in milliseconds.
All policies must have a value set for this property.
778 779 780 |
# File 'game_lift/cfn_game_session_queue.rb', line 778 def maximum_individual_player_latency_milliseconds @maximum_individual_player_latency_milliseconds end |
#policy_duration_seconds ⇒ Numeric? (readonly)
The length of time, in seconds, that the policy is enforced while placing a new game session.
A null value for this property means that the policy is enforced until the queue times out.
785 786 787 |
# File 'game_lift/cfn_game_session_queue.rb', line 785 def policy_duration_seconds @policy_duration_seconds end |
Class Method Details
.jsii_properties ⇒ Object
787 788 789 790 791 792 |
# File 'game_lift/cfn_game_session_queue.rb', line 787 def self.jsii_properties { :maximum_individual_player_latency_milliseconds => "maximumIndividualPlayerLatencyMilliseconds", :policy_duration_seconds => "policyDurationSeconds", } end |
Instance Method Details
#to_jsii ⇒ Object
794 795 796 797 798 799 800 801 |
# File 'game_lift/cfn_game_session_queue.rb', line 794 def to_jsii result = {} result.merge!({ "maximumIndividualPlayerLatencyMilliseconds" => @maximum_individual_player_latency_milliseconds, "policyDurationSeconds" => @policy_duration_seconds, }) result.compact end |