[JBoss Tools] - Wrong warning detection for CDI injection point
by Grégoire Rolland
Grégoire Rolland [http://community.jboss.org/people/grolland.jspirit] created the discussion
"Wrong warning detection for CDI injection point"
To view the discussion, visit: http://community.jboss.org/message/603949#603949
--------------------------------------------------------------
Hi,
I realize the Weld Example for injecting SLF4J Logger with Eclipse, Maven and Jboss Tools.
I build one project where there is the bean with the producer method for Logger :
Project 1
--> LoggerFactory
--> Log Annotation
And I create a second project wich depend from the first :
Project 2
--> BeanWithLogger
I write this code :
Log.java
{code}
@BindingType
@Retention(RetentionPolicy.RUNTIME)
@Target({ ElementType.METHOD, ElementType.FIELD, ElementType.PARAMETER })
public @interface Log
{
}
{code}
LoggerFactory.java
{code}
@Named
public class LoggerFactory
{
@Produces
@Log
public Logger createLogger(final InjectionPoint in_injectionPoint)
{
return org.slf4j.LoggerFactory.getLogger(in_injectionPoint.getMember().getDeclaringClass());
}
}
{code}
BeanWithLogger.java
{code}
@Named
public class BeanWithLogger
{
@Inject
@Log // Here CDI validiator says : No bean is eligible for injection to the injection point [JSR-299 §5.2.1]
private Logger logger = null;
}
{code}
I think this warning is wrong. The code works fine. Is there a problem (misconfuguration or bug) with the CDI validator ?
Thanks for your answers
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/603949#603949]
Start a new discussion in JBoss Tools at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
13 years, 6 months
[JBoss Web Services] - jbossws update error
by sury bu
sury bu [http://community.jboss.org/people/bushurui] created the discussion
"jbossws update error"
To view the discussion, visit: http://community.jboss.org/message/603859#603859
--------------------------------------------------------------
Hi,all
i want to updae the jbossws-native-3.1.2.GA to jbossws-native-3.3.1.GA,and my JBoss version is jboss-5.1.0.GA-jdk6.zip run with JDK1.6 update 23.
i have download apache ant version apache-ant-1.8.2,and do ++ *+ant deploy-jboss510,+* but when i do +*ant tests >c:/ant_tests,*+
there comes one FAILED, as follow:
*+[junit] Test org.jboss.test.ws.management.recording.MemoryBufferRecorderTestCase FAILED+*
** and when i put my ear package under deploy folder, there throw some WARNING like this,
*+2011-05-06 17:49:59,100 WARNING [com.sun.xml.bind.v2.runtime.reflect.opt.Injector] (main) duplicate class definition bug occured? Please report this : egret/ws/task/WSNursingOutstandingTaskListPage$JaxbAccessorM_getNursingOutstandingTaskList_setNursingOutstandingTaskList_[Legret_ws_task_WSNursingOutstandingTask;+*
*+java.lang.ClassFormatError: Illegal class name "egret/ws/task/WSNursingOutstandingTaskListPage$JaxbAccessorM_getNursingOutstandingTaskList_setNursingOutstandingTaskList_[Legret_ws_task_WSNursingOutstandingTask;" in class file egret/ws/task/WSNursingOutstandingTaskListPage$JaxbAccessorM_getNursingOutstandingTaskList_setNursingOutstandingTaskList_[Legret_ws_task_WSNursingOutstandingTask;+*
*+ at java.lang.ClassLoader.defineClass1(Native Method)+*
*+ at java.lang.ClassLoader.defineClassCond(ClassLoader.java:632)+*
*+ at java.lang.ClassLoader.defineClass(ClassLoader.java:616)+*
*+ at java.lang.ClassLoader.defineClass(ClassLoader.java:466)+*
*+ at sun.reflect.GeneratedMethodAccessor117.invoke(Unknown Source)+*
*+ at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)+*
*+ at java.lang.reflect.Method.invoke(Method.java:597)+*
*+ at com.sun.xml.bind.v2.runtime.reflect.opt.Injector.inject(Injector.java:205)+*
*+ at com.sun.xml.bind.v2.runtime.reflect.opt.Injector.inject(Injector.java:85)+*
*+ at com.sun.xml.bind.v2.runtime.reflect.opt.AccessorInjector.prepare(AccessorInjector.java:89)+*
*+ at com.sun.xml.bind.v2.runtime.reflect.opt.OptimizedAccessorFactory.get(OptimizedAccessorFactory.java:114)+*
*+ at com.sun.xml.bind.v2.runtime.reflect.Accessor$GetterSetterReflection.optimize(Accessor.java:369)+*
*+ at com.sun.xml.bind.v2.runtime.property.ArrayProperty.<init>(ArrayProperty.java:65)+*
*+ at com.sun.xml.bind.v2.runtime.property.ArrayERProperty.<init>(ArrayERProperty.java:84)+*
*+ at com.sun.xml.bind.v2.runtime.property.ArrayElementProperty.<init>(ArrayElementProperty.java:96)+*
*+ at com.sun.xml.bind.v2.runtime.property.ArrayElementNodeProperty.<init>(ArrayElementNodeProperty.java:58)+*
*+ at sun.reflect.GeneratedConstructorAccessor211.newInstance(Unknown Source)+*
*+ at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)+*
*+ at java.lang.reflect.Constructor.newInstance(Constructor.java:513)+*
*+ at com.sun.xml.bind.v2.runtime.property.PropertyFactory.create(PropertyFactory.java:124)+*
*+ at com.sun.xml.bind.v2.runtime.ClassBeanInfoImpl.<init>(ClassBeanInfoImpl.java:179)+*
*+ at com.sun.xml.bind.v2.runtime.JAXBContextImpl.getOrCreate(JAXBContextImpl.java:515)+*
*+ at com.sun.xml.bind.v2.runtime.JAXBContextImpl.getOrCreate(JAXBContextImpl.java:534)+*
*+ at com.sun.xml.bind.v2.runtime.property.SingleElementNodeProperty.<init>(SingleElementNodeProperty.java:101)+*
*+ at sun.reflect.GeneratedConstructorAccessor44.newInstance(Unknown Source)+*
*+ at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)+*
*+ at java.lang.reflect.Constructor.newInstance(Constructor.java:513)+*
*+ at com.sun.xml.bind.v2.runtime.property.PropertyFactory.create(PropertyFactory.java:124)+*
*+ at com.sun.xml.bind.v2.runtime.ClassBeanInfoImpl.<init>(ClassBeanInfoImpl.java:179)+*
*+ at com.sun.xml.bind.v2.runtime.JAXBContextImpl.getOrCreate(JAXBContextImpl.java:515)+*
*+ at com.sun.xml.bind.v2.runtime.JAXBContextImpl.<init>(JAXBContextImpl.java:330)+*
*+ at com.sun.xml.bind.v2.runtime.JAXBContextImpl$JAXBContextBuilder.build(JAXBContextImpl.java:1140)+*
*+ at com.sun.xml.bind.v2.ContextFactory.createContext(ContextFactory.java:154)+*
*+ at com.sun.xml.bind.api.JAXBRIContext.newInstance(JAXBRIContext.java:106)+*
*+ at org.jboss.ws.core.jaxws.CustomizableJAXBContextFactory.createContext(CustomizableJAXBContextFactory.java:154)+*
*+ at org.jboss.ws.metadata.builder.jaxws.JAXWSMetaDataBuilder.createJAXBContext(JAXWSMetaDataBuilder.java:1115)+*
*+ at org.jboss.ws.metadata.builder.jaxws.JAXWSWebServiceMetaDataBuilder.buildWebServiceMetaData(JAXWSWebServiceMetaDataBuilder.java:176)+*
*+ at org.jboss.ws.metadata.builder.jaxws.JAXWSServerMetaDataBuilder.setupProviderOrWebService(JAXWSServerMetaDataBuilder.java:50)+*
*+ at org.jboss.ws.metadata.builder.jaxws.JAXWSMetaDataBuilderJSE.buildMetaData(JAXWSMetaDataBuilderJSE.java:62)+*
*+ at org.jboss.wsf.stack.jbws.UnifiedMetaDataDeploymentAspect.start(UnifiedMetaDataDeploymentAspect.java:64)+*
*+ at org.jboss.webservices.integration.deployers.WSDeploymentAspectDeployer.internalDeploy(WSDeploymentAspectDeployer.java:107)+*
*+ at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer.deploy(AbstractRealDeployer.java:50)+*
*+ at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:171)+*
*+ at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(DeployersImpl.java:1439)+*
*+ at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1157)+*
*+ at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1210)+*
*+ at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:1098)+*
*+ at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)+*
*+ at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1631)+*
*+ at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:934)+*
*+ at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1082)+*
*+ at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:984)+*
*+ at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:822)+*
*+ at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:553)+*
*+ at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:781)+*
*+ at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:702)+*
*+ at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.process(MainDeployerAdapter.java:117)+*
*+ at org.jboss.system.server.profileservice.repository.ProfileDeployAction.install(ProfileDeployAction.java:70)+*
*+ at org.jboss.system.server.profileservice.repository.AbstractProfileAction.install(AbstractProfileAction.java:53)+*
*+ at org.jboss.system.server.profileservice.repository.AbstractProfileService.install(AbstractProfileService.java:361)+*
*+ at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)+*
*+ at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1631)+*
*+ at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:934)+*
*+ at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1082)+*
*+ at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:984)+*
*+ at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:822)+*
*+ at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:553)+*
*+ at org.jboss.system.server.profileservice.repository.AbstractProfileService.activateProfile(AbstractProfileService.java:306)+*
*+ at org.jboss.system.server.profileservice.ProfileServiceBootstrap.start(ProfileServiceBootstrap.java:271)+*
*+ at org.jboss.bootstrap.AbstractServerImpl.start(AbstractServerImpl.java:461)+*
*+ at org.jboss.Main.boot(Main.java:221)+*
*+ at org.jboss.Main$1.run(Main.java:556)+*
*+ at java.lang.Thread.run(Thread.java:662)+*
anyone can help me figure out the problem?
Thank** ,
sury** +*
*+
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/603859#603859]
Start a new discussion in JBoss Web Services at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
13 years, 6 months
[jBPM] - 530 5.7.1 Client was not authenticated
by Rajan Bansal
Rajan Bansal [http://community.jboss.org/people/rajan01] created the discussion
"530 5.7.1 Client was not authenticated"
To view the discussion, visit: http://community.jboss.org/message/603127#603127
--------------------------------------------------------------
I am calling the jBPM process, in which it sends the mail, And I configure tha mail jbpm mail host in the *jbpm.cfg.xml* as under:
<?xml version="1.0" encoding="UTF-8"?>
<jbpm-configuration>
<string name="jbpm.mail.smtp.host" value="172.25.15.4" />
</jbpm-configuration>
and my SMTP server Ip is 172.25.15.4
and i got the following error:
Inside the Node Handler execute method....// It calls the handlers execute method
Exception in thread "main" org.jbpm.JbpmException: couldn't send email
at org.jbpm.mail.Mail.send(Mail.java:149)
at org.jbpm.mail.Mail.send(Mail.java:113)
at org.jbpm.mail.Mail.execute(Mail.java:63)
at org.jbpm.graph.def.Action.execute(Action.java:122)
at org.jbpm.graph.def.GraphElement.executeAction(GraphElement.java:255)
at org.jbpm.graph.def.GraphElement.executeActions(GraphElement.java:220)
at org.jbpm.graph.def.GraphElement.fireAndPropagateEvent(GraphElement.java:190)
at org.jbpm.graph.def.GraphElement.fireEvent(GraphElement.java:174)
at org.jbpm.graph.def.Node.leave(Node.java:381)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:157)
at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$d02de78a.leave(<generated>)
at org.jbpm.graph.exe.Token.signal(Token.java:194)
at org.jbpm.graph.exe.Token.signal(Token.java:139)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:157)
at org.jbpm.graph.exe.Token$$EnhancerByCGLIB$$7cbc8e1e.signal(<generated>)
at org.jbpm.graph.exe.ProcessInstance.signal(ProcessInstance.java:270)
at com.sample.initiator.ProcessInitiator.signalProcessInstance(ProcessInitiator.java:126)
at com.sample.initiator.StartProcessOne.main(StartProcessOne.java:11)
Caused by: javax.mail.SendFailedException: Sending failed;
nested exception is:
class javax.mail.MessagingException: 530 5.7.1 Client was not authenticated
at javax.mail.Transport.send0(Transport.java:218)
at javax.mail.Transport.send(Transport.java:80)
at org.jbpm.mail.Mail.send(Mail.java:147)
... 25 more
And plz tell me how do i check the SMTP server ip given to me is correct or not..
Thanks
Rajan
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/603127#603127]
Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
13 years, 6 months