netconf.git
10 years agoMerge "Bug 931, Bug 910 - Enhance Restconf Swagger Documentation"
Tony Tkacik [Wed, 18 Jun 2014 16:56:03 +0000 (16:56 +0000)]
Merge "Bug 931, Bug 910 - Enhance Restconf Swagger Documentation"

10 years agoMerge "Bug 225 - added support for depth RESTCONF parameter in URI"
Tony Tkacik [Wed, 18 Jun 2014 12:34:14 +0000 (12:34 +0000)]
Merge "Bug 225 - added support for depth RESTCONF parameter in URI"

10 years agoMerge "BUG-1105: Implement subtree filtering in netconf"
Tony Tkacik [Wed, 18 Jun 2014 12:11:59 +0000 (12:11 +0000)]
Merge "BUG-1105: Implement subtree filtering in netconf"

10 years agoBug 931, Bug 910 - Enhance Restconf Swagger Documentation
Devin Avery [Mon, 16 Jun 2014 13:38:18 +0000 (09:38 -0400)]
Bug 931, Bug 910 - Enhance Restconf Swagger Documentation

    1) We now generate different data models for config and operation data stores
    2) We no longer generate URLs for leaf nodes since RESTConf doesn't support those
    3) We now expose our mount points in our system in a list, which a user can select and view the list of mounted resources
    4) Cleaned up non-ODL branding, adding in ODL branding.

    To test
    A) Add a device which has mounts in your system (consider ping 2.0 https://wiki.opendaylight.org/view/Ping_2.0_-_Discover_and_Model_Plugin or a netconf device)
    B) Navigate to http://localhost:8080/apidoc/explorer)

Patch Set 2: Original Change
Patch Set 3: Rebased, remformmated existing code which used 2 spaces instead of 4
Patch Set 4: Kicking off a second build, since I got mixed build messages.

Change-Id: Ic1f7ad60c6ccd1079d35e66c0dbc4d1a760dd0ec
Signed-off-by: Devin Avery <devin.avery@brocade.com>
10 years agoBUG 1129:Removed hard coded version from netconf project as part of the automated...
Vaishali Mithbaokar [Tue, 17 Jun 2014 01:41:07 +0000 (18:41 -0700)]
BUG 1129:Removed hard coded version from netconf project as part of the automated release changes for controller

Change-Id: If4884987d8a0683a7a7817bc724fa707a93e3628
Signed-off-by: Vaishali Mithbaokar <vmithbao@cisco.com>
10 years agoBug 225 - added support for depth RESTCONF parameter in URI
tpantelis [Wed, 4 Jun 2014 22:53:36 +0000 (18:53 -0400)]
Bug 225 - added support for depth RESTCONF parameter in URI

Modified RestconfImpl to prune the resulting ComositeNode tree
based on the depth parameter, if specified.

A depth of 1 retrieves just the target resource and no children. This is
a way to determine if the resource exists. A depth of 2 retrieves the
target resource and just its direct children - any child container would
be empty.

Change-Id: I44d99f9886e3837a1bb13eda84aec3c4cc6b21ae
Signed-off-by: tpantelis <tpanteli@brocade.com>
10 years agoBug 1176: Lower log level when netconf ssh connection fails
Tomas Olvecky [Fri, 13 Jun 2014 10:53:55 +0000 (12:53 +0200)]
Bug 1176: Lower log level when netconf ssh connection fails

Change-Id: I041a91040d33d055b8d05c3251f357c826e20c09
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
10 years agoFix netconf ssh client
Tomas Olvecky [Fri, 13 Jun 2014 10:26:33 +0000 (12:26 +0200)]
Fix netconf ssh client

Do not throw exceptions from Runnable, instead log them.

Change-Id: I0e5e6cb2b23eacecc5e4b4a737437d3c4e5058b3
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
10 years agoBUG-272: Fix module whitespace
Robert Varga [Sun, 8 Jun 2014 18:38:17 +0000 (20:38 +0200)]
BUG-272: Fix module whitespace

This patch fixes yang module whitespace to make the structure clear.

Change-Id: I05442cff873b31a2e68f010c630a4b3da2f5c0c3
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoBug 951 - Externalize cors definition of restconf
Tomas Olvecky [Wed, 7 May 2014 12:23:08 +0000 (14:23 +0200)]
Bug 951 - Externalize cors definition of restconf

Create new project called filter-valve that allows defining filters
outside of web.xml. An xml file is added to configuration folder
of distribution.

The valve allows any kind of filters to be applied around each
request, mapping contexts and path pattern same way as servlet
specification does. The xml file allows defining filter templates,
each context (WAB) can reuse and modify the common configuration.

Currently only restconf has externalized cors filter definition.

Change-Id: Ia8b6053efdff2b3c1150eec95e63b460d84c457e
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
10 years agoMerge changes I52e0dd0d,I6dbf3316,Iafae27bc,Ibbb1250b,Icdb56d14,I7ede1482,Ib335fd1d...
Tony Tkacik [Tue, 10 Jun 2014 19:33:30 +0000 (19:33 +0000)]
Merge changes I52e0dd0d,I6dbf3316,Iafae27bc,Ibbb1250b,Icdb56d14,I7ede1482,Ib335fd1d,I6ce09820,I621fa3a4

* changes:
  BUG-272: fix issues in sal-rest-docgen
  BUG-272: fix sal-binding-api
  BUG-272: fix sal-compatibility
  BUG-272: fix sal-dom-spi
  BUG-272: fix sal-dom-broker
  BUG-272: fix sal-remoterpc-connector
  BUG-272: fix remoterpc-routingtable
  BUG-272: fix sal-dom-api
  BUG-272: fix sal-binding-broker

