8

Currently I'm building my Java Web Application on Google AppEngine (GAE), but due to a lot of limitations they have I'm afraid that I'm going to have to switch from GAE to my own server which is running Glassfish (or I can setup any other server if needed). Also I'm planning to run Oracle or MySql databases. What do I need to do in order to switch from GAE to my server? Do I need to rewrite my code? Should I continue using Datanucleus or switch to something else? Anything else?

2
  • 1
    just out of curiosity, what was the major limiting factor of gae that didn't work for you? Jul 18, 2009 at 4:39
  • 1) File Size Limit 2) Some JEE5 features 3) Database (would like to use Oracle or MySql) 4) Control over my server infrastructure These are four major ones. I have not decided yet if I want to switch, just gathering information and the will decide.
    – Maksim
    Jul 18, 2009 at 8:57

3 Answers 3

6

Why not follow the info given in the original Google campfire ? There was a presentation by IBM on how to run an AppEngine app using DB2. They simply dropped the datanucleus-rdbms jar in the CLASSPATH, changed the connection URL etc, and ran it. Like in this PDF http://download.boulder.ibm.com/ibmdl/pub/software/dw/wes/hipods/GAE_Java_Interoperability.pdf

--Andy (DataNucleus)

1
  • 1
    Wow. That's cool. They have implemented the User and UrlFetch services. Besides config stuff the only real code changes are refactoring certain key types and changing import statements. Jul 18, 2009 at 15:06
4

We won't be able to give very good advice without knowing how you wrote your app. Did you create a data access layer that separates your datastore access from your business logic? Or do you pass app engine specific objects all over the place? Are you using the gae user service? or memcache?

The first thing you should do is look at all your import statements. Anytime you see a com.google.something in there, you know you need to change that. You didn't give much detail about how you wrote your app, but if you are asking about datanucleus you probably were using JDO or JPA, which means you may be able to reuse most of your data layer. You might have a bunch of Key fields which you'll have to change, and maybe a few gae specific annotations. You'll probably have to double check how you handle transactions, as that is likely to be different in a SQL database, which don't use entity groups like GAE does.

4

I haven't tried but there is an open source implementation of GAE called appscale http://code.google.com/p/appscale/

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.