[JBoss Tools (users)] - Re: JMX perspective
by rob.stryker@jboss.com
The MBean explorer view was originally a google code project which we took and expanded on quite a bit. It has no concept of actually starting the JMX server at all. You must start the server separately.
What the JMX server *can* do is connect to an already running mbean server if you know how to connect to it. This can be a jboss server or a non-jboss server. Basically if you wanted you could start a JMX server with a simple main class (JMX is pretty much standard in java now) and then use the view to connect to it.
I recognize there's no way to edit a connection and you're welcome to add a feature request for it in JIRA which we'd be happy to look at.
If you want to use it specifically with JBoss servers, however, thanks to some added hooks, if you go to the servers view or jboss servers view and create a JBoss type server (must be from the "JBoss Community" or "JBoss Enterprise Middleware" category, NOT the "JBoss" category) then a server will automatically appear in the mbean explorer.
If you then start the server in the servers view, once the server is started, the connection in the mbean explorer should be made and you should be able to browse the MBeans of the running jboss server.
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4248242#4248242
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4248242
16 years, 8 months
[Beginners Corner] - Noob in EJB3 :D
by kamikadze
Hello,
I have entity bean eg:
@Entity
| public class Apple()
| {
| @Id
| public Integer id;
| public String name;
| }
Stateless Bean:
@Stateless
| public class FruitManager implements FruitManagerRemote()
| {
| public apple getAppleById(int id)
| {
| Apple apple=em.find(apple.class,1);
| return apple;
| }
| }
Client Code:
public class Client {
| public static void main(String[] args) {
| Properties properties = new Properties();
| //init of properties are here for jndi
| Context context;
| try
| {
| context = new InitialContext();
| FruitManagerRemote fruit = (FruitManagerRemote)context.lookup("FruitManager/Remote");
| Apple apple=fruit.getAppleById(1);
| }
| }
Why I can obtain Apple object at client side?
There are some error at client side (I can add stack trace tomorow).
If I made an Apple in FruitManager I can get it from client, but if it was persisted it can be send to client? Is it right behaviour?
Maybe at client side should I remove annotations?
Any ideas?
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4248241#4248241
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4248241
16 years, 8 months