[ckan-dev] CKAN API - Problems using config_option_update
Adrià Mercader
adria.mercader at okfn.org
Thu Sep 3 08:18:38 UTC 2015
Hi Vladimir,
Not all configuration options can be updated remotely, only a limited
selection considered safe to be updated at runtime. To check the ones
that can be updated you can call `config_option_list` [0]
You can add to these default options following the steps in this tutorial:
http://docs.ckan.org/en/latest/extensions/remote-config-update.html
But having said, `ckan.plugins` is a bad choice, because you will need
to restart the server for it to take effect, otherwise the plugins
won't be actually loaded and you will get exceptions, so it is not
safe to update remotely.
Adrià
[0] http://docs.ckan.org/en/latest/api/index.html#ckan.logic.action.get.config_option_list
On 2 September 2015 at 16:20, Vladimir Mašala <vladimirmasala at gmail.com> wrote:
> Hi all
>
> I have problem with CKAN api.
>
> When I try to update active plugins i get response
>
> {
>
> "help":
> "http://odf-v24-2.cloudapp.net/api/3/action/help_show?name=config_option_update",
>
> "success": false,
>
> "error": {
>
> "message": "Configuration option(s) 'ckan.plugins' can not be updated",
>
> "__type": "Validation Error"
>
> }
>
> }
>
>
> I am calling method
> http://odf-v24-2.cloudapp.net/api/3/action/config_option_update
>
> with payload
>
> {"ckan.plugins":"stats text_view image_view recline_view recline_grid_view
> recline_graph_view recline_map_view webpage_view"}
>
>
> Works fine with other params so as I understand changing this option is
> forbidden by default.
>
>
> What can i do to enable changing plugins via API?
>
>
>
> Thank you
>
>
>
>
>
>
> _______________________________________________
> ckan-dev mailing list
> ckan-dev at lists.okfn.org
> https://lists.okfn.org/mailman/listinfo/ckan-dev
> Unsubscribe: https://lists.okfn.org/mailman/options/ckan-dev
>
More information about the ckan-dev
mailing list