10 years agoMerge changes I63383291,I1c9f10e9,I9cac529f,I269d373b,I7ede3ba5,I4afc1e15
Tony Tkacik [Tue, 10 Jun 2014 17:32:19 +0000 (17:32 +0000)]
Merge changes I63383291,I1c9f10e9,I9cac529f,I269d373b,I7ede3ba5,I4afc1e15

* changes:
  BUG-272: fix sal-common-api
  BUG-272: fix sal-netconf-connector
  BUG-272: fix toaster-consumer
  BUG-272: cleanup sal-rest-connector
  BUG-272: use L for long suffix
  BUG-272: remove empty statements

10 years agoBUG-272: fix issues in sal-rest-docgen
Robert Varga [Tue, 10 Jun 2014 12:51:08 +0000 (14:51 +0200)]
BUG-272: fix issues in sal-rest-docgen

This fixes some small issues in sal-rest-docgen.

Change-Id: I52e0dd0d4aaed1363f203e81acf3922b4dd285b5
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoBUG-272: cleanup sal-rest-connector
Robert Varga [Tue, 10 Jun 2014 09:15:04 +0000 (11:15 +0200)]
BUG-272: cleanup sal-rest-connector

Preparatory patch, expand wildcard imports to get rid of checkstyle
failures. Save action added final keywords where appropriate.

Change-Id: I269d373bed9fd83d3837f9ed4d3ff7fc105d7305
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoBUG-272: remove empty statements
Robert Varga [Tue, 10 Jun 2014 09:05:54 +0000 (11:05 +0200)]
BUG-272: remove empty statements

Preparatory patch: removes reported empty statements.

Change-Id: I4afc1e15efe6edd5d48ea8f40e189ee1e1774d4e
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoMerge "BUG-272: remove tabs from Java files"
Tony Tkacik [Tue, 10 Jun 2014 11:02:28 +0000 (11:02 +0000)]
Merge "BUG-272: remove tabs from Java files"

10 years agoMerge "BUG-272: remove trailing whitespace from Java files"
Tony Tkacik [Tue, 10 Jun 2014 10:47:22 +0000 (10:47 +0000)]
Merge "BUG-272: remove trailing whitespace from Java files"

10 years agoMerge "BUG-272: remove trailing whitespace from XML files"
Tony Tkacik [Tue, 10 Jun 2014 10:46:50 +0000 (10:46 +0000)]
Merge "BUG-272: remove trailing whitespace from XML files"

10 years agoMerge "BUG-272: remove tabs from XML files"
Tony Tkacik [Tue, 10 Jun 2014 10:46:37 +0000 (10:46 +0000)]
Merge "BUG-272: remove tabs from XML files"

10 years agoBUG-272: remove tabs from Java files
Robert Varga [Tue, 10 Jun 2014 09:02:29 +0000 (11:02 +0200)]
BUG-272: remove tabs from Java files

Preparatory patch: bulk-convert tabs to 4 spaces.

Change-Id: I4c24c763faf41cb4fcfd0277f8b3c7511269e9b7
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoBUG-272: remove trailing whitespace from Java files
Robert Varga [Tue, 10 Jun 2014 08:58:26 +0000 (10:58 +0200)]
BUG-272: remove trailing whitespace from Java files

Preparatory patch, bulk-removes all trailing whitespace from Java files.

Change-Id: I1fbef5746df7277b3865429d4faa82fc8ba8cbb5
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoBUG-272: remove trailing whitespace from XML files
Robert Varga [Tue, 10 Jun 2014 08:56:20 +0000 (10:56 +0200)]
BUG-272: remove trailing whitespace from XML files

Preparatory patch, bulk-removes trailing whitespace.

Change-Id: I32287893c6ed3079aa7926567f8d0705f8607564
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoBUG-272: remove tabs from XML files
Robert Varga [Tue, 10 Jun 2014 08:54:33 +0000 (10:54 +0200)]
BUG-272: remove tabs from XML files

Preparatory patch, replaces tabs with 4 spaces.

Change-Id: I84bff9c83d19b9252cf277f23d2931e2ba8dd6de
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoBUG-1105: Implement subtree filtering in netconf
Tomas Olvecky [Thu, 5 Jun 2014 15:43:20 +0000 (17:43 +0200)]
BUG-1105: Implement subtree filtering in netconf

Implement subtree filtering according to RFC 6241 section 6.
Current implementation first gathers response XML, then
applies filtering. Since netconf server is pluggable,
modules that might consume significant amount of time
to build their response can read the filter and optimize
their result. Even if modules do not support filtering,
their result is filtered by SubtreeFilter right before
sending out the aggregated response.

Change-Id: Ica04f8f3adfe06599e54a577fceca0508554d667
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
10 years agoBUG-981: Fix XML serialization test
Robert Varga [Sun, 8 Jun 2014 18:56:59 +0000 (20:56 +0200)]
BUG-981: Fix XML serialization test

Since commit 7624eedc495e85d12c2c2c56efb09dfd9406f977 changed XML
resolution rules such that XML namespace is required to properly
identify a node.

This broke serialization tests, which did not provide module/revision
identification -- which meant serialized data was being handled by
String encoder. The string encoder does not do the right thing for
arrays -- which broke the bits and binary encoding tests.

Fix the tests to specify module/revision, thus matching conforming to
schema.

Change-Id: I5cbee0e19b85ebe3a5cf181a0e2d2ca044bfe07e
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoMerge "Checkstyle plugin check - config & netconf"
Tony Tkacik [Fri, 6 Jun 2014 08:19:33 +0000 (08:19 +0000)]
Merge "Checkstyle plugin check - config & netconf"

