public class NoOpTransaction extends java.lang.Object implements Transaction
Constructor and Description |
---|
NoOpTransaction() |
Modifier and Type | Method and Description |
---|---|
void |
close()
No-op
|
void |
collectData(java.lang.String key,
java.lang.String value,
java.util.Set<DataScope> dataScopes)
No-op
|
void |
end()
No-op
|
void |
endSegment()
No-op
|
java.util.Map<java.lang.String,java.lang.String> |
getEumMetadata()
No-op
|
java.lang.String |
getUniqueIdentifier()
Returns an empty string
|
boolean |
isAsyncTransaction()
Returns false
|
void |
markAsError(java.lang.String errorMessage)
No-op
|
void |
markHandoff(java.lang.Object commonObject)
No-op
|
ExitCall |
startExitCall(java.util.Map<java.lang.String,java.lang.String> uniquePropertiesIdentifier,
java.lang.String displayName,
java.lang.String exitType,
boolean async)
Returns a
NoOpExitCall object |
ExitCall |
startExitCall(java.lang.String uniquePropertiesIdentifier,
java.lang.String displayName,
java.lang.String exitType,
boolean async)
Returns a
NoOpExitCall object |
ExitCall |
startHttpExitCall(java.util.Map<java.lang.String,java.lang.String> uniquePropertiesIdentifier,
java.net.URL url,
boolean async)
Declares the start of an http exit call.
|
public void end()
end
in interface Transaction
public ExitCall startExitCall(java.lang.String uniquePropertiesIdentifier, java.lang.String displayName, java.lang.String exitType, boolean async)
NoOpExitCall
objectstartExitCall
in interface Transaction
uniquePropertiesIdentifier
- A String
unique to this exit call (can be the same between requests)displayName
- The display name of exit callexitType
- Specifies the exit type. If this is null, then it is treated as a custom exit.
For supported types, refer ExitTypes
. For example, HTTP.async
- Specifies if the exit call is asynchronousNoOpExitCall
objectpublic ExitCall startExitCall(java.util.Map<java.lang.String,java.lang.String> uniquePropertiesIdentifier, java.lang.String displayName, java.lang.String exitType, boolean async)
NoOpExitCall
objectstartExitCall
in interface Transaction
uniquePropertiesIdentifier
- A map of key/value pairs used to aggregate exit calls together to the same placedisplayName
- The display name of exit callexitType
- Specifies the exit type. If this is null, then it is treated as a custom exit.
For supported types, refer ExitTypes
. For example, HTTP.async
- Specifies if the exit call is asynchronousNoOpExitCall
objectpublic ExitCall startHttpExitCall(java.util.Map<java.lang.String,java.lang.String> uniquePropertiesIdentifier, java.net.URL url, boolean async)
Transaction
Note: This returns a no-op IExitCall if called when an exit call already exists, or if it is otherwise unable to start a new exit call.
startHttpExitCall
in interface Transaction
uniquePropertiesIdentifier
- A map of key/value pairs used to aggregate exit calls together to the same placeurl
- The url of the exitasync
- Specifies if the exit call is asynchronousExitCall
object to represent the exit callpublic void markHandoff(java.lang.Object commonObject)
markHandoff
in interface Transaction
commonObject
- A unique common object to link the start and execution of the asynchronous handoff.public void markAsError(java.lang.String errorMessage)
markAsError
in interface Transaction
errorMessage
- The message to associate with the error object created.public void endSegment()
endSegment
in interface Transaction
public java.lang.String getUniqueIdentifier()
getUniqueIdentifier
in interface Transaction
String
public boolean isAsyncTransaction()
isAsyncTransaction
in interface Transaction
public void close()
close
in interface Transaction
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
public void collectData(java.lang.String key, java.lang.String value, java.util.Set<DataScope> dataScopes)
collectData
in interface Transaction
key
- The String
keyvalue
- The String
valuedataScopes
- A set of DataScopes specifying everywhere the data must be addedpublic java.util.Map<java.lang.String,java.lang.String> getEumMetadata()
getEumMetadata
in interface Transaction