Hey,

yeah it has been a long time ;) For me, everything is fine, and how are you?
I totally understand your problems, for this purpose I have contributed the
LocalBSPRunner.
When I am developing a BSP, I am trying to get my algorithm running with
the LocalBSPRunner first, and then make it running on a cluster.

The whole start is really easy with it:
Get your favourite IDE (I use eclipse), start a new project, put the hama
(or hama-core) jar into your classpath.
Then create a class and extend from org.apache.hama.bsp.BSP class.
Now you can add a main method which will run a new job. You can use the
following snippet:

 public static void main(String[] args) throws IOException,
>         ClassNotFoundException, InterruptedException {
>
>     HamaConfiguration conf = new HamaConfiguration();
>     BSPJob job = new BSPJob(conf, YOUR_BSP_CLASS.class);
>     job.setJobName("YOUR NAME");
>     job.setNumBspTask(4);
>     job.setJarByClass(YOUR_BSP_CLASS.class);
>     job.setBspClass(YOUR_BSP_CLASS.class);
>     job.waitForCompletion(true);
>

Normally, this should run the LocalBSPRunner and execute your BSP with 4
threads. (configured by setNumBspTask).
Now you can debug it very easily until you're confident with it and submit
it to a real cluster.

You can checkout the latest trunk, besides one nifty bug in distributed
environment (HAMA-486 <https://issues.apache.org/jira/browse/HAMA-486>) you
can use the LocalBSPRunner very well.
I am currently developing a k-means clustering with it. [1]

This is how I do it, some others like LOG debugging and developing right on
a real cluster, but this has too high latency for me.

Hope it helps you ;)

PS: should we rename this mailing list to "
[email protected]"?:P

[1]
https://github.com/thomasjungblut/thomasjungblut-common/blob/master/src/de/jungblut/clustering/KMeansBSP.java

2011/12/8 changguanghui <[email protected]>

> Hi, Thomas:
>
>
>
> Long time no see. How's everything?
>
> I'm back from other business by now ,so I can care HAMA again :-) When I
> want to develop a small program on the platform, I find it is not easy for
> me.
>
> How can I use HAMA to develop a simple instance by myself, and how can I
> execute it smoothly. could you show me some knacks ?
>
> Thank you very much.
>
>
>
> Have a good day!
>
>
>
> Chang
>
>


-- 
Thomas Jungblut
Berlin <[email protected]>

Reply via email to