Package com.amazonaws.xray.entities
Class DummySubsegment
- java.lang.Object
-
- com.amazonaws.xray.entities.DummySubsegment
-
- All Implemented Interfaces:
Entity,Subsegment,java.lang.AutoCloseable
@Deprecated public class DummySubsegment extends java.lang.Object implements Subsegment
Deprecated.
-
-
Constructor Summary
Constructors Constructor Description DummySubsegment(AWSXRayRecorder creator)Deprecated.DummySubsegment(AWSXRayRecorder creator, TraceID traceId)Deprecated.DummySubsegment(AWSXRayRecorder creator, TraceID traceId, SamplingStrategyOverride samplingStrategyOverride)Deprecated.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description voidaddException(java.lang.Throwable exception)Deprecated.Adds an exception to the entity's cause and sets fault to true.voidaddPrecursorId(java.lang.String precursorId)Deprecated.voidaddSubsegment(Subsegment subsegment)Deprecated.Adds a subsegment.voidclose()Deprecated.Implements theAutoCloseableinterface.booleancompareAndSetEmitted(boolean current, boolean next)Deprecated.Checks whether thisEntitycurrently has emitted state ofcurrentand if so, set emitted state tonext.booleandecrementReferenceCount()Deprecated.Decrements the subsegment-reference counter.booleanend()Deprecated.Ends the subsegment.java.util.Map<java.lang.String,java.lang.Object>getAnnotations()Deprecated.java.util.Map<java.lang.String,java.lang.Object>getAws()Deprecated.CausegetCause()Deprecated.AWSXRayRecordergetCreator()Deprecated.doublegetEndTime()Deprecated.java.util.Map<java.lang.String,java.lang.Object>getHttp()Deprecated.java.lang.StringgetId()Deprecated.java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>>getMetadata()Deprecated.java.lang.StringgetName()Deprecated.java.lang.StringgetNamespace()Deprecated.EntitygetParent()Deprecated.java.lang.StringgetParentId()Deprecated.SegmentgetParentSegment()Deprecated.java.util.Set<java.lang.String>getPrecursorIds()Deprecated.intgetReferenceCount()Deprecated.Returns the reference count of the segment.SamplingStrategyOverridegetSamplingStrategyOverride()Deprecated.java.util.Map<java.lang.String,java.lang.Object>getSql()Deprecated.doublegetStartTime()Deprecated.java.util.List<Subsegment>getSubsegments()Deprecated.java.util.List<Subsegment>getSubsegmentsCopy()Deprecated.Returns a copy of the currently added subsegments.java.util.concurrent.locks.ReentrantLockgetSubsegmentsLock()Deprecated.java.util.concurrent.atomic.LongAddergetTotalSize()Deprecated.TraceIDgetTraceId()Deprecated.voidincrementReferenceCount()Deprecated.Increments the subsegment-reference counter.booleanisEmitted()Deprecated.booleanisError()Deprecated.booleanisFault()Deprecated.booleanisInProgress()Deprecated.booleanisRecording()Deprecated.booleanisSampled()Deprecated.booleanisThrottle()Deprecated.java.lang.StringprettySerialize()Deprecated.java.lang.StringprettyStreamSerialize()Deprecated.Pretty-serializes the subsegment as a standalone String with enough information for the subsegment to be streamed on its own.voidputAllAws(java.util.Map<java.lang.String,java.lang.Object> all)Deprecated.Puts AWS information.voidputAllHttp(java.util.Map<java.lang.String,java.lang.Object> all)Deprecated.Puts HTTP information.voidputAllSql(java.util.Map<java.lang.String,java.lang.Object> all)Deprecated.Puts SQL information.voidputAnnotation(java.lang.String key, java.lang.Boolean value)Deprecated.Puts a Boolean annotation.voidputAnnotation(java.lang.String key, java.lang.Number value)Deprecated.Puts a Number annotation.voidputAnnotation(java.lang.String key, java.lang.String value)Deprecated.Puts a String annotation.voidputAws(java.lang.String key, java.lang.Object value)Deprecated.Puts AWS information.voidputHttp(java.lang.String key, java.lang.Object value)Deprecated.Puts HTTP information.voidputMetadata(java.lang.String key, java.lang.Object object)Deprecated.Puts metadata under the namespace 'default'.voidputMetadata(java.lang.String namespace, java.lang.String key, java.lang.Object object)Deprecated.Puts metadata.voidputSql(java.lang.String key, java.lang.Object value)Deprecated.Puts SQL information.voidremoveSubsegment(Subsegment subsegment)Deprecated.Removes a subsegment from the subsegment list.java.lang.Stringserialize()Deprecated.voidsetAnnotations(java.util.Map<java.lang.String,java.lang.Object> annotations)Deprecated.voidsetAws(java.util.Map<java.lang.String,java.lang.Object> aws)Deprecated.voidsetCreator(AWSXRayRecorder creator)Deprecated.voidsetEmitted(boolean emitted)Deprecated.Sets emitted on the entity.voidsetEndTime(double endTime)Deprecated.voidsetError(boolean error)Deprecated.Sets the error value of the entity.voidsetFault(boolean fault)Deprecated.voidsetHttp(java.util.Map<java.lang.String,java.lang.Object> http)Deprecated.voidsetId(java.lang.String id)Deprecated.voidsetInProgress(boolean inProgress)Deprecated.voidsetMetadata(java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> metadata)Deprecated.voidsetNamespace(java.lang.String namespace)Deprecated.voidsetParent(Entity parent)Deprecated.voidsetParentId(@Nullable java.lang.String parentId)Deprecated.voidsetParentSegment(Segment parentSegment)Deprecated.voidsetPrecursorIds(java.util.Set<java.lang.String> precursorIds)Deprecated.voidsetSampledFalse()Deprecated.voidsetSql(java.util.Map<java.lang.String,java.lang.Object> sql)Deprecated.voidsetStartTime(double startTime)Deprecated.voidsetSubsegmentsLock(java.util.concurrent.locks.ReentrantLock subsegmentsLock)Deprecated.voidsetThrottle(boolean throttle)Deprecated.Sets the throttle value.voidsetTraceId(TraceID traceId)Deprecated.booleanshouldPropagate()Deprecated.Determines if this subsegment should propagate its trace context downstreamjava.lang.StringstreamSerialize()Deprecated.Serializes the subsegment as a standalone String with enough information for the subsegment to be streamed on its own.
-
-
-
Constructor Detail
-
DummySubsegment
public DummySubsegment(AWSXRayRecorder creator)
Deprecated.
-
DummySubsegment
public DummySubsegment(AWSXRayRecorder creator, TraceID traceId)
Deprecated.
-
DummySubsegment
@Deprecated public DummySubsegment(AWSXRayRecorder creator, TraceID traceId, SamplingStrategyOverride samplingStrategyOverride)
Deprecated.
-
-
Method Detail
-
getId
public java.lang.String getId()
Deprecated.
-
setId
public void setId(java.lang.String id)
Deprecated.
-
getStartTime
public double getStartTime()
Deprecated.- Specified by:
getStartTimein interfaceEntity- Returns:
- the startTime
-
setStartTime
public void setStartTime(double startTime)
Deprecated.- Specified by:
setStartTimein interfaceEntity- Parameters:
startTime- the startTime to set
-
getEndTime
public double getEndTime()
Deprecated.- Specified by:
getEndTimein interfaceEntity- Returns:
- the endTime
-
setEndTime
public void setEndTime(double endTime)
Deprecated.- Specified by:
setEndTimein interfaceEntity- Parameters:
endTime- the endTime to set
-
isFault
public boolean isFault()
Deprecated.
-
setFault
public void setFault(boolean fault)
Deprecated.
-
isError
public boolean isError()
Deprecated.
-
setError
public void setError(boolean error)
Deprecated.Description copied from interface:EntitySets the error value of the entity.
-
getNamespace
public java.lang.String getNamespace()
Deprecated.- Specified by:
getNamespacein interfaceEntity- Specified by:
getNamespacein interfaceSubsegment- Returns:
- the namespace
-
setNamespace
public void setNamespace(java.lang.String namespace)
Deprecated.- Specified by:
setNamespacein interfaceEntity- Specified by:
setNamespacein interfaceSubsegment- Parameters:
namespace- the namespace to set
-
getCause
public Cause getCause()
Deprecated.
-
getHttp
public java.util.Map<java.lang.String,java.lang.Object> getHttp()
Deprecated.
-
setHttp
public void setHttp(java.util.Map<java.lang.String,java.lang.Object> http)
Deprecated.
-
getAws
public java.util.Map<java.lang.String,java.lang.Object> getAws()
Deprecated.
-
setAws
public void setAws(java.util.Map<java.lang.String,java.lang.Object> aws)
Deprecated.
-
getSql
public java.util.Map<java.lang.String,java.lang.Object> getSql()
Deprecated.
-
setSql
public void setSql(java.util.Map<java.lang.String,java.lang.Object> sql)
Deprecated.
-
getMetadata
public java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> getMetadata()
Deprecated.- Specified by:
getMetadatain interfaceEntity- Returns:
- the metadata
-
setMetadata
public void setMetadata(java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> metadata)
Deprecated.- Specified by:
setMetadatain interfaceEntity- Parameters:
metadata- the metadata to set
-
setAnnotations
public void setAnnotations(java.util.Map<java.lang.String,java.lang.Object> annotations)
Deprecated.- Specified by:
setAnnotationsin interfaceEntity- Parameters:
annotations- the annotations to set
-
getParent
public Entity getParent()
Deprecated.
-
setParent
public void setParent(Entity parent)
Deprecated.
-
isThrottle
public boolean isThrottle()
Deprecated.- Specified by:
isThrottlein interfaceEntity- Returns:
- the throttle
-
setThrottle
public void setThrottle(boolean throttle)
Deprecated.Description copied from interface:EntitySets the throttle value. When setting to true, error is also set to true and fault set to false.- Specified by:
setThrottlein interfaceEntity- Parameters:
throttle- the throttle to set
-
isInProgress
public boolean isInProgress()
Deprecated.- Specified by:
isInProgressin interfaceEntity- Returns:
- the inProgress
-
setInProgress
public void setInProgress(boolean inProgress)
Deprecated.- Specified by:
setInProgressin interfaceEntity- Parameters:
inProgress- the inProgress to set
-
getTraceId
public TraceID getTraceId()
Deprecated.- Specified by:
getTraceIdin interfaceEntity- Returns:
- the traceId
-
setTraceId
public void setTraceId(TraceID traceId)
Deprecated.- Specified by:
setTraceIdin interfaceEntity- Parameters:
traceId- the traceId to set
-
getCreator
public AWSXRayRecorder getCreator()
Deprecated.- Specified by:
getCreatorin interfaceEntity- Returns:
- the creator
-
setCreator
public void setCreator(AWSXRayRecorder creator)
Deprecated.- Specified by:
setCreatorin interfaceEntity- Parameters:
creator- the creator to set
-
getParentId
public java.lang.String getParentId()
Deprecated.- Specified by:
getParentIdin interfaceEntity- Returns:
- the parentId
-
setParentId
public void setParentId(@Nullable java.lang.String parentId)
Deprecated.- Specified by:
setParentIdin interfaceEntity- Parameters:
parentId- the parentId to set
-
getSubsegments
public java.util.List<Subsegment> getSubsegments()
Deprecated.- Specified by:
getSubsegmentsin interfaceEntity- Returns:
- the subsegments
-
getSubsegmentsCopy
public java.util.List<Subsegment> getSubsegmentsCopy()
Deprecated.Description copied from interface:EntityReturns a copy of the currently added subsegments. Updates to the returnedListwill not be reflected in theEntity.- Specified by:
getSubsegmentsCopyin interfaceEntity
-
addSubsegment
public void addSubsegment(Subsegment subsegment)
Deprecated.Description copied from interface:EntityAdds a subsegment.- Specified by:
addSubsegmentin interfaceEntity- Parameters:
subsegment- the subsegment to add
-
addException
public void addException(java.lang.Throwable exception)
Deprecated.Description copied from interface:EntityAdds an exception to the entity's cause and sets fault to true.- Specified by:
addExceptionin interfaceEntity- Parameters:
exception- the exception to add
-
putHttp
public void putHttp(java.lang.String key, java.lang.Object value)Deprecated.Description copied from interface:EntityPuts HTTP information.
-
putAllHttp
public void putAllHttp(java.util.Map<java.lang.String,java.lang.Object> all)
Deprecated.Description copied from interface:EntityPuts HTTP information.- Specified by:
putAllHttpin interfaceEntity- Parameters:
all- the HTTP information to put
-
putAws
public void putAws(java.lang.String key, java.lang.Object value)Deprecated.Description copied from interface:EntityPuts AWS information.
-
putAllAws
public void putAllAws(java.util.Map<java.lang.String,java.lang.Object> all)
Deprecated.Description copied from interface:EntityPuts AWS information.
-
putSql
public void putSql(java.lang.String key, java.lang.Object value)Deprecated.Description copied from interface:EntityPuts SQL information.
-
putAllSql
public void putAllSql(java.util.Map<java.lang.String,java.lang.Object> all)
Deprecated.Description copied from interface:EntityPuts SQL information.
-
putAnnotation
public void putAnnotation(java.lang.String key, java.lang.String value)Deprecated.Description copied from interface:EntityPuts a String annotation.- Specified by:
putAnnotationin interfaceEntity- Parameters:
key- the key under which the annotation is storedvalue- the String annotation
-
putAnnotation
public void putAnnotation(java.lang.String key, java.lang.Number value)Deprecated.Description copied from interface:EntityPuts a Number annotation.- Specified by:
putAnnotationin interfaceEntity- Parameters:
key- the key under which the annotation is storedvalue- the Number annotation
-
putAnnotation
public void putAnnotation(java.lang.String key, java.lang.Boolean value)Deprecated.Description copied from interface:EntityPuts a Boolean annotation.- Specified by:
putAnnotationin interfaceEntity- Parameters:
key- the key under which the annotation is storedvalue- the Boolean annotation
-
putMetadata
public void putMetadata(java.lang.String key, java.lang.Object object)Deprecated.Description copied from interface:EntityPuts metadata under the namespace 'default'.- Specified by:
putMetadatain interfaceEntity- Parameters:
key- the key under which the metadata is storedobject- the metadata
-
putMetadata
public void putMetadata(java.lang.String namespace, java.lang.String key, java.lang.Object object)Deprecated.Description copied from interface:EntityPuts metadata.- Specified by:
putMetadatain interfaceEntity- Parameters:
namespace- the namespace under which the metadata is storedkey- the key under which the metadata is storedobject- the metadata
-
setEmitted
public void setEmitted(boolean emitted)
Deprecated.Description copied from interface:EntitySets emitted on the entity.- Specified by:
setEmittedin interfaceEntity
-
compareAndSetEmitted
public boolean compareAndSetEmitted(boolean current, boolean next)Deprecated.Description copied from interface:EntityChecks whether thisEntitycurrently has emitted state ofcurrentand if so, set emitted state tonext. Returnstrueif the state was updated, orfalseotherwise.- Specified by:
compareAndSetEmittedin interfaceEntity
-
serialize
public java.lang.String serialize()
Deprecated.
-
prettySerialize
public java.lang.String prettySerialize()
Deprecated.- Specified by:
prettySerializein interfaceEntity
-
end
public boolean end()
Deprecated.Description copied from interface:SubsegmentEnds the subsegment. Sets the end time to the current time. Sets inProgress to false. Decrements its parent segment's segment-reference counter.- Specified by:
endin interfaceSubsegment- Returns:
- true if 1) the parent segment now has a ref. count of zero and 2) the parent segment is sampled
-
getAnnotations
public java.util.Map<java.lang.String,java.lang.Object> getAnnotations()
Deprecated.- Specified by:
getAnnotationsin interfaceEntity- Returns:
- the annotations
-
getParentSegment
public Segment getParentSegment()
Deprecated.- Specified by:
getParentSegmentin interfaceEntity- Specified by:
getParentSegmentin interfaceSubsegment- Returns:
- the parentSegment
-
close
public void close()
Deprecated.Description copied from interface:SubsegmentImplements theAutoCloseableinterface. Warning. This method is intended to be private to the xray library and should not be used externally. Instead, useAWSXRay.endSubsegment(Subsegment).- Specified by:
closein interfacejava.lang.AutoCloseable- Specified by:
closein interfaceSubsegment
-
setParentSegment
public void setParentSegment(Segment parentSegment)
Deprecated.- Specified by:
setParentSegmentin interfaceSubsegment- Parameters:
parentSegment- the parentSegment to set
-
getPrecursorIds
public java.util.Set<java.lang.String> getPrecursorIds()
Deprecated.- Specified by:
getPrecursorIdsin interfaceSubsegment- Returns:
- the precursorIds
-
setPrecursorIds
public void setPrecursorIds(java.util.Set<java.lang.String> precursorIds)
Deprecated.- Specified by:
setPrecursorIdsin interfaceSubsegment- Parameters:
precursorIds- the precursorIds to set
-
addPrecursorId
public void addPrecursorId(java.lang.String precursorId)
Deprecated.- Specified by:
addPrecursorIdin interfaceSubsegment- Parameters:
precursorId- the precursor ID to add to the set
-
shouldPropagate
public boolean shouldPropagate()
Deprecated.Description copied from interface:SubsegmentDetermines if this subsegment should propagate its trace context downstream- Specified by:
shouldPropagatein interfaceSubsegment- Returns:
- true if its trace context should be propagated downstream, false otherwise
-
streamSerialize
public java.lang.String streamSerialize()
Deprecated.Description copied from interface:SubsegmentSerializes the subsegment as a standalone String with enough information for the subsegment to be streamed on its own.- Specified by:
streamSerializein interfaceSubsegment- Returns:
- the string representation of the subsegment with enough information for it to be streamed
-
prettyStreamSerialize
public java.lang.String prettyStreamSerialize()
Deprecated.Description copied from interface:SubsegmentPretty-serializes the subsegment as a standalone String with enough information for the subsegment to be streamed on its own. Only used for debugging.- Specified by:
prettyStreamSerializein interfaceSubsegment- Returns:
- the pretty string representation of the subsegment with enough information for it to be streamed
-
getSubsegmentsLock
public java.util.concurrent.locks.ReentrantLock getSubsegmentsLock()
Deprecated.- Specified by:
getSubsegmentsLockin interfaceEntity- Returns:
- the subsegmentsLock
-
setSubsegmentsLock
public void setSubsegmentsLock(java.util.concurrent.locks.ReentrantLock subsegmentsLock)
Deprecated.- Specified by:
setSubsegmentsLockin interfaceEntity- Parameters:
subsegmentsLock- the subsegmentsLock to set
-
getReferenceCount
public int getReferenceCount()
Deprecated.Description copied from interface:EntityReturns the reference count of the segment. This number represents how many open subsegments are children of this segment. The segment is emitted when its reference count reaches 0.- Specified by:
getReferenceCountin interfaceEntity- Returns:
- the reference count
-
getTotalSize
public java.util.concurrent.atomic.LongAdder getTotalSize()
Deprecated.- Specified by:
getTotalSizein interfaceEntity- Returns:
- the totalSize
-
incrementReferenceCount
public void incrementReferenceCount()
Deprecated.Description copied from interface:EntityIncrements the subsegment-reference counter.- Specified by:
incrementReferenceCountin interfaceEntity
-
decrementReferenceCount
public boolean decrementReferenceCount()
Deprecated.Description copied from interface:EntityDecrements the subsegment-reference counter.- Specified by:
decrementReferenceCountin interfaceEntity- Returns:
- true if the segment is no longer in progress and the reference count is less than or equal to zero.
-
removeSubsegment
public void removeSubsegment(Subsegment subsegment)
Deprecated.Description copied from interface:EntityRemoves a subsegment from the subsegment list. Decrements the total size of the parentSegment. Marks the removed subsegment as emitted future modification on this subsegment may raise an AlreadyEmittedException.- Specified by:
removeSubsegmentin interfaceEntity- Parameters:
subsegment- the subsegment to remove
-
isRecording
public boolean isRecording()
Deprecated.- Specified by:
isRecordingin interfaceSubsegment
-
setSampledFalse
public void setSampledFalse()
Deprecated.- Specified by:
setSampledFalsein interfaceSubsegment
-
getSamplingStrategyOverride
@Deprecated public SamplingStrategyOverride getSamplingStrategyOverride()
Deprecated.- Specified by:
getSamplingStrategyOverridein interfaceSubsegment
-
-