Package org.springframework.kafka.event
Enum ConsumerStoppedEvent.Reason
- java.lang.Object
-
- java.lang.Enum<ConsumerStoppedEvent.Reason>
-
- org.springframework.kafka.event.ConsumerStoppedEvent.Reason
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<ConsumerStoppedEvent.Reason>
- Enclosing class:
- ConsumerStoppedEvent
public static enum ConsumerStoppedEvent.Reason extends java.lang.Enum<ConsumerStoppedEvent.Reason>
Reasons for stopping a consumer.- Since:
- 2.5.9
-
-
Enum Constant Summary
Enum Constants Enum Constant Description AUTH
An authorization exception occurred.ERROR
AError
was thrown.FENCED
The transactional producer was fenced and the containerstopContainerWhenFenced
property is true.NO_OFFSET
No offset found for a partition and no reset policy.NORMAL
The consumer was stopped because the container was stopped.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static ConsumerStoppedEvent.Reason
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static ConsumerStoppedEvent.Reason[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
NORMAL
public static final ConsumerStoppedEvent.Reason NORMAL
The consumer was stopped because the container was stopped.
-
FENCED
public static final ConsumerStoppedEvent.Reason FENCED
The transactional producer was fenced and the containerstopContainerWhenFenced
property is true.
-
AUTH
public static final ConsumerStoppedEvent.Reason AUTH
An authorization exception occurred.- Since:
- 2.5.10
-
NO_OFFSET
public static final ConsumerStoppedEvent.Reason NO_OFFSET
No offset found for a partition and no reset policy.- Since:
- 2.5.10
-
ERROR
public static final ConsumerStoppedEvent.Reason ERROR
AError
was thrown.
-
-
Method Detail
-
values
public static ConsumerStoppedEvent.Reason[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (ConsumerStoppedEvent.Reason c : ConsumerStoppedEvent.Reason.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static ConsumerStoppedEvent.Reason valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
-