controller.git
10 years agoRemoved duplicated dependency declaration: ietf-netconf-monitoring,ietf-netconf-monit... 26/5426/2
Tomas Olvecky [Thu, 20 Feb 2014 13:30:10 +0000 (14:30 +0100)]
Removed duplicated dependency declaration: ietf-netconf-monitoring,ietf-netconf-monitoring-extension from commons.opendaylight.

Change-Id: I1b834def2831acfae7749b24a6778f5811aca182
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
10 years agoMove xtend dependency definition from md-sal pom to commons.opendaylight 25/5425/3
Tomas Olvecky [Thu, 20 Feb 2014 12:59:28 +0000 (13:59 +0100)]
Move xtend dependency definition from md-sal pom to commons.opendaylight

Change-Id: Iece78be2da9a8797deb082a7d81030a2c85dac26
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
10 years agoMerge "Fix some sonar bugs in config-api and config-manager."
Tony Tkacik [Tue, 25 Feb 2014 11:10:25 +0000 (11:10 +0000)]
Merge "Fix some sonar bugs in config-api and config-manager."

10 years agoRpcRegistration.close() should not throw 55/5455/1
Robert Varga [Tue, 25 Feb 2014 10:12:14 +0000 (11:12 +0100)]
RpcRegistration.close() should not throw

Closing an RPC registration is an atomic act, e.g. it should never be
allowed to throw exceptions.

Change-Id: Ie49c67691540db4d4a8a21814e01d3287c5f31cd
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoMerge "Modify config-api exceptions, bump config and netconf to 0.2.5-SNAPSHOT."
Tony Tkacik [Mon, 24 Feb 2014 17:22:10 +0000 (17:22 +0000)]
Merge "Modify config-api exceptions, bump config and netconf to 0.2.5-SNAPSHOT."

10 years agoAdded support to register of RPC Implementation. 49/5449/1
Lukas Sedlak [Mon, 24 Feb 2014 10:00:40 +0000 (11:00 +0100)]
Added support to register of RPC Implementation.

NetconfDevice has now has capability to support of rpc implementation which adds support for ODL to send rpcs towards netconf server.
Added fix for commit handler registration. Now the commit handler is registered only and only when mount instance is availible.

Change-Id: I11eced0fda40b3c0cd66fd6477c4df45304d3e18
Signed-off-by: Lukas Sedlak <lsedlak@cisco.com>
10 years agoAdded documentation into web socket in RestConf 39/5439/2
Ladislav Borak [Fri, 21 Feb 2014 12:19:50 +0000 (13:19 +0100)]
Added documentation into web socket in RestConf

Change-Id: I36fae4c8916c6d25a1b9619390467e48b64e8a3d
Signed-off-by: Ladislav Borak <lborak@cisco.com>
10 years agoMerge "Backward compatibility for User management"
Andrew Kim [Sun, 23 Feb 2014 01:50:47 +0000 (01:50 +0000)]
Merge "Backward compatibility for User management"

10 years agoModify config-api exceptions, bump config and netconf to 0.2.5-SNAPSHOT. 61/5261/6
Maros Marsalek [Tue, 11 Feb 2014 15:36:32 +0000 (16:36 +0100)]
Modify config-api exceptions, bump config and netconf to 0.2.5-SNAPSHOT.

Change ConflictingVersionException and ValidationException to be checked instead of
runtime exceptions.
Fix ConfigPusher's ConflictVersionException handling that was introduced when IOException was
used to wrap RuntimeException.
Small fixes in netconf, more refactoring of exception handling will be needed there.

Maros Marsalek: Rebase commit + fix compliation issue in ShutdownTest

Change-Id: Iab89de6ef6ced0de0a267470f860912ae3c56892
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
10 years agoMerge "Fix message aggregator for chunked netconf messages."
Tony Tkacik [Fri, 21 Feb 2014 10:44:16 +0000 (10:44 +0000)]
Merge "Fix message aggregator for chunked netconf messages."

10 years agoFix message aggregator for chunked netconf messages. 23/5423/3
Maros Marsalek [Thu, 20 Feb 2014 12:19:03 +0000 (13:19 +0100)]
Fix message aggregator for chunked netconf messages.

Aggregator did not work with 1 message in multiple chunks.

Change-Id: I03cc89c3fc56a52f077fd21f77bd98e47ea358a9
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
10 years agoFix some sonar bugs in config-api and config-manager. 15/5415/2
Tomas Olvecky [Wed, 19 Feb 2014 14:43:41 +0000 (15:43 +0100)]
Fix some sonar bugs in config-api and config-manager.

Change-Id: I417bb4bdd649606d871382e7bf561d35daafc11b
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
10 years agoMake use of new sendMessage method in AbstractNegotiator 93/5393/2
Maros Marsalek [Tue, 18 Feb 2014 11:58:47 +0000 (12:58 +0100)]
Make use of new sendMessage method in AbstractNegotiator

