vdammala vkumar

Ranch Hand
+ Follow
since Jan 16, 2012
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
3
Received in last 30 days
0
Total given
7
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by vdammala vkumar

Hi ,

I am using Tomcat 7 for deploying restful webservices , I've set the initialisize to '5' in context.xml.

I would like to tell to tomcat to close the connection if it is idle more than 60sec .

I tried the attributes like  minEvictableIdleTimeMillis="60" maxAge="60",removeAbandonedTimeout="60"   removeAbandoned="true" maxWait="5000" maxActive="60" maxIdle="5",rollbackOnReturn="true" , but No Luck.

1)Initially , I want to see 5 connection
2)Close the connection which is idle for 60sec ( count should be 4)
3)Create new connection if needed again ( could should come back to 5)

Please advise.

Regards,
Vijay
7 years ago
Hi,

How do i prevent the NIL tags in SOAP response? I am looking for a global solution if possible.

Ex :

<contractStartDate xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"/> // value of contractStartDate is  NULL.

Regards,
Vijay
7 years ago
Hi All,

I would like to invoke a SOAP service using org.springframework.web.client.RestTemplate.postForEntity() and get the SoapFault object when error occurs in the SOAP service?

Please share a sample piece of code if possible.

Please note , positive scenarios are working fine.


Regards,
Vijay

7 years ago
below conf resolved the issue.

<configuration>
<fork>once</fork>
</configuration>
7 years ago
Only once during first build and stop from 2nd build onwards.
7 years ago
Hi All,

I generated java code from WSDL using wsdl2java plugin in pom.xml , when i tried to make changes to the code , due to the wsdl2java plugin i am loosing the changes.

Is there any extraArg to make this plugin execution NON-RECURSIVE?

Regards,
Vijay
I have all these jars in my class path:

