Project

General

Profile

« Previous | Next » 

Revision 48042

fixed parameter order

View differences:

modules/dnet-openaireplus-workflows/trunk/src/main/java/eu/dnetlib/msro/openaireplus/workflows/nodes/claims/ApplyClaimUpdatesJobNode.java
43 43
			String contextId = claim.getSource();
44 44
			String rowKey = getFullId(getOpenAIREType(claim.getTargetType()), claim.getTarget());
45 45

  
46
			String value = getValue(contextId, rowKey, claim.getSemantics(), timestamp);
46
			String value = getValue(rowKey, contextId , timestamp);
47 47
			hadoopService.addHBaseColumn(getClusterName(), getTableName(), rowKey, "result", "update_" + System.nanoTime(), value);
48 48
			totalWrites++;
49 49
			incrementProcessed();
......
63 63
		return Arc.DEFAULT_ARC;
64 64
	}
65 65

  
66
	protected String getValue(final String sourceId, final String semantics, final String targetId, final long timestamp) throws MSROException {
67
		log.debug(StringUtils.format("%s -- %s -- %s", sourceId, semantics, targetId));
66
	protected String getValue(final String rowkey, final String contextid, final long timestamp) throws MSROException {
67
		log.debug(StringUtils.format("%s --  %s", rowkey, contextid));
68 68

  
69
		Result.Builder resultBuilder = Result.newBuilder().setMetadata(Result.Metadata.newBuilder().addContext(getContext(sourceId)));
70
		OafEntity.Builder entityBuilder = OafEntity.newBuilder().setId(targetId).setType(Type.result).setResult(resultBuilder);
69
		Result.Builder resultBuilder = Result.newBuilder().setMetadata(Result.Metadata.newBuilder().addContext(getContext(contextid)));
70
		OafEntity.Builder entityBuilder = OafEntity.newBuilder().setId(rowkey).setType(Type.result).setResult(resultBuilder);
71 71
		Oaf.Builder builder = Oaf.newBuilder().setKind(Kind.entity).setLastupdatetimestamp(timestamp).setEntity(entityBuilder);
72 72

  
73 73
		return Base64.encodeBase64String(builder.build().toByteArray());

Also available in: Unified diff