Change-Id: Ieeb104aa34b8140936a1daf8011ba3b0effc79d5
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
10 years agoMerge "ConfigurationService to create default config dir"
Alessandro Boch [Wed, 19 Feb 2014 21:42:43 +0000 (21:42 +0000)]
Merge "ConfigurationService to create default config dir"

10 years agoConfigurationService to create default config dir 07/5407/5
Yevgeny Khodorkovsky [Wed, 19 Feb 2014 03:16:15 +0000 (19:16 -0800)]
ConfigurationService to create default config dir

- Have ConfigurationService create a default startup config directory,
  so that container unaware apps/modules can initiate and individual
  save.
- Semantic fixes in IConfigurationContainerService
- Bump configuration api rev since methods were added since last rev

Change-Id: Ifec274c258859a402f6dad7394c43c28ed162b95
Signed-off-by: Yevgeny Khodorkovsky <ykhodork@cisco.com>
10 years agoMerge "bug 433 NPE in onGlobalContextUpdated of ControllerContext class"
Tony Tkacik [Wed, 19 Feb 2014 15:29:03 +0000 (15:29 +0000)]
Merge "bug 433 NPE in onGlobalContextUpdated of ControllerContext class"

10 years agoAdd ModuleInfoBackedContext loading strategy to RuntimeGeneratedMapping service. 14/5414/2
Maros Marsalek [Tue, 18 Feb 2014 15:51:09 +0000 (16:51 +0100)]
Add ModuleInfoBackedContext loading strategy to RuntimeGeneratedMapping service.

RuntimeGeneratedMappingServiceImpl is now started by the config-manager.
ModuleInfoBackedContext is filled by BundleTracker in config-manager.

This fix allows use of yang identities in netconf and restconf.

Change-Id: Id59d9d2ce08bfc9216d90cb5673e2d02aafd9151
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
10 years agoMerge "BUG-421: Define multipart-transaction-aware"
Tony Tkacik [Wed, 19 Feb 2014 14:41:07 +0000 (14:41 +0000)]
Merge "BUG-421: Define multipart-transaction-aware"

10 years agobug 433 NPE in onGlobalContextUpdated of ControllerContext class 12/5412/1
Jozef Gloncak [Wed, 19 Feb 2014 12:32:51 +0000 (13:32 +0100)]
bug 433 NPE in onGlobalContextUpdated of ControllerContext class

Input parameter of type SchemaContext of method onGlobalContextUpdated is
now checked if is different from null to be able to call getOperations method.
In addition clearing of map of rpcs was added.

Change-Id: I2b69d7f50acba041ade17acba8b3f2af7b3e4d9c
Signed-off-by: Jozef Gloncak <jgloncak@cisco.com>
10 years agoStop config-manager as first bundle when shutting down container. 11/5411/1
Tomas Olvecky [Wed, 19 Feb 2014 10:58:33 +0000 (11:58 +0100)]
Stop config-manager as first bundle when shutting down container.

If config-manager is stopped after a configured module's bundle has been stopped, config-manager will be unable to cleanly
close other instances, so it needs to be stopped as first bundle.
GlobalEventExecutorModule (netty-global-event-executor) is singleton, enforce it in only allowing one instance
called 'singleton'.
Make shutdown grace period smaller in order to close netty threads sooner that shutdown issues System.exit(1).

Change-Id: I042c606a5bedc49492784dcb0a5ad4dcbdcb0939
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
10 years agoBackward compatibility for User management 04/5404/1
Sapan Shah [Wed, 19 Feb 2014 02:45:48 +0000 (18:45 -0800)]
Backward compatibility for User management

Change-Id: I844d959852cd40fa242ac56b6efa36b2982e73ec
Signed-off-by: Sapan Shah <sapshah@cisco.com>
10 years agoAdd logging for HashMapDataStore 95/5395/1
Robert Varga [Tue, 18 Feb 2014 15:36:36 +0000 (16:36 +0100)]
Add logging for HashMapDataStore

Change-Id: Icea99ff59317cc387a1143762840795149d4058e
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoMerge "bug 344 interpretation of slashes ('/') in URI"
Tony Tkacik [Tue, 18 Feb 2014 15:18:53 +0000 (15:18 +0000)]
Merge "bug 344 interpretation of slashes ('/') in URI"

10 years agoMerge "Switch from using xtend to java in md-sal adapters"
Tony Tkacik [Tue, 18 Feb 2014 15:18:22 +0000 (15:18 +0000)]
Merge "Switch from using xtend to java in md-sal adapters"

10 years agoMerge "Activate enforcement of Path type"
Tony Tkacik [Tue, 18 Feb 2014 12:30:44 +0000 (12:30 +0000)]
Merge "Activate enforcement of Path type"

10 years agobug 344 interpretation of slashes ('/') in URI 68/5368/3
Jozef Gloncak [Mon, 17 Feb 2014 14:13:56 +0000 (15:13 +0100)]
bug 344 interpretation of slashes ('/') in URI

