Edit by Adrien: Since the question was posted without a body, I took the liberty of filling in the symptoms.
If a plugin needs a cache, the Atlassian documentation advises to import following, which doesn't work:
<component-import key="cacheFactory" interface="com.atlassian.cache.CacheFactory" />
The plugin installation fails with the following messages:
Plugin 'com.[...]' never resolved service '&cacheFactory' with filter '(objectClass=com.atlassian.cache.CacheFactory)'
How to use the cache in JIRA?
As Nic said, you haven't given us much to work with, but I'll take a wild stab...
For historic reasons, JIRA exports the heavier CacheManager interface instead of the nice, thin CacheFactory. It really shouldn't do this, because CacheManager has management interfaces that plugins have no business using, like flushing all of the caches, but it's what we did so it's here to stay for the time being.
This may make it harder for the plugin system to resolve it as a CacheFactory, particularly if you are using the atlassian-cache-compat for cross-version compatibility or have made your plugin "transformerless".
tl;dr: Replace CacheFactory with CacheManager (even though the former has @PublicApi and the latter @Internal, yes)
<component-import key="cacheFactory" interface="com.atlassian.cache.CacheManager" />
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Adrien Ragot (Play SQL / CYO): "... the Atlassian documentation advises ..."
Could you provide a link to the documentation that you're speaking of? The only example of that I have been able to find was in the documentation for Stash add-on developers, and it actually works there because they were not burdened with this historical usage and chose to register it in the container properly.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Might need a bit more detail on this one...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.