Sunday, August 23, 2009

The best programing language to start with

There are several leading programing languages(C, C++, C#, .Net, Visual Basic, Java, Ruby, HP, Perl, Python and more) that various programmers from various institutions are interested of writing programs. The choice of a programing language depends upon the requirement. But as a beginner to programing there are some important factors to be considered.

I started with java. It went good but now I believe that it would be better If I could start with C. I would not say that java as the first programing language is totally a bad choice. Its not a bad choice actually. In fact many people recommend it. But I think object orientation is not good design methodology for beginers because java is too far from machine. In other words Java is very high level language. Unless somebody know C or assembler it is difficult to understand what the java interpreter doing.

So I believe that C is the language to start with. Although no one can really suggest you a programing language, starting with C lead to lay a strong foundation to become a better programmer. The choice can be convinced. C has both high-level and low-level features and function-oriented approach. It is simple(somewhat tricky though) to learn and forms the base from which you can jump to any other language. Also C is high speed and versatility language. Not only those, the fact that many of the languages that have been developed during the following decades derive syntax of C. And C is not going to be a dead language as it is still being used widely and the demand for C is also at a higher position around the world. This is not just only my openion. Google for it and try to find the facts behind this in more details.

Thursday, July 30, 2009

P2P Instance Messaging - Dalesa-Sallapa was born at LSF

At LSF I could able to develop a zeroconf Instance Messagin(IM) platform (we named it with the sinhala term "Sallapa" which gives the meaning of "chat"). This attempt was initiated as a requirement by ICTA who funded us. ICTA wanted to give the chatting facility to the peers which runs Dalesa. Therefore since Dalesa is a Peer-To-Peer(P2P) overlay this IM platform also should have been configured according P2P manner. Hence the Sallapa was needed to implement as a zeroconf IM which works in P2P manner. So Sallapa assures the concept of decentralization which we believe and work on at LSF.

Sallapa has designed and developed as a pidgin plugging. One could ask the question why Sallapa was born as a pidgin plugging. We basically did not want to implement all the GUI things that is needed to a IM client. Other reasons are those pidgin is open source and it provides a complete and clear API and docs to its plugging architecture.

Ok now I want to talk about how Sallapa works. Once you install Sallapa It appears as a new IM communication protocol like Yahoo IM, Google Talk in pidgin. Then you can create new pidgin login account to Sallapa. Now if you are running Dalesa on you computer you are getting signed-in to you newly created Sallapa account and list all the other peers in your network who running Dalesa and logged into their Sallapa.

Does Sallapa run on top of Dalesa?
No, not like that actually. Architecturally Sallapa does not run on Dalesa. Dalesa is a P2P overlay which is to run on and hide the IP layer. Sallapa is also running on IP layer. So if someone got to think as Sallapa is running on Dalesa then that is meaningless. But Sallapa and Dalesa has integrated by IPC module which is used to check the status of Dalesa from Sallapa. That is the only link that Dalesa and Sallapa are in.

How Sallapa works Technically?
Sallapa uses MDNS to publish its presence in the network. In linux like environments Sallapa uses Avahi to do this. But in win32 like environments it uses separate MDNS implementation developed for win32.
Once Sallapa published the presence of a peer in the network others peers are callbacked by MDNS-SD(MDNS-Service Discovery) running in them and updated their buddy list accordingly. Now at the moment Sallapa uses Bonjour as the communication protocol to exchange messages.

Wednesday, May 27, 2009

web caching on P2P overlay + mesh networking

Mesh networking has recently become popular in deploying wireless networks.
Similarly with the growth of internet browsing, implementation of a P2P overlay for web caching has identified as a major requirement to reduce the latency of the web content delivery and the network bandwidth. So emerging these two concepts together facilitates to overcome underline issues and deliver advantages to all the stake holders in the phenomena.

Currently we are at LSF developing a set of software components to address the issues mentioned above. The idea is a p2p overlay to cache the web contents. Basically the system consists of two main components(layers) that are the P2P multicasting layer and the caching proxy. These two layers have integrated in a way so that each node in the p2p overlay cache the possible web content it brows. Later when some other node requests for a particular url, which has already been visited from a node in the group previously, is then served from the cache instead of going to the actual location of the resource. This obviously cut off the latency and the bandwidth. We basically have developed this to run on top of a mesh network which contains less number of peer nodes(not hundreds of) runing on both UNIX and Win distributions.

Tuesday, April 28, 2009