Class SamplingResponse

java.lang.Object
com.amazonaws.xray.strategy.sampling.SamplingResponse

public class SamplingResponse
extends java.lang.Object
Represents the sampling decision output by the sampler. Used by the SDK to decide whether or not a segment should be emitted.
  • Constructor Summary

    Constructors 
    Constructor Description
    SamplingResponse()  
    SamplingResponse​(boolean sampled)  
    SamplingResponse​(boolean sampled, java.lang.String ruleName)  
    SamplingResponse​(java.lang.String ruleName)  
  • Method Summary

    Modifier and Type Method Description
    java.util.Optional<java.lang.String> getRuleName()  
    boolean isSampled()  
    SamplingResponse setSampled​(boolean sampled)  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • SamplingResponse

      public SamplingResponse​(boolean sampled, java.lang.String ruleName)
      Parameters:
      sampled - the boolean sampling decision
      ruleName - the name of the rule used to make the sampling decision
    • SamplingResponse

      public SamplingResponse​(java.lang.String ruleName)
    • SamplingResponse

      public SamplingResponse​(boolean sampled)
    • SamplingResponse

      public SamplingResponse()
  • Method Details