"Azure Services Platform Step by step-8th" Development Deploy Azure message Board

Source: Internet
Author: User
Keywords Here look can't see clearly
Tags .net application applications azure applications clear click cloud cloud service
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.

If your preparation is just not enough, please select the following articles for a quick, selective glance:

"Preparation Knowledge 0" Introducing the AZURE SERVICES PLATFORM

"Prep Knowledge 1" Forget SQL Server 200x--introducing SQL Data Services (SDS)

"Prep Knowledge 2" Don't take Windows Azure as a virtual host-understand the Windows Azure Service architecture

"Prep Knowledge 3" with unarmed play. SQL Data Services (SDS)

"Preparation Knowledge 4" SQL Data Services Programming Basics

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".

The picture is not clear? Please click here to view the original image (larger).

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. Please refer to "Preparation knowledge 3" for specific procedures.

The picture is not clear? Please click here to view the original image (larger).

The picture is not clear? Please click here to view the original image (larger).

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)

 

The picture is not clear? Please click here to view the original image (larger).

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".

The picture is not clear? Please click here to view the original image (larger).

The picture is not clear? Please click here to view the original image (larger).

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.

The picture is not clear? Please click here to view the original image (larger).

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.

The picture is not clear? Please click here to view the original image (larger).

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.

The picture is not clear? Please click here to view the original image (larger).

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

The picture is not clear? Please click here to view the original image (larger).

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.