EM328-1502B-01 Server-Side Scripts: thoughts on an assignment

So this week I started two new classes. The first one and the one we are talking about today is Server side scripting. I admit right out of the gate that server-side is not my forte. Although it is something I intend to learn, I just wanted to get that out of the way before some one reads the post I am about to make and smites me for being absolutely and totally wrong. For the most part, I think I pretty much got it. Anyway, here is the post and you can determine for yourselves if the ideas put forth within it are accurate.

How do server-side scripts use the request/response model to dynamically communicate with the user?

The request/response model is an example of two way communication. It works by having one system send a request to another and a response is sent back. This can be ongoing in a back and forth sort of nature much like a telephone call. The next aspect to consider with such topics is whether the request is asynchronous. That means does the browser wait for the response or just keep doing its thing. This is the heart of AJAX, Asynchronous JavaScript and XML. These days XML isn’t used like it used to be. Most requests return JSON, JavaScript Object Notation. Then via JavaScript the data is rendered into HTML/CSS and placed on the appropriate place on the page. Alternatively, if said request was not asynchronous nor AJAX. The page would wait after sending a request, more or less frozen, until a response from the server was returned. This is a big part of why JavaScript was not popular in the early days of the net.

Compare and contrast features of the popular serverside scripting languages such as C#, PHP, and Visual Basic.Net in supporting such an application.

When I think of server side scripting langauges, I think of JavaScript’s node.js, Python’s Django, Ruby on Rails, and PHP. While server side programming is not my forte, it is something that I want to learn and hope to tackle in a more thorough way than this five week course will permit. These are the languages that I am most interested in. For my purposes, I will likely choose node.js for my future endeavors and that’s only because I already know a lot about JavaScript. I know a bit of Python although I am rusty. And Ruby has a special place in my heart. Some of the things Ruby can do are really awesome. For the future of web development, I see node.js as being one of the larger forces. We are to compare and contrast these languages, so in attempt to do that I will write a short summary of them. Really they do a lot of the same stuff, it’s the how it does it that makes them different.

Node.js is an open source project created by developers at Joyent for use on Linux systems in 2009. It is a cross-platform project written in you guessed it JavaScript. Like other JS applications it runs event driven architecture and non bloicking API. It is used by Microsoft, Yahoo, Walmart, SAP, LinkedIn, PayPal, Voxer, and GoDaddy to mention a few. It uses Google V8 JavaScript engine and has a built in library that doesn’t require it to run Apache HTTP Server or IIS. It is very fast, and web focused and therefore is liked by many developers. It will be a huge force in the coming years.

Django is a language that I know very little about, but considering that Python was the first language I learned I have always been interested, just too busy to check it out. It is free and open sourced. It follows the Model-view-controller architectural pattern. It is maintained by the Django Software Foundation that is nonprofit. Django is used by sites like Pinterest, Instagram, Mozilla, The Washington Times, Disqus, BitBucket, and the Public Broadcasting Service. It’s main purpose is to create complex, database driven websites and emphasizes reusability and ideas like DRY, Don’t Repeat Yourself (which is a concept all programmers can/should embrace).

Ruby on Rails is also an open sourced project and like Django it is a MVC. It is written in Ruby as it’s name would suggest. It encourages the use of XML and JSON and marries well against HTML, CSS, and JavaScript on the front end. It as most all of these also encourage the use of CoC, DRY, and the active record pattern. Ruby works best on UNIX based system such as Mac or Linux. Unlike node.js RoR is typically designed over a database server such as MySQL and a web server like Apache. RoR is used on many websites, such as, Twitter, Shopify, CrunchBase, Groupon, Bloomberg, Airbnb, SoundCloud, Heroku, and more.

In short, there are a lot of similarities between these guys, but there are also little differences. Each has its own structure and syntax. All of them could be used for something great, but depending on the project, developer, and style the choice will be narrowed down and ultimately productivity of the developer will show just what can be done with such scripts.”

So that is it. It is as much opinions about these than it is about fact. But I thought that since I write these every week and no one hardly ever reads them except my teachers. Maybe I will put a bit more effort in them if I know that all of you are going to read them as well.

So send me some feedback. Correct me if I am wrong. I love to learn.

Advertisements