[JBoss JIRA] Created: (JBAS-7321) EJB3 deploy problem
by Alexander Tsibulnikov (JIRA)
EJB3 deploy problem
-------------------
Key: JBAS-7321
URL: https://jira.jboss.org/jira/browse/JBAS-7321
Project: JBoss Application Server
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: EJB3
Affects Versions: JBossAS-5.1.0.GA
Environment: Windows XP SP2, java JDK 1.6.0_10, IDE IDEA 8.1.3, JBOSS 5.1.0.GA
Reporter: Alexander Tsibulnikov
Assignee: Carlo de Wolf
I have 2 statless beans:
1)
@Stateless(name = "TestSession")
public class TestSessionBean implements TestSessionLocal, TestSessionRemote {
@EJB
private TestSession1Local testSession1;
@PersistenceContext
private EntityManager em;
public TestSessionBean() {
}
public Long getSessionName() {
return 18276852348752374L;
}
public String getHellow() {
return testSession1.getHellow();
}
public UpravDokument getDokumentById(Long dokumentId) throws Exception {
return em.find(UpravDokument.class, dokumentId);
}
}
2)
@Stateless(name = "TestSession1")
public class TestSessionBean1 implements TestSession1Local {
@EJB
private TestSessionLocal testSession;
public TestSessionBean1() {
}
public String getHellow() {
return "Hello World!!!";
}
public Long getSessionName() {
return testSession.getSessionName();
}
}
Then i make one ear - application. The problem is application not deploing because probably self referencing beans. On JBoss 4.2.3 deploy is fine.
stacktrace error:
12:32:40,536 INFO [JBossASKernel] Added bean(jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession1,service=EJB3) to KernelDeployment of: testejb.jar
12:32:40,536 INFO [EJB3EndpointDeployer] Deploy AbstractBeanMetaData@1d091d1{name=jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession,service=EJB3_endpoint bean=org.jboss.ejb3.endpoint.deployers.impl.EndpointImpl properties=[container] constructor=null autowireCandidate=true}
12:32:40,536 INFO [EJB3EndpointDeployer] Deploy AbstractBeanMetaData@1119598{name=jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession1,service=EJB3_endpoint bean=org.jboss.ejb3.endpoint.deployers.impl.EndpointImpl properties=[container] constructor=null autowireCandidate=true}
12:32:40,551 INFO [PersistenceUnitDeployment] Starting persistence unit persistence.unit:unitName=testear.ear/testejb.jar#PU
12:32:40,567 INFO [Ejb3Configuration] Processing PersistenceUnitInfo [
name: PU
...]
12:32:40,567 WARN [Ejb3Configuration] Persistence provider caller does not implement the EJB3 spec correctly. PersistenceUnitInfo.getNewTempClassLoader() is null.
12:32:40,567 INFO [AnnotationBinder] Binding entity from annotated class: ejb.UpravDokument
12:32:40,567 INFO [EntityBinder] Bind entity ejb.UpravDokument on table DOKUMENT_V
12:32:40,598 INFO [HibernateSearchEventListenerRegister] Unable to find org.hibernate.search.event.FullTextIndexEventListener on the classpath. Hibernate Search is not enabled.
12:32:40,598 INFO [ConnectionProviderFactory] Initializing connection provider: org.hibernate.ejb.connection.InjectedDataSourceConnectionProvider
12:32:40,598 INFO [InjectedDataSourceConnectionProvider] Using provided datasource
12:32:40,614 INFO [STDOUT] USER CONNECTED TO SERVER - ERROR EJBContext not bound
12:32:40,614 INFO [SettingsFactory] RDBMS: Oracle, version: Oracle Database 10g Release 10.2.0.1.0 - Production
12:32:40,614 INFO [SettingsFactory] JDBC driver: Oracle JDBC driver, version: 10.2.0.2.0
12:32:40,614 INFO [Dialect] Using dialect: org.hibernate.dialect.Oracle10gDialect
12:32:40,614 INFO [TransactionFactoryFactory] Transaction strategy: org.hibernate.ejb.transaction.JoinableCMTTransactionFactory
12:32:40,614 INFO [TransactionManagerLookupFactory] instantiating TransactionManagerLookup: org.hibernate.transaction.JBossTransactionManagerLookup
12:32:40,614 INFO [TransactionManagerLookupFactory] instantiated TransactionManagerLookup
12:32:40,614 INFO [SettingsFactory] Automatic flush during beforeCompletion(): disabled
12:32:40,614 INFO [SettingsFactory] Automatic session close at end of transaction: disabled
12:32:40,614 INFO [SettingsFactory] JDBC batch size: 15
12:32:40,614 INFO [SettingsFactory] JDBC batch updates for versioned data: disabled
12:32:40,614 INFO [SettingsFactory] Scrollable result sets: enabled
12:32:40,614 INFO [SettingsFactory] JDBC3 getGeneratedKeys(): disabled
12:32:40,614 INFO [SettingsFactory] Connection release mode: auto
12:32:40,614 INFO [SettingsFactory] Default batch fetch size: 1
12:32:40,614 INFO [SettingsFactory] Generate SQL with comments: disabled
12:32:40,614 INFO [SettingsFactory] Order SQL updates by primary key: disabled
12:32:40,629 INFO [SettingsFactory] Order SQL inserts for batching: disabled
12:32:40,629 INFO [SettingsFactory] Query translator: org.hibernate.hql.ast.ASTQueryTranslatorFactory
12:32:40,629 INFO [ASTQueryTranslatorFactory] Using ASTQueryTranslatorFactory
12:32:40,629 INFO [SettingsFactory] Query language substitutions: {}
12:32:40,629 INFO [SettingsFactory] JPA-QL strict compliance: enabled
12:32:40,629 INFO [SettingsFactory] Second-level cache: enabled
12:32:40,629 INFO [SettingsFactory] Query cache: disabled
12:32:40,629 INFO [SettingsFactory] Cache region factory : org.hibernate.cache.impl.bridge.RegionFactoryCacheProviderBridge
12:32:40,629 INFO [RegionFactoryCacheProviderBridge] Cache provider: org.hibernate.cache.HashtableCacheProvider
12:32:40,629 INFO [SettingsFactory] Optimize cache for minimal puts: disabled
12:32:40,629 INFO [SettingsFactory] Cache region prefix: persistence.unit:unitName=testear.ear/testejb.jar#PU
12:32:40,629 INFO [SettingsFactory] Structured second-level cache entries: disabled
12:32:40,629 INFO [SettingsFactory] Statistics: disabled
12:32:40,629 INFO [SettingsFactory] Deleted entity synthetic identifier rollback: disabled
12:32:40,629 INFO [SettingsFactory] Default entity-mode: pojo
12:32:40,629 INFO [SettingsFactory] Named query checking : enabled
12:32:40,629 INFO [SessionFactoryImpl] building session factory
12:32:40,645 INFO [SessionFactoryObjectFactory] Factory name: persistence.unit:unitName=testear.ear/testejb.jar#PU
12:32:40,645 INFO [NamingHelper] JNDI InitialContext properties:{java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory, java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces}
12:32:40,645 INFO [SessionFactoryObjectFactory] Bound factory to JNDI name: persistence.unit:unitName=testear.ear/testejb.jar#PU
12:32:40,645 WARN [SessionFactoryObjectFactory] InitialContext did not implement EventContext
12:32:40,645 INFO [NamingHelper] JNDI InitialContext properties:{java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory, java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces}
12:32:40,707 INFO [TomcatDeployment] deploy, ctxPath=/test
12:32:40,801 WARN [MainDeployer] Failed to deploy: file:/D:/Work/java/idea/testEE/out/testear.ear
org.jboss.deployers.client.spi.IncompleteDeploymentException: Summary of incomplete deployments (SEE PREVIOUS ERRORS FOR DETAILS):
DEPLOYMENTS MISSING DEPENDENCIES:
Deployment "jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession,service=EJB3" is missing the following dependencies:
Dependency "<UNKNOWN jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession,service=EJB3>" (should be in state "Described", but is actually in state "** UNRESOLVED Demands 'jndi:testear/TestSession1/local-ejb.TestSession1Local' **")
Deployment "jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession,service=EJB3_endpoint" is missing the following dependencies:
Dependency "jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession,service=EJB3" (should be in state "Configured", but is actually in state "PreInstall")
Deployment "jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession1,service=EJB3" is missing the following dependencies:
Dependency "<UNKNOWN jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession1,service=EJB3>" (should be in state "Described", but is actually in state "** UNRESOLVED Demands 'jndi:testear/TestSession/local-ejb.TestSessionLocal' **")
Deployment "jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession1,service=EJB3_endpoint" is missing the following dependencies:
Dependency "jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession1,service=EJB3" (should be in state "Configured", but is actually in state "PreInstall")
DEPLOYMENTS IN ERROR:
Deployment "<UNKNOWN jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession1,service=EJB3>" is in error due to the following reason(s): ** UNRESOLVED Demands 'jndi:testear/TestSession/local-ejb.TestSessionLocal' **
Deployment "<UNKNOWN jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession,service=EJB3>" is in error due to the following reason(s): ** UNRESOLVED Demands 'jndi:testear/TestSession1/local-ejb.TestSession1Local' **
at org.jboss.deployers.plugins.deployers.DeployersImpl.checkComplete(DeployersImpl.java:993)
at org.jboss.deployers.plugins.deployers.DeployersImpl.checkComplete(DeployersImpl.java:939)
at org.jboss.deployers.plugins.main.MainDeployerImpl.checkComplete(MainDeployerImpl.java:873)
at org.jboss.deployers.plugins.main.MainDeployerImpl.checkComplete(MainDeployerImpl.java:862)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:833)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:157)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:96)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:668)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.jmx.connector.invoker.InvokerAdaptorService.invoke(InvokerAdaptorService.java:263)
at sun.reflect.GeneratedMethodAccessor272.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:157)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:96)
at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:138)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:90)
at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:140)
at org.jboss.jmx.connector.invoker.SerializableInterceptor.invoke(SerializableInterceptor.java:74)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:90)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:668)
at org.jboss.invocation.jrmp.server.JRMPProxyFactory.invoke(JRMPProxyFactory.java:180)
at sun.reflect.GeneratedMethodAccessor271.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:157)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:96)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:668)
at org.jboss.invocation.jrmp.server.JRMPInvoker$MBeanServerAction.invoke(JRMPInvoker.java:855)
at org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:422)
at sun.reflect.GeneratedMethodAccessor270.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:305)
at sun.rmi.transport.Transport$1.run(Transport.java:159)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:155)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:535)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:790)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:649)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
org.jboss.deployment.DeploymentException: Failed to deploy: file:/D:/Work/java/idea/testEE/out/testear.ear
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:838)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:157)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:96)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:668)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.jmx.connector.invoker.InvokerAdaptorService.invoke(InvokerAdaptorService.java:263)
at sun.reflect.GeneratedMethodAccessor272.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:157)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:96)
at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:138)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:90)
at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:140)
at org.jboss.jmx.connector.invoker.SerializableInterceptor.invoke(SerializableInterceptor.java:74)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:90)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:668)
at org.jboss.invocation.jrmp.server.JRMPProxyFactory.invoke(JRMPProxyFactory.java:180)
at sun.reflect.GeneratedMethodAccessor271.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:157)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:96)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:668)
at org.jboss.invocation.jrmp.server.JRMPInvoker$MBeanServerAction.invoke(JRMPInvoker.java:855)
at org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:422)
at sun.reflect.GeneratedMethodAccessor270.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:305)
at sun.rmi.transport.Transport$1.run(Transport.java:159)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:155)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:535)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:790)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:649)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
Caused by: org.jboss.deployers.client.spi.IncompleteDeploymentException: Summary of incomplete deployments (SEE PREVIOUS ERRORS FOR DETAILS):
DEPLOYMENTS MISSING DEPENDENCIES:
Deployment "jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession,service=EJB3" is missing the following dependencies:
Dependency "<UNKNOWN jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession,service=EJB3>" (should be in state "Described", but is actually in state "** UNRESOLVED Demands 'jndi:testear/TestSession1/local-ejb.TestSession1Local' **")
Deployment "jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession,service=EJB3_endpoint" is missing the following dependencies:
Dependency "jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession,service=EJB3" (should be in state "Configured", but is actually in state "PreInstall")
Deployment "jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession1,service=EJB3" is missing the following dependencies:
Dependency "<UNKNOWN jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession1,service=EJB3>" (should be in state "Described", but is actually in state "** UNRESOLVED Demands 'jndi:testear/TestSession/local-ejb.TestSessionLocal' **")
Deployment "jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession1,service=EJB3_endpoint" is missing the following dependencies:
Dependency "jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession1,service=EJB3" (should be in state "Configured", but is actually in state "PreInstall")
DEPLOYMENTS IN ERROR:
Deployment "<UNKNOWN jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession1,service=EJB3>" is in error due to the following reason(s): ** UNRESOLVED Demands 'jndi:testear/TestSession/local-ejb.TestSessionLocal' **
Deployment "<UNKNOWN jboss.j2ee:ear=testear.ear,jar=testejb.jar,name=TestSession,service=EJB3>" is in error due to the following reason(s): ** UNRESOLVED Demands 'jndi:testear/TestSession1/local-ejb.TestSession1Local' **
at org.jboss.deployers.plugins.deployers.DeployersImpl.checkComplete(DeployersImpl.java:993)
at org.jboss.deployers.plugins.deployers.DeployersImpl.checkComplete(DeployersImpl.java:939)
at org.jboss.deployers.plugins.main.MainDeployerImpl.checkComplete(MainDeployerImpl.java:873)
at org.jboss.deployers.plugins.main.MainDeployerImpl.checkComplete(MainDeployerImpl.java:862)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:833)
... 50 more
How to resolve this problem?
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 5 months
[JBoss JIRA] Created: (JASSIST-100) Using CtBehavior.addCatch() on method that was already instrumented with ExprEditor results in unreachable code.
by Martin Burger (JIRA)
Using CtBehavior.addCatch() on method that was already instrumented with ExprEditor results in unreachable code.
----------------------------------------------------------------------------------------------------------------
Key: JASSIST-100
URL: https://jira.jboss.org/jira/browse/JASSIST-100
Project: Javassist
Issue Type: Bug
Affects Versions: 3.11.0.GA
Reporter: Martin Burger
Assignee: Shigeru Chiba
I want to instrument a method with CtBehavior.addCatch() after it was already modified by an ExprEditor. Unfortunately, this results in unreachable code.
Here is the original method:
/**
* Decompiled by jad - The Fast JAva Decompiler:
* Original method.
*/
public Object getObject() {
/* 74*/ return new Object();
}
Using CtBehavior.addCatch() results in the expected modified code:
/**
* Decompiled by jad - The Fast JAva Decompiler:
* Method instrumented via m.addCatch("{ System.out.println($e); throw $e; }", etype).
*/
public Object getObject() {
/* 74*/ try {
/* 74*/ return new Object();
}
/* 74*/ catch(Throwable throwable) {
/* 74*/ System.out.println(throwable);
/* 74*/ throw throwable;
}
}
If I only apply an ExprEditor alone, the modified code will look as expected as well:
/**
* Decompiled by jad - The Fast JAva Decompiler:
* Method instrumented via ExprEditor.edit(NewExpr ne):
* ne.replace("{ System.out.println(\"Constructor call.\"); $_ = $proceed($$); }");
*/
public Object getObject() {
/* 74*/ Object obj = null;
/* 74*/ Object obj1 = null;
/* 74*/ System.out.println("Constructor call.");
/* 74*/ obj1 = new Object();
/* 74*/ return obj1;
}
However, if I use both, the instrumented code contains an unreachable part:
/**
* Decompiled by jad - The Fast JAva Decompiler:
* Method first instrumented via ExprEditors, afterwards via addCatch(...) as shown above.
*/
public Object getObject() {
/* 74*/ Object obj = null;
/* 74*/ Object obj1 = null;
/* 74*/ System.out.println("Constructor call.");
/* 74*/ obj1 = new Object();
/* 74*/ return obj1;
Throwable throwable;
/* 74*/ throwable;
/* 74*/ System.out.println(throwable);
/* 74*/ throw throwable;
}
I would expect something like that:
/**
* Expected result.
*/
public Object getObject() {
/* 74*/ try {
/* 74*/ System.out.println("Constructor call.");
/* 74*/ return new Object();
}
/* 74*/ catch(Throwable throwable) {
/* 74*/ System.out.println(throwable);
/* 74*/ throw throwable;
}
}
Currently, method CtBehavior.addCatch() seems to not work on code that was modified before.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 5 months
[JBoss JIRA] Created: (JGRP-1106) Custom LogFactory instead of the built in log4j / jdk logging
by kimchy (JIRA)
Custom LogFactory instead of the built in log4j / jdk logging
-------------------------------------------------------------
Key: JGRP-1106
URL: https://jira.jboss.org/jira/browse/JGRP-1106
Project: JGroups
Issue Type: Feature Request
Reporter: kimchy
Assignee: Bela Ban
Fix For: 2.8
Attachments: CustomLogFactory.java, LogFactory.java
Hi,
I would love to be able to plug into jboss my own construction of loggers and not rely on the built in ones. I do some special things when constructing loggers (I am using slf4j ontop of log4j, but I modify the loggers a bit). Also, I would love to change categories and such on the fly.
For that, I am attaching two files. The first is an interface called CustomLogFactory which needs to be implemented to provide the custom implementation. The second is a modified LogFactory in order to support that. I apologize for not attaching a patch, I can't seem to connect to CVS, and I am hoping to get this into 2.8 if possible ;), so I want to provide this as fast as possible.
If this can make it into 2.8 it would be great!
Cheers,
Shay
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 5 months
[JBoss JIRA] Created: (JBID-227) SAML20TokenProvider cannot handle missing cancel_ids_file
by Jaap Reitsma (JIRA)
SAML20TokenProvider cannot handle missing cancel_ids_file
---------------------------------------------------------
Key: JBID-227
URL: https://jira.jboss.org/jira/browse/JBID-227
Project: JBoss Identity
Issue Type: Bug
Components: Identity-Federation
Affects Versions: IDFED-1.0.0.beta3
Environment: Windows XP SP3, JBoss 5.1.0.GA
Reporter: Jaap Reitsma
Assignee: Anil Saldhana
In org.jboss.identity.federation.core.wstrust.plugins.saml.SAML20TokenProvider:
The logic to handle a potential missing cancel_ids_file is not correct. Instead of:
if (file == null && logger.isDebugEnabled())
logger.debug("File to store canceled ids has not been specified: ids will not be persisted!");
else
....
the intention is probably:
if (file == null) {
if (logger.isDebugEnabled()) {
logger.debug("File to store canceled ids has not been specified: ids will not be persisted!");
}
}
else
....
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 5 months