[ckan-dev] Override Core Functionalities

Kirstein, Fabian fabian.kirstein at fokus.fraunhofer.de
Tue Apr 7 13:10:19 UTC 2015


Hi,

thanks for the fast response.
I know you provide already a lot of hooks and they are sufficient for a lot of use cases. But still you cannot provide hooks for every possible case. So it would be great to a have a fallback solution when it is necessary to override some module. I just thought the dynamic nature of Python might support such things.




-----Ursprüngliche Nachricht-----
Von: ckan-dev [mailto:ckan-dev-bounces at lists.okfn.org] Im Auftrag von Adrià Mercader
Gesendet: Dienstag, 7. April 2015 14:43
An: CKAN Development Discussions
Betreff: Re: [ckan-dev] Override Core Functionalities

Hi,

The safest way is to use the available interfaces and hooks [1].

Specifically you could look at before_index, that allows you to modify what gets indexed into Solr:

http://docs.ckan.org/en/latest/extensions/plugin-interfaces.html#ckan.plugins.interfaces.IPackageController.before_index

If the functionality you need is not exposed there we might need to add further extension points.


Adrià


[1] http://docs.ckan.org/en/latest/extensions/plugin-interfaces.html

On 7 April 2015 at 13:04, Kirstein, Fabian <fabian.kirstein at fokus.fraunhofer.de> wrote:
> Hello,
>
>
>
> I need to override some core functionalities. For example the 
> ckan.lib.search.index module. I was wondering if there is any way to 
> do that without forking CKAN and modifying it directly. Is it possible 
> to copy the module into an extension and modify the module loading in 
> a way to use the customized module. Any experiences with that?
>
>
>
> 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
>
_______________________________________________
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