Class IgniteCommonsSystemProperties

  • Direct Known Subclasses:
    IgniteSystemProperties

    public class IgniteCommonsSystemProperties
    extends Object
    Contains constants for all common system properties and environmental variables in Ignite. These properties and variables can be used to affect the behavior of Ignite.
    • Field Detail

      • IGNITE_TO_STRING_INCLUDE_SENSITIVE

        @SystemProperty(value="Enables writing sensitive information in toString() output",
                        defaults="true")
        public static final String IGNITE_TO_STRING_INCLUDE_SENSITIVE
        Setting to true enables writing sensitive information in toString() output.
        See Also:
        Constant Field Values
      • IGNITE_MEMORY_PER_BYTE_COPY_THRESHOLD

        @SystemProperty(value="When unsafe memory copy if performed below this threshold, Ignite will do it on per-byte basis instead of calling to Unsafe.copyMemory(). 0 disables threshold",
                        type=java.lang.Long.class,
                        defaults="0")
        public static final String IGNITE_MEMORY_PER_BYTE_COPY_THRESHOLD
        When unsafe memory copy if performed below this threshold, Ignite will do it on per-byte basis instead of calling to Unsafe.copyMemory().

        Defaults to 0, meaning that threshold is disabled.

        See Also:
        Constant Field Values
      • IGNITE_MEMORY_UNALIGNED_ACCESS

        @SystemProperty("Whether Ignite can access unaligned memory addresses. Defaults to false, meaning that unaligned access will be performed only on x86 architecture")
        public static final String IGNITE_MEMORY_UNALIGNED_ACCESS
        Whether Ignite can access unaligned memory addresses.

        Defaults to false, meaning that unaligned access will be performed only on x86 architecture.

        See Also:
        Constant Field Values
      • IGNITE_MARSHAL_BUFFERS_RECHECK

        @SystemProperty(value="How often in milliseconds marshal buffers should be rechecked and potentially trimmed",
                        type=java.lang.Long.class,
                        defaults="10000")
        public static final String IGNITE_MARSHAL_BUFFERS_RECHECK
        System property to specify how often in milliseconds marshal buffers should be rechecked and potentially trimmed. Default value is 10,000ms.
        See Also:
        Constant Field Values
      • IGNITE_OPTIMIZED_MARSHALLER_USE_DEFAULT_SUID

        @SystemProperty("Manages OptimizedMarshaller behavior of serialVersionUID computation for Serializable classes")
        public static final String IGNITE_OPTIMIZED_MARSHALLER_USE_DEFAULT_SUID
        Manages OptimizedMarshaller behavior of serialVersionUID computation for Serializable classes.
        See Also:
        Constant Field Values
      • IGNITE_DEV_ONLY_LOGGING_DISABLED

        @SystemProperty("Enables development environments warnings")
        public static final String IGNITE_DEV_ONLY_LOGGING_DISABLED
        When set to true, warnings that are intended for development environments and not for production (such as coding mistakes in code using Ignite) will not be logged.
        See Also:
        Constant Field Values
      • IGNITE_BINARY_MARSHALLER_USE_STRING_SERIALIZATION_VER_2

        @SystemProperty("Manages type of serialization mechanism for String that is marshalled/unmarshalled by BinaryMarshaller. Should be used for cases when a String contains a surrogate symbol without its pair one. This is frequently used in algorithms that encrypts data in String format")
        public static final String IGNITE_BINARY_MARSHALLER_USE_STRING_SERIALIZATION_VER_2
        Manages type of serialization mechanism for String that is marshalled/unmarshalled by BinaryMarshaller. Should be used for cases when a String contains a surrogate symbol without its pair one. This is frequently used in algorithms that encrypts data in String format.
        See Also:
        Constant Field Values
      • IGNITE_USE_BINARY_ARRAYS

        @SystemProperty(value="Flag to enable store of array in binary format and keep component type",
                        defaults="false")
        public static final String IGNITE_USE_BINARY_ARRAYS
        Enables storage of typed arrays. The default value is BinaryUtils#DFLT_IGNITE_USE_BINARY_ARRAYS.
        See Also:
        Constant Field Values
      • IGNITE_BINARY_SORT_OBJECT_FIELDS

        @SystemProperty("Enables fields to be written by BinaryMarshaller in sorted order. By default, the natural order is used")
        public static final String IGNITE_BINARY_SORT_OBJECT_FIELDS
        When set to true fields are written by BinaryMarshaller in sorted order. Otherwise the natural order is used.

        NOTICE: Should be the default in Apache Ignite 3.0

        See Also:
        Constant Field Values
      • IGNITE_OFFHEAP_SAFE_RELEASE

        @SystemProperty("Force Ignite to fill memory block with some recognisable pattern right before this memory block is released. This will help to recognize cases when already released memory is accessed")
        public static final String IGNITE_OFFHEAP_SAFE_RELEASE
        Flag that will force Ignite to fill memory block with some recognisable pattern right before this memory block is released. This will help to recognize cases when already released memory is accessed.
        See Also:
        Constant Field Values
    • Constructor Detail

      • IgniteCommonsSystemProperties

        public IgniteCommonsSystemProperties()
    • Method Detail

      • getEnum

        public static <E extends Enum<E>> E getEnum​(Class<E> enumCls,
                                                    String name)
        Type Parameters:
        E - Type of the enum.
        Parameters:
        enumCls - Enum type.
        name - Name of the system property or environment variable.
        Returns:
        Enum value or null if the property is not set.
      • getEnum

        public static <E extends Enum<E>> E getEnum​(String name,
                                                    E dflt)
        Type Parameters:
        E - Type of the enum.
        Parameters:
        name - Name of the system property or environment variable.
        dflt - Default value if property is not set.
        Returns:
        Enum value or the given default.
      • getString

        @Nullable
        public static @Nullable String getString​(String name)
        Gets either system property or environment variable with given name.
        Parameters:
        name - Name of the system property or environment variable.
        Returns:
        Value of the system property or environment variable. Returns null if neither can be found for given name.
      • getString

        @Nullable
        public static @Nullable String getString​(String name,
                                                 String dflt)
        Gets either system property or environment variable with given name.
        Parameters:
        name - Name of the system property or environment variable.
        dflt - Default value.
        Returns:
        Value of the system property or environment variable. Returns null if neither can be found for given name.
      • getBoolean

        public static boolean getBoolean​(String name)
        Gets either system property or environment variable with given name. The result is transformed to boolean using Boolean.valueOf() method.
        Parameters:
        name - Name of the system property or environment variable.
        Returns:
        Boolean value of the system property or environment variable. Returns False in case neither system property nor environment variable with given name is found.
      • getBoolean

        public static boolean getBoolean​(String name,
                                         boolean dflt)
        Gets either system property or environment variable with given name. The result is transformed to boolean using Boolean.valueOf() method.
        Parameters:
        name - Name of the system property or environment variable.
        dflt - Default value.
        Returns:
        Boolean value of the system property or environment variable. Returns default value in case neither system property nor environment variable with given name is found.
      • getInteger

        public static int getInteger​(String name,
                                     int dflt)
        Gets either system property or environment variable with given name. The result is transformed to int using Integer.parseInt() method.
        Parameters:
        name - Name of the system property or environment variable.
        dflt - Default value.
        Returns:
        Integer value of the system property or environment variable. Returns default value in case neither system property nor environment variable with given name is found.
      • getFloat

        public static float getFloat​(String name,
                                     float dflt)
        Gets either system property or environment variable with given name. The result is transformed to float using Float.parseFloat() method.
        Parameters:
        name - Name of the system property or environment variable.
        dflt - Default value.
        Returns:
        Float value of the system property or environment variable. Returns default value in case neither system property nor environment variable with given name is found.
      • getLong

        public static long getLong​(String name,
                                   long dflt)
        Gets either system property or environment variable with given name. The result is transformed to long using Long.parseLong() method.
        Parameters:
        name - Name of the system property or environment variable.
        dflt - Default value.
        Returns:
        Integer value of the system property or environment variable. Returns default value in case neither system property nor environment variable with given name is found.
      • getDouble

        public static double getDouble​(String name,
                                       double dflt)
        Gets either system property or environment variable with given name. The result is transformed to double using Double.parseDouble() method.
        Parameters:
        name - Name of the system property or environment variable.
        dflt - Default value.
        Returns:
        Integer value of the system property or environment variable. Returns default value in case neither system property nor environment variable with given name is found.