IBM Connections 4.5 SPI - ibm-connections

I tried to implement the post event handler using IBM Connections SPI and deployed into IBM Connections using the below link.
http://www-10.lotus.com/ldd/lcwiki.nsf/xpDocViewer.xsp?lookupName=Lotus+Connections+3+documentation#action=openDocument&res_title=Deploying_an_event_handler_lc3&content=pdcontent
However, I am getting below error in the trace logs.
[5/30/14 16:35:32:462 IST] 00000014 EventConfigPa 3 com.ibm.lconn.events.internal.config.EventConfigParser bindVariables: postHandlers.postHandler[#name][6] has value MyHandler null
[5/30/14 16:35:32:474 IST] 00000014 EventConfigPa 3 com.ibm.lconn.events.internal.config.EventConfigParser getPostEventHandlers Handler name: MyHandler, class: com.tcs.Events
[5/30/14 16:35:32:474 IST] 00000014 EventConfigPa 3 com.ibm.lconn.events.internal.config.EventConfigParser getPostEventHandlers Handler name: MyHandler loaded from configuration
[5/30/14 16:35:34:305 IST] 00000030 EventConfigPa 3 com.ibm.lconn.events.internal.config.EventConfigParser bindVariables: postHandlers.postHandler[#name][6] has value MyHandler null
Could you please help me in the resolving this issue and also please let me know if you need any further information.

Related

Kafka Connect Sink to Cassandra :: java.lang.VerifyError: Bad return type

I'm trying to setup a Kafka Connect Sink to collect data from a topic into a Cassandra Table using the Datastax connector : https://downloads.datastax.com/#akc
Running a standalone worker running directly on the broker, running Kafka 0.10.2.2-1 :
name=dse-sink
connector.class=com.datastax.kafkaconnector.DseSinkConnector
tasks.max=1
datastax-java-driver.advanced.protocol.version = V4
key.converter=org.apache.kafka.connect.storage.StringConverter
value.converter=org.apache.kafka.connect.storage.StringConverter
key.converter.schemas.enable=false
value.converter.schemas.enable=false
internal.key.converter=org.apache.kafka.connect.json.JsonConverter
internal.value.converter=org.apache.kafka.connect.json.JsonConverter
internal.key.converter.schemas.enable=false
internal.value.converter.schemas.enable=false
plugin.path=/usr/share/java/kafka-connect-dse/kafka-connect-dse-1.2.1.jar
topics=connect-test
contactPoints=172.16.0.48
loadBalancing.localDc=datacenter1
port=9042
ignoreErrors=true
topic.connect-test.cdrs.test.mapping= kafkakey=key, value=value
topic.connect-test.cdrs.test.consistencyLevel=LOCAL_QUORUM
But i have the following error :
2019-12-23 16:58:43,165] ERROR Task dse-sink-0 threw an uncaught and unrecoverable exception (org.apache.kafka.connect.runtime.WorkerTask)
java.lang.VerifyError: Bad return type
Exception Details:
Location:
com/fasterxml/jackson/databind/cfg/MapperBuilder.streamFactory()Lcom/fasterxml/jackson/core/TokenStreamFactory; #7: areturn
Reason:
Type 'com/fasterxml/jackson/core/JsonFactory' (current frame, stack[0]) is not assignable to 'com/fasterxml/jackson/core/TokenStreamFactory' (from method signature)
Current Frame:
bci: #7
flags: { }
locals: { 'com/fasterxml/jackson/databind/cfg/MapperBuilder' }
stack: { 'com/fasterxml/jackson/core/JsonFactory' }
Bytecode:
0x0000000: 2ab4 0002 b600 08b0
at com.fasterxml.jackson.databind.json.JsonMapper.builder(JsonMapper.java:114)
at com.datastax.dsbulk.commons.codecs.json.JsonCodecUtils.getObjectMapper(JsonCodecUtils.java:36)
at com.datastax.kafkaconnector.codecs.CodecSettings.init(CodecSettings.java:131)
at com.datastax.kafkaconnector.state.LifeCycleManager.lambda$buildInstanceState$9(LifeCycleManager.java:423)
at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193)
at java.util.HashMap$ValueSpliterator.forEachRemaining(HashMap.java:1625)
at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:481)
at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471)
at java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:708)
at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
at java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:499)
at com.datastax.kafkaconnector.state.LifeCycleManager.buildInstanceState(LifeCycleManager.java:457)
at com.datastax.kafkaconnector.state.LifeCycleManager.lambda$startTask$0(LifeCycleManager.java:106)
at java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1660)
at com.datastax.kafkaconnector.state.LifeCycleManager.startTask(LifeCycleManager.java:101)
at com.datastax.kafkaconnector.DseSinkTask.start(DseSinkTask.java:74)
at org.apache.kafka.connect.runtime.WorkerSinkTask.initializeAndStart(WorkerSinkTask.java:244)
at org.apache.kafka.connect.runtime.WorkerSinkTask.execute(WorkerSinkTask.java:145)
at org.apache.kafka.connect.runtime.WorkerTask.doRun(WorkerTask.java:139)
at org.apache.kafka.connect.runtime.WorkerTask.run(WorkerTask.java:182)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
No additional error on cassandra or Kafka side.
I see active connection on the cassandra node but nothing arrive in the Keyspace.
Any idea why ?
Imho this is a problem caused by use of the JSON internal converters with BigDecimal data (see related SO question). As described in the following blog post, the internal.key.converter and internal.value.converter are deprecated since Kafka 2.0, and shouldn't be explicitly set. Can you comment out all internal. properties & re-try?
P.S. Also see how JSON + Decimal has changed in Kafka 2.4

