Questions tagged [weld]

Weld is the reference implementation (RI) for JSR-299: Java Contexts and Dependency Injection for the Java EE platform (CDI)

Weld is the reference implementation (RI) for JSR-299: Java Contexts and Dependency Injection for the Java EE platform (CDI)

See http://seamframework.org/Weld

592 questions
0
votes
1 answer

CDI WELD Beans.xml in META-INF from jar in lib blocking the one in WEB-INF of project

Depending on where I place my beans.xml's, in my project CDI is either working for @Named annotated classes found in lib jars OR for @Alternative annotated classes found in the main project. I can't figure out where to place them to get both to…
4nti
  • 196
  • 1
  • 14
0
votes
0 answers

JavaFX FXML initialize fires before Weld dependencies are injected

I am using FXML and Weld SE together. So far it works well except for certain cases. public class ApiController extends AnchorPane implements Initializable { @Inject private ApiFactory apiFactory; @FXML private TextArea …
user2914191
  • 877
  • 1
  • 8
  • 21
0
votes
1 answer

CDI and JANDEX and deployment enhancement approach - no speed difference detected

I am opening this thread as I was requested to do so, in a reply to comment/question i added here: Disable scanning of CDI beans in WAR The question is the following. Is there any specific additional step that one needs to take besides adding jandex…
99Sono
  • 3,554
  • 27
  • 39
0
votes
1 answer

Passivation of CDI SessionBean with Constructor Injection

I have following CDI Bean: @SessionScoped public class ReportService implements Serializable { private static final long serialVersionUID = 1L; private MyDao myDao; @Inject public ReportService(MyDao myDao) { this.myDao =…
shout
  • 35
  • 4
0
votes
1 answer

Drools 7 with CDI using Weld

I've managed to run Drools with CDI using version 6.3.0.Final, CDI version 1.2 and Weld version 2.30.Final. Using code sample below. https://github.com/Salaboy/drools-workshop/tree/master/my-first-drools-project public class App { @Inject …
fanvabra
  • 140
  • 1
  • 8
0
votes
1 answer

Make interceptors work on injected "self" by wrapping it using CDI-extension

If you inject objects into itself in cdi, all interceptors are left out. That is a big difference to @EJB-Injection. In my project ejb-cdi-unit I try to simulate the injection of Ejbs by injecting them with CDI-means. Therefore I try to extend the…
aschoerk
  • 3,333
  • 2
  • 15
  • 29
0
votes
0 answers

After upgrade WildFly 8.2.1 to 10.0.0 "WELD-001304: More than one context active for scope type javax.enterprise.context.SessionScoped"

I do have a web application working fine on our machines, and fine on many different installations. But one customer does have very strange problems and I do not have any idea about the reasons. Environment: Wildfly 10.0.0 Own EAR with Java 8 UI…
Martin Metz
  • 308
  • 1
  • 3
  • 13
0
votes
1 answer

Websphere code on Wildfly

I am trying to incorporate a library into my JSF2 application running on Wildfly. The library was developed in house by a team that uses websphere. They don't support wildfly, only websphere. I would really like to use their library as it allows…
april26
  • 833
  • 3
  • 14
  • 27
0
votes
1 answer

PAX-CDI + Drool + @Inject @KSession @KReleaseId Not working

The pax cdi + weld + drool not working getting the following exception WELD-001408: Unsatisfied dependencies for type KieSession with qualifiers @KSession https://salaboy.com/2015/10/20/back-to-the-basics-getting-started-with-drools-6-3-0-final/
0
votes
0 answers

After rename package to lower case WELD cannot find class

I am using wildfly and I have weird problem. Firstly i had class in package: 1) app.service.parkingMeter.ParkingMeterService Everything works fine, deploy is ok. Then i renamed this package to: 2) …
Hadson
  • 123
  • 2
  • 9
0
votes
1 answer

Jersey 1.x to 2.x using CDI

I am working on a web service currently using Jersey 1.17 and CDI (Weld 2.4.1). I'm running on Tomcat8. My ContextListener and resource classes are successfully being injected with my service implementations marked with @Inject. I'm trying to move…
fmpdmb
  • 1,370
  • 3
  • 21
  • 34
0
votes
1 answer

Weld (CDI) and Jersey-Server(JAX-RS) Bootstrap in Java SE

I am trying to figure out how to correctly bootstrap Weld (3.0.0) together with Jersey-Server (1.19.3) to establish a Rest Server with Java SE. I am not! talking about a JEE solution. The application server does a good job here. I would like to have…
magicroomy
  • 395
  • 1
  • 6
  • 19
0
votes
0 answers

Spring MVC and CDI (Weld)

Is it possible to use Spring MVC and Weld in a Web Application? I'm also using WildFly 10.1 as my Server and RestEasy.
Fábio
  • 3,291
  • 5
  • 36
  • 49
0
votes
2 answers

How to add a portable CDI Extension programmatically?

Examples for creating a portable CDI Extension (like this) all use the javax.enterprise.inject.spi.Extension extension point to allow the ServiceLoader to load the Extension. Is there a Weld/CDI API/SPI to register the Extension dynamically,…
Scott Kurz
  • 4,985
  • 1
  • 18
  • 40
0
votes
2 answers

How do I use Weld and EclipseLink together in an SE environment?

I am trying to create a unit test that uses EclipseLink via JPA and I noticed that I needed to inject a DAO into a listener. The code itself works as expected inside a container, but I am having trouble making a unit test for it. The listener looks…
Archimedes Trajano
  • 35,625
  • 19
  • 175
  • 265