If slash (/) should be part of path parameter from URI it can be specified with %2F
placeholder.
e.g. list which key is "ke/y_1" CAN'T be specified as
list_name/ke/y_1
but should be constructed as
list_name/ke%2Fy_1

It is also necessary to add to target distribution folder
/opendaylight/configuration/config.ini
following line
org.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH=true

Change-Id: Id07e7969247f3b60a44b808c95dac6375cebc011
Signed-off-by: Jozef Gloncak <jgloncak@cisco.com>
10 years agoMerge "Introduce checked sendMessage() method"
Tony Tkacik [Tue, 18 Feb 2014 12:23:33 +0000 (12:23 +0000)]
Merge "Introduce checked sendMessage() method"

10 years agoActivate enforcement of Path type 92/5392/1
Robert Varga [Tue, 18 Feb 2014 11:33:01 +0000 (12:33 +0100)]
Activate enforcement of Path type

This activates pre-prepared requirement of P to be of type Path<P>,
which had prerequisites in generated DTOs. Yangtools have been updated,
so it should be safe to activate this now.

Change-Id: I68ad3a77311e44db2e6bee1d7e2b3684090e5cbd
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoFix warnings in netconf-api and netconf-util 67/5367/4
Maros Marsalek [Mon, 17 Feb 2014 14:03:57 +0000 (15:03 +0100)]
Fix warnings in netconf-api and netconf-util

Change-Id: Icd7f605796ddb38cc01ac08c4de7e3c62cc8da39
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
10 years agoImprove NETCONF encoding performance 80/5380/3
Robert Varga [Sat, 15 Feb 2014 17:24:21 +0000 (18:24 +0100)]
Improve NETCONF encoding performance

This changes the protocol encoder such that it is piped directly into
the output buffer rather than constructing intermediate buffers and
strings.

Change-Id: I4938b2fd72b2321d21617c4e9c8a4d491778b657
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoMerge "Untangle the XML/Hello message decoders"
Tony Tkacik [Tue, 18 Feb 2014 11:05:27 +0000 (11:05 +0000)]
Merge "Untangle the XML/Hello message decoders"

10 years agoMerge "Do not instantiate multiple DocumentBuilderFactories"
Tony Tkacik [Tue, 18 Feb 2014 11:01:13 +0000 (11:01 +0000)]
Merge "Do not instantiate multiple DocumentBuilderFactories"

10 years agoMerge "Split message aggregators"
Tony Tkacik [Tue, 18 Feb 2014 10:59:36 +0000 (10:59 +0000)]
Merge "Split message aggregators"

10 years agoMerge "Correct encoding"
Tony Tkacik [Tue, 18 Feb 2014 10:58:25 +0000 (10:58 +0000)]
Merge "Correct encoding"

10 years agoMerge "Cleanup framing mechanisms"
Tony Tkacik [Tue, 18 Feb 2014 10:57:13 +0000 (10:57 +0000)]
Merge "Cleanup framing mechanisms"

10 years agoIntroduce checked sendMessage() method 90/5390/1
Robert Varga [Tue, 18 Feb 2014 10:39:14 +0000 (11:39 +0100)]
Introduce checked sendMessage() method

This method send a message down the socket and makes sure that
negotiation fails if the message does not reach the peer for any reason.
Subclasses should use this method instead of talking directly to the
underlying channel.

Change-Id: I5b8201caef1c4ba655dad12fb139b054b9e75f06
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoFix a few more warnings 86/5386/1
Robert Varga [Tue, 18 Feb 2014 08:53:30 +0000 (09:53 +0100)]
Fix a few more warnings

- Remove unused string constants
- Add type arguments
- Removed unused field

Change-Id: I8fbbd238a805d9445eecc4d7c65176ce4ff36b6d
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoOptimize empty transactions 84/5384/3
Robert Varga [Tue, 18 Feb 2014 08:34:14 +0000 (09:34 +0100)]
Optimize empty transactions

This is a micro-optimization: if we know there are no affected paths,
we used to spin an entire transaction -- which ended up revalidating an
empty delta. Let's skip the entire circus and proceed to commit
directly.

Change-Id: Ia6250663c01348dd08610c2a44dc01743761a05c
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoAnother round of warnings fixes 82/5382/3
Robert Varga [Tue, 18 Feb 2014 07:34:56 +0000 (08:34 +0100)]
Another round of warnings fixes

Removes one unused method
Fixes raw type usage where possible
Organize imports to get rid of unused/duplicate imports
Remove the use of deprecated InstanceIdentifier methods

Change-Id: I75bac5eae1e8cffcf88ab01451d3e4a8afa8c43e
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoPlace an upper bound on notification concurrency 81/5381/3
Robert Varga [Tue, 18 Feb 2014 06:43:15 +0000 (07:43 +0100)]
Place an upper bound on notification concurrency

In Cbench tests we have seen as many as 2000 threads being created. This
is certainly an overkill and thus let's place an upper bound on the
number of threads we create.