10 years agoMerge "BUG 624 - Make netconf TCP port optional."
Tony Tkacik [Fri, 6 Jun 2014 08:14:13 +0000 (08:14 +0000)]
Merge "BUG 624 - Make netconf TCP port optional."

10 years agoMerge "Bug 762: Fix sal-rest-connector unit tests"
Ed Warnicke [Thu, 5 Jun 2014 16:06:54 +0000 (16:06 +0000)]
Merge "Bug 762: Fix sal-rest-connector unit tests"

10 years agoCheckstyle plugin check - config & netconf
Milos Fabian [Wed, 4 Jun 2014 14:13:04 +0000 (16:13 +0200)]
Checkstyle plugin check - config & netconf

-violations do not fail build
-rules defined in yangtools/common/checkstyle-logging:
https://git.opendaylight.org/gerrit/#/c/7595/
https://git.opendaylight.org/gerrit/#/c/7108/

Change-Id: I2b1c458c09068c4a520afe37b3adb26e503882ba
Signed-off-by: Milos Fabian <milfabia@cisco.com>
10 years agoBug 762: Fix sal-rest-connector unit tests
tpantelis [Sun, 25 May 2014 04:04:21 +0000 (00:04 -0400)]
Bug 762: Fix sal-rest-connector unit tests

The cnsn-to-json/simple-data-types/xml/data.xml test file used by
CnSnToJsonBasicDataTypesTest actually contains some invalid union type data.
The tests currently pass because union type input data isn't currently
validated. Patch https://git.opendaylight.org/gerrit/#/c/7367/
in yangtools adds validation so the unit tests must be fixed before
that patch is merged.

In addition, the yangtools patch changes some static fields in
TypeDefinitionAwareCodec to private which breaks compilation of
CnSnToXmlTest. This patch modifies CnSnToXmlTest to not use the static
fields.

Change-Id: I020ffacd4a6c96265a191fa74f982de807e336a4
Signed-off-by: tpantelis <tpanteli@brocade.com>
10 years agoMerge "Do not use deprecated destroyConfigBean in config tests"
Tony Tkacik [Wed, 4 Jun 2014 14:25:52 +0000 (14:25 +0000)]
Merge "Do not use deprecated destroyConfigBean in config tests"

10 years agoDo not use deprecated destroyConfigBean in config tests
Tomas Olvecky [Wed, 4 Jun 2014 09:32:54 +0000 (11:32 +0200)]
Do not use deprecated destroyConfigBean in config tests

Replace org.opendaylight.controller.config.util.ConfigTransactionJMXClient
destroyConfigBean with destroyModule in tests.
Test resource leaks in FixedThreadPoolConfigBeanTest.

Change-Id: If3847d3cb9211d9e830006400c258dad9e6ffb35
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
10 years agoMerge "Bug 1100 - Invoking an RPC with no input should not throw 500 when expected"
Tony Tkacik [Tue, 3 Jun 2014 16:21:56 +0000 (16:21 +0000)]
Merge "Bug 1100 - Invoking an RPC with no input should not throw 500 when expected"

10 years agoBUG 624 - Make netconf TCP port optional.
Tomas Olvecky [Tue, 27 May 2014 10:41:16 +0000 (12:41 +0200)]
BUG 624 - Make netconf TCP port optional.

Previously netconf-impl opened a TCP port with no authentication on
localhost, and netconf-ssh used it as a bridge to forward trafic
after processing authentication and encryption.

This patch creates new project netconf-tcp and modifies netconf-impl
to open the netconf server on LocalAddress. Both tcp and ssh modules
now communicate with this local server.
Config ini is modified so that the TCP port (8383) is not enabled
by default.

Change-Id: I74bded660f10b20d09535d32308aff5b2ae611d9
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
10 years agoBug 981: Converted test to use BitsType.create()
Tony Tkacik [Fri, 30 May 2014 14:39:36 +0000 (16:39 +0200)]
Bug 981: Converted test to use BitsType.create()

Change-Id: I759c55c48de64e48c5757aba5b7665f2478aa0fb
Signed-off-by: Tony Tkacik <ttkacik@cisco.com>
10 years agoMerge "Bug 1003: Restconf - remove whitespace on input"
Tony Tkacik [Fri, 30 May 2014 12:33:04 +0000 (12:33 +0000)]
Merge "Bug 1003: Restconf - remove whitespace on input"

10 years agoBug 1100 - Invoking an RPC with no input should not throw 500 when expected
Devin Avery [Thu, 29 May 2014 20:42:03 +0000 (16:42 -0400)]
Bug 1100 - Invoking an RPC with no input should not throw 500 when expected

Patch Set 3:
*Modified the Json/Xml readers to not throw an except if the content is empty
*Moved the validation of non empty object into restconf where the knowledge
of what is expected exists.

Change-Id: I4e689770d1a6843e99ce498bd12cecc5e1817eaa
Signed-off-by: Devin Avery <devin.avery@brocade.com>
10 years agoBug 1010: Implement restconf error responses
tpantelis [Thu, 8 May 2014 18:25:02 +0000 (14:25 -0400)]
Bug 1010: Implement restconf error responses

- RestconfError (new): encapsulates error information as defined in the
  RESTCON RFC.

- RestconfDocumentedException (new): exception that wraps RestconError info.

- RestconfDocumentedExceptionMapper (new): JAX-RS ExceptionMapper that
  translates a RestconfDocumentedException appropriately to XML or
  JSON depending on the user's mime type.

