`Func new` not working for java runtime
Version
4.1.0 (and all other recent ones; this hasn't been working for a bit)
Description
Running func new --template "Http Trigger" --name MyHttpTrigger does not work on core tools after running func init
Steps to reproduce
func init TestJavaProject --worker-runtime javafunc new --template "Http Trigger" --name MyHttpTrigger
@aishwaryabh are you able to identify the last CLI version where this worked?
Official docs recommend that users use Maven for java apps (https://learn.microsoft.com/en-us/azure/azure-functions/functions-develop-local?pivots=programming-language-java). From past GH issues and this one, it seems that func new and func init in the command line aren't intende to be used with Java (not in selection menu, throws errors): https://github.com/Azure/azure-functions-core-tools/issues/2562, https://github.com/Azure/azure-functions-core-tools/issues/2542.
Removing Java support is not really an option either (see Maven plugin).
Instead, this issue will be used to update messaging and documentation related to this limitation/restriction.
Marking this as design, as we need to better define this experience.
From @liliankasem : The request for this issue is simply to have a clear error message to improve the experience.
The linked Java epic (#4579) has additional tasks tracking the work required to bring Java templates into Core Tools.