Change-Id: I6a7f429080504cbfa75679cc5879264a0622f140
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoRemove unused ganymed.version property 83/5383/3
Robert Varga [Tue, 18 Feb 2014 07:47:06 +0000 (08:47 +0100)]
Remove unused ganymed.version property

Change-Id: Ifffaa15f77bed86c04909b5f6aee8ec389779994
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoUntangle the XML/Hello message decoders 79/5379/1
Robert Varga [Sun, 16 Feb 2014 05:46:06 +0000 (06:46 +0100)]
Untangle the XML/Hello message decoders

The tie between these classes was completely unnecessary -- we had this
complicated contract just for the sake of reusing couple of lines of
code. Untangle and optimize.

Change-Id: I6fd29ba0ff5d87a5fb2362e87e4fb1361544429f
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoDo not instantiate multiple DocumentBuilderFactories 78/5378/1
Robert Varga [Sun, 16 Feb 2014 05:44:49 +0000 (06:44 +0100)]
Do not instantiate multiple DocumentBuilderFactories

We're instantiating builders themsenves, so we can safely reuse a single
factory. No sense in initiating it more than once.

Change-Id: I70dfa2d5cc51a09722bb7ad41ce4d61f8691ac3d
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoSplit message aggregators 77/5377/1
Robert Varga [Sun, 16 Feb 2014 04:29:51 +0000 (05:29 +0100)]
Split message aggregators

This splits the EOM aggregator and the chunked encoding aggregator. The
chunked encoding can be much more efficient and hardened as it allows
for proper stream processing.

We do not go the entire way here, just tighten the chunk header parsing
by keeping an explicit state machine. We still need to gather the entire
message before shifting it, as our downstream expects to see the message
in its entirety.

Change-Id: I60947b6d018b73581a56adda5212d3482dda61ea
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoCorrect encoding 76/5376/1
Robert Varga [Sun, 16 Feb 2014 03:31:16 +0000 (04:31 +0100)]
Correct encoding

NETCONF chunked encoding is transferred in US_ASCII, not UTF-8.

Change-Id: I33d45b0d2806c91aaf5c22fcaf3731fdad6cf7f6
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoCleanup framing mechanisms 75/5375/1
Robert Varga [Sat, 15 Feb 2014 22:21:51 +0000 (23:21 +0100)]
Cleanup framing mechanisms

This gets rid of pre-instantiated NetconfMessageHeader in favor of
creating a static constructor method.

Furthermore allow our output chunking to be variable and bump the
default from 1K to 8K. The upper limit on chunk size is 16M.

Change-Id: I0ab4405fc7d750cca5875049f03b053aa80037ef
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoUpdate UserConfig with salt value while changing roles 74/5374/1
Sapan Shah [Tue, 18 Feb 2014 01:31:20 +0000 (17:31 -0800)]
Update UserConfig with salt value while changing roles

Change-Id: If99955c69cbf374e891db37c7a7f584f37acc047
Signed-off-by: Sapan Shah <sapshah@cisco.com>
10 years agoSwitch from using xtend to java in md-sal adapters 73/5373/3
Moiz Raja [Mon, 17 Feb 2014 23:55:59 +0000 (15:55 -0800)]
Switch from using xtend to java in md-sal adapters

This is part of my effort to switch all xtend code in the adapters to java

Change-Id: I10c679fbe5f7980facd1b5e5d2e0a5c3ae997ff6
Signed-off-by: Moiz Raja <moraja@cisco.com>
10 years agoMerge "Fix eclipse warnings about maven-enforcer-plugin"
Tony Tkacik [Mon, 17 Feb 2014 17:03:54 +0000 (17:03 +0000)]
Merge "Fix eclipse warnings about maven-enforcer-plugin"

10 years agoMerge "CHange log level from warn to debug in ProtocolSessionPromise when connection...
Tony Tkacik [Mon, 17 Feb 2014 16:31:35 +0000 (16:31 +0000)]
Merge "CHange log level from warn to debug in ProtocolSessionPromise when connection attempt fails"

10 years agoFix eclipse warnings about maven-enforcer-plugin 58/5358/2
Robert Varga [Sun, 16 Feb 2014 11:53:22 +0000 (12:53 +0100)]
Fix eclipse warnings about maven-enforcer-plugin

This patch adds an ignore lifecycle mapping, letting eclipse know it
should ignore the plugin.

Change-Id: I6508c5a929a30042197af3a390fe34378a348b9a
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoMerge changes I393151af,I0a302cde
Tony Tkacik [Mon, 17 Feb 2014 16:30:03 +0000 (16:30 +0000)]
Merge changes I393151af,I0a302cde

* changes:
  Fix unused field warnings
  Fix warnings about overriden versions

10 years agoMerge "Add support for multiple choice case statements within one augument in config...
Tony Tkacik [Mon, 17 Feb 2014 16:28:11 +0000 (16:28 +0000)]
Merge "Add support for multiple choice case statements within one augument in config yang files"

