Eliminate protocol-framework This piece of code has been moved to netconf, eliminate it from controller. Change-Id: I1a04ed800d88ab49ef6e1d0782ca722f18e16581 Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
Remove logback related stuff as discussed on https://lists.opendaylight.org/pipermail/odlparent-dev/2017-July/001262.html ' Change-Id: I09146cd363d1ab706143bc12c8b1e37aa96c8723 Signed-off-by: Michael Vorburger <vorburger@redhat.com>
Replace logger and log by LOG Replace logger and log by LOG to follow the OpenDaylight recommendations [1]. [1] https://wiki.opendaylight.org/view/BestPractices/Logging_Best_Practices Change-Id: I63787ccee5950bebbc8c3769885574593a666809 Signed-off-by: David Suarez <david.suarez.fuentes@ericsson.com>
protocol-framework: use lambdas This series of patches uses lambdas instead of anonymous classes for functional interfaces when possible. Lambdas are replaced with method references when appropriate. Change-Id: Ife557068a519c0b2822b9ee5dc4b5150373e0cf8 Signed-off-by: Stephen Kitt <skitt@redhat.com>
protocol-framework: final parameters This automatically-generated patch flags all appropriate parameters as final (including caught exceptions). Change-Id: I48aac237ca7730845935e53adbbe2ce314f7c564 Signed-off-by: Stephen Kitt <skitt@redhat.com>
Mechanical code cleanup (commons) * Remove unnecessary type specifiers (use Java 7 <>) * Remove unnecessary "extends Object" declarations * Remove unnecessary semi-colons * Merge identical catch blocks * Remove redundant modifiers: - enum constructors are private by default - interface properties are public static final by default - interface methods are public abstract by default - interfaces are abstract by default - inner interfaces are static by default - inner classes in interfaces are public static by default Change-Id: If1805b63e52c1ab0c68983e7856e7ccf184cb2a9 Signed-off-by: Stephen Kitt <skitt@redhat.com>
Switch to StandardCharsets Guava's Charsets should not be used when StandardCharsets are available. Change-Id: I7c52bd3070bb48857cbba82e8d4bc5993d7aea9d Signed-off-by: Robert Varga <rovarga@cisco.com>
Modify config Module impls to co-exist with blueprint Modified various config system Module implementation classes which have corresponding instances created and advertised via blueprint to obtain the instance in createInstance from the OSGi registry. The instance may not be available yet so it will wait. I added a WaitingServiceTracker class to encapsulate this logic using a ServiceTracker. For those modules that don't advertise services, createInstance simply returns a noop AutoCloseable since the components are created via blueprint. I also added the new disable-osgi-service-registration flag to the corresponding service yang identities to prevent the CSS from duplicating the service registrations. This patch also adds the blueprint bundle to the mdsal features and "turns on" blueprint. Change-Id: I60099c82a2a248fc233ad930c4808d6ab19ea881 Signed-off-by: Tom Pantelis <tpanteli@brocade.com>
BUG-8: migrate newMBeanProxy() -> newMXBeanProxy() newMBeanProxy() is deprecated, so migrate users over, eliminating associated warnings. Change-Id: Ifd9ff1146f2f0e5b2a20a55bd8c34f48f837cb01 Signed-off-by: Robert Varga <rovarga@cisco.com> Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
BUG-2340 Fix improper cleanup of resources in netconf ssh handler This commit also fixes proper reconnect scheduling for netconf-connector. Change-Id: I1d848af57fddc35e73596fc47f8c7318b8747130 Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
Fix failing reconnect test. Test verified that session that was dropped during negotiation was not reconnected. This is no longer true, so the test is failing. However not on jenkins. Change-Id: I5f416a3397c33607e5004dc48f9569d9da992326 Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
Fix config attributes with same names for different modules. Yang does not allow attributes in different cases to have the same name. In yang modules for config, the configuration is located in cases and if 2 cases in same yang module contain child with same name, the transformation of data from CompositeNode to NormalizedNode NOTE: This might break bgpcep and SP distribution, check. Change-Id: I9bad24df9ac149da74b745ff648c72345e33deb1 Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
BUG-190 Simplify reconnect logic in protocol-framework. - Removed duplicate code from ReconnectPromise (almost the same code in ProtocolSessionPromise) - ReconnectPromise now only calls ProtocolSessionPromise.connect (once right away to connect initially, then every time channel is closed by dropped session) - Removed second ReconnectingStrategyFactory from ReconnectPromise and AbstractDispatcher.createReconnectingClient (Kept in AbstractDispatcher for backwards compatibility as deprecated). Only one factory needed for reconnecting client - Added unit tests to ServerTest to test different cases of reconnecting - Slightly refactored ProtocolSessionPromise to make code more readable Change-Id: If3af8f468e7d59822c984cf814d15460ab35921f Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
Resolve Bug:681 - Fix config module registration to Service Registry. Rework OSGi service registration during second phase commit: only service references will be registered into SR, instead of old behaviour when each module's service interfaces were used. Only one key-value entry is persisted in registration: {name: name of service reference} . Change-Id: I25249fe8f9e51570cd3ea963e91145b7e44da57d Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
BUG-467: reconnect-strategy configuration moved into controller/commons/protocol-framework -changed reconnect-strategy service and modules to reconnect-strategy-factory - configuration of ReconnectStrategyFactory. Change-Id: I863cf4f7cf559504d05e14293af9d2c5e9373ca7 Signed-off-by: Milos Fabian <milfabia@cisco.com>
Remove deprecated API elements from protocol framework The use of these concepts has been deprecated in version 0.4.0, which was released. The only in-tree user was netconf, which was refactored to not to rely on these concepts, so bump the version to 0.5.0 and purge the code. Change-Id: Ibf2195b51bf12ea99b8b21f3da322d666b103b5e Signed-off-by: Robert Varga <rovarga@cisco.com>
Move protocol framework from BGPCEP project This moves the current parts of BGPCEP protocol framework into the controller project, eliminating the circular dependency forced by netconf being resident in this project. Change-Id: I7c8457ebaec5c261217587d60a95a7b35e473d1e Signed-off-by: Robert Varga <rovarga@cisco.com>