- JsonMapper: modified to handle null child schema as restconf error-info
  is defined as 'anyxml' and thus no schema may be present.

- ControllerContext: added getRestconfModuleErrorsSchemaNode method to
  obtain the 'errors' container schema from the ietf-restconf module.

- Removed ResponseException and changed occurrences in various classes that
  threw ResponseException to throw RestconfDocumentedException instead.

- Added unit tests for new classes and modified existing ones
  accordingly.

Change-Id: Idbe6f6cae9b40ba14701ee05dfadfdd51e961c6b
Signed-off-by: tpantelis <tpanteli@brocade.com>
10 years agoMerge "BUG-624 make netconf tcp address optional in config.ini with default value...
Tony Tkacik [Mon, 26 May 2014 19:49:08 +0000 (19:49 +0000)]
Merge "BUG-624 make netconf tcp address optional in config.ini with default value set to 127.0.0.1:8383"

10 years agoMerge "Bug 1036 - Allow using container in case stmt to preserve uniqueness."
Tony Tkacik [Mon, 26 May 2014 19:48:32 +0000 (19:48 +0000)]
Merge "Bug 1036 - Allow using container in case stmt to preserve uniqueness."

10 years agoBUG-624 make netconf tcp address optional in config.ini with default value set to...
Tomas Olvecky [Mon, 26 May 2014 09:49:00 +0000 (11:49 +0200)]
BUG-624 make netconf tcp address optional in config.ini with default value set to 127.0.0.1:8383

Change-Id: I2a5732bd6bbb010b03d7daebb6bf30633ad536fb
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
10 years agoBug 1003: Restconf - remove whitespace on input
tpantelis [Mon, 26 May 2014 05:47:18 +0000 (01:47 -0400)]
Bug 1003: Restconf - remove whitespace on input

JsonReader, XmlReader:
   - Trimmed whitespace on leaf data input

AbsractRpcExecutor, BrokerRpcExecutor, MountPointRpcExecutor:
   - Modified to handle IllegalArgumentEx and UnsupportedOperationEx
     thrown from invokeRpc to throw appropriate ResconfDocumentedEx.

ResconfDocumentedExeptionMapper, RestconfError, RestconfErrorTest:
   - I discovered that the Response.Status.NOT_IMPLEMENTED jaxrs enum
     is defined in the enum class that is used at compile time but
     isn't defined in the run time enum class provided by jersey.
     So I changed RestconfError.ErrorTag to store the integer status
     code (501) instead of the enum. Ideally compile and run time
     should use the same lib.

- SchemaAwareRpcBroker:
   - Modified to throw UnsupportedOperationEx if no RPC impl is found
     so the restconf front-end can yield the appropriate
     501 (Not Implemented) status code.

Change-Id: Ibfa1dc7ff1526b6d352b9f4e6be2aae0d19ab655
Signed-off-by: tpantelis <tpanteli@brocade.com>
10 years agoMerge changes I8dc2b4df,I09e448f4
Tony Tkacik [Fri, 23 May 2014 15:11:10 +0000 (15:11 +0000)]
Merge changes I8dc2b4df,I09e448f4

* changes:
  Bug 1062 - Disallow implicit serviceref creation.
  Bug 1062 - Allow multiple service references with same name.

10 years agoMerge changes Ieef23a07,I8057763e
Tony Tkacik [Fri, 23 May 2014 15:02:57 +0000 (15:02 +0000)]
Merge changes Ieef23a07,I8057763e

* changes:
  BUG-868: migrate users of CompositeNode.getChildren()
  BUG-731: Warning suppression is not necessary

10 years agoMerge "Bug 716: Errors on controller shutdown"
Tony Tkacik [Fri, 23 May 2014 12:42:54 +0000 (12:42 +0000)]
Merge "Bug 716: Errors on controller shutdown"

10 years agoMerge "Bug 735 - Part 2 - Modify controller to reference new yang-types bundle and...
Tony Tkacik [Fri, 23 May 2014 12:34:21 +0000 (12:34 +0000)]
Merge "Bug 735 - Part 2 - Modify controller to reference new yang-types bundle and and ietf-bundles."

10 years agoBUG-868: migrate users of CompositeNode.getChildren()
Robert Varga [Fri, 23 May 2014 10:35:19 +0000 (12:35 +0200)]
BUG-868: migrate users of CompositeNode.getChildren()

This converts the callers from getChildren() to getValue(), eliminating
around a hundred of warnings in eclipse.

Change-Id: Ieef23a07ac02b719866ec447a7e3365ab11e150a
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoBug 1036 - Allow using container in case stmt to preserve uniqueness.
Tomas Olvecky [Tue, 20 May 2014 12:26:07 +0000 (14:26 +0200)]
Bug 1036 - Allow using container in case stmt to preserve uniqueness.

Modify yang-jmx-generator and config-netconf-connector to allow adding
dummy container node.
This allows declaring multiple config modules with same attributes within
single yang module.

Change-Id: I49ae30143e45f590f4be6b4713e048bdf9e72edb
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
10 years agoBug 1062 - Disallow implicit serviceref creation.
Tomas Olvecky [Thu, 22 May 2014 09:46:21 +0000 (11:46 +0200)]
Bug 1062 - Disallow implicit serviceref creation.

Remove auto registration of service references by netconf. Old behaviour
was adding ref_ + module name for each interface module implements even
if it is not declared in /services node.

Fix code style warning in config-netconf-connector.

Change-Id: I8dc2b4dffac212d9b8b8243ccd7aaf290b87499b
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
10 years agoBug 735 - Part 2 - Modify controller to reference new yang-types bundle and and ietf...
Devin Avery [Tue, 20 May 2014 15:03:07 +0000 (11:03 -0400)]
Bug 735 - Part 2 - Modify controller to reference new yang-types bundle and and ietf-bundles.

