Code running in Cloud

Code run is an amazing cloud based services provider for programmers and developers. I have recently tried out code run Studio aka IDE by which we can develop websites with browser based IDE’s.

To much amusement, the IDE pretty much has a style of Visual Studio, with rich intellisense and with debugging options. My attempt is to take you to a simple walkthrough to ASP.NET development in CODE RUN.

To create a project, got to NEW>Project

New Project in CODERUN
New Project in CODERUN

It will pop up, a new Javascript modal, as shown below. Believe this what a web dev want, especially those who are learning web languages, or want to try something without installing and configuring the paths etc. etc.. Cloudrun has a great level of abstraction and transparency. The studio provides lots of templates categoriesed into sections such as C-sharp, Javascript and PHP. Well, I havn’t seen a VB.NET option. But there are a bunch templates for Csharp, including silverlight, A facebook template, an ASP.NET MVC application, ASP.NET Website and WebApplication, An ASMX webservice template and WPF browser based application(Though I found xaml extensions, I havn’t XBAP extensions).

Project Templates in CODERUN
Project Templates in CODERUN

In the Javascript section, there is the JQueryUI application, what it creates is a simple example, an html page of JQueryUI features. What the only difference with the sample page provide by the  offical JQueryUI is the theme. So I ask why?

One which I try to exemplify is the ASP.NET dev in the cloud using CODE run. There is a document editor, but there is  no view of it. For those who love to design by code than by drag and drop methods,they will love it. There is a side panel with a tree control with the list of file, which simulate the solution explorer, Right click it and you can add new items. When I clicked the run button, a new browser window popped up which took a bit of time. But sometimes worked bit oddly and showed some invalid exceptions.

Document editor
Document editor
The Solution Explorer
The Solution Explorer

In the codebehind file, The intellisense which I found was amazing. Though it  is not that intelligent a visual studio is, there is a great level of brilliance shown by the devs of Coderun in implementing an appealing, stunning, intelliSense featured web based IDE.

IntelliSense
IntelliSense

VIEWSTATE chunking

In my opinion, VIEWSTATE is what which makes ASP.NET, ASP.NET.  However this mode of memory, precisely the memory mechanism which stores the state, through a input type of hidden field might not work in those systems which has tight constraints over hidden vairables. This includes certain firewalls and proxies which restricts the hidden field to a certain limit. As the data withheld by these controls increases the size of this hidden field(__VIEWSTATE) increases, apparently and what results finally is the denial of VIEWSTATE and hence during the next phase on server side, the ASP.NET will fail to deserialize the user data.

But there is a way to overcome this problem. And that is what VIEWSTATE chunking is about. What VIEWSTATE chunking does is that, it simply divides the VIEWSTATE into set a hidden fields with a defined size limit. To perform that, go to the Web.config and provide the limit as shown below.

<configuration>
..
<system.web>
<pages maxPageStateFieldLength="20">... </pages>
</system.web>
</configuration>

The maxPageStateFieldLength parameter value is set to 20. Well, that is the number of bytes per each hidden field. Obviosuly, 20 bytes is very less and I did it for demonstraton only.

I have created a page with some text boxes. and filled it with values and created a button to perform Postback. And the following are the chunked STATE with set of values I received from the server.


<input type="hidden" name="__VIEWSTATEFIELDCOUNT" id="__VIEWSTATEFIELDCOUNT" value="5" />
<input type="hidden" name="__VIEWSTATE" id="__VIEWSTATE" value="/wEPDwULLTE4MTM5NTMz" />
<input type="hidden" name="__VIEWSTATE1" id="__VIEWSTATE1" value="MTgPZBYCAgMPZBYCAgEP" />
<input type="hidden" name="__VIEWSTATE2" id="__VIEWSTATE2" value="DxYCHgRUZXh0BQlzb21l" />
<input type="hidden" name="__VIEWSTATE3" id="__VIEWSTATE3" value="dGhpbmdkZGRmA1ctuFJC" />
<input type="hidden" name="__VIEWSTATE4" id="__VIEWSTATE4" value="RQdfo8rSra9Ik4399w==" />

Image source: flickr album of Cushing Memorial Library and Archives, Texas A&M’s.

Create a free website or blog at WordPress.com.

Up ↑