Skip to content
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

noDaemon not supported in native mode #374

Open
rmannibucau opened this issue Mar 10, 2021 · 6 comments
Open

noDaemon not supported in native mode #374

rmannibucau opened this issue Mar 10, 2021 · 6 comments
Labels
enhancement New feature or request
Milestone

Comments

@rmannibucau
Copy link
Contributor

$ mvnd install -Dmvnd.noDaemon=true
Exception in thread "main" java.lang.UnsupportedOperationException: The mvnd.noDaemon property is not supported in native mode.
	at org.mvndaemon.mvnd.client.DaemonConnector.connectNoDaemon(DaemonConnector.java:126)
	at org.mvndaemon.mvnd.client.DaemonConnector.connect(DaemonConnector.java:93)
	at org.mvndaemon.mvnd.client.DefaultClient.execute(DefaultClient.java:245)
	at org.mvndaemon.mvnd.client.DefaultClient.main(DefaultClient.java:112)

Would be great to have at least a fallback not "leaking" a daemon when used (even if it is about starting a daemon and killing it at the end)

@gnodet
Copy link
Contributor

gnodet commented Mar 15, 2021

What's your use case for using this option ? My original purpose was to ease debugging, but since you want to use it in native mode, I suspect yours is different ...

@rmannibucau
Copy link
Contributor Author

Mvnd brings more than just mvn without the daemon, like better defaults to cite just one thing.
In some cases I dont want to leak the daemon (consumes too much mem for me in some cases)
Installed with sdkman it is native so unifying both options would be nice.

@gnodet gnodet added the enhancement New feature or request label Mar 15, 2021
@delanym
Copy link
Contributor

delanym commented Mar 30, 2023

With Maven wrapper I have to choose either mvn or mvnd. I don't want to force users either way.

@gnodet
Copy link
Contributor

gnodet commented Mar 30, 2023

With Maven wrapper I have to choose either mvn or mvnd. I don't want to force users either way.

You choose the tool (maven vs any other build system) and the version of the tool used, but you don't want to force the user between mvn and mvnd. Why ?

@delanym
Copy link
Contributor

delanym commented Mar 30, 2023

mvnd requires at least another 1Gb of always-on memory

@gnodet
Copy link
Contributor

gnodet commented Mar 30, 2023

mvnd requires at least another 1Gb of always-on memory

Makes sense. I totally agree with the idea of spawning a daemon and not keeping it alive if the mvnd.noDaemon option is set. It should just be a matter of spawning a daemon, passing the mvnd.noDaemon option and handle it correctly in the daemon after the build (i.e. letting the process die).

@gnodet gnodet added this to the 1.0-m7 milestone Apr 6, 2023
@gnodet gnodet modified the milestones: 1.0-m7, 1.0-m8 Jul 11, 2023
@gnodet gnodet modified the milestones: 1.0-m8, 1.0-m9 Oct 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants