[Clustering/JBoss] - Re: Loadbalancing & clustering
by fayaz
Thanks for your reply, i am trying to implement just load balancing, no clustering required, as you described, but i am having some problems, i have used the default setup,
i have copied the loadbalancer.sar directory to the deploy directory on a default setup of jboss, and changed the entries in the jboss-service.xml as below, and i get the new entry for loadbalancer in the jmx-console, there is a statistics attribute , and the requests always stay at zero for both nodes when i browse to this url from the server.
https://localhost:8443
whats going wrong!!, what is the best way to see if it is working?
<!-- The URL to use to connect the host. URLs like http://www.xx.yy:8080/ are also allowed -->
<host-url>https://localhost:8443/</host-url>
<!-- The loadbalancer-factor -->
<lb-factor>1</lb-factor>
<host-url>https://server2:8443/</host-url>
<lb-factor>2</lb-factor>
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3966263#3966263
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3966263
19 years, 8 months
[Javassist user questions] - NewExpr Error!!!!
by Panzer_Kavalier
public class Test implements Runnable{
public Test(){
Thread t = new Thread(this);
t.start();
}
public void run(){
System.out.println("run");
}
/**
* @param args
*/
public static void main(String[] args) {
Test test = new Test();
}
}
-----------------------------------------------------------------------------
public class EmulatorThread implements Runnable{
public Runnable _target;
public EmulatorThread(Runnable target) {
_target = target;
}
protected void start(){
(new Thread(this)).start();
}
public void run()
{
if(_target != null)
_target.run();
}
}
---------------------------------------
public class MethodSetEditor extends ExprEditor {
public void edit(NewExpr m) throws CannotCompileException{
try{
if (m.getConstructor().getDeclaringClass().getName()
.equals("java.lang.Thread")) {
if (m.getConstructor().getSignature().equals(
"(Ljava/lang/Runnable;)V")) {
m.replace("{$_ = new EmulatorThread($1);}");
}
}
}
catch(Exception e){
e.printStackTrace();
}
}
}
-----------------------------------------
when I use the folowing codes to modify the above code:
ClassPool pool = ClassPool.getDefault();
try{
pool.appendClassPath("D:\\eclipse\\workspace\\Javassist\\");
CtClass cc = pool.makeClass(new FileInputStream("D:\\eclipse\\workspace\\Javassist\\Test.class"));
CtField [] cts = cc.getFields();
for(int i = 0; i < cts.length; i++){
if(cts.getSignature().equals("Ljava/lang/Thread;"))
cts.setType(pool.makeClass("EmulatorThread"));
}
cc.instrument(new MethodSetEditor());
cc.writeFile("E:\\");
}
catch(Exception e){
e.printStackTrace();
}
when I run the Test. the following error occured:
Exception in thread "main" java.lang.VerifyError: (class: Test, method: s
ignature: ()V) Incompatible object argument for function call
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3966260#3966260
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3966260
19 years, 8 months
[JBoss Seam] - How can I run example for seam-booking ?
by jinxuerong
Hi, All
I'm a green hand for seam. I have download JBoss 4.0.4 and seam1.0.1 GA, and build the seam-booking to JBoss, and the jboss no error after the deploy.
But there are some error happen where I try logon seam-booking the execption been thrown
| description The server encountered an internal error () that prevented it from fulfilling this request.
|
| exception
|
| javax.servlet.ServletException: Error calling action method of component with id _id2:_id14
| javax.faces.webapp.FacesServlet.service(FacesServlet.java:121)
| org.jboss.seam.servlet.SeamRedirectFilter.doFilter(SeamRedirectFilter.java:30)
| org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
|
|
| root cause
|
| javax.faces.FacesException: Error calling action method of component with id _id2:_id14
| org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:74)
| javax.faces.component.UICommand.broadcast(UICommand.java:106)
| javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:90)
| javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:164)
| org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:316)
| org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
| javax.faces.webapp.FacesServlet.service(FacesServlet.java:106)
| org.jboss.seam.servlet.SeamRedirectFilter.doFilter(SeamRedirectFilter.java:30)
| org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
|
|
|
Who can help me ?
Ronnie
08/20/2006
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3966259#3966259
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3966259
19 years, 8 months
[EJB 3.0] - Re: Same datasource in multiple ear applications
by connerjohn
ok - last piece of information and I'm out of ideas:
Also, I am runing the latest EJB JEMS and the latest CVS Seam.
When I go look at jmx-console I find two persistent unit listed:
* ear=backoffice-local.ear,jar=backoffice-local.jar,unitName=em
* ear=shop-local.ear,jar=shop-local.jar,unitName=em
Here are the details for both and the shop-local deployment failed:
| List of MBean attributes:
| Name Type Access Value Description
| StateString java.lang.String R Started MBean Attribute.
| State int R 3 MBean Attribute.
| Name java.lang.String R ServiceDelegateWrapper MBean Attribute.
|
| List of MBean attributes:
| Name Type Access Value Description
| StateString java.lang.String R Failed MBean Attribute.
| State int R 4 MBean Attribute.
| Name java.lang.String R ServiceDelegateWrapper MBean Attribute.
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3966255#3966255
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3966255
19 years, 8 months