Thursday, September 12, 2013

I will handle the concurrency for you - from Panini

Hi all I was talking about the concurrency programming in java with my earlier blog post. Those are very simple examples but if you go to real world software development the concurrency handling will be mess for the developers with their business logic. So if some one can handle the concurrency implicitly then it would be grate for the developers then they do not want to consider the concurrent problems rather mainly focus on their business logic.

Think about there is a software development requirement of "manage the memory but not required to do it manually" so then you can use JAVA to do this because you don't want to handle the memory by manually, JAVA will take care of it.

As it is if you have requirement of "handle the concurrent connections but not required to do it by manually" then you can use capsules-oriented programming provided by Panini

lets talk about little bit of Panini program.
Panini is a new programming style designed to address the challenges of concurrent programming. Main goal is to enable non-concurrency experts to write correct and efficient concurrent programs.

How to set up the Panini to your command line
1. Download panini distribution from here then extract to any place in your computer
2. Set the $Panini/bin folder to the path variable in you Windows computer.
3. Then go to command line and check whether Panini is set to the command line by type "panc"
panc
4. Now create the Simple Panini HelloWorld example as follows and save it as paniniHelloWorld.java
[code language="java"]
capsule HelloWorld {
void run(){
System.out.println("Panini: Hello World!");
long time = System.currentTimeMillis();
System.out.println("Time is now: " + time);
}
}
[/code]
5. Compile the Panini program
pancH

6. Run the program
pancH

You can follow the complex examples given by Panini and feel the difference with implicit concurrent behavior then Feel free to make the feed back about Panini :).

No comments:

Post a Comment