kapua
kapua copied to clipboard
Possible issue with array configuration properties
Describe the bug I defined a Kura service with the following metatype:
<MetaData xmlns="http://www.osgi.org/xmlns/metatype/v1.2.0" localization="en_us">
<OCD id="org.eclipse.kura.internal.rest.provider.RestService"
name="RestService" >
<AD id="allowed.ports"
name="Allowed ports"
type="Integer"
cardinality="3"
required="false"
min="1"
max="65535">
</AD>
</OCD>
<Designate pid="org.eclipse.kura.internal.rest.provider.RestService">
<Object ocdref="org.eclipse.kura.internal.rest.provider.RestService"/>
</Designate>
</MetaData>
I couldn't update the value of the allowed.ports parameter from the Devices -> device entry -> Configuration section of Kapua web console. The configuration sent by the cloud through CONF-V1 doesn't contain the value of the parameter even if it is specified in the Web UI:
<?xml version="1.0" encoding="UTF-8"?>
<esf:configurations xmlns:esf="http://eurotech.com/esf/2.0" xmlns:ns0="http://www.osgi.org/xmlns/metatype/v1.2.0" xmlns:ocd="http://www.osgi.org/xmlns/metatype/v1.2.0">
<esf:configuration pid="org.eclipse.kura.internal.rest.provider.RestService">
<esf:properties/>
</esf:configuration>
</esf:configurations>
To Reproduce
Define a Kura service with the metatype above and try to update the value of the allowed.ports parameter using Kapua console.
Expected behavior The configuration change is applied by the device