I am writing the plugin for Jira by using Atlassian SDK and I want to change the logic of
API:
com.atlassian.jira.issue.changehistory.metadata.HistoryMetadataManager (its default implementation is
com.atlassian.jira.issue.changehistory.metadata.DefaultHistoryMetadataManager)
Is it possible? If yes, how can I implement it, thank a lot.
I have used injection annotation of spring like @Primary @Component but it does not run correctly, the default implementation cannot be overriden by this way.
I think the solution will be the same for confluence, bitbucket,....
That's a core built-in function, you'll need a "type 1" plugin, or changes to the main code if you want to override it.
I'd recommend not doing that. Write a "type 2" plugin that provides an extra REST endpoint to do what you need, and leave the main code alone. You'll find it easier to write, support and upgrade.
No, seriously, you don't want to do this, it's a nightmare to write, implement or support and wrecks your chances of upgrade.
The developer docs do have stuff on writing them, but it's not explicitly "type 1", it's just quietly pointed out that installation and usage is manual and risky when you get to it.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.