Spring Integration Bridge with poller not working as expected for JMS

Using spring-integration 5.0.7 to throttle the bridging of msgs between two JMS queues.
The docs at: https://docs.spring.io/spring-integration/docs/5.0.7.RELEASE/reference/html/messaging-channels-section.html#bridge-namespace
suggest:
<int:bridge input-channel="pollable" output-channel="subscribable">
<int:poller max-messages-per-poll="10" fixed-rate="5000"/>
</int:bridge>
But schema validator complains "no nested poller allowed for subscribable input channel" on bridge elt.
But, if I put the poller on the input-channel-adapter as in:
<?xml version="1.0" encoding="UTF-8"?>
<beans:beans xmlns:int="http://www.springframework.org/schema/integration"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:beans="http://www.springframework.org/schema/beans"
xmlns:int-jms="http://www.springframework.org/schema/integration/jms"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/integration
http://www.springframework.org/schema/integration/spring-integration.xsd
http://www.springframework.org/schema/integration/jms
http://www.springframework.org/schema/integration/jms/spring-integration-jms.xsd
">
<int:channel id="inChannel" />
<int:channel id="outChannel" />
<int-jms:inbound-channel-adapter id="jmsIn" connection-factory="jmsConnectionFactory" destination-name="_dev.inQueue" channel="inChannel">
<int:poller fixed-delay="5000" max-messages-per-poll="2"/>
</int-jms:inbound-channel-adapter>
<int-jms:outbound-channel-adapter id="jmsOut" connection-factory="jmsConnectionFactory" destination-name="_dev.outQueue" channel="outChannel"/>
<int:bridge input-channel="inChannel" output-channel="outChannel">
</int:bridge>
</beans:beans>
Nothing is ever moved from input to output.
How can I bridge from one JMS queue to another with a rate-limit?
Update:
Turning on logging confirms nothing getting picked up from input channel but otherwise not helpful:
018-08-10 15:36:33.345 DEBUG 112066 --- [ask-scheduler-1] o.s.i.e.SourcePollingChannelAdapter : Received no Message during the poll, returning 'false'
2018-08-10 15:36:38.113 DEBUG 112066 --- [ask-scheduler-2] o.s.integration.jms.DynamicJmsTemplate : Executing callback on JMS Session: ActiveMQSession {id=ID:whitechapel-35247-1533940593148-3:2:1,started=true} java.lang.Object#5c278302
2018-08-10 15:36:38.116 DEBUG 112066 --- [ask-scheduler-2] o.s.i.e.SourcePollingChannelAdapter : Received no Message during the poll, returning 'false'
2018-08-10 15:36:43.115 DEBUG 112066 --- [ask-scheduler-1] o.s.integration.jms.DynamicJmsTemplate : Executing callback on JMS Session: ActiveMQSession {id=ID:whitechapel-35247-1533940593148-3:3:1,started=true} java.lang.Object#1c09a81e
2018-08-10 15:36:43.118 DEBUG 112066 --- [ask-scheduler-1] o.s.i.e.SourcePollingChannelAdapter : Received no Message during the poll, returning 'false'
Here is a Spring Boot app, using Java DSL configuration which is the exact equivalent of what you have in XML (minus the bridge); it works fine.
#SpringBootApplication
public class So51792909Application {
private static final Logger logger = LoggerFactory.getLogger(So51792909Application.class);
public static void main(String[] args) {
SpringApplication.run(So51792909Application.class, args);
}
#Bean
public ApplicationRunner runner(JmsTemplate template) {
return args -> {
for (int i = 0; i < 10; i++) {
template.convertAndSend("foo", "test");
}
};
}
#Bean
public IntegrationFlow flow(ConnectionFactory connectionFactory) {
return IntegrationFlows.from(Jms.inboundAdapter(connectionFactory)
.destination("foo"), e -> e
.poller(Pollers
.fixedDelay(5000)
.maxMessagesPerPoll(2)))
.handle(Jms.outboundAdapter(connectionFactory)
.destination("bar"))
.get();
}
#JmsListener(destination = "bar")
public void listen(String in) {
logger.info(in);
}
}
and
2018-08-10 19:38:52.534 INFO 13408 --- [enerContainer-1] com.example.So51792909Application : test
2018-08-10 19:38:52.543 INFO 13408 --- [enerContainer-1] com.example.So51792909Application : test
2018-08-10 19:38:57.566 INFO 13408 --- [enerContainer-1] com.example.So51792909Application : test
2018-08-10 19:38:57.582 INFO 13408 --- [enerContainer-1] com.example.So51792909Application : test
2018-08-10 19:39:02.608 INFO 13408 --- [enerContainer-1] com.example.So51792909Application : test
2018-08-10 19:39:02.622 INFO 13408 --- [enerContainer-1] com.example.So51792909Application : test
2018-08-10 19:39:07.640 INFO 13408 --- [enerContainer-1] com.example.So51792909Application : test
2018-08-10 19:39:07.653 INFO 13408 --- [enerContainer-1] com.example.So51792909Application : test
2018-08-10 19:39:12.672 INFO 13408 --- [enerContainer-1] com.example.So51792909Application : test
2018-08-10 19:39:12.687 INFO 13408 --- [enerContainer-1] com.example.So51792909Application : test
As you can see, the consumer gets 2 messages every 5 seconds.
Your debug log implies there are no messages in the queue.
EDIT
I figured it out; the XML parser sets the JmsTemplate receiveTimeout to nowait (-1). Since you are not using a caching connection factory, we'll never get a message because the ActiveMQ client returns immediately if there's not already a message present in the client (see this answer). Since there's no caching going on, we get a new consumer on every poll (and do a no-wait receive each time).
The DSL leaves the JmsTemplate's default (Infinite wait - which is actually wrong since it blocks the poller thread indefinitely if there are no messages).
To fix the XML version, adding receive-timeout="1000" fixes it.
However, it's better to use a CachingConnectionFactory to avoid creating a new connection/session/consumer on each poll.
Unfortunately, configurating a CachingConnectionFactory turns off Spring Boot's auto-configuration. This is fixed in Boot 2.1.
I have opened an issue to resolve the inconsistency between the DSL and XML here.
If you stick with the DSL, I would recommend setting the receive timeout to something reasonable, rather than indefinite:
#Bean
public IntegrationFlow flow(ConnectionFactory connectionFactory) {
return IntegrationFlows.from(Jms.inboundAdapter(connectionFactory)
.configureJmsTemplate(t -> t.receiveTimeout(1000))
.destination("foo"), e -> e
.poller(Pollers
.fixedDelay(5000)
.maxMessagesPerPoll(2)))
.handle(Jms.outboundAdapter(connectionFactory)
.destination("bar"))
.get();
}
But, the best solution is to use a CachingConnectionFactory.

