-
- try {
- bgpThriftClient.addPrefix(rd, prefix, nextHop, vpnLabel);
- } catch (BgpRouterException b) {
- LOGGER.error("Failed to add BGP prefix " + prefix + "due to BgpRouter Exception number " + b.getErrorCode());
- LOGGER.debug("BgpRouterException trace ", b);
- throw b;
- } catch (TException t) {
- LOGGER.error(String.format("Failed adding prefix entry <vrf:prefix:nexthop:vpnlabel> %s:%s:%s:%d due to Transport error",
- rd, prefix, nextHop, vpnLabel));
- reInitConn();
- throw t;
- } catch (Exception e) {
- LOGGER.error(String.format("Failed adding prefix entry <vrf:prefix:nexthop:vpnlabel> %s:%s:%s:%d",
- rd, prefix, nextHop, vpnLabel));
- throw e;
+ errorSubCode = BgpAlarmErrorCodes.checkErrorSubcode(subcode);
+ if (errorSubCode == BgpAlarmErrorCodes.ERROR_IGNORE) {
+ // Need to report only those subcodes, defined in
+ // BgpAlarmErrorCodes enum class.
+ return;