Este conteúdo não está disponível no idioma selecionado.

20.11.2. Selector filter


<type name="selector-filter" class="restricted" source="string" provides="filter">
    <descriptor name="apache.org:selector-filter:string" code="0x0000468C:0x00000004"/>
</type>
Copy to Clipboard Toggle word wrap
The qpid-java JMS "selector" defines an SQL like syntax for filtering messages. The selector filters based on the values of "headers" and "properties". The selector-filter uses the selector as defined by JMS but with the names of JMS headers translated into their AMQP equivalents. The defined JMS headers can be mapped to equivalent fields within the AMQP message sections:
The full list of headers is included in Section 20.6, “Java JMS Message Properties”.
When encoding the selector string on the wire, these JMS header names should be translated to amqp.field_name where field_name is the appropriate AMQP 1.0 field named in the table above, with the hyphen replaced by an underscore. For example, the selector: JMSCorrelationID = 'abc' AND color = 'blue' AND weight > 2500 would be transferred over the wire as: amqp.correlation_id = 'abc' AND color = 'blue' AND weight > 2500
The "properties" of the JMS message are equivalent to the AMQP application-properties section. Thus a reference to a property Foo in a message selector would be evaluated as the value associated with the key "Foo" (if present) in the application-properties section.
The operands of the JMS selector are defined in terms of the types available within JMS, When evaluated against the application properties section, the values within that section are evaluated according to the following type mapping:
Expand
Table 20.15. Mapping AMQP types to JMS types
AMQP Type JMS Selector Type
null
null
boolean
boolean
ubyte
short
ushort
int
uint
long
ulong
long
byte
byte
short
short
int
int
long
long
float
float
double
double
decimal32
double
decimal64
double
decimal128
double
char
char
timestamp
long
uuid
byte[16]
binary
byte[]
string
String
symbol
String
Voltar ao topo
Red Hat logoGithubredditYoutubeTwitter

Aprender

Experimente, compre e venda

Comunidades

Sobre a documentação da Red Hat

Ajudamos os usuários da Red Hat a inovar e atingir seus objetivos com nossos produtos e serviços com conteúdo em que podem confiar. Explore nossas atualizações recentes.

Tornando o open source mais inclusivo

A Red Hat está comprometida em substituir a linguagem problemática em nosso código, documentação e propriedades da web. Para mais detalhes veja o Blog da Red Hat.

Sobre a Red Hat

Fornecemos soluções robustas que facilitam o trabalho das empresas em plataformas e ambientes, desde o data center principal até a borda da rede.

Theme

© 2025 Red Hat