Deploy of war file on JBOSS EAP 7.0.5 failed. Failed to load annotated class:

I am migrating JSF application from JBOSS EAP 6.4 to JBOSS EAP 7.0.5. I do deployment using JBOSS console. Deployment of the application fails with the following error:
Unexpected HTTP response: 500 Request { "operation" => "add", "address" => [ ("server-group" => "<INSTANCE_NAME>"),
("deployment" => "<APPNAME>.war") ], "runtime-name" => "<APPNAME>", "enabled" => true }
Response Internal Server Error { "outcome" => "failed", "result" => undefined, "failure-description" => {"WFLYDC0074:
Operation failed or was rolled back on all servers. Server failures:" => {"server-group" => {"<INSTANCE_NAME>" =>
{"host" => {"WUWVC0ASDOF01" => {"<INSTANCE_NAME>" => {"WFLYCTL0080: Failed services" =>
{"jboss.deployment.unit.<APPNAME>.INSTALL" => "org.jboss.msc.service.StartException in service jboss.deployment.unit.<APPNAME>.INSTALL:
WFLYSRV0153: Failed to process phase INSTALL of deployment \"<APPNAME>\"
Caused by: org.jboss.as.server.deployment.DeploymentUnitProcessingException: WFLYJSF0008:
Failed to load annotated class: com.access.mbean.MyManagedBean"}}}}}}}}, "rolled-back" => true, "server-groups" =>
{"<INSTANCE_NAME>" => {"host" => {"WUWVC0ASDOF01" => {"<INSTANCE_NAME>" => {"response" =>
{ "outcome" => "failed", "result" => undefined, "failure-description" =>
{"WFLYCTL0080: Failed services" => {"jboss.deployment.unit.<APPNAME>.INSTALL" =>
"org.jboss.msc.service.StartException in service jboss.deployment.unit.<APPNAME>.INSTALL: WFLYSRV0153:
Failed to process phase INSTALL of deployment \"<APPNAME>\"
Caused by: org.jboss.as.server.deployment.DeploymentUnitProcessingException: WFLYJSF0008:
Failed to load annotated class: com.access.mbean.MyManagedBean"}}, "rolled-back" => true }}}}}} }
Class MyManagedBean has annotation:
#ManagedBean(name="myMB")
#ViewScoped
WEB-INF of war file consists of such xml files: faces-config.xml, jboss-deployment-structure.xml, jboss-web.xml, web.xml.
Before migration application was compiled in Java 1.8 and tested locally in JBOSS EAP 7.0
I tried solution described in similar post, it did not work for me.
Error in the server.log :
2017-08-17 15:50:33,442 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-1) MSC000001: Failed to start service jboss.deployment.unit.Portal.INSTALL: org.jboss.msc.service.StartException in service jboss.deployment.unit.Portal.INSTALL: WFLYSRV0153: Failed to process phase INSTALL of deployment "Portal"
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:172)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:2032)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1955)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: org.jboss.as.server.deployment.DeploymentUnitProcessingException: WFLYJSF0008: Failed to load annotated class: com.access.mbean.MyManagedBean
at org.jboss.as.jsf.deployment.JSFAnnotationProcessor.deploy(JSFAnnotationProcessor.java:115)
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:165)
... 5 more

Did not realize init() exception thrown by servlet Faces Servlet: java.lang.NullPointerException

i am trying to run JSF2/PrimeFaces application on WebSphere 6.1
and my configuration is as follows:
Class loader order: Classes loaded with application class loader first.
WAR class loader policy: Class loader for each WAR file in application.
My Jars are as follows:
all-themes-1.0.9
aopalliance-1.0
com.springsource.org.apache.commons.logging-1.1.1
commons-beanutils-1.8.3
commons-codec-1.3
commons-collections-3.2
commons-io-1.3.2
commons-lang-2.3
commons-logging-1.1.1
jsf-api-2.1.20
jsf-impl-2.1.20
jstl-1.2
log4j-1.2.16
org.springframework.binding-2.3.1.RELEASE
org.springframework.faces-2.3.1.RELEASE
org.springframework.js-2.3.1.RELEASE
org.springframework.web.servlet-3.1.1.RELEASE
org.springframework.webflow-2.3.1.RELEASE
primefaces-4.0-20130427.150835-5
slf4j-api-1.6.4
slf4j-log4j12-1.6.4
spring-aop-3.1.2.RELEASE
spring-asm-3.1.2.RELEASE
spring-beans-3.1.2.RELEASE
spring-context-3.1.2.RELEASE
spring-context-support-3.1.2.RELEASE
spring-core-3.1.2.RELEASE
spring-expression-3.1.2.RELEASE
spring-jdbc-3.1.2.RELEASE
spring-orm-3.1.2.RELEASE
spring-oxm-3.1.2.RELEASE
spring-tx-3.1.2.RELEASE
spring-web-3.1.2.RELEASE
spring-webmvc-3.1.2.RELEASE
spring-webmvc-portlet-3.1.2.RELEASE
standard-1.1.2
when trying to access the application, i am getting the exception:
SRVE0100E: Did not realize init() exception thrown by servlet Faces Servlet: java.lang.NullPointerException
at javax.faces.webapp.FacesServlet.init(FacesServlet.java:144)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:199)
at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.init(ServletWrapper.java:319)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:393)
at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:478)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:321)
at com.ibm.ws.webcontainer.extension.DefaultExtensionProcessor.handleRequest(DefaultExtensionProcessor.java:581)
at com.ibm.ws.wswebcontainer.extension.DefaultExtensionProcessor.handleRequest(DefaultExtensionProcessor.java:113)
at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3391)
at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:267)
at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:811)
at com.ibm.ws.wswebcontainer.WebContainer.handleRequest(WebContainer.java:1455)
at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:115)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:458)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:387)
at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:102)
at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165)
at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161)
at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:136)
at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:195)
at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:743)
at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:873)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1473)
[5/8/13 14:25:37:291 AST] 0000002c ServletWrappe E Deregister the mbean because of uncaught init() exception thrown by servlet Faces Servlet: javax.servlet.ServletException: SRVE0207E: Uncaught initialization exception thrown by servlet
at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:251)
at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.init(ServletWrapper.java:319)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:393)
at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:478)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:321)
at com.ibm.ws.webcontainer.extension.DefaultExtensionProcessor.handleRequest(DefaultExtensionProcessor.java:581)
at com.ibm.ws.wswebcontainer.extension.DefaultExtensionProcessor.handleRequest(DefaultExtensionProcessor.java:113)
at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3391)
at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:267)
at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:811)
at com.ibm.ws.wswebcontainer.WebContainer.handleRequest(WebContainer.java:1455)
at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:115)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:458)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:387)
at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:102)
at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165)
at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161)
at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:136)
at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:195)
at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:743)
at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:873)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1473)
---- Begin backtrace for Nested Throwables
java.lang.NullPointerException
at javax.faces.webapp.FacesServlet.init(FacesServlet.java:144)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:199)
at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.init(ServletWrapper.java:319)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:393)
at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:478)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:321)
at com.ibm.ws.webcontainer.extension.DefaultExtensionProcessor.handleRequest(DefaultExtensionProcessor.java:581)
at com.ibm.ws.wswebcontainer.extension.DefaultExtensionProcessor.handleRequest(DefaultExtensionProcessor.java:113)
at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3391)
at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:267)
at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:811)
at com.ibm.ws.wswebcontainer.WebContainer.handleRequest(WebContainer.java:1455)
at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:115)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:458)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:387)
at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:102)
at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165)
at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161)
at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:136)
at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:195)
at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:743)
at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:873)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1473)
,
[5/8/13 14:25:37:322 AST] 0000002c WebApp E [Servlet Error]-[SRVE0207E: Uncaught initialization exception thrown by servlet]: java.lang.NullPointerException
at javax.faces.webapp.FacesServlet.init(FacesServlet.java:144)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:199)
at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.init(ServletWrapper.java:319)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:393)
at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:478)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:321)
at com.ibm.ws.webcontainer.extension.DefaultExtensionProcessor.handleRequest(DefaultExtensionProcessor.java:581)
at com.ibm.ws.wswebcontainer.extension.DefaultExtensionProcessor.handleRequest(DefaultExtensionProcessor.java:113)
at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3391)
at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:267)
at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:811)
at com.ibm.ws.wswebcontainer.WebContainer.handleRequest(WebContainer.java:1455)
at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:115)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:458)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:387)
at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:102)
at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165)
at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161)
at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:136)
at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:195)
at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:743)
at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:873)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1473)
please advise how to fix it, thanks.
> jsf-api-2.1.20
> jsf-impl-2.1.20
From the JSF 2.1 specification:
Other Java™ Platform Specifications
JSF is based on the following Java API specifications:
JavaServer Pages™ Specification, version 2.1 (JSP™)
Java™ Servlet Specification, version 2.5 (Servlet)
Java™2 Platform, Standard Edition, version 5.0
Java™2 Platform, Enterprise Edition, version 5.0
JavaBeans™ Specification, version 1.0.1
JavaServer Pages™ Standard Tag Library, version 1.2 (JSTL)
Therefore, a JSF container must support all of the above
specifications.
WebSphere Application Server 6.1 is a J2EE 1.4 implementation and only supports Servlet 2.4.
You should ideally move to WAS 8 as Java EE 6 platforms support JSF 2 by specification.

