Most part of
my career I worked on Windows based systems, when cloud computing evolved, in
one of my previous companies I had a great opportunity to work on open sources
stuff Go Lang and Mongo Db. My manager was not intended to experiment on business critical application using GO Lang. But understanding the ease of compilation and
scalability of Go he was convinced, so I did a POC. It got approved and moved to production after a
through testing .The entire application development was done on
Windows 7 running machines.
Since the
organization has sufficient resources (man, money and metals) my job was only
to develop the application using GO Lang and provide binaries for Linux and
Windows servers.
Problem statement:
After couple
of years, one of my close friends (Naveen) come up with an idea to develop remote
monitoring system using telemetric devices, since he is an instrumentation engineer,
did research and selected two telemetric devices.
The idea is,
we install telemetric devices in heavy machinery, and periodically telemetric
devices send extensive information(what he calls it as extreme instrumentation engineering) to the server. The added value is to monitor systems and give sensible notifications to the end user about the health and status of the machines.
Since each type of the device contains different protocol to send and
receive data, we decided not to go ahead with any vendor specific server. Vendor servers are designed to work only with their devises and they impose many rules to use them. So we planned to design a server that should suffice all kinds of protocols.
What we need to up
the application , our initial solution?
As it is an experimental stuff , we do not want to spend so much of money
but the below are the basic requirements to embark the project execution.
- Required equipment
- Teltonika FM5300 (Purchased)
- Ruptel device (Purchased)
- Two Simcards with data bundle (Thought to use our spare sim cards)
- Static IP address (Took MyStaticIP Subscription 23$ @ month)
- Required software
- Two windows development machines ( Personal Laptops)
- Visual studio as we started writing using C# (Express version)
- SQL Server database (Express version)
- Source control ( Not to use at the moment)
- Windows based server( Looking for free hosting options)
Somehow
spending very limited amount we could arrange all required stuff and start
developing server using Microsoft stack.
Server
development was impressive, tested with device satisfied with the development.
We then started analyzing similar products and market requirements, what we
understood is most of the companies are struggling to scale their servers due
to technology constraints when there is high demand from their clients.
For example
1000 devices are connected and every 10 sec a device has to send data to the
server... 1000 * 3600/10 * 24 = 860000 transactions per day. Actually 1000 devices are very minimal for an
average sized company in the market.
Re-designing the problem statement
from the nonfunctional requirements point of view
- We had a lengthy discussion and decided to considering the below requirements as well
- As more number of devices with more frequency of request-response cycle are configured
- Server resources should be scalable
- Server application can be configured to multiple platforms as the application may be moved to different clouds based on the future financial and technology decisions
- As type of the devices grow, code changes and then binaries change, so agile, easy compilation and easy deployment options to be considered
- Easy to host options to be considered
- Open source and free technologies and tools to be used
- Development should be inclined with evolving cloud frameworks
As our non-functional and deployment requirements changes it directly impact development
technology stack, hence it require redesign as below.
- Required equipment
- Teltonika FM5300 (Purchased)
- Ruptel device (Purchased)
- Two Simcards with data bundle (Thought to use our spare sim cards)
- Static IP address (Took MyStaticIP Subscription 23$ @ month
- Required software
- Installed Ubuntu instead of Windows.
- Go Lang with LiteIDE
- MongoDB with MonghChef
- GIT and made our application as opensource on GITHUB
- Linux Server
We started re-developing the application, using GO Lang and MongoDb as
NOSQL database.
As I am not a usual Linux user , it took me 2 days., to install Ubuntu,
understand Linux commands and directory system.
Configured GO , MongoDb, LiteIDE ,MongoChef ,GIT as very nice installation guides are given.
Configured Go and Mongo environment variables and GIT directorys are
configured according to my desired directory structure , every thing is up and
and development application is running well.
After spending 15 days of time , could develop a very good concurrent
server using Go Lang, it is really fast and tested with 10,000 virtual clients
with the frequence of 5 sec a request (Cannot purchase many devices and
configure)
We made one of our laptop as server and compiled the binaries and
configured the server with Static IP every things works fine
To test server scalability, we created upto 4 Linux containers configured server application , application
is smoot and dam .. good.
Developing &
hosting on cloud
After a little search on Amazon,
Microsoft, Google cloud services decided to go with Www.Koding.Com which is a simple and efficinet ,
free cloud provider for research and expermental projects.
What benefits we get
with Koding.Com?
- A clean Ubuntu terminal with reasonably good resources
- Any package can be installed on the provided VM as sudo permissions are given to you.
- GoLang , GIT are pre-installed so, cloning from GITHUB is very easy. Using Go tools source can be compiled and binaries are extracted with hassle free.
- Could install MongoDB and required tools as easy as I could do on my personal machine
- The biggest benefit we got is, we get a public ip for free so all clients can communicate the the server hosted on Clould free of cost. Only the issue is IP changes for every server reboot. This alone saves us 25$ a month and no need of any additional server required.
- As we move to production, without changing the set-up can upgrade to a commercial package.
What you should know
to use Koding.Com Cloud?
- Should know to use Linux terminal and Linux basic commands (ls,mkdir,mv,rm etc..)
- Should know to configure .bashsr and .profile environment settings on Linux
- Should know to install required packages using apt-get
This is all how we develop an application and trying to move it to
production with limited resources in hand.
Any enthusiastic developers can develop and host applications on cloud
without spending a single penny.
I am very much thankful to the open source community and Koding.Com.