\apache-cxf-3.1.6\lib\activemq-broker-5.12.0.jar
\apache-cxf-3.1.6\lib\activemq-client-5.12.0.jar
\apache-cxf-3.1.6\lib\activemq-openwire-legacy-5.12.0.jar
\apache-cxf-3.1.6\lib\antlr-2.7.7.jar
\apache-cxf-3.1.6\lib\aopalliance-1.0.jar
\apache-cxf-3.1.6\lib\asm-5.0.4.jar
\apache-cxf-3.1.6\lib\bcprov-jdk15on-1.54.jar
\apache-cxf-3.1.6\lib\commons-codec-1.10.jar
\apache-cxf-3.1.6\lib\commons-collections-3.2.2.jar
\apache-cxf-3.1.6\lib\commons-lang-2.6.jar
\apache-cxf-3.1.6\lib\cryptacular-1.0.jar
\apache-cxf-3.1.6\lib\cxf-core-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-manifest.jar
\apache-cxf-3.1.6\lib\cxf-rt-bindings-coloc-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-bindings-corba-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-bindings-object-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-bindings-soap-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-bindings-xml-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-databinding-aegis-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-databinding-jaxb-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-databinding-jibx-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-databinding-sdo-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-databinding-xmlbeans-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-features-clustering-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-frontend-jaxrs-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-frontend-jaxws-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-frontend-js-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-frontend-simple-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-javascript-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-management-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-rs-client-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-rs-extension-providers-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-rs-extension-search-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-rs-json-basic-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-rs-security-cors-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-rs-security-jose-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-rs-security-jose-jaxrs-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-rs-security-oauth-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-rs-security-oauth2-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-rs-security-sso-saml-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-rs-security-xml-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-rs-service-description-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-security-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-security-saml-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-transports-http-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-transports-http-hc-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-transports-http-jetty-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-transports-http-netty-client-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-transports-http-netty-server-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-transports-jms-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-transports-local-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-transports-udp-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-ws-addr-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-ws-mex-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-ws-policy-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-ws-rm-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-ws-security-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-rt-wsdl-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-services-sts-core-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-services-ws-discovery-api-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-services-ws-discovery-service-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-services-wsn-api-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-services-wsn-core-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-tools-common-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-tools-corba-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-tools-java2ws-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-tools-misctools-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-tools-validator-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-tools-wadlto-jaxrs-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-tools-wsdlto-core-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-tools-wsdlto-databinding-jaxb-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-tools-wsdlto-frontend-javascript-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-tools-wsdlto-frontend-jaxws-3.1.6.jar
\apache-cxf-3.1.6\lib\cxf-xjc-boolean-3.0.5.jar
\apache-cxf-3.1.6\lib\cxf-xjc-bug671-3.0.5.jar
\apache-cxf-3.1.6\lib\cxf-xjc-dv-3.0.5.jar
\apache-cxf-3.1.6\lib\cxf-xjc-javadoc-3.0.5.jar
\apache-cxf-3.1.6\lib\cxf-xjc-runtime-3.0.5.jar
\apache-cxf-3.1.6\lib\cxf-xjc-ts-3.0.5.jar
\apache-cxf-3.1.6\lib\ehcache-2.10.1.jar
\apache-cxf-3.1.6\lib\FastInfoset-1.2.13.jar
\apache-cxf-3.1.6\lib\geronimo-j2ee-management_1.1_spec-1.0.1.jar
\apache-cxf-3.1.6\lib\geronimo-javamail_1.4_spec-1.7.1.jar
\apache-cxf-3.1.6\lib\geronimo-jms_1.1_spec-1.1.1.jar
\apache-cxf-3.1.6\lib\geronimo-jta_1.1_spec-1.1.1.jar
\apache-cxf-3.1.6\lib\geronimo-servlet_3.0_spec-1.0.jar
\apache-cxf-3.1.6\lib\guava-18.0.jar
\apache-cxf-3.1.6\lib\hawtbuf-1.11.jar
\apache-cxf-3.1.6\lib\httpasyncclient-4.1.1.jar
\apache-cxf-3.1.6\lib\httpclient-4.5.2.jar
\apache-cxf-3.1.6\lib\httpcore-4.4.4.jar
\apache-cxf-3.1.6\lib\httpcore-nio-4.4.4.jar
\apache-cxf-3.1.6\lib\jasypt-1.9.2.jar
\apache-cxf-3.1.6\lib\java-support-7.1.1.jar
\apache-cxf-3.1.6\lib\javax.annotation-api-1.2.jar
\apache-cxf-3.1.6\lib\javax.servlet-api-3.1.0.jar
\apache-cxf-3.1.6\lib\javax.ws.rs-api-2.0.1.jar
\apache-cxf-3.1.6\lib\jaxb-core-2.2.11.jar
\apache-cxf-3.1.6\lib\jaxb-impl-2.2.11.jar
\apache-cxf-3.1.6\lib\jaxb-xjc-2.2.11.jar
\apache-cxf-3.1.6\lib\jcl-over-slf4j-1.7.19.jar
\apache-cxf-3.1.6\lib\jettison-1.3.7.jar
\apache-cxf-3.1.6\lib\jetty-continuation-9.2.15.v20160210.jar
\apache-cxf-3.1.6\lib\jetty-http-9.2.15.v20160210.jar
\apache-cxf-3.1.6\lib\jetty-io-9.2.15.v20160210.jar
\apache-cxf-3.1.6\lib\jetty-security-9.2.15.v20160210.jar
\apache-cxf-3.1.6\lib\jetty-server-9.2.15.v20160210.jar
\apache-cxf-3.1.6\lib\jetty-util-9.2.15.v20160210.jar
\apache-cxf-3.1.6\lib\joda-time-2.7.jar
\apache-cxf-3.1.6\lib\js-1.7R2.jar
\apache-cxf-3.1.6\lib\mina-core-2.0.9.jar
\apache-cxf-3.1.6\lib\neethi-3.0.3.jar
\apache-cxf-3.1.6\lib\oauth-20100527.jar
\apache-cxf-3.1.6\lib\oauth-provider-20100527.jar
\apache-cxf-3.1.6\lib\opensaml-core-3.1.1.jar
\apache-cxf-3.1.6\lib\opensaml-profile-api-3.1.1.jar
\apache-cxf-3.1.6\lib\opensaml-saml-api-3.1.1.jar
\apache-cxf-3.1.6\lib\opensaml-saml-impl-3.1.1.jar
\apache-cxf-3.1.6\lib\opensaml-security-api-3.1.1.jar
\apache-cxf-3.1.6\lib\opensaml-security-impl-3.1.1.jar
\apache-cxf-3.1.6\lib\opensaml-soap-api-3.1.1.jar
\apache-cxf-3.1.6\lib\opensaml-xacml-api-3.1.1.jar
\apache-cxf-3.1.6\lib\opensaml-xacml-impl-3.1.1.jar
\apache-cxf-3.1.6\lib\opensaml-xacml-saml-api-3.1.1.jar
\apache-cxf-3.1.6\lib\opensaml-xacml-saml-impl-3.1.1.jar
\apache-cxf-3.1.6\lib\opensaml-xmlsec-api-3.1.1.jar
\apache-cxf-3.1.6\lib\opensaml-xmlsec-impl-3.1.1.jar
\apache-cxf-3.1.6\lib\slf4j-api-1.7.19.jar
\apache-cxf-3.1.6\lib\slf4j-jdk14-1.7.19.jar
\apache-cxf-3.1.6\lib\spring-aop-4.1.9.RELEASE.jar
\apache-cxf-3.1.6\lib\spring-beans-4.1.9.RELEASE.jar
\apache-cxf-3.1.6\lib\spring-context-4.1.9.RELEASE.jar
\apache-cxf-3.1.6\lib\spring-core-4.1.9.RELEASE.jar
\apache-cxf-3.1.6\lib\spring-expression-4.1.9.RELEASE.jar
\apache-cxf-3.1.6\lib\spring-web-4.1.9.RELEASE.jar
\apache-cxf-3.1.6\lib\stax2-api-3.1.4.jar
\apache-cxf-3.1.6\lib\velocity-1.7.jar
\apache-cxf-3.1.6\lib\woodstox-core-asl-4.4.1.jar
\apache-cxf-3.1.6\lib\wsdl4j-1.6.3.jar
\apache-cxf-3.1.6\lib\wss4j-bindings-2.1.5.jar
\apache-cxf-3.1.6\lib\wss4j-policy-2.1.5.jar
\apache-cxf-3.1.6\lib\wss4j-ws-security-common-2.1.5.jar
\apache-cxf-3.1.6\lib\wss4j-ws-security-dom-2.1.5.jar
\apache-cxf-3.1.6\lib\wss4j-ws-security-policy-stax-2.1.5.jar
\apache-cxf-3.1.6\lib\wss4j-ws-security-stax-2.1.5.jar
\apache-cxf-3.1.6\lib\xml-resolver-1.2.jar
\apache-cxf-3.1.6\lib\xmlbeans-2.6.0.jar
\apache-cxf-3.1.6\lib\xmlschema-core-2.2.1.jar
\apache-cxf-3.1.6\lib\xmlsec-2.0.6.jar
7 years ago
All,

