Google App Engine + OpenCMIS - google-app-engine

Problem in SOAP connection From the GWT solution to CMIS webServer.
GWT 2.4.0
Google App Engine 1.7.3 is used.
Apache OpenCMIS 0.8 library is used.
i've looked in
consuming SOAP web serives in google app engine and GWT article.
And http://code.google.com/appengine/articles/soap.html. http://code.google.com/p/googleappengine/issues/detail?id=5332
SOAP CMIS connection is made internaly in the Apache OpenCMIS library. (jaxws-rt-2.1.7.jar)
REST Atom Pub connection works nice.
I've got the following error, trying to connect to the SOAP webservice:
Caused by: java.lang.NoClassDefFoundError: java.net.ProxySelector is a restricted class. Please see the Google App Engine developer's guide for more details.
at com.google.appengine.tools.development.agent.runtime.Runtime.reject(Runtime.java:51)
at com.sun.xml.ws.api.EndpointAddress$1.run(EndpointAddress.java:153)
at com.sun.xml.ws.api.EndpointAddress$1.run(EndpointAddress.java:152)
at java.security.AccessController.doPrivileged(Native Method)
at com.sun.xml.ws.api.EndpointAddress.chooseProxy(EndpointAddress.java:149)
at com.sun.xml.ws.api.EndpointAddress.<init>(EndpointAddress.java:130)
at com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.parsePort(RuntimeWSDLParser.java:369)
at com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.parseService(RuntimeWSDLParser.java:341)
at com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.parseWSDL(RuntimeWSDLParser.java:323)
at com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.parse(RuntimeWSDLParser.java:146)
at com.sun.xml.ws.client.WSServiceDelegate.parseWSDL(WSServiceDelegate.java:265)
at com.sun.xml.ws.client.WSServiceDelegate.<init>(WSServiceDelegate.java:228)
at com.sun.xml.ws.client.WSServiceDelegate.<init>(WSServiceDelegate.java:176)
at com.sun.xml.ws.spi.ProviderImpl.createServiceDelegate(ProviderImpl.java:104)
at javax.xml.ws.Service.<init>(Service.java:56)
at org.apache.chemistry.opencmis.commons.impl.jaxb.DiscoveryService.<init>(DiscoveryService.java:42)

Related

Deploy CXF jax-ws webservice on Websphere 8.5.5.12

I am trying to deploy a jax-ws webservice on Websphere 8.5.5.12. I am using CXF as my jax-ws engine. I have gone through the prerequisites and changed the class loader as well as desabled the JaxWs engine in websphere. I have set the property to disable Jax-WS engine in the manifest file of my war file.
My application is a Spring boot application. I am also using apache camel 2.20.1 and using the cxf end point to consume the messages.
As a spring boot application my application is working fine.
When I deploy on Websphere my application starts without any issues. But when it intercepts any incoming requests, it throws class not found exception for javax.servlet.WriteListener class. This class is part of the servlet api. It should have been part of the Websphere j2ee library.
Need to know what I did wrong. I don't want to take the shared library route. I have been suggested, that I need to move all my cxf dependencies, into a shared library and set my class loader for this library. I am not comfortable with this solution.
javax.servlet.WriteListener is a Servlet 3.1 / Java EE7 API.
WebSphere Application Server 8.5.5 implements Servlet 3.0 / Java EE6.
You should use either WebSphere Application Server 9.0.0.x or any recent WebSphere Liberty release (which has been versioned differently for quite some time).
(or, remove the 3.1 dependencies from your app if you must run it on WebSphere Application Server 8.5.5)

Google App Engine not supported Java.io.FileOutputStream

I am very new to google App engine please give me proper solution,my problem is below
when i am trying to deploy my web application to google app engine it shows me error like Java.io.FileOutputStream restricted in google app engine
How to fix it.Is there any setting in google app angine so that this class is supportable without changing java code,
If not what is the alternative way for this problem. Below is my error code.
Uncaught exception from servlet
java.lang.NoClassDefFoundError: java.io.FileOutputStream is a restricted class.
Please see the Google App Engine developer's guide for more details.
On the Google App Engine lots of classes are simply not available or give you an SecurityException. You are simply not allowed to read or write files on GAE.

Google App Engine for Java meet DFP API- V201302

I am not able to access DFP Api using latest version (v201302) on Google App Engine, it works fine at localhost:8888 but gives error at Google App Engine.
Error: Exception retrieving data; nested exception is:
java.net.SocketException: Permission denied: Attempt to access a blocked recipient without permission. (mapped-IPv4)
This is fixed by adding right jars from maven repository.
see complete servlet here.

Salesforce's Database.com and Google App Engine via JPA

Currently i try to connect (via JPA/Datanucleus) with an application, hosted by Google App Engine, to the database service of database.com (Salesforce)
After many hours of reading and trying, i could not find any solution.
So, is it even possible??
Some Information....
Database.com provides JPA: http://forcedotcom.github.com/java-sdk/jpa-provider, but i could not found any sdk on this side, but i found a jar-file hosted by grepcode http://grepcode.com/snapshot/repo1.maven.org/maven2/com.force.sdk/force-jpa/22.0.7-BETA/ - Possibly there is currently no official release ...
The problem is that this SDK from Salesforce needs datanucleus 2.0, but Google App Engine includes only datanucleus 1.1.5. So i try to update theses libaries and found this.... code.google.com/p/datanucleus-appengine/ . I tried a few hours to replace the old libaries and to use the newer, but unsuccessfully. The error was that eclipse could not find some libaries, because the newer libaries, provided by the side above, have different package structure -
I am thankful for any help...
Kotake
The official release of the JPA provider is available on Maven Central:
http://search.maven.org/remotecontent?filepath=com/force/sdk/force-jpa/22.0.7-BETA/force-jpa-22.0.7-BETA.jar
The external connection restriction won't be a limiting factor because the JPA adapter connects to Database.com over https using a SOAP API.
I can't speak to the challenges around getting DN 2.0 running on GAE. Perhaps GAE support can help with that?
As stated here in the App Engine docs, you cannot make direct connections to external servers from GAE (except over http or https using the app engine specific url APIs). You will need to find some other way to get data out of your remote database.
This link describes how to solve your problem:
How to use Force.com Database SDK on Google APP Engine
(He has updated the Saleforce SDK source code to allow it to work without problem on GAE.)

JDBC Driver does not work with GWT?

I want to access to an external MySQL server from my server using GWT, I added the mysql-connector jar to the build path and in war/WEB-INF/lib
Although I get this exception:
java.lang.NoClassDefFoundError:
com.mysql.jdbc.Driver is a restricted
class. Please see the Google App
Engine developer's guide for more
details.
Any ideas? Would jdbc driver be on a black-list?
App Engine doesn't support JDBC. Maybe your project is set to target App Engine. If you're using Eclipse, right click the project, choose properties, and under "Google>App Engine" deselect "Use Google App Engine".
It seems Google has not yet released JDBC support..

Resources