Forums Register Login

Google App Engine + Simple Stripes web-app

+Pie Number of slices to send: Send
Hello,

I have a very basic web application that uses the Stripes framework. I've set this up in Netbeans, and it runs perfectly fine locally on Glassfish v3.

My app consists of a few JSPs and a few actions that navigate through the various pages, nothing fancy at the moment.

I've followed the GAE documentation as provided on the google site, I have successfully run my application locally using the GAE server as included in the SDK, this works fine I can access my application on port 8080 no problem.

I've checked in my app to GAE (once again following their documentation) however this fails to run, I'm able to get the following from their logs



Am I missing something completely obvious? Could there be an issue with my code? It runs fine on the GAE server I have running locally, so I'm unsure of what would change

Many thanks

+Pie Number of slices to send: Send
After some more searching, it appears there is one common issue with GAE and stripes

Stripes Framework
Version(s): ?
Status: COMPATIBLE

* The default multipartwrapper implementation needs a temporary directory on the local file system for file uploads, which App Engine doesn't allow. The workaround is to create your own implementation -- more details at http://groups.google.com/group/google-appengine-java/browse_thread/thread/81dbcf7cf2281014.



source

This leads onto some discussions of initialising the multipartWrapper : http://groups.google.com/group/google-appengine-java/browse_thread/thread/81dbcf7cf2281014

I'm not sure how to do that, can anyone please advise? I will continue to research and post any solutions I find

Thanks
+Pie Number of slices to send: Send
If you don't need file uploads, then proceed as described in the last section of http://www.stripesframework.org/display/stripes/File+Uploads: implement MultipartWrapperFactory with an implementation that does nothing at all.

If you do need file uploads, then you'd also implement MultipartWrapperFactory (maybe by subclasssing DefaultMultipartWrapperFactory), but with an implementation that does not use temp directories. In that case you should use the Apache Commons FileUpload library, since that can be configured to not use files, but hold everything in memory. Or you can configure it to use a directory that does exist, and to which GAE allows access.
+Pie Number of slices to send: Send
Just for the record, I had to provide an empty implementation of MultipartWrapper and update my web.xml, as follows






I also wrote up what I had to do on my blog

Hopefully this will help others in the future ;)

+Pie Number of slices to send: Send
 

GAE has no support for uploading of files, so we use this to disable that part of Stripes


I'm fairly certain that's not correct. The way it looks to me is that GAE doesn't support file uploads the way they work by default in Stripes. But that can apparently be changed in the way I described.
+Pie Number of slices to send: Send
Sorry got that comment wrong, cheers for pointing it out I'll make a note to update my code

thanks Ulf,

J
Right! We're on it! Let's get to work tiny ad!
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 2547 times.
Similar Threads
Problem with mail api on google app engine.
Appengine Error
Saving a file under my GWT project's '/war' path - Security Exception
Strange Problem with struts2-convention-plugin-2.1.8.1.jar
Need help on animation using GUI Builder.
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 29, 2024 02:23:03.