XMLDirectMapping - No conversion value provided

docx4j (which I host) is typically used with the Sun/Oracle JAXB implementation; the classes of interest below were generated using XJC.
Following on from an earlier issue which the MOXy guys kindly fixed, I'm continuing to try to get it working with EclipseLink MOXy.
With a particular DOM document, I'm now getting:
[Exception [EclipseLink-25004] (Eclipse Persistence Services - 2.4.0.v20120529-r11529): org.eclipse.persistence.exceptions.XMLMarshalException
Exception Description: An error occurred unmarshalling the document
Internal Exception: Exception [EclipseLink-116] (Eclipse Persistence Services - 2.4.0.v20120529-r11529): org.eclipse.persistence.exceptions.DescriptorException
Exception Description: No conversion value provided for the value [1] in field [#ns1:val].
Mapping: org.eclipse.persistence.oxm.mappings.XMLDirectMapping[val-->#ns1:val]
Descriptor: XMLDescriptor(org.docx4j.math.CTOnOff --> [])]
at org.eclipse.persistence.jaxb.JAXBBinder.unmarshal(JAXBBinder.java:100)
at org.docx4j.openpackaging.parts.JaxbXmlPartXPathAware.unmarshal(JaxbXmlPartXPathAware.java:211)
at org.docx4j.openpackaging.io.LoadFromZipNG.getRawPart(LoadFromZipNG.java:556)
at org.docx4j.openpackaging.io.LoadFromZipNG.getPart(LoadFromZipNG.java:427)
at org.docx4j.openpackaging.io.LoadFromZipNG.addPartsFromRelationships(LoadFromZipNG.java:350)
at org.docx4j.openpackaging.io.LoadFromZipNG.process(LoadFromZipNG.java:243)
at org.docx4j.openpackaging.io.LoadFromZipNG.get(LoadFromZipNG.java:193)
at org.docx4j.openpackaging.packages.OpcPackage.load(OpcPackage.java:301)
at org.docx4j.openpackaging.packages.OpcPackage.load(OpcPackage.java:245)
at org.docx4j.openpackaging.packages.OpcPackage.load(OpcPackage.java:195)
at org.docx4j.openpackaging.packages.OpcPackage.load(OpcPackage.java:178)
at org.docx4j.openpackaging.packages.WordprocessingMLPackage.load(WordprocessingMLPackage.java:172)
at org.docx4j.samples.OpenAndSaveRoundTripTest.main(OpenAndSaveRoundTripTest.java:60)
Caused by: Exception [EclipseLink-25004] (Eclipse Persistence Services - 2.4.0.v20120529-r11529): org.eclipse.persistence.exceptions.XMLMarshalException
Exception Description: An error occurred unmarshalling the document
Internal Exception: Exception [EclipseLink-116] (Eclipse Persistence Services - 2.4.0.v20120529-r11529): org.eclipse.persistence.exceptions.DescriptorException
Exception Description: No conversion value provided for the value [1] in field [#ns1:val].
Mapping: org.eclipse.persistence.oxm.mappings.XMLDirectMapping[val-->#ns1:val]
Descriptor: XMLDescriptor(org.docx4j.math.CTOnOff --> [])
at org.eclipse.persistence.exceptions.XMLMarshalException.unmarshalException(XMLMarshalException.java:109)
at org.eclipse.persistence.internal.oxm.XMLCompositeObjectMappingNodeValue.startElement(XMLCompositeObjectMappingNodeValue.java:328)
at org.eclipse.persistence.oxm.record.UnmarshalRecord.startElement(UnmarshalRecord.java:783)
at org.eclipse.persistence.internal.oxm.record.DOMReader.reportElementEvents(DOMReader.java:147)
at org.eclipse.persistence.internal.oxm.record.DOMReader.handleChildNodes(DOMReader.java:250)
at org.eclipse.persistence.internal.oxm.record.DOMReader.reportElementEvents(DOMReader.java:148)
at org.eclipse.persistence.internal.oxm.record.DOMReader.handleChildNodes(DOMReader.java:250)
at org.eclipse.persistence.internal.oxm.record.DOMReader.reportElementEvents(DOMReader.java:148)
at org.eclipse.persistence.internal.oxm.record.DOMReader.handleChildNodes(DOMReader.java:250)
at org.eclipse.persistence.internal.oxm.record.DOMReader.reportElementEvents(DOMReader.java:148)
at org.eclipse.persistence.internal.oxm.record.DOMReader.handleChildNodes(DOMReader.java:250)
at org.eclipse.persistence.internal.oxm.record.DOMReader.reportElementEvents(DOMReader.java:148)
at org.eclipse.persistence.internal.oxm.record.DOMReader.handleChildNodes(DOMReader.java:250)
at org.eclipse.persistence.internal.oxm.record.DOMReader.reportElementEvents(DOMReader.java:148)
at org.eclipse.persistence.internal.oxm.record.DOMReader.handleChildNodes(DOMReader.java:250)
at org.eclipse.persistence.internal.oxm.record.DOMReader.reportElementEvents(DOMReader.java:148)
at org.eclipse.persistence.internal.oxm.record.DOMReader.handleChildNodes(DOMReader.java:250)
at org.eclipse.persistence.internal.oxm.record.DOMReader.reportElementEvents(DOMReader.java:148)
at org.eclipse.persistence.internal.oxm.record.DOMReader.handleChildNodes(DOMReader.java:250)
at org.eclipse.persistence.internal.oxm.record.DOMReader.reportElementEvents(DOMReader.java:148)
at org.eclipse.persistence.internal.oxm.record.DOMReader.handleChildNodes(DOMReader.java:250)
at org.eclipse.persistence.internal.oxm.record.DOMReader.reportElementEvents(DOMReader.java:148)
at org.eclipse.persistence.internal.oxm.record.DOMReader.parse(DOMReader.java:89)
at org.eclipse.persistence.internal.oxm.record.SAXUnmarshaller.unmarshal(SAXUnmarshaller.java:462)
at org.eclipse.persistence.oxm.XMLBinder.unmarshal(XMLBinder.java:84)
at org.eclipse.persistence.jaxb.JAXBBinder.unmarshal(JAXBBinder.java:89)
... 12 more
Caused by: Exception [EclipseLink-116] (Eclipse Persistence Services - 2.4.0.v20120529-r11529): org.eclipse.persistence.exceptions.DescriptorException
Exception Description: No conversion value provided for the value [1] in field [#ns1:val].
Mapping: org.eclipse.persistence.oxm.mappings.XMLDirectMapping[val-->#ns1:val]
Descriptor: XMLDescriptor(org.docx4j.math.CTOnOff --> [])
at org.eclipse.persistence.oxm.record.UnmarshalRecord.startElement(UnmarshalRecord.java:851)
at org.eclipse.persistence.internal.oxm.XMLRelationshipMappingNodeValue.processChild(XMLRelationshipMappingNodeValue.java:91)
at org.eclipse.persistence.internal.oxm.XMLCompositeObjectMappingNodeValue.startElement(XMLCompositeObjectMappingNodeValue.java:323)
... 36 more
Caused by: Exception [EclipseLink-116] (Eclipse Persistence Services - 2.4.0.v20120529-r11529): org.eclipse.persistence.exceptions.DescriptorException
Exception Description: No conversion value provided for the value [1] in field [#ns1:val].
Mapping: org.eclipse.persistence.oxm.mappings.XMLDirectMapping[val-->#ns1:val]
Descriptor: XMLDescriptor(org.docx4j.math.CTOnOff --> [])
at org.eclipse.persistence.exceptions.DescriptorException.noFieldValueConversionToAttributeValueProvided(DescriptorException.java:1052)
at org.eclipse.persistence.mappings.converters.ObjectTypeConverter.convertDataValueToObjectValue(ObjectTypeConverter.java:140)
at org.eclipse.persistence.oxm.mappings.XMLDirectMapping.getAttributeValue(XMLDirectMapping.java:287)
at org.eclipse.persistence.internal.oxm.XMLDirectMappingNodeValue.attribute(XMLDirectMappingNodeValue.java:153)
at org.eclipse.persistence.oxm.record.UnmarshalRecord.startElement(UnmarshalRecord.java:834)
... 38 more
That was with JAXBBinder.unmarshall. The same thing occurs if I use JAXBUnmarshaller.unmarshal:
[Exception [EclipseLink-25004] (Eclipse Persistence Services - 2.4.0.v20120529-r11529): org.eclipse.persistence.exceptions.XMLMarshalException
Exception Description: An error occurred unmarshalling the document
Internal Exception: Exception [EclipseLink-116] (Eclipse Persistence Services - 2.4.0.v20120529-r11529): org.eclipse.persistence.exceptions.DescriptorException
Exception Description: No conversion value provided for the value [1] in field [#ns1:val].
Mapping: org.eclipse.persistence.oxm.mappings.XMLDirectMapping[val-->#ns1:val]
Descriptor: XMLDescriptor(org.docx4j.math.CTOnOff --> [])]
at org.eclipse.persistence.jaxb.JAXBUnmarshaller.handleXMLMarshalException(JAXBUnmarshaller.java:956)
at org.eclipse.persistence.jaxb.JAXBUnmarshaller.unmarshal(JAXBUnmarshaller.java:210)
The XML file causing the breakage may be found at https://gist.github.com/2834081 and org.docx4j.math.CTOnOff is here.
Any suggestions?
Note: I'm the EclipseLink JAXB (MOXy) lead an a member of the JAXB (JSR-222) expert group.
The XML document being unmarshalled is actually invalid. If the value in the ns1:val attribute is changed to match the allowed enum values then everything works as expected.
XML File
Line 95 of the xml doc is this
<m:radPr>
<m:degHide m:val="1" />
STOnOff
1 is not a valid value...should be "on" or "off"
#XmlType(name = "ST_OnOff")
#XmlEnum
public enum STOnOff {
#XmlEnumValue("on")
ON("on"),
#XmlEnumValue("off")
OFF("off");
private final String value;
}
CTRadPr
public class CTRadPr implements Child
{
protected CTOnOff degHide;
protected CTCtrlPr ctrlPr;
...
}
CTOnOff
#XmlType(name = "CT_OnOff")
public class CTOnOff implements Child
{
#XmlAttribute(namespace = "http://schemas.openxmlformats.org/officeDocument/2006/math")
protected STOnOff val;
There is a bug in MOXy related to handling the invalid value. What MOXy should do is when it spots the invalid value it should report an error to the ValidationEventHandler. If the ValidationEventHandler handles the event then a value will not be set for the corresponding field/property. When you try this with the JAXB RI you will see that the invalid values are not populated in the object model
You can use the following bug to track our progress on this issue:
http://bugs.eclipse.org/381217
UPDATE
We have fixed bug 381217 in the EclipseLink 2.4.0 stream. You can download a nightly label from the following location:
http://www.eclipse.org/eclipselink/downloads/nightly.php
Note: With the fix, MOXy will report a validation event for the invalid attribute value just as it would for an invalid element value. This is different) behaviour from the JAXB-RI which throws validation events for invalid elements but not invalid attributes. I believe the RI behaviour is a bug.

Resources