Patch 1: Set up the restconf bundle to reference the ietf-restconf and ietf-yangtypes-2013 bundles respectively.

Patch 2: Kick off another jenkins build now that dependent artifacts exist.

Patch 3/4: Fixed version issue.

Change-Id: I68b8edc577f5b2e84661a8a4eaed2078c0623aab
Signed-off-by: Devin Avery <devin.avery@brocade.com>
10 years agoMerge "Bug 992 - Fix broken netconf xml serialization."
Tony Tkacik [Wed, 21 May 2014 16:18:51 +0000 (16:18 +0000)]
Merge "Bug 992 - Fix broken netconf xml serialization."

10 years agoCouple of warnings
Robert Varga [Tue, 20 May 2014 10:05:49 +0000 (12:05 +0200)]
Couple of warnings

This fixes a couple of warnings about pom.xml declaring duplicate things
(groupId, version).

Change-Id: Idb6e362a78cfa5d96609db6ebcc581e9349a08a4
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoMerge "Bug 624 - Separate netty and exi specific classes from netconf-util."
Ed Warnicke [Mon, 19 May 2014 12:39:04 +0000 (12:39 +0000)]
Merge "Bug 624 - Separate netty and exi specific classes from netconf-util."

10 years agoMerge "Bug 953 - Enable mounted RPC calls via RestConf"
Tony Tkacik [Mon, 19 May 2014 12:35:53 +0000 (12:35 +0000)]
Merge "Bug 953 - Enable mounted RPC calls via RestConf"

10 years agoMerge "Store yang store snapshot cache using soft reference."
Ed Warnicke [Mon, 19 May 2014 12:28:20 +0000 (12:28 +0000)]
Merge "Store yang store snapshot cache using soft reference."

10 years agoBug 992 - Fix broken netconf xml serialization.
Tomas Olvecky [Wed, 14 May 2014 15:34:11 +0000 (17:34 +0200)]
Bug 992 - Fix broken netconf xml serialization.

Empty commit and restart triggered xml deserialization errors
in netconf. The problem is in type and name elements - they
should not be prefixed with 'prefix:'.

This fix triggers other bugs in md-sal modules, tracked
as dependencies of this bug. To test proper (de)serialization
with this fix, 01-netconf-connector.xml and 02-clustering.xml
must be delted.

Change-Id: I54d6ab23ec27ccbed924bf6abff95736f49dd5a3
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
10 years agoMerge "Trigger a GC once initial configuration has been pushed"
Tony Tkacik [Mon, 19 May 2014 09:50:34 +0000 (09:50 +0000)]
Merge "Trigger a GC once initial configuration has been pushed"

10 years agoBug 624 - Separate netty and exi specific classes from netconf-util.
Tomas Olvecky [Tue, 13 May 2014 13:26:28 +0000 (15:26 +0200)]
Bug 624 - Separate netty and exi specific classes from netconf-util.

As preparation step for splitting netconf into service and protocol,
create netconf-netty-util bundle with classes dependent on protocol
handlers - netty, exi, ssh.

Change-Id: I22ba17d0fa4f86c5f64cb3258a55f2c54da85dee
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
10 years agoBug 953 - Enable mounted RPC calls via RestConf
Devin Avery [Thu, 8 May 2014 13:00:29 +0000 (09:00 -0400)]
Bug 953 - Enable mounted RPC calls via RestConf

Modify RestconfImpl to allow RPC calls via mount points.
===
MountPointImpl - wired pass through call for invokeRpc that was missing.
RestconfImpl - abstract the execution of RPC out to an "RpcExecutor" class.
Remaining classes - added tests to cover new code, including the toaster.yang file (modified from original) to test various RPC calls.

- Patch Set 8 - fixed unit tests which were failing (one failure due to missing future enhancement, another due to missing test rpc in yang file).
- Patch Set 10 - fixed run failure by addressing package import.
- Patch Set 13 - Cleaned up exception throws / used Preconditions checking.
- Patch Set 14 - Rebased
- Patch Set 15 - Added back change that was accidently removed during merge / rebase.

Change-Id: Ib214b4c82ffc487ee2f7b912e65d5c189b82154a
Signed-off-by: Devin Avery <devin.avery@brocade.com>
10 years agoMerge "Bug 1002 - REST POST transaction is not commited"
Tony Tkacik [Thu, 15 May 2014 12:02:38 +0000 (12:02 +0000)]
Merge "Bug 1002 - REST POST transaction is not commited"

10 years agoBug 1002 - REST POST transaction is not commited
Vaclav Demcak [Wed, 14 May 2014 12:39:10 +0000 (14:39 +0200)]
Bug 1002 - REST POST transaction is not commited

fix REST POST create workflow (create data only), fix according to specification
  http://tools.ietf.org/html/draft-bierman-netconf-restconf-03#section-2.4

I'm missing implementation for ietf-restconf:errors, so I can't do more for now
  http://tools.ietf.org/html/draft-bierman-netconf-restconf-03#page-48

* fix a check for an existing node in DataStore
* add warn log and a correct ResponseException
* fix tests for BrokerFacade

Change-Id: I68c95e831f42cae4df0608a40c585251a631693f
Signed-off-by: Vaclav Demcak <vdemcak@cisco.com>
10 years agoTrigger a GC once initial configuration has been pushed
Robert Varga [Wed, 14 May 2014 22:04:17 +0000 (00:04 +0200)]
Trigger a GC once initial configuration has been pushed