10 years agoMerge "Fix namespaces for netconf monitoring extensions."
Tony Tkacik [Mon, 17 Feb 2014 16:19:09 +0000 (16:19 +0000)]
Merge "Fix namespaces for netconf monitoring extensions."

10 years agoFix typo in switchmanager log message in word 'available' 66/5366/1
Alissa Bonas [Mon, 17 Feb 2014 12:49:20 +0000 (14:49 +0200)]
Fix typo in switchmanager log message in word 'available'

Change-Id: I97bd3d69109b9fec460793758f9a56459a5226b0
Signed-off-by: Alissa Bonas <abonas@redhat.com>
10 years agoFix unused field warnings 57/5357/2
Robert Varga [Sun, 16 Feb 2014 11:22:03 +0000 (12:22 +0100)]
Fix unused field warnings

Removes affected fields, add @Override annotations and make constant
fields final.

Change-Id: I393151af1459e31eeded0786cf32223068635172
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoFix warnings about overriden versions 56/5356/2
Robert Varga [Sun, 16 Feb 2014 11:03:08 +0000 (12:03 +0100)]
Fix warnings about overriden versions

With proper parent structure, version overrides should not be present.

Change-Id: I0a302cde1c619af76f9290f7e5ca5080ff4fe251
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoFix namespaces for netconf monitoring extensions. 53/5253/6
Maros Marsalek [Tue, 11 Feb 2014 10:13:02 +0000 (11:13 +0100)]
Fix namespaces for netconf monitoring extensions.

Change-Id: Ib191dbcb121ead95db65263b4b478b8eac64c004
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
10 years agoCleanup warnings 55/5355/2
Robert Varga [Sun, 16 Feb 2014 10:22:45 +0000 (11:22 +0100)]
Cleanup warnings

Change-Id: I26d45b3f3856ddd893b54089521b5366deb34db3
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoMerge "Serializable classes should have serialVersionUID"
Tony Tkacik [Mon, 17 Feb 2014 09:57:38 +0000 (09:57 +0000)]
Merge "Serializable classes should have serialVersionUID"

10 years agoMerge "Do not access static methods through object instances"
Tony Tkacik [Mon, 17 Feb 2014 09:56:36 +0000 (09:56 +0000)]
Merge "Do not access static methods through object instances"

10 years agoMerge "Add a bit of documentation"
Tony Tkacik [Mon, 17 Feb 2014 08:54:30 +0000 (08:54 +0000)]
Merge "Add a bit of documentation"

10 years agoSerializable classes should have serialVersionUID 54/5354/1
Robert Varga [Sun, 16 Feb 2014 09:56:01 +0000 (10:56 +0100)]
Serializable classes should have serialVersionUID

Change-Id: I3b7e3270202275a6bc08617957f78ee969d3ac70
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoDo not access static methods through object instances 53/5353/1
Robert Varga [Sun, 16 Feb 2014 09:48:01 +0000 (10:48 +0100)]
Do not access static methods through object instances

Stops eclipse from complaining.

Change-Id: I153b651068cceb8263f2f4a8ea65b8de45a1ba50
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoAdd a bit of documentation 47/5347/1
Robert Varga [Sat, 15 Feb 2014 06:05:11 +0000 (07:05 +0100)]
Add a bit of documentation

Change-Id: I57883cffb62f4f22de74d567f9d040a90e21a5d0
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoDisconnect node statistics tracking 46/5346/1
Robert Varga [Sat, 15 Feb 2014 06:36:09 +0000 (07:36 +0100)]
Disconnect node statistics tracking

This patch moves scheduling into the node handlers themselves. This
should allow for spreading out of the statistics collection, preventing
spikes. Additionally delay the initial collection by up to 5 seconds to
deal with multiple switches connecting at the same time.

Change-Id: I6ea039b405595b3756263bddd9cf8997bc73a038
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoHandle openflowplugin returning null 45/5345/1
Robert Varga [Sat, 15 Feb 2014 02:17:36 +0000 (03:17 +0100)]
Handle openflowplugin returning null

It turns out that openflow plugin reports success with null transaction
ID if the switch does not support a feature. This is quite bad, but we
can recover rather easily. Rework the registration contract to take care
of the changes.

Change-Id: I62fe7badeb5d792c8533762f5e68b7d37811f8ed
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoDetect RPC failures 42/5342/1
Robert Varga [Sat, 15 Feb 2014 02:17:36 +0000 (03:17 +0100)]
Detect RPC failures

This detects when RPCs to stats services fail. Also it removes the enums
used only for legacy debug.

Change-Id: Id4eb348b92378735a143b799b4c97b9840766ff6
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoMerge "Move queue/meter/flow listeners into their trackers"
Tony Tkacik [Sat, 15 Feb 2014 03:52:52 +0000 (03:52 +0000)]
Merge "Move queue/meter/flow listeners into their trackers"

