Cloud Computing Instance Resolution: Developing and deploying Azure message Board

Source: Internet
Author: User
Keywords Message board we development department

I believe that after reading the first 7 of this set of tutorials, there has been a more comprehensive understanding of azure Services platform. Now let's move on to the simplest message boards, using Windows Azure in Azure Services platform as the host, SQL data Services, as the data store, to understand the whole process of developing and deploying Azure applications.

The final effect figure is as follows: (also available through Http://ibm.cloudapp.net View network version)

Development process:

1. Start the development Fabric in the native Windows Azure SDK to open the debugging environment for this machine.

2. Open VS2008 and create a new visual C#–cloud Service–web Cloud Service project. This example is simple enough to use web role only.
For the difference between web role and worker role, refer to "Prepare Knowledge 2".

After you create a new project, the guestbook and guestbook_webrole two projects will appear in the solution. Where guestbook is a configuration file about roles, in this case you can ignore it. The main operation of this example is the Guestbook_webrole project, that is, a asp.net web site project.

3. Open SDS Explorer in the SQL Data Services SDK. Configure user name, password, new authority and container.

4. Here we have a new authority named "Guestbook" and a container called "1st". Now we configure them into the Web.config file of the Guestbook_webrole project for the program to read.

5. Create a new Clouddatahelper class in Guestbook_webrole. To write some basic operations on the SQL Data service. Detailed code is shown in the attachment.

The following is an example of a function that reads a configuration file and stores data.

6. Drag several controls and simple logical code into the Default.aspx page. Oh, I don't need to teach it? Details are also included in the attachment.

7.F5 for debug operation. If you run successfully, the home page will appear in front of you-just like debugging the traditional ASP.net Web creator. At the same time, some relevant information will appear in the development fabric.

8. If you are satisfied with the results of debug, then you need to deploy our first cloud application to the cloud.

Right-click on the guestbook item and select Publish (publish)

If the publication is successful, vs will pop up two boxes in front of you:

folder containing publishing files and Azure Services Developer Portal (login required LiveID)

9. Create a new Windows Azure-Hosted Services project in the Azure services Developer portal. Fill in some simple information.
If you have questions about Azure Services Developer portal, please refer to "Preparation knowledge 0".

10. Introduce the main interface of hosted service: the following figure. Each host application on Windows Azure consists of two states (or two different deployment platforms): Production and Staging. Simply put, production is a place for formal deployment, staging is a backup server for internal test deployments.

 

11. We first deploy our application to the staging server. Click on the Deploy button in the above image to enter the following interface. Follow the prompts to upload the two files that were generated when you just publish.

12. After successful deploy on the staging server, click the circle in the middle of the image below to swap the contents of the staging server to the production server and click the "Run" button. Note: Both processes require long waits.

13. If the deployment succeeds, you will see an interface similar to the one shown below. When the "Webrole" logo appears with the green tick and the word "started", you can now access your "cloud apps" on the web. such as Http://ibm.cloudapp.net

Oh, is it easy? Go and experience your own cloud application!

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.