Project

General

Profile

Actions

Patch #20263

closed

Redmine load hook

Added by Ondřej Ezr over 8 years ago. Updated almost 3 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
Plugin API
Target version:
-
Start date:
Due date:
% Done:

0%

Estimated time:

Description

It would be cool to have a load hook to refer from a plugins


Files

redmine-hook.diff (324 Bytes) redmine-hook.diff load_hook Ondřej Ezr, 2015-07-07 12:48
redmine-hook.patch (799 Bytes) redmine-hook.patch load_hook v2 Ondřej Ezr, 2015-07-07 15:43

Related issues

Related to Redmine - Patch #34072: Hook after plugins were loadedClosedGo MAEDA

Actions
Actions #1

Updated by Ondřej Ezr over 8 years ago

This version may be more usefull ... ( after all plugins had loaded, do something... )

Actions #2

Updated by Toshi MARUYAMA over 8 years ago

  • Category set to Plugin API
Actions #3

Updated by Ondřej Ezr over 5 years ago

Any news?

Actions #4

Updated by Go MAEDA over 5 years ago

Ondřej Ezr wrote:

It would be cool to have a load hook to refer from a plugins

Would you describe use cases of the hook?

Actions #5

Updated by Ondřej Ezr over 5 years ago

Whatever code you write you can assure that redmine is fully loaded already.

1) Engine initializers (for plugins in engine) for example.
2) Plugins who wants to load some code after all plugins were initialized.
3) Any code in libs depending on the redmine code should know if redmine is loaded.
4) You can write code for rails and have feature for redmine in your gem.

loads of other cases, always solvable in different way, but nicer by the hook.

My case was 1) 2) and 4) in my experiences with developement for redmine, but obviously after 3 years even the GIT forgot the code I needed it in ... ;)
So if I am concern, close this one rather than asking me iritating questions with obvious answers after 3 years of having simple one line diff.

Please move to some kind of git source code management. You got mergerequests, pull requests. Of course you dont have time to go through every patch by hand :X
Otherwise your software is dead, because community is unable to contribute.

Actions #6

Updated by Go MAEDA over 5 years ago

  • Target version set to Candidate for next major release

Thank you for describing the use cases. Sorry for irritating you but those points were not obvious to me because I am not interested in developing plugins. So, your explanation was helpful to me.

Setting target version to "Candidate for next major release". I think that we need a little more work to merge this change.

  • Someone has to write test code. Test code is needed to add new features to Redmine core.
  • I would like to get feedback from users. Adding/changing public API will affect many users, and it is not easy to change once it is implemented.
Actions #7

Updated by Ondřej Ezr over 5 years ago

Yeah, I was more irritated for the 3 years gap from first response, I understand this needs time to get evaluated and tested before merge.
But 3 years is far from being effective.

I think that gitlab for example would give you a lot more efficiency you need.
Exactly what you are describing would still be needed to be done, but it would be much easier.

AND community is used to git nowadays, somebody could even write the tests already for me :)
OR I could do it far more easily :)

Just the notes. I know, you probably already considered it and still didn't, for some reason I can't see, do it, but I am voting for it if it's worth something :)

I alone know of at least 4 programmers who would like to colaborate, but doesn't because they knows your response time is too high to be helpful for them, so they has to go monkey patch and don't bother to program to the core :)

I will try to remember it and help if I got time, but I already dont have the code localy. So needs more time.

Actions #8

Updated by Go MAEDA over 3 years ago

  • Related to Patch #34072: Hook after plugins were loaded added
Actions #9

Updated by Go MAEDA over 3 years ago

  • Status changed from New to Needs feedback
  • Target version deleted (Candidate for next major release)

The upcoming Redmine 4.2.0 will have :after_plugins_loaded that is called after all plugins are loaded (#34072). I think you you can use the new hook as an alternative to the proposed patch.

Actions #10

Updated by Go MAEDA almost 3 years ago

  • Status changed from Needs feedback to Closed
Actions

Also available in: Atom PDF