I solved the problem. I was mixing edge requests with immediate changes to
the graph. I'm now only using Vertex.addEdgeRequest() and
Vertex.addVertexRequest() and the modifications are being performed without
errors. Previously, I was calling Vertex.addEdgeRequest() and
Vertex.setEdges() in the same Vertex.compute() call, which was causing the
changes to be performed in two different super steps. I'm guessing that was
the problem.

Larry


On Tue, Dec 31, 2013 at 4:27 AM, Pushparaj Motamari
<pushpara...@gmail.com>wrote:

> By the time vertex.compute() on vertex A did adding A-> and A->C
> other worker incharge of vertex B also could have executed vertex.compute
> on B leading to formation of B->C. Now if you try to add B->C from A, it
> might be giving error.
>
>
> On Tue, Dec 31, 2013 at 3:37 AM, Larry Compton <lawrence.comp...@gmail.com
> > wrote:
>
>> All of what I described previously is happening in the Vertex.compute()
>> method for vertex A. It needs to...
>>
>>    - Add edges A->B and A->C to its own adjacency list - I have this
>>    working
>>    - Add edge B->C to B's adjacency list - this is failing stating that
>>    "Already has missing vertex on this worker for B"
>>
>> The Vertex.addEdgeRequest() method looks like the right call to be
>> making, but it's failing.
>>
>> Larry
>>
>>
>>
>> On Mon, Dec 30, 2013 at 4:51 PM, Ameya Vilankar <ameya.vilan...@gmail.com
>> > wrote:
>>
>>> I don't get what you are trying to solve here. If vertex A already has
>>> edges to B and C, what edges are your trying to add? Could you explain in
>>> detail what you are trying to do?
>>>
>>> You can call vertex.getEdges() to get an iterable list of edges where
>>> you know the the value on the edge and the vertex id of the vertex to which
>>> the edge connects.
>>>
>>>
>>>
>>>
>>> On Mon, Dec 30, 2013 at 4:29 PM, Larry Compton <
>>> lawrence.comp...@gmail.com> wrote:
>>>
>>>> Giraph 1.0.0 - Hadoop 0.20.2 (CDH3U5)
>>>>
>>>> The Giraph algorithm I'm developing dynamically retrieves adjacent
>>>> vertices from within the Vertex.compute() method. The retrieval returns
>>>> immediate neighbors and also relationships between the neighbors. For
>>>> instance, for vertex A, the following edges could be retrieved...
>>>> A->B
>>>> A->C
>>>> B->C
>>>>
>>>> I'm trying to use the Vertex API to dynamically add vertices B and C
>>>> and all three edges. I've managed to successfully add B and C, along with
>>>> edges A->B and A->C (using Vertex.setEdges()). However, I'm having problems
>>>> adding B->C using Vertex.addEdgeRequest(). It's saying...
>>>>
>>>> Already has missing vertex on this worker for B
>>>>
>>>> ...presumably because the addition of B to A's adjacency list also
>>>> causes the vertex for B to be created.
>>>>
>>>> What's the proper way to update the graph?
>>>>
>>>> Larry
>>>>
>>>
>>>
>>
>

Reply via email to