hama-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Aditya Sarawgi <sarawgi.adi...@gmail.com>
Subject Hama receive queue
Date Wed, 16 May 2012 22:48:30 GMT
Hi Guys,

I am wondering how do the receive queues in hama work. Consider this case
that I want to sent a different type of BSPMessage in 2 consecutive
superstep.
In this first superstep I am sending IntMessage and in the next one I am
sending a ArrayMessage ( custom message class).

Now in the second super step when I do a
 while ((arrayMessage = (ArrayMessage) peer.getCurrentMessage()) != null) {

it is throwing a java.lang.ClassCastException, which is obvious since its
trying to cast IntMessage to ArrayMessage.
I thought the message is dropped from the queue after it is read, is this
not the case ?
And if it is not, how can this be handled elegantly ?

-- 
Cheers,
Aditya Sarawgi

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message