Allow AttributeRegistry to signal treat-as-withdraw 52/78352/12
authorRobert Varga <robert.varga@pantheon.tech>
Wed, 5 Dec 2018 22:18:34 +0000 (23:18 +0100)
committerRobert Varga <nite@hq.sk>
Thu, 6 Dec 2018 10:21:33 +0000 (10:21 +0000)
commit834c7f32cc3e4836c64c5874ebaaec17e9dab899
tree3d145965b460faa9ef07c4a62c0df8c38e6aef3e
parent2cb281a0d977fea786717faa7bf2ae1c45a073a2
Allow AttributeRegistry to signal treat-as-withdraw

When any attribute indicates we should be treating the resulting
message as withdraw, we need to report this indication upwards,
so that the it can be evaluated once the complete contents of
the message are known.

This can result in either a conversion of reachability to
unreachability, or, if we fail to parse the NLRI-bearing fields,
in a session teardown.

Change-Id: I8c3b7b9d9f9523b42a328820cc6b7c9168976aeb
JIRA: BGPCEP-359
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
bgp/extensions/mvpn/src/test/java/org/opendaylight/protocol/bgp/mvpn/impl/attributes/PEDistinguisherLabelsAttributeHandlerTest.java
bgp/extensions/mvpn/src/test/java/org/opendaylight/protocol/bgp/mvpn/impl/attributes/PMSITunnelAttributeHandlerTest.java
bgp/parser-impl/src/main/java/org/opendaylight/protocol/bgp/parser/impl/message/BGPUpdateMessageParser.java
bgp/parser-impl/src/test/java/org/opendaylight/protocol/bgp/parser/impl/PathAttributeParserTest.java
bgp/parser-impl/src/test/java/org/opendaylight/protocol/bgp/parser/impl/message/update/CommunitiesAttributeParserTest.java
bgp/parser-spi/src/main/java/org/opendaylight/protocol/bgp/parser/spi/AttributeRegistry.java
bgp/parser-spi/src/main/java/org/opendaylight/protocol/bgp/parser/spi/ParsedAttributes.java [new file with mode: 0644]
bgp/parser-spi/src/main/java/org/opendaylight/protocol/bgp/parser/spi/pojo/SimpleAttributeRegistry.java
bgp/parser-spi/src/test/java/org/opendaylight/protocol/bgp/parser/spi/pojo/UnrecognizedAttributesTest.java