Annotation Interface RabbitProperty


Used to set properties while publishing or bind to properties while consuming. For example while producing messages, the annotation can be set at the method or class level to provide static data. It can be applied at the parameter level to set the property differently per execution. While consuming the annotation can be applied to a parameter to bind the property to the argument. In addition, it may also be used to supply any arguments to the broker.
Since:
1.1.0
Author:
James Kleeh
See Also:
  • BasicProperties
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    Never used if applied to a parameter.
    Only to be used when defining consumer arguments to convert the value to the required type by RabbitMQ.
    If used as a bound parameter, this is the property name.
  • Element Details

    • value

      String value
      If used as a bound parameter, this is the property name. If used on a class level this is value and not the property name.
      Returns:
      The name of the property, otherwise it is inferred from the name()
      Default:
      ""
    • name

      String name
      Never used if applied to a parameter. Supplies the property name if used on a class or method.
      Returns:
      The name of property
      Default:
      ""
    • type

      Class type
      Only to be used when defining consumer arguments to convert the value to the required type by RabbitMQ.
      Returns:
      The type to convert the value to
      Default:
      java.lang.Void.class