Posts

Messaging for the Internet of Things

Messaging for the Internet of Things   As we embed processing power to a lot of our everyday things. The thing will need to communicate with a server to send data or get data . The thing needs data in order to make something happen. The thing needs to send data so that we can be smarter on how we use the thing. But How do we send data to a central server that is robust, asynchronous and reliable ? MQ, what is old is new Again  MQ or Message Qeueing is new again in the age of the Internet of Things. Messaging Patterns for the enterprise has been around for ages. What were the major reasons that messaging addresses ? 1. Networks are unreliable - data needs to be transported over the network. These networks are a conglemeration of different types of network. Since we do not have control of over most of the network that we use to access the internet. The network will present a lot of problem specially when you are sending messages across the internet. 2. Networks are slow - The

OAuth 1.0a Request Signing and Verification - HMAC-SHA1 - HMAC-SHA256

Image
This is a security project that I did this Fall semester. I was interested in why the OAuth1.0a specification did not require you to sign a request using RSA-SHA1 or any RSA algorithm. The first issue that I found is where would you store your private keys in a javascript client? - as a javascript encrypted file ? from the browser ?  - that will be a security hole if you allow javascript to get private keys. These are some of the questions that got me asking and which I cannot find answers to for now. OAuth 1.0a Signature Signing and Verification using JavaScript Implementation Background The OAuth specification tries to define an API authentication method that allows consumer websites or applications to access protected API Resources from a Service provider. The advantage that OAuth provides is that the user of the website or application is not required to disclose their credentials to their service provider. Another advantage of using OAuth to authenticate is that it does not

10 years of AJAX - Now much cleaner and standardized !

Image
A decade of Ajax About 10 years ago the Ajax word was coined to describe the interactive  web that Google created at that time Google Suggest and Google Maps  ( Ajax - Jesse James )  . At the heart of that emerging technology is a Microsoft created object XHR(XMLHttpRequest - XMLHttpRequest ) and is now adopted by Mozilla, Apple, and Google (IE is a different Web technology story). XHR is now being adopted as a standard in W3C ( standardized XHR - W3C ). But not only that there is XHR2 ( HTML5 Rocks )  - (I think this has been discontinued.) XHR provides an easy way to retrieve data without doing a page refresh. Despite its name we are using XHR for any structured data that the server can provide us. (JSON, JSON-LD) - and binary data ( SPDY HTTP 2.0 ) We have used AJAX in a lot of creative  (SPA, Web API, MashUps) ways and I am excited to see the next decade of highly interactive web designs. The Future What would the role of AJAX be in the internet of things ? M

Javascript Prototype Gets in the Way!

Image
I have been re-reading  eloquent javascript  because I am taking up a class this summer that greatly deals with javascript. This book really helped me a lot transitioning from programming solely in Java to understanding some of the practical details of using javascript. The Prototype One of the sections in the book that i found really helpful was the explanation of how prototypes work. Prototype Interference in this section of the book ( Secret life of Objects ). If you are beginning javascript, how the prototype works in javascript is one of the fundamental concepts that you must grasp. There are probably several prototypes in javascript but the three prototypes that you might want to know about are Object.prototype Array.prototype Function.prototype There are a lot of things in each prototype above and I will not discuss each in detail. Ultimately, prototypes are the object that is used as a fallback if the property or method is not on the current object you are refe

Private final - some things you can't change!

Image
Access ! Access ! For as long as I can remember writing programs in Java. I have used the access modifiers to control access to members of my classes. It is one of the topics in the Certification test in java (SCJP, OCJP). The table below taken from the Oracle Java Tutorials summarizes how each access modifier can restrict or expose a member of your class. Java Access Control Access Levels Modifier Class Package Subclass World public Y Y Y Y protected Y Y Y N no modifier Y Y N N private Y N N N Don't worry it is a private final variable! I can't change its value because it is private final member of the class. Well that is not really true. There is an API for that  Java Reflection . The Java Reflection API will allow you to examine and modify runtime behavior of applications in the JVM. "Reflection is powerful, but should not be used indiscriminately". In relation to the access modifiers mentioned above you can disregard it all and do as you please.

Big Ball of Mud - Revisited!

Big Ball of Mud (more likely Great Balls of Fire that will burn you down!) I am being mentored by Arun Batchu  this semester looking into the exciting world of software architecture and as a self study we should look into this  Big ball of Mud . I have read the page before and was also mentioned to me recently by my peer as we were discussing software architecture, Conway's Law , microservices architecture . The Big ball of mud page (1999) existed before the Agile Manifesto (2001) was conceived. This means that the observation that the authors wrote were noted before most of the agile processes ever existed but I somehow still observe the same kind of things (now more prevalent) in an agile world. Well I guess the forces that they have observed still applies to the software projects of the agile world. How would we consciously prevent ourselves from creating Big balls of mud ? I think that there is no clear answer to that because any software project will be constrained by

Agile Software Development - The Wonder (Teen) years!

What stage is Agile Process of Software Development in its life?  The Agile Manifesto was created around 2001, so Agile development processes is now entering its teen years. During this year there is probably a lot of dilemma that software developers encounter with this method of software development. Like a teenager that succumb to peer pressure, Agile software methodologies becomes popular based on the most influential advocates of that process. But by now most software developers ,who tried most of the agile software methodologies, already know what works based on the successes it brought to our practice. Knowing what works means that we also know what doesn't work. Here is the dilemma, there is no one size fits all solution for agility because that is the whole point of agility. You need to react to factors of the current situation to best decide what is going to work.  If I understand Agile development, we start building before the outcome is fully understood. Adjust o