This introduces a single run of GC once we complete the initial
configuration.

The reasoning behind that is that we generate a fair amount of metadata
which we are likely to retain unmodified for extended periods of time.
We take care to store it in both memory and CPU efficient format, which
unfortunately requires us to do some copying around to compact it,
leaving a sizeable chunk of garbage on the heap.

Change-Id: I81af7d317e3b6f82a431e78b5fb439d8cb5f1997
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoMerge "BUG 1001 Failing test - RestGetOperationTest.getStreamsTest"
Tony Tkacik [Wed, 14 May 2014 10:16:45 +0000 (10:16 +0000)]
Merge "BUG 1001 Failing test - RestGetOperationTest.getStreamsTest"

10 years agoBUG 1001 Failing test - RestGetOperationTest.getStreamsTest
Jozef Gloncak [Wed, 14 May 2014 08:23:24 +0000 (10:23 +0200)]
BUG 1001 Failing test - RestGetOperationTest.getStreamsTest

responseBody variable now contained some data and therefore it wasn't xml
tag <streams/> but <streams></streams>

Change-Id: I73004f848f0dfc5f2929f8f8ea2dbd6afc25d35a
Signed-off-by: Jozef Gloncak <jgloncak@cisco.com>
10 years agoMerge "Bug 617: Remove extend files from sal-rest-connector"
Tony Tkacik [Tue, 13 May 2014 15:02:41 +0000 (15:02 +0000)]
Merge "Bug 617: Remove extend files from sal-rest-connector"

10 years agoMerge "BUG-704 Remove pax from netconf identity-ref test."
Tony Tkacik [Mon, 12 May 2014 16:35:07 +0000 (16:35 +0000)]
Merge "BUG-704 Remove pax from netconf identity-ref test."

10 years agoStore yang store snapshot cache using soft reference.
Tomas Olvecky [Mon, 12 May 2014 12:58:53 +0000 (14:58 +0200)]
Store yang store snapshot cache using soft reference.

Change-Id: I9b159db83ba204b4a636f2314fd4fc2e7b6f654c
Signed-off-by: Tomas Olvecky <tolvecky@cisco.com>
10 years agoBUG-704 Remove pax from netconf identity-ref test.
Maros Marsalek [Fri, 9 May 2014 12:58:08 +0000 (14:58 +0200)]
BUG-704 Remove pax from netconf identity-ref test.

Make this test a regular unit test without pax.

Change-Id: I0f9767d860f25bb60494ded2011e3f398fbcf43f
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
10 years agoMerge "Add serialVersionUID to Serializable"
Tony Tkacik [Mon, 12 May 2014 07:02:33 +0000 (07:02 +0000)]
Merge "Add serialVersionUID to Serializable"

10 years agoAdd serialVersionUID to Serializable
Robert Varga [Sun, 11 May 2014 07:16:29 +0000 (09:16 +0200)]
Add serialVersionUID to Serializable

Serializable classes have to have serialVersionUID. Add it where it's
missing.

Change-Id: I23689005878280b6ee9f97fb12ae0b15151f20d7
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoBUG-981: remove deprecated use of constructors
Robert Varga [Sun, 11 May 2014 05:35:34 +0000 (07:35 +0200)]
BUG-981: remove deprecated use of constructors

This removes the use of all constructors, such that we initialize in one
go.

Change-Id: Iff461a878fb7061b0ea1c8efea6a34b833645784
Signed-off-by: Robert Varga <rovarga@cisco.com>
10 years agoBug 716: Errors on controller shutdown
tpantelis [Tue, 22 Apr 2014 16:05:23 +0000 (12:05 -0400)]
Bug 716: Errors on controller shutdown

    Fixed miscellaneous errors on shutdown:
        -  FlowProvider, GroupProvider and MeterProvider: all throw an
           UnsupportedOperationEx from their close methods with a TODO message.
           Implemented close to close the commitHandlerRegistration.

        - NetconfSSHServer: logs a socket closed exception due to closing the socket
          on shutdown. We can ignore this and not log the error (if 'up' is false).

        - RestconfProvider: NPE in stop method calling session.close.
          The 'session' member is never initialized or otherwise used so removed it.

        - RuntimeMappingModule and SchemaServiceImplSingletonModule:
          IllegalStateException from bundleContext.ungetService() call because the
          bundle has already been shutdown. Ignore ex as this can occur
          normally.

Need someone to commit this!

Change-Id: I31d9d6d66418dda7f5b73c2ad12bb251f3689643
Signed-off-by: tpantelis <tpanteli@brocade.com>
10 years agoMerge "Bug 946: Fixed eclipse errors with nagasena projects"
Tony Tkacik [Wed, 7 May 2014 11:14:22 +0000 (11:14 +0000)]
Merge "Bug 946: Fixed eclipse errors with nagasena projects"

10 years agoBug 617: Remove extend files from sal-rest-connector
tpantelis [Sun, 4 May 2014 17:29:22 +0000 (13:29 -0400)]
Bug 617: Remove extend files from sal-rest-connector

Converted ControllerContext and BrokerFacade xtend code to java.

Addressed review comments:
  - Removed SupressWarnings "all"
  - Converted use of xext classes to guava
  - Removed sneakyThrow

Patch set 4: mistake - no changes

Patch set 5: Converted RestconfImpl

Patch set 6: removed xtend plugin anf dependencies from pom file

