Class ServerConfiguration


  • public class ServerConfiguration
    extends java.lang.Object
    Configuration class storing all configuration parameters as returned by Dynatrace.
    • Method Detail

      • from

        public static ServerConfiguration from​(ResponseAttributes responseAttributes)
        Creates a new server configuration from the given ResponseAttributes
        Parameters:
        responseAttributes - the response attributes from which to create the server configuration.
        Returns:
        the newly created server configuration.
      • isCaptureEnabled

        public boolean isCaptureEnabled()
        Get a boolean indicating whether capturing is enabled in Dynatrace or not.
        Returns:
        true if capturing is enabled, false otherwise.
      • isCrashReportingEnabled

        public boolean isCrashReportingEnabled()
        Get a boolean indicating whether crash reporting is enabled in Dynatrace or not.
        Returns:
        true if crash reporting is enabled, false otherwise.
      • isErrorReportingEnabled

        public boolean isErrorReportingEnabled()
        Get a boolean indicating whether error reporting is enabled in Dynatrace or not.
        Returns:
        true if error reporting is enabled, false otherwise.
      • getServerID

        public int getServerID()
        Get the server's id to communicate with.
        Returns:
        Server ID to communicate with
      • getBeaconSizeInBytes

        public int getBeaconSizeInBytes()
        Get the maximum beacon size, that is the post body, in bytes.
        Returns:
        Maximum beacon size in bytes.
      • getMultiplicity

        public int getMultiplicity()
        Get multiplicity value.

        Multiplicity is a factor on the server side, which is greater than 1 to prevent overload situations. This value comes from the server and has to be sent back to the server.

        Returns:
        Multiplicity factor
      • getSendIntervalInMilliseconds

        public int getSendIntervalInMilliseconds()
        Returns the send interval in milliseconds.
        Returns:
        send interval in milliseconds.
      • getMaxSessionDurationInMilliseconds

        public int getMaxSessionDurationInMilliseconds()
        Returns the maximum duration in milliseconds after which a session is to be split.
        Returns:
        the maximum duration of a session in milliseconds.
      • isSessionSplitBySessionDurationEnabled

        public boolean isSessionSplitBySessionDurationEnabled()
        Returns true if session splitting when exceeding the maximum session duration is enabled, false otherwise.
      • getMaxEventsPerSession

        public int getMaxEventsPerSession()
        Returns the maximum number of events after which a session is to be split.
        Returns:
        the maximum number of top level actions per session.
      • isSessionSplitByEventsEnabled

        public boolean isSessionSplitByEventsEnabled()
        Returns true if session splitting when exceeding the maximum number of events is enabled, false otherwise.
      • getSessionTimeoutInMilliseconds

        public int getSessionTimeoutInMilliseconds()
        Returns the idle timeout after which a session is to be split.
        Returns:
        the idle timeout of a session.
      • isSessionSplitByIdleTimeoutEnabled

        public boolean isSessionSplitByIdleTimeoutEnabled()
        Returns true if session splitting by exceeding the idle timeout is enabled, false otherwise.
      • getVisitStoreVersion

        public int getVisitStoreVersion()
        Returns the version of the visit store that should be used.
        Returns:
        version of the visit store.
      • getTrafficControlPercentage

        public int getTrafficControlPercentage()
        Returns a percentage value that is used for session rate limiting.
        Returns:
        percentage of sessions to be captured.
      • isSendingDataAllowed

        public boolean isSendingDataAllowed()
        Get a boolean indicating whether sending arbitrary data to the server is allowed or not.

        Sending data is only allowed if all of the following conditions evaluate to true. * isCaptureEnabled() is true * getMultiplicity() is greater than 0 To check if sending errors is allowed, use isSendingErrorsAllowed(). To check if sending crashes is allowed, use isSendingCrashesAllowed().

        Returns:
        true if data sending is allowed, false otherwise.
      • isSendingCrashesAllowed

        public boolean isSendingCrashesAllowed()
        Get a boolean indicating whether sending crashes to the server is allowed or not.

        Sending crashes is only allowed if all of the following conditions evaluate to true. * isSendingDataAllowed() yields true * isCrashReportingEnabled() is true

        Returns:
        true if sending crashes is allowed, false otherwise.
      • isSendingErrorsAllowed

        public boolean isSendingErrorsAllowed()
        Get a boolean indicating whether sending errors to the server is allowed or not.

        Sending errors is only allowed if all of the following conditions evaluate to true. * isSendingDataAllowed() yields true * isErrorReportingEnabled() is true

        Returns:
        true if sending errors is allowed, false otherwise.