10 years agoMerge "Move statistics request functions into trackers"
Tony Tkacik [Sat, 15 Feb 2014 03:26:48 +0000 (03:26 +0000)]
Merge "Move statistics request functions into trackers"

10 years agoMerge "Bug fixes for netconf southbound plugin."
Tony Tkacik [Sat, 15 Feb 2014 03:25:14 +0000 (03:25 +0000)]
Merge "Bug fixes for netconf southbound plugin."

10 years agoMove queue/meter/flow listeners into their trackers 35/5335/3
Robert Varga [Fri, 14 Feb 2014 19:24:40 +0000 (20:24 +0100)]
Move queue/meter/flow listeners into their trackers

This completes the move of triggers under a per-node registration. With
this structure we should have a complete control of what should be going
on for a switch.

Change-Id: Ia35c925947e044ff826c1f2560c040fe696aaed0
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoMove statistics request functions into trackers 23/5323/5
Robert Varga [Fri, 14 Feb 2014 19:24:05 +0000 (20:24 +0100)]
Move statistics request functions into trackers

This moves the gory details of specific requests into their respective
trackers. It also makes the request pipeline asynchronous.

Change-Id: I56ad175bc75b1af18263ae294cb3ffc118557abd
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoMove statistics request methods into NodeStatisticsHandler 22/5322/3
Robert Varga [Fri, 14 Feb 2014 01:42:01 +0000 (02:42 +0100)]
Move statistics request methods into NodeStatisticsHandler

This move make sure we route all requests through a particular node
handler, so it now sees which stats are actually requested for a
particular node.

This means that MultipartMessageManager can use a simple map, as all
operations are now protected by the NodeStatisticsHandler's lock.

Current code organization now allows the individual statistics request
methods to be moved into individual trackers.

Change-Id: Iebd53d6dd447db7ab684cd2c6a90d9abf1b0e91e
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoMove MultipartMessageManager into NodeStatisticsHandler 21/5321/3
Robert Varga [Thu, 13 Feb 2014 22:37:20 +0000 (23:37 +0100)]
Move MultipartMessageManager into NodeStatisticsHandler

There is no reason to have a global manager, now each
NodeStatisticsHandler instantiates its own manager -- thus the nodeId
in its tables has no point. This has the added value of being protected
by the NodeStatisticsHandler lock, thus we are prepared to having a
completely consistent view of what operations are really expected even
when switches flap.

Change-Id: I4ca63982506c6f290967040d5626400cb0a0996e
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoSplit out statistics tracking into separate classes 12/5312/4
Robert Varga [Thu, 13 Feb 2014 18:45:13 +0000 (19:45 +0100)]
Split out statistics tracking into separate classes

- FlowStats
- FlowTableStats
- GroupDescStats
- GroupStats
- MeterConfigStats
- MeterStats
- NodeConnectorStats
- QueueStats

are all now tracked by dedicated classes. Also create a dedicated
QueueStatsEntry and FlowStatsEntry class.

Furthermore the flow walking code is modified to stop searching as soon
as it finds a matching flow.

Change-Id: Ia2bacb12f9c0af6520c115c161388b72a846b062
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoAdd proxies for statistics getters 11/5311/3
Robert Varga [Thu, 13 Feb 2014 08:33:28 +0000 (09:33 +0100)]
Add proxies for statistics getters

This is a simple unification of stats collection triggers so they are
centered about their per-node collector.

Change-Id: Iaf63d782b58b84ed3270b9215587f96f93aab3cc
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoUse a single Timer instead of two threads 00/5300/4
Robert Varga [Thu, 13 Feb 2014 07:45:36 +0000 (08:45 +0100)]
Use a single Timer instead of two threads

It turns out that we really want to have the aging and collection bound
to a common timeline, so let's combine them. This will give us the
opportunity to perform mark&sweep in future.

Furthermore we use the threads only for periodic tasks, so let's convert
to a Timer with TimerTasks. This will allow us more flexibility going
forward, for example allowing NodeStatisticsHandlers to manage how often
they wish to collect individual statistics.

Change-Id: Ie2cd0e4e7391e1175a8927773f85278b80f16c48
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoStart rework of MultipartMessageManager 99/5299/4
Robert Varga [Thu, 13 Feb 2014 07:00:13 +0000 (08:00 +0100)]
Start rework of MultipartMessageManager

- TxIdEntry should be private static final
- Remove unused method
- Use System.nanoTime() for timekeeping

Change-Id: I51bf99082aadeb1f83055a0bf6a07e320c089db0
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoCentralize targetNodeRef in the NodeStatisticsHandler 98/5298/7
Robert Varga [Thu, 13 Feb 2014 03:41:07 +0000 (04:41 +0100)]
Centralize targetNodeRef in the NodeStatisticsHandler

There's no reason to allocate it over and over again, we will be using
for a long time. Also push the DataProviderService into
NodeStatisticsHandler such that we do not have circular references.