Change-Id: I45c22b22fee07a178faba9fcb9e52d3ff12a6697
Signed-off-by: tpantelis <tpanteli@brocade.com>
10 years agoMerge "Bug: 627 Added RESTConf API Explorer that dynamically generates API documentat...
Tony Tkacik [Tue, 6 May 2014 06:52:40 +0000 (06:52 +0000)]
Merge "Bug: 627 Added RESTConf API Explorer that dynamically generates API documentation and serves it through swagger UI. Details are documented in this wiki: https://wiki.opendaylight.org/view/OpenDaylight_Controller:MD-SAL:Restconf_API_Explorer"

10 years agoMerge changes I05e784af,Ie975a2ec
Tony Tkacik [Tue, 6 May 2014 06:49:43 +0000 (06:49 +0000)]
Merge changes I05e784af,Ie975a2ec

* changes:
  BUG-693 Config module for netconf client dispatcher.
  BUG-938 Fix negotiation error when using exi

10 years agoMerge "Skip from the surefire execution plugins that can step over guava feet"
Ed Warnicke [Mon, 5 May 2014 12:10:39 +0000 (12:10 +0000)]
Merge "Skip from the surefire execution plugins that can step over guava feet"

10 years agoBUG-693 Config module for netconf client dispatcher.
Maros Marsalek [Wed, 23 Apr 2014 13:12:47 +0000 (15:12 +0200)]
BUG-693 Config module for netconf client dispatcher.

netconf/
NetconfClientDispatcher and NetconfSSHClientDispatcher merged into NetconfClientDispatcherImpl.
Introduced NetconfClientConfiguration to contain all configuration attributes for netconf clients.
Introduced interface for NetconfClientDispatchers.
Removed NetconfITSecureTest since it did not test secure connection.

config/
Added netconf-config-api maven module, which contains service definition of client-dispatcher.
Added netconf-config-dispatcher maven module, which contains config module for client-dispatcher.

md-sal/
Updated configuration for sal-netconf-connector with client dispatcher dependency (backwards compatibility preserved).

Change-Id: I05e784af6a9b8e11fad21d3bad0311c110754d31
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
10 years agoBug 946: Fixed eclipse errors with nagasena projects
tpantelis [Sat, 3 May 2014 07:30:58 +0000 (03:30 -0400)]
Bug 946: Fixed eclipse errors with nagasena projects

- Uploaded the nagasena OSGi bundle jars to nexus with group ID
org.openexi.
- Changed affected dependencies
- Removed thirdparty/org.openexi project

Change-Id: I280749e287a7b8e918095cff79729888b7caa4ec
Signed-off-by: tpantelis <tpanteli@brocade.com>
10 years agoBUG-938 Fix negotiation error when using exi
Maros Marsalek [Fri, 2 May 2014 08:43:07 +0000 (10:43 +0200)]
BUG-938 Fix negotiation error when using exi

EXIConfirmation handler is now added to pipeline before start-exi is sent.

Add test with secure netconf server + exi

Change-Id: Ie975a2ecf31cfbb8c1fd4e25e8f41876e0552a00
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
10 years agoMerge "BUG 274 REST response instead of NumberFormatException"
Ed Warnicke [Thu, 1 May 2014 15:17:55 +0000 (15:17 +0000)]
Merge "BUG 274 REST response instead of NumberFormatException"

10 years agoSkip from the surefire execution plugins that can step over guava feet
Giovanni Meo [Sun, 27 Apr 2014 00:09:40 +0000 (02:09 +0200)]
Skip from the surefire execution plugins that can step over guava feet

Seems like the com.google.common.collect.* package has been reused in
several jars like:

- guava
- google-collection
- pax-url-aether

Now the netconf-it in the classpath of contains via transitive the 3
of them but only guava is usable by yang-bindings used by the netconf
client test. The presence of the 3 cause unreliability on the test
pass based on who comes first in the classpath of surefire. The fix is
to make sure surefire ignore the other two libraries except guava.

Change-Id: I77260989a19f60db94286434444530bacb1947d4
Signed-off-by: Giovanni Meo <gmeo@cisco.com>
10 years agoMerge "Default auth parameters in config.ini."
Ed Warnicke [Wed, 30 Apr 2014 11:57:27 +0000 (11:57 +0000)]
Merge "Default auth parameters in config.ini."

10 years agoBUG 274 REST response instead of NumberFormatException
Jozef Gloncak [Thu, 24 Apr 2014 13:57:14 +0000 (15:57 +0200)]
BUG 274 REST response instead of NumberFormatException

Raised NumberFormatException is now catched and thrown next as
WebApplicationException which is displayed as return message for REST
call.

Change-Id: I1b4ee74c6a953fe3b64ef47c07477c29d892a87c
Signed-off-by: Jozef Gloncak <jgloncak@cisco.com>
10 years agoBug: 627
Abhishek Kumar [Mon, 28 Apr 2014 23:37:53 +0000 (16:37 -0700)]
Bug: 627
Added RESTConf API Explorer that dynamically generates API documentation and serves it through swagger UI.
Details are documented in this wiki:
https://wiki.opendaylight.org/view/OpenDaylight_Controller:MD-SAL:Restconf_API_Explorer

Change-Id: I11bcf95a8ab3ba0591a06070259c53cf5d7113b0
Signed-off-by: Abhishek Kumar <abhishk2@cisco.com>
10 years agoMerge changes Ie84ea1ff,Ifa0a97da
Tony Tkacik [Tue, 29 Apr 2014 08:32:33 +0000 (08:32 +0000)]
Merge changes Ie84ea1ff,Ifa0a97da

* changes:
  BUG-848 Make base capabilities from netconf server configurable
  BUG-848 Fix netconf communication while using CHUNK encoding

