From the course: Java EE 7: Enterprise JavaBeans (EJB)

Unlock the full course today

Join today to access over 22,500 courses taught by industry experts or purchase this course individually.

Create your message-driven bean

Create your message-driven bean

From the course: Java EE 7: Enterprise JavaBeans (EJB)

Start my 1-month free trial

Create your message-driven bean

- [Instructor] Now that we've looked into more details around message driven beans, lets go ahead and create one. So let's get to it. So again let's go back to our AGB here, so right click on vinyl app in the projects tab, like so, select new, and then other. And then what we'll do is select Enterprise JavaBeans and then select Message Driven Bean. And then for the name what we're going to do is basically leave it as new message beans. For the package we're going to select the AGB. And for the project destination you need to add one because you don't have any, so let's go and click on add. You want to enter JMS/new message and keep the destination type as a queue. We're going to use queue to actually interact with the messages. Then click okay, and then click next, finish. All right so the first thing we're going to do is scroll down until we get to our public class here, and what I'm going to do first is add a resource. So what I'm going to do is add resource, private, message driven…

Contents