Posts

Showing posts from 2014

Elements of PaaS

PaaS (Platform as a Service) is a layer over IaaS (Infrastructure as a Service) that provides the following:
Some kind of deployement interfacecoupled with a load balancer - HAProxya service provisioning system Scalingin/out supportOptional add-on services: Backup and restore service PatchingCaching or data grid serviceDifferent DB types - relational, in-memory, no-sql 

The above is generally controlled by a service management layer that exposes all of the above operations of PaaS as REST endpoints. The implementation of the endpoints will use IaaS service endpoints to perform infrastructure related operations (like say adding/removing a VM etc).
Generally some devops toolkit like chef (solo)/puppet combined with some bash scripts are used to provision the platform (like say application server or database server) in the VM after the VM has been created.
The tenant user can either use the REST endpoints directly or through some SDK or CLI or through a web UI to request say, …

Understanding Heroku

Based on - https://devcenter.heroku.com/articles/how-heroku-works
Deploy, run and manage Java application on Heroku: Application = source code for application + web or application server framework + dependencies on third party libraries + dependency description (pom.xml) that instructs a build system (maven) to download the needed dependencies from a repository in order to build the application + Procfile.Procfile - lists named commands that you may want executed.
web: java -jar lib/foobar.jar $PORT
queuty: java -jar lib/queue-processor.jar
Defines a 'web' process type and provides a command that needs to be executed in order to run it. Git - used as primary means for deploying applications on Heroku platform. When application is created on Heroku, a new git remote is associated typically named "heroku" with the local git repository for your application. To deploy, simply do a git push heroku master. Thus git acts …

Book Review: The Giver by Lois Lowry

Image
** spoiler alert ** The Giver is a science fiction about a special community which has attained a very peaceful and strictly disciplined lifestyle for its citizens by enforcing rules and cutting them off from any and all randomness of life. Everything is controlled - population, feelings, freedom to choose their own job. It makes one think about what living in such a time will be like where people just don't feel anything wrong in killing (called releasing in the book) because they have never thought about releasing being bad - as it is what they have learned to expect by living in their community. We can compare this kind of feeling with our times and come up with a lot of aspects in our lives that we believe are bad today but were being practiced just a few years ago by some communities. Overall a thought provoking story. I am looking forward to read the other books in this series.

HTML/CSS Basics

Styles within HTML tags:
<p style="font-family: Arial; font-size: 20px; color: blue">A truly spectacular paragraph!</p>

<ol style="background-color: yellow;">
<li style="text-align:left">The Hawthorn Football Club</li>
</ol>

<strong> -- bold
<em> -- to italicize

<table style="border-collapse:collapse;">
<thead>
<tr>
<th colspan="2">test</th>
</tr>
</thead>
<tbody>
<tr>
<td style="padding:5px;border-left:1px solid black;">1</td>
<td style="padding:5px;border-left:1px solid black;">2</td>
</tr>
</tbody>
</table>

Following div will create a 50px X 50px rectangular block of red color:
<div style="width:50px; height:50px; background-color:red"></div>

A very long <span style="color:red;">text</span>!

CSS:
<head>
<link type="text/css&qu…

Python 2 by example

Python 2.7 syntax examples: Code samples at : https://github.com/rwatsh/python 

1.Math: 2**3 = 8 , where, ** is exponent operator +, -, *, / = math operators % = modulo operator 2.Comments: # - single line comment
“”” my multi line comment “”” 3.Print: print(“%.2f”, total) -> will print total rounded to 2 decimal places. 4.Escape char: 'There\'s a snake in my boot!' Not required when using double quotes for string. 5.String: fifth_letter = "MONTY"[4] print fifth_letter => prints Y parrot = "Norwegian Blue" print len(parrot) print parrot.lower() print parrot.upper() pi = 3.14 print str(pi) => str() converts non-strings to string Methods that use dot notation only work with strings. On the other hand,len()andstr()can work on other data types. print "Spam " + "and " + "eggs" print "The value of pi is around " + str(3.14) string_1 = "Camelot" string_2 = "place"
print "Let's not go to %s. 'Tis a silly %s…

WebLogic Administration: WLS Scripting Tool (WLST) Tutorial

Book Review: Pro Git

Image
Very nicely explained and author has a sound understanding of the fundamentals of the Git version control system is evident from his writing. I did not need to buy the dead tree version of the book since the ebook for my kindle was available for free. It delves into the basic topics first so that if you have read the first 4 chapters, then that knowledge will be sufficient to get you to start using git on a day 2 day basis. The remaining chapters can be browsed over and read on an as needed basis. Since the book is available in several formats it is very easy to access it at work on a PC and at home on my kindle. Scott Chacon has done an excellent job explaining Git concepts very clearly and the illustrations in the book are also very well done and aid in the understanding of the text and the subject matter. Highly recommended.

Concise Git Reference for everyday use

This is compilation of all Git commands referring to "Pro Git" book by Scott Chacon. Git config files:/etc/gitconfig - config applicable to all users./.gitconfig - specific to a user.~/.git/config - config per git repo.Typical configs:git config --global user.name "Watsh Rajneesh"git config --global user.email "rwatsh@gmail.com"git config --global color.ui truegit config --global push.default simplegit config alias.last=log -1 HEADgit config -l => shows the current config.git [command]  --helpe.g. git commit --helpCreate a new git repo from existing directory:git initgit add *git commit -m 'my comment'Cloning an existing repo:git clone https://github.com/rwatsh/MyGit.gitwill create a local .git directory which will hold the entire repo with all the history known at the time of cloning.will create a tracking branch "master" which will track the "master" branch on remote (or origin/master - see below point)will save the https:…