[jboss-jira] [JBoss JIRA] (WFLY-10851) Enable CDI by default when MP Config usage is detected in the deployment
Brian Stansberry (JIRA)
issues at jboss.org
Wed Aug 15 11:49:00 EDT 2018
[ https://issues.jboss.org/browse/WFLY-10851?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Brian Stansberry moved WFWIP-59 to WFLY-10851:
----------------------------------------------
Project: WildFly (was: WildFly WIP)
Key: WFLY-10851 (was: WFWIP-59)
Component/s: MP Config
(was: MP Config)
> Enable CDI by default when MP Config usage is detected in the deployment
> ------------------------------------------------------------------------
>
> Key: WFLY-10851
> URL: https://issues.jboss.org/browse/WFLY-10851
> Project: WildFly
> Issue Type: Enhancement
> Components: MP Config
> Reporter: Rostislav Svoboda
> Assignee: Jeff Mesnil
>
> Enable CDI by default when MP Config usage is detected in the deployment.
> Currently users are forced to add empty {{beans.xml}} to the deployment every time they want to use MP Config - e.g. in simple servlet scenario
> {code}
> @WebServlet("/")
> public class HelloServlet extends HttpServlet {
> @Inject
> @ConfigProperty(name = "port_number")
> Integer port;
> @Override
> protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws IOException {
> resp.getWriter().println("Value of port: " + port);
> }
> }
> {code}
> MP Config without CDI makes no sense to me. MP Config subsystem should be able to ensure CDI is enabled. CCing [~manovotn] [~brian.stansberry]
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
More information about the jboss-jira
mailing list