[CONTROLLER-1619] Better error logging for blueprint config parsing errors Created: 22/Mar/17 Updated: 25/Jul/23 Resolved: 14/Nov/18 |
|
| Status: | Resolved |
| Project: | controller |
| Component/s: | blueprint |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | ||
| Reporter: | Sam Hague | Assignee: | Robert Varga |
| Resolution: | Cannot Reproduce | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
Operating System: All |
||
| Attachments: |
|
| Comments |
| Comment by Sam Hague [ 22/Mar/17 ] |
|
The following error came out when a clustered-app-config config.xml file was parsed. The reason the parse failed was because a tag in the config.xml was not defined in the yang. It would be helpful if the error had listed the tag that failed to be parsed. The failing config.xml is also below and the tag was auto-bridge-create. 2017-03-22 17:07:35,931 | ERROR | rint Extender: 2 | ServiceRecipe | 15 - org.apache.aries.blueprint.core - 1.6.1 | Error retrieving service from ServiceRecipe[name='.component-1'] auto-create-bridge was not defined in the yang: <elanmanager-config xmlns="urn:opendaylight:netvirt:elan:config"> |
| Comment by Vratko Polak [ 23/Mar/17 ] |
|
> ServiceRecipe[name='.component-1'] Anyone fixing this, can you look also how your changes affect |
| Comment by Tom Pantelis [ 04/Jul/17 ] |
|
It should log the underlying exception as well that should contain the informative error info. Either way the clustered-app-config just propagates the error so the error reporting would have to be addressed in the underlying parsing code. |
| Comment by Robert Varga [ 14/Nov/18 ] |
|
tpantelis what are the enxt steps on this? |
| Comment by Tom Pantelis [ 14/Nov/18 ] |
|
See my prior comment from July. |
| Comment by Robert Varga [ 14/Nov/18 ] |
|
Ah, now I see, sorry about that. shague do you by any chance have the full exception somewhere? |
| Comment by Sam Hague [ 14/Nov/18 ] |
|
no I don't have the original log, this was on a downstream job that had a bad config.xml file and blew up. I did recreate the original scenario by adding a undefined tag and attached that karaf log on a neon build and the problem is fixed. The output is what was requested. since the original bug was filed we moved to blueprint annotations so maybe that had an impact. 2018-11-14T16:40:24,395 | ERROR | Blueprint Extender: 1 | AbstractFuture | 82 - com.google.guava - 25.1.0.jre | RuntimeException while executing runnable CallbackListener{org.opendaylight.controller.blueprint.ext.DataStoreAppConfigMetadata$1@7888a2f} with executor MoreExecutors.directExecutor()
java.lang.IllegalStateException: Schema for node with name auto-create-bridge2 and namespace urn:opendaylight:netvirt:elan:config does not exist at AbsoluteSchemaPath{path=[(urn:opendaylight:netvirt:elan:config?revision=2015-07-10)elan-config]}
at com.google.common.base.Preconditions.checkState(Preconditions.java:842) ~[82:com.google.guava:25.1.0.jre]
at org.opendaylight.yangtools.yang.data.codec.xml.XmlParserStream.read(XmlParserStream.java:364) ~[?:?]
at org.opendaylight.yangtools.yang.data.codec.xml.XmlParserStream.parse(XmlParserStream.java:186) ~[?:?]
at org.opendaylight.yangtools.yang.data.codec.xml.XmlParserStream.traverse(XmlParserStream.java:216) ~[?:?]
at org.opendaylight.controller.blueprint.ext.BindingContext.parseDataElement(BindingContext.java:93) ~[?:?]
at org.opendaylight.controller.blueprint.ext.DataStoreAppConfigDefaultXMLReader.parsePossibleDefaultA
|