I am trying to create a web service project using existing WSDLs , i could not able to complete the deployment due to below errors.

Technology Stack :

Spring 4.1.7
Tomcat7
Apache CXF : 3.1.6

Error:

org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'cxf' is defined
at org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeanDefinition(DefaultListableBeanFactory.java:687)
at org.springframework.beans.factory.support.AbstractBeanFactory.getMergedLocalBeanDefinition(AbstractBeanFactory.java:1168)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:281)

I have already tried all the options suggested in internet. Like

<import resource="classpath:META-INF/cxf/cxf.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
<import resource="classpath:META-INF/cxf/cxf-servlet.xml" />

etc

Regards,
Vijay

7 years ago
fixed by adding javax.xml.accessExternalSchema = all in right JRE location. It was my mistake.
Hi,

When i tried to generate java code from WSDL using Apache CXF , i was getting below error.

I tried adding jvm arg : -Djavax.xml.accessExternalSchema=all but NO LUCK

org.apache.cxf.tools.common.ToolException: org.xml.sax.SAXNotRecognizedException: Property 'http://javax.xml.XMLConstants/property/accessExternalSchema' is not recognized.
at org.apache.cxf.tools.validator.internal.SchemaValidator.validate(SchemaValidator.java:215)
at org.apache.cxf.tools.validator.internal.SchemaValidator.validate(SchemaValidator.java:120)
at org.apache.cxf.tools.validator.internal.SchemaValidator.isValid(SchemaValidator.java:103)
at org.apache.cxf.tools.validator.internal.WSDL11Validator.isValid(WSDL11Validator.java:157)
at org.apache.cxf.tools.wsdlto.frontend.jaxws.wsdl11.JAXWSDefinitionBuilder.validate(JAXWSDefinitionBuilder.java:207)
at org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.processWsdl(WSDLToJavaContainer.java:205)
at org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContainer.java:165)
at org.apache.cxf.tools.wsdlto.WSDLToJavaContainer.execute(WSDLToJavaContainer.java:416)
at org.apache.cxf.tools.common.toolspec.ToolRunner.runTool(ToolRunner.java:103)
at org.apache.cxf.tools.wsdlto.WSDLToJava.run(WSDLToJava.java:113)
at org.apache.cxf.tools.wsdlto.WSDLToJava.run(WSDLToJava.java:86)
at org.apache.cxf.tools.wsdlto.WSDLToJava.main(WSDLToJava.java:184)
Caused by: org.xml.sax.SAXNotRecognizedException: Property 'http://javax.xml.XMLConstants/property/accessExternalSchema' is not recognized.
at com.sun.org.apache.xerces.internal.jaxp.validation.XMLSchemaFactory.setProperty(XMLSchemaFactory.java:399)
at org.apache.cxf.tools.validator.internal.SchemaValidator.createSchema(SchemaValidator.java:129)
at org.apache.cxf.tools.validator.internal.SchemaValidator.validate(SchemaValidator.java:194)
... 11 more

How to enable CXF to access all external schema?
All,

I couldn't find simple tutorial to understand the steps to create a Webservice using existing WSDLs.I would like to avoid Apache CXF or any other third party runtime library...that is the whole idea.

IDE : STS
Techstack : Spring 1.4.7

Any input regarding this will be much appreciated.

Regards,
Vijay
7 years ago
Thank you all for valuable time and inputs , I tried to fix the problem in JAVA which actually created by DataPower(IBM) ,as per your suggestions i am going ahead and working with IBM people for finding fix in DataPower itself.
7 years ago
@Tim Holloway

I do agree with you on that , but how come it worked as expected on Windows JVM?

Please forget about Webapp , this particular question and piece of work doesn't involve any browser/html etc.
7 years ago
Front end app sends those character set to the service request , I am trying to decode and populate in database.

Ideally front end app should restrict them , due to some other limitation i am trying to handle it in service layer.

7 years ago