-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make the prefix a bit more unique #6
Comments
This seems like a reasonable default. I would like to use |
I really think it's a mistake to use a new prefix for each project @benedekfazekas. Using a unique prefix that we can easily filter on when needed is great, but you're now loading n versions of the same thing into the runtime for no reason. |
not sure I follow. this commit only replaces "deps" with projectname-projectversion (as default) or your custom prefix as the first element of rewritten namespaces. in fact "deps" used to be repeated for transient dependencies but the customisable prefix is not repeated any more. so it used to be this can you post an example tree what you would like to see perhaps? |
Here's a concrete example: cider-nrepl and refactor-nrepl have these deps in common at present: With this new change these libraries will be loaded into the runtime as What I would've liked to have seen is this:
|
I see and appreciate your point. a few points:
any other opinion on this? @frenchy64 @rundis @bbatsov? |
If
Yes, but there's already interest from other projects in using mranderson....
It's not just the load-time, it's also runtime performance (the JIT thinks the code is different when it's the same) and the size of the runtime (same thing loaded by different names). There isn't even a tradeoff here that I can see, all the benefits are on the side of sticking to a single, version-specific, prefix for rewriting. |
still interested in other ppls opinion but i am nearly sold to change the default just to |
Without the version, or some other uniquifyer, you might get conflicts if mranderson starts publishing clojure artifacts. In a sense it has the same problem as the You also risk claiming that rewritten deps are identical when they might not be, because they were created by different versions of mranderson. I'm not sure what sort of problems this might cause, which makes me want to avoid the situation altogether and stick with a version prefix, even if that leads to slightly less sharing. |
I don't fully understand the problems related to having multiple copies of Is a better solution a package manager? ie. rebundling jars with mranderson Perhaps a cron job can watch repositories and automatically copy/release Slight crazy I realise, but more comfortable than having 20 copies of the On Mon, Jul 6, 2015 at 6:08 PM, Lars Andersen [email protected]
|
As discussed here
In the referenced thread a desire to prefix the dependencies with the project name is expressed. I think this is a mistake. We want to eliminate dependency clashes, when several versions of a class is loaded into the classloader, but we don't want to load multiple versions of identical code under different names. If we use the project name as a prefix we won't be able to share the common code and the run time will grow unnecessarily large.
The text was updated successfully, but these errors were encountered: