You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@felix.apache.org by "Carsten Ziegeler (Jira)" <ji...@apache.org> on 2020/12/04 06:30:00 UTC

[jira] [Comment Edited] (FELIX-6363) Simplify updating of OSGi configurations through REST API

    [ https://issues.apache.org/jira/browse/FELIX-6363?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17243749#comment-17243749 ] 

Carsten Ziegeler edited comment on FELIX-6363 at 12/4/20, 6:29 AM:
-------------------------------------------------------------------

I've updated the web console implementation. If the parameter "apply=update" is specified, then parameters not listed in the properties list are not deleted anymore. Allowing to just update/add the provided ones.
I decided against introducing another parameter as this would be an incompatible change in the case a configuration has a property named "update" 


was (Author: cziegeler):
I've updated the web console implementation. If the paramtere "apply=update" is specified, then parameters not listed in the properties list are not deleted anymore. Allowing to just update/add the provided ones.
I decided against introducing another parameter as this would be an incompatible change in the case a configuration has a property named "update" 

> Simplify updating of OSGi configurations through REST API
> ---------------------------------------------------------
>
>                 Key: FELIX-6363
>                 URL: https://issues.apache.org/jira/browse/FELIX-6363
>             Project: Felix
>          Issue Type: Bug
>          Components: Web Console
>            Reporter: Peter Grape
>            Assignee: Carsten Ziegeler
>            Priority: Major
>             Fix For: webconsole-4.5.6
>
>
> When updating a single value using the REST API the unreferenced properties in a configuration is deleted, this is not what the documentation is saying on: 
> [https://felix.apache.org/documentation/subprojects/apache-felix-web-console/web-console-restful-api.html#configuration-admin-plugin]
> If I instead add all the properties to the propertyList parameter all those referenced are updated and/or saved .
>  
> This cannot be right because I will then have to query for all parameters before I am able to update a single one.
> Since there is a delete option in the REST API this should only as stated in the documentation update the referenced parameters and leave all others untouched.
>  
> Either add an extra option with the possibility to delete unreferenced properties.
> or remove the code all together.
>  
> The code that does the deletion is here: 
> [https://github.com/apache/felix-dev/blob/ab2c3ac3a570ba316daeb6368bab8193805f37c0/webconsole/src/main/java/org/apache/felix/webconsole/internal/configuration/ConfigAdminSupport.java#L304]
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)