Change-Id: I1e2444644a27516c87ca93d386f5dc2ac334ffaf
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoKeep track of the tables we discover 97/5297/6
Robert Varga [Thu, 13 Feb 2014 03:23:54 +0000 (04:23 +0100)]
Keep track of the tables we discover

NodeStatisticsHandler has always the most uptodate information about
which tables were discovered. Let's cache the table IDs -- we will
need them for sending out follow-up requests.

And now that we do that, we do not have to read the tables from
DataProviderService just to get the keys -- use whatever we cached.

Change-Id: I9550ae3330215277d373ec0b2ea67945ef0e7c5c
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoMerge "Walk the tables directly"
Tony Tkacik [Sat, 15 Feb 2014 01:38:51 +0000 (01:38 +0000)]
Merge "Walk the tables directly"

10 years agoMerge "Do not rely od DataStore for all connected nodes"
Tony Tkacik [Sat, 15 Feb 2014 01:37:07 +0000 (01:37 +0000)]
Merge "Do not rely od DataStore for all connected nodes"

10 years agoMerge "Split off tracking of node presence"
Tony Tkacik [Sat, 15 Feb 2014 01:36:41 +0000 (01:36 +0000)]
Merge "Split off tracking of node presence"

10 years agoMerge "Fix issue where NodeConnector ADDED events were propagated as NodeConnector...
Tony Tkacik [Sat, 15 Feb 2014 01:32:32 +0000 (01:32 +0000)]
Merge "Fix issue where NodeConnector ADDED events were propagated as NodeConnector CHANGED events"

10 years agoBug fixes for netconf southbound plugin. 22/5222/5
Lukas Sedlak [Mon, 10 Feb 2014 07:15:51 +0000 (23:15 -0800)]
Bug fixes for netconf southbound plugin.

Fixed wrong operation type sending in edit-config for netconf device. Action type replaced for "operation" type.
Fixed conversion of toRpcMessage in NetconfMapping. Fixed wrong QName - changed from "action" to "operation".

Change-Id: Ic9e07dfc2bdb50552321754cb92333ef88aa14bb
Signed-off-by: Lukas Sedlak <lsedlak@cisco.com>
10 years agoMerge "Changing SimpleBroadcastHandler so that it's disabled by default to fix stabil...
Alessandro Boch [Fri, 14 Feb 2014 22:33:16 +0000 (22:33 +0000)]
Merge "Changing SimpleBroadcastHandler so that it's disabled by default to fix stability issues with >10 switches."

10 years agoSwitch Manager should ignore redundant updates 29/5329/3
Yevgeny Khodorkovsky [Wed, 12 Feb 2014 18:04:41 +0000 (10:04 -0800)]
Switch Manager should ignore redundant updates

- Redundant node and node connector updates (such as in the case of
  cluster switchover) should not be notified to apps/listeners, to avoid expensive tasks

Change-Id: Ia541bdcba6b53170c7a6c29e2c35f1b7b8104d60
Signed-off-by: Yevgeny Khodorkovsky <ykhodork@cisco.com>
10 years agoMerge "Fixed bug when RPC was not propagared"
Tony Tkacik [Fri, 14 Feb 2014 22:06:04 +0000 (22:06 +0000)]
Merge "Fixed bug when RPC was not propagared"

10 years agoChanging SimpleBroadcastHandler so that it's disabled by default to fix stability... 36/5336/1
Colin Dixon [Fri, 14 Feb 2014 21:37:04 +0000 (15:37 -0600)]
Changing SimpleBroadcastHandler so that it's disabled by default to fix stability issues with >10 switches.

Change-Id: I6ac1c15e431760c97348bc466a9783f25f6d9fee
Signed-off-by: Colin Dixon <ckd@us.ibm.com>
10 years agoFix for container directory creation/deletion in startup without saving config 38/5238/7
Diti Bhatia [Fri, 14 Feb 2014 21:42:42 +0000 (13:42 -0800)]
Fix for container directory creation/deletion in startup without saving config

Change-Id: I423e7c3ab186af5ea5bd0ab6d42553b4f988e82f
Signed-off-by: Diti Bhatia <dibhatia@cisco.com>
10 years agoWalk the tables directly 96/5296/5
Robert Varga [Thu, 13 Feb 2014 02:52:54 +0000 (03:52 +0100)]
Walk the tables directly

This inlines a function with a single caller, such that we do not have
to create an interim list. This allows us to know the call site which
needs to know about tables.

Change-Id: I530233bd3ec8e85417a3b9efa878c80b683ce5ff
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoDo not rely od DataStore for all connected nodes 92/5292/5
Robert Varga [Thu, 13 Feb 2014 02:27:26 +0000 (03:27 +0100)]
Do not rely od DataStore for all connected nodes

Now that we track all connected flow-capable nodes we do need to go and
read all nodes just to find them. Just look at which handlers are
currently created.

