giraph-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paolo Castagna <castagna.li...@gmail.com>
Subject Re: Why TextVertexReaderFromEachLine and TextVertexReader are protected?
Date Tue, 25 Sep 2012 21:55:47 GMT
On 25 September 2012 22:42, Paolo Castagna <castagna.lists@gmail.com> wrote:
> I am still trying to find out what could have possibly gone wrong...

Ok, I found it, but I do not understand.

Here is what happened...

public class PageRankVertex extends EdgeListVertex<Text,
DoubleWritable, NullWritable, DoubleWritable> {

        [...]
	
	@Override
	public void compute(Iterable<DoubleWritable> msgIterator) {

		if ( getConf() != null ) {
			numIterations = getConf().getInt("giraph.pagerank.iterations",
DEFAULT_NUM_ITERATIONS);
			tolerance = getConf().getFloat("giraph.pagerank.tolerance",
DEFAULT_TOLERANCE);
		} else {
			log.warn("{}#{} compute() getConf() is null!", getId(), getSuperstep());
		}

I used to call getConf() from within a compute(...) method (and it wasn't null).

I made a stupid mistake, here is the fix:
https://github.com/castagna/jena-grande/commit/aad1fc23d72a09b1d34d444171c34f5dd1057bca

However, I do not understand why getConf(...) is now returning null.
(I am running via InternalVertexRunner).

Cheers,
Paolo

Mime
View raw message