6

I have just finished developing a REST web service that is consumed by a mobile application. The web service is developed with Java and runs on an Apache server.

I'm now moving to the testing part. And for that purpose, I need to host my web service in a real server. It is a first experience for, and I just knew that using mutualised (shared) hosting does not allow me to host whatever application, in whatever language.

The one I get to use is OVH, which does not support java web services hosting.

Does anybody have any other alternative to provide. It would help a lot!!

mfaisalhyder
  • 2,250
  • 3
  • 28
  • 38
ashabasa
  • 311
  • 2
  • 9
  • 20

2 Answers2

2

Like I said, if it is for testing purposes you could always use a "normal" PC, running something like XAMPP.

As an alternative you could give RedHat's OpenShift a try, which offers a free, getting-started plan (more info here) that should more than cover your testing requirements.

gkalpak
  • 47,844
  • 8
  • 105
  • 118
  • Thanks for the tip ! I've been trying to use the OpenShift, I downloaded all the required, I created an application under the OpenShift as described, but now I need to push the code I have already worked with into this new application. They are explaining how to create one from scratch! I don't know how to use mine! It's all so complicated !! Have you ever used it ?? – ashabasa May 14 '13 at 09:53
  • Unfortunately, I have only recently found out about OpenShift and didn't yet finf the chance to use it myself. From what I've read though it shouldn't be difficult to push your sources from a GIT repo to OpenShift. (1. Create new Application, 2. Push from your existing GIT repo) – gkalpak May 14 '13 at 10:05
  • Have you managed to deploy your app ? I just deployed mine (just a simple tomcat6 [demo application](http://tomcat.apache.org/tomcat-6.0-doc/appdev/sample/), no DB dependencies or anything). Basically, what I did was: 1. create an application (using Web Console), 2. clone the automatically created GIT repo, 3. copy my .WAR in `'webapps/'` directory, 4. `git add/commit/push`. Fairly straight forward - I don't know how complex your app is though (let us know how it worked out for you). – gkalpak May 14 '13 at 14:07
  • I created the app using the Console as well. I then downloaded the Jboss tools in the IDE section. I opened my eclipse and found a new wizard : called Open Shift Application. I then followed this tutorial : http://www.youtube.com/watch?v=4Htd9vAxJAc but I still can't open my existing app (which is a web service app that doesn't contain any jsp pages). – ashabasa May 14 '13 at 14:34
  • @ashabasa: Questions: 1. Does your app need access to a DB ? 2. Is your app packaged in a .WAR ? 3. what is your app's _context root_ ? 4. Are you willing to use GIT ? – gkalpak May 14 '13 at 14:41
  • 1 : Yes it needs access to a database, which is still in localhost as well (Oracle XE) / 2 : The way I added it, I just added one of the projects open in my work-space / 3 : context root ?? / 4 : I installed it while following the installing instruction, but I don't remember using it. – ashabasa May 14 '13 at 15:41
  • Did you have any luck with deploying your app ? – gkalpak May 16 '13 at 06:35
  • I am also looking solution for same problem – Developer Aug 21 '13 at 16:03
0

To run your app (in Eclipse) you would need to : Run As -> Run on Server And then select a server. If you haven't done so; I suggest you install a local JBoss/WildFly server (the wizard can take care of that for you). Doing this will display options to run your app either on the local or the OpenShift/rhcloud server.This makes testing faster and allow you to avoid testing on the OpenShift live server.

ninjayoto
  • 693
  • 1
  • 7
  • 14