3

I am getting a problem on this line:

@Resource 
public void setMessageDrivenContext(MessageDrivenContext context) {
    this.context = context;
}

The message is:

JSR250: CommonAnnotations for Java, 2.3: @Resource methods must be setters that follow the standard JavaBeans convention. i.e. void "setProperty( value)" for " property".

ProjGatewayBean.java /DocViewerEJB/src/main/java/com/tscdv/document/b/beans line 72 Annotation Problem

What could be the problem, and how do I resolve it?

I have upgraded editor from Rad 7.5 to 8 and maven 2 to 3. This happens just after importing the maven projects, but I have no errors on any pom files.

I have some other issue with two xml files that might be related, separated into a new post:

Error: Projects containing version <unknown> deployment descriptors require XMI-format bindings or extensions files. ibm-web-bnd.xml

Community
  • 1
  • 1
mjs
  • 21,431
  • 31
  • 118
  • 200

1 Answers1

2

Rename the context attribute messageDrivenContext in your class and change your method as follow:

@Resource 
public void setMessageDrivenContext(MessageDrivenContext context) {
   this.messageDrivenContext = context;
}

Regards.

Farid
  • 2,265
  • 18
  • 14