10 years agoDefault auth parameters in config.ini.
Martin Bobak [Thu, 10 Apr 2014 09:10:35 +0000 (11:10 +0200)]
Default auth parameters in config.ini.

    Hardcoded default username and password for ssh authenticaton moved from AuthProvider.java to config.ini
    IUSerManager in AuthProvider.java is not static anymore.

Change-Id: Ia4fd2cddf42d17842869d599d645881b77d2afbd
Signed-off-by: Martin Bobak <mbobak@cisco.com>
10 years agoBUG-848 Make base capabilities from netconf server configurable
Maros Marsalek [Mon, 28 Apr 2014 13:41:35 +0000 (15:41 +0200)]
BUG-848 Make base capabilities from netconf server configurable

Refactor ConcurrentClientsTest, add cases for different netconf server configuration (EXI/CHUNK)

Change-Id: Ie84ea1ff716b11b0da49e0498127a0defc86f41f
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
10 years agoBUG-848 Fix netconf communication while using CHUNK encoding
Maros Marsalek [Mon, 28 Apr 2014 09:12:08 +0000 (11:12 +0200)]
BUG-848 Fix netconf communication while using CHUNK encoding

Cause:
When using Chunk encoding, the negotiation process lasts longer due to pipeline manipulation.
Messages received while still in negotiation were not processed correctly (This is incorrect, messages should not be processed while still in negotiation).

Fix:
Introduce a message barrier that will forward only hello message until negotiation is completed (implemented in NetconfXmlToHelloMessageDecoder).
Modify SessionNegotiators to replace message barier/hello decoder when negotiation is finished and to process non-hello messages stopped by the barier.

* Exclude pax-url-aether dependency in netconf-it

Change-Id: Ifa0a97da75ac3cdca29e29bf40138b637e08ff45
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
10 years agoMerge "Resolve Bug:748 - Remove test resources from netconf-impl."
Ed Warnicke [Mon, 28 Apr 2014 12:28:30 +0000 (12:28 +0000)]
Merge "Resolve Bug:748 - Remove test resources from netconf-impl."

10 years agoMerge changes I8e90a7d5,I25249fe8
Ed Warnicke [Mon, 28 Apr 2014 12:21:45 +0000 (12:21 +0000)]
Merge changes I8e90a7d5,I25249fe8

* changes:
  Resolve Bug:807 - Keep ModuleFactory references shutdown purposes.
  Resolve Bug:681 - Fix config module registration to Service Registry.

10 years agoMerge "BUG 652 leafref CCE & BUG 720 colons problem"
Ed Warnicke [Mon, 28 Apr 2014 12:21:21 +0000 (12:21 +0000)]
Merge "BUG 652 leafref CCE & BUG 720 colons problem"

10 years agoMerge "Bug 460 - Fix warning throughout netconf subsystem"
Ed Warnicke [Mon, 28 Apr 2014 12:18:40 +0000 (12:18 +0000)]
Merge "Bug 460 - Fix warning throughout netconf subsystem"

10 years agoMerge "BUG-732 Fix sal-netconf-connector unable to download schemas"
Tony Tkacik [Mon, 28 Apr 2014 12:01:53 +0000 (12:01 +0000)]
Merge "BUG-732 Fix sal-netconf-connector unable to download schemas"

10 years agoBUG-732 Fix sal-netconf-connector unable to download schemas
Maros Marsalek [Thu, 24 Apr 2014 12:09:02 +0000 (14:09 +0200)]
BUG-732 Fix sal-netconf-connector unable to download schemas

BUG#1 NetconfDeviceListener used wrong method to parse rpc results
BUG#2 Parsing rpc result in NetconfMapping was looking for schema to response even if it was not needed
BUG#3 Netconf client sent base netconf capability in wrong format

Change-Id: I4798b29bb8cd7361d24188b6d5ac40a612a0c6c8
Signed-off-by: Maros Marsalek <mmarsale@cisco.com>
10 years agoBug 460 - Fix warning throughout netconf subsystem
Martin Bobak [Mon, 10 Mar 2014 16:11:35 +0000 (17:11 +0100)]
Bug 460 - Fix warning throughout netconf subsystem

Change-Id: I461a7bab47ef67c13c6fd5864d8938cdd47c3c8b
Signed-off-by: Martin Bobak <mbobak@cisco.com>
10 years agoFix Operation not permitted warning.
Martin Bobak [Fri, 25 Apr 2014 14:05:48 +0000 (16:05 +0200)]
Fix Operation not permitted warning.

This fix removes warning
WARN  o.o.c.n.c.m.c.ModuleElementDefinition - Operation not permitted on
current strategy  while default strategy is merge. Element definition
strategy set to default

that occured on osgi startup.

Change-Id: Ic12ce37e9bfa08cfffd0cac0e591fc49ffe227c6
Signed-off-by: Martin Bobak <mbobak@cisco.com>
10 years agoMerge "Bug 451 - Fix netconf exception handling"
Tony Tkacik [Fri, 25 Apr 2014 08:56:45 +0000 (08:56 +0000)]
Merge "Bug 451 - Fix netconf exception handling"

10 years agoMerge "BUG-832 Add initial configuration for controller self mount"
Tony Tkacik [Fri, 25 Apr 2014 08:02:04 +0000 (08:02 +0000)]
Merge "BUG-832 Add initial configuration for controller self mount"

10 years agoBug 451 - Fix netconf exception handling
Martin Bobak [Mon, 3 Mar 2014 10:17:50 +0000 (11:17 +0100)]
Bug 451 - Fix netconf exception handling

Change-Id: I815b34da996cf2660650577edb2e8ca623ae96df
Signed-off-by: Martin Bobak <mbobak@cisco.com>