Change-Id: I1a33b53399d0de0e2cdbdbd90512a09933d127c8
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoSplit off tracking of node presence 90/5290/6
Robert Varga [Thu, 13 Feb 2014 02:03:13 +0000 (03:03 +0100)]
Split off tracking of node presence

Introducing FlowCapableTracker. It's sole responsibility is to react
to FlowCapableNodes appearing and disappearing in the inventory and
spinning up statistics handlers based on that. This makes the
NodeStatisticsHandler lifecycle more predictable, thus we can activate
the 'ignore' part of the getStatisticsHandler(). Final part limits the
visibility of the various 'getFooStats' methods, so we can reason about
them better.

Change-Id: Icdbcca6038ae7fb0bff06d378fafa0f476f0fe18
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoBUG-421: Define multipart-transaction-aware 33/5333/1
Robert Varga [Fri, 14 Feb 2014 19:31:14 +0000 (20:31 +0100)]
BUG-421: Define multipart-transaction-aware

This bundles up the 'moreReplies' leaf into a grouping, as it is used in
multiple places. The new multipart-transaction-aware is used instead,
resulting in a common class shared between the notifications, which
should allow for better code reuse.

Change-Id: If225ba4a24d64158893c9f67b5115a6b8b19fcd9
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoFixed bug when RPC was not propagared 15/5315/2
Abhishek Kumar [Fri, 14 Feb 2014 00:20:35 +0000 (16:20 -0800)]
Fixed bug when RPC was not propagared

 - Fixed DOM Broker and BI Connector code
 - The refactoring was done so that DOM Broker does not get exposed to
 - BA Broker directly but rather through a proxy. This also fixes the
   issue where DOM Broker would not be initialized in BI Connector, therefore
   any messages from BA Broker would not flow to DOM Broker via BI Connector.

Change-Id: Ia25a71787857c8d052a5dbd40e8237015d8c4d63
Signed-off-by: Abhishek Kumar <abhishk2@cisco.com>
10 years agoMerge "Fixed bug when Binding-Aware Data Change Listeners we're not triggered."
Ed Warnicke [Fri, 14 Feb 2014 15:36:23 +0000 (15:36 +0000)]
Merge "Fixed bug when Binding-Aware Data Change Listeners we're not triggered."

10 years agoLimit visibility of FlowEntry 91/5291/4
Robert Varga [Thu, 13 Feb 2014 02:26:08 +0000 (03:26 +0100)]
Limit visibility of FlowEntry

This class is no longer needed to be visible. Make it private and
static.

Change-Id: I30c612fca44aa993f29922fb1465ecdb16ea50c5
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoFixed bug when Binding-Aware Data Change Listeners we're not triggered. 20/5320/3
Tony Tkacik [Fri, 14 Feb 2014 05:10:59 +0000 (06:10 +0100)]
Fixed bug when Binding-Aware Data Change Listeners we're not triggered.

  - Added additional strategy to inspect changes based on registered listeners
  - Fixed normalization of data for changes where parent node was written
      - Extracts data for listener, so listener does not need to
        extract that data manually
  - Splitted AbstractDataBroker.xtend into several classes

Change-Id: I7e5d1d759c40519d164b08678a9dc22743d329bb
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
10 years agoFix issue where NodeConnector ADDED events were propagated as NodeConnector CHANGED... 41/5241/6
Moiz Raja [Tue, 11 Feb 2014 03:23:50 +0000 (19:23 -0800)]
Fix issue where NodeConnector ADDED events were propagated as NodeConnector CHANGED events

Note that this is an interim fix which will work only in a non-clustered setup

The major part of this fix is coded in InventoryAndReadAdapter. The fix is as follows when a NodeConnectorChanged
event is received by the InventoryAdapter it first checks whether this node connector has ever been seen before by
it. It does this by looking at a Map of Nodes to NodeConnectors that it maintains. If the Node Connector is not found
in the Map then this must be a NodeConnector ADDED notification otherwise it is a NodeConnector CHANGED notification.

This commit also contains some code for what would be the ideal fix - one that would work in a cluster scenario as well
That code is in InventoryNotificationProvider and NodeConnectorDataChangeListener. The fix in there works like this. We set
up a DataChangeListener on the MD-SAL DataProvider Service which would notify us whenever a NodeConnector is added, modified
or removed. When the change event comes in depending on whether the node connector was added or modified the data change
listener fires the ADDED or CHANGED event. This fix is disabled for now till another issue with MD-SAL regarding removal
of nodes on mininet exit (or switch disconnect) is resolved.

There are some other changes in the FlowProgrammerAdapter which basically suppress some error conditions when a flow that is
being removed or modified does not exist in the cache that the FlowProgrammerAdapter maintains to translate between AD-SAL and
MD-SAL flows.

This fix allows pingall to work with upto 32 switches - after that other issues prevent testing with more switches.

Change-Id: Ide2e6e85191856a8c6a9746b2397605905938d56
Signed-off-by: Moiz Raja <moraja@cisco.com>