English|Português|Español
UserPasswordLogin

HOME
SESSIONS
INFO
Amazon Web Services

GeneXus Ajax in the new EC2 of Amazon

Amazon launched its new service: EC2; a virtual server that operates on demand. Sabrina Juárez, from GeneXus Java Support team, tells us how she managed to have a sample application (GeneXus Ajax) running with a few steps with Amazon EC2 beta version.

A few days ago Amazon launched the limited beta version of a new web service:  Amazon Elastic Compute Cloud (Amazon EC2). A few months ago, Amazon had launched the Simple Storage Service (or S3), a web managed storage system.  EC2 is similar to S3, but it provides processing capacity.

The new Amazon service presents a truly virtual environment that, when linked to the space of the S3, allows using the web services interface required by the PCs used, load applications from a normal environment, manage network access rights and run images using as many systems as desired. Basically, this beta allows developers to access powerful computers without spending large amounts of money.

EC2 reduces the time required to obtain and restart the instances of a new server in minutes, allowing for a scaled speed capacity, depending on requirements. EC2 changes IT economy by enabling to pay only for the capacity that is effectively used. In fact, it is almost the ideal solution for developers, since this Amazon beta allows that anyone with the capacity to develop ideas through programming can do it almost immediately, paying only for the storage and processing resources.   

Developers will be able to rent "the cloud” for 10 cents of a dollar an hour, plus 20 cents per giga of traffic, and 15 cents per giga of monthly storage.  Each virtual server uses the equivalent to a of 1.7 GHz Xeon CPU, with 1.75GB of RAM, 160GB of hard disk and 250Mb/s of bandwidth.

And, of course, we tested it with GeneXus.  We currently have the GeneXus Ajax sample running hosted in Amazon EC2. Sabrina Juárez, member of GeneXus Java Support team and responsible for “hanging” the application, tells us how she did it:

“Amazon EC2 is a web service, and its methods are available through a command line interface. Using those methods, it is possible to setup and run an application in any of Amazon EC2's virtual images.  It is also possible, using those methods, to start several virtual instances of the same image and download them, according to the company requirements. 

Once the application has been published, it can be accessed, administered and updated quite safely, since the owner of the image has certificates to access it. In our case, with a few steps, we managed to publish the “Ajax Sample” application in a Linux Fedora image.

Amazon supplies a series of preconfigured Linux images that can be used as a shortcut for the preparation of the environment and the production cutover.

It would have been possible to prepare our own image by installing the operative system and other requirements and then installing the Ajax Sample and uploading it to Amazon.  However, we opted for taking an already preconfigured image provided by Amazon as a starting point for our work.

1. We chose one of the images provided by Amazon because they already have an installed Linux operating system (Fedora distribution) plus Mysql DBMS. It is possible to get an instance of that image, upload it and execute it, to start working on it. Once this instance has been uploaded, the connection is secure and is through SSH.

2. We installed the software requirements needed, so as to leave the image ready to execute a Java web application (SUN JDK, Tomcat servlets engine) and we setup the database and other access rights.

3. We installed the .war corresponding to the "Ajax Sample" application, which was previously setup using GeneXus Deployment Wizard. That is to say, we transferred the war to our image, so the corresponding web application was installed and running under the Tomcat engine. The access URL is the following:
http://domu-12-31-33-00-03-5a.usma1.compute.amazonaws.com:8080/ajaxsample/servlet/hhome

In the community Wiki, there is a detailed guide of the different methods provided by EC2 to publish an application along with other useful tips.

Related
Special Edition #GeneXusTheBestOf2014 :: Cloud Computing, the Internet of Things, GeneXus X Evolution 3, Success Stories, Smart Devices and ... Much More!
Release of U2 of GeneXus Evolution 3
Chopo Mobile introduces successful app in Mexico, developed with GeneXus and used for medical studies
GeneXus™ ERP Explorer and Connector for SAP® ERP Now Live on SAP Store
We have a new Download Center! The GeneXus download center has an enhanced appearance at its new location
Demand for Apple TV apps expected to double in 2016
What we've learned about GeneXus by working with Gartner (by Gabriel Simonet)
Agile or Waterfall development? (by Breogán Gonda)
We are pleased to share an interesting white paper about GeneXus, written by Kapil Ambwani from India!
Mickey, Toy Story & GeneXus: Why robots will transform developers?
GeneXus™ Named a NEW Challenger by Gartner In Its 2017 Magic Quadrant for App Development Platforms Report
Free Live Webinar: Conversations on Digital Transformation - Wednesday, November 8, 2:30PM (EST)
GeneXus™ Announces Its Participation at SAPPHIRE NOW® to Showcase GeneXus for SAP® Systems