So I’m able to get an entry that instance A commits and instance B retrieves when running two instances on the same conductor but it doesn’t seem to work for links.
This is my process so far:
Instance A commits an entry and links it to their AGENT_ADDRESS.
Instance A can retrieve this link using their own AGENT_ADDRESS.
Instance B gets back an empty Vec when trying to retrieve the links to Instance A’s AGENT_ADDRESS.
Is this possible or am I trying to do something a bit weird here?
This should be an entirely legitimate use of links. I suspect that something’s off re: propagation of data. Does it work if you wait long enough? If not, I suspect that it’s caused by the way links are validated:
In order to be valid and available, a link metadata must point to a base that exists.
If a link metadata arrives at a validator before the base it’s attached to, the validator keeps it in an intedeterminate state — sort of an “I can’t validate yet; holding this for a while in case the base shows up” state.
This should be fine if B sees A as the authority for their own agent address and asks A for all the links on its own agent address. But if B ends up being an authority, it’ll search its own DHT shard for the links and find none. But still, I’d expect the base to eventually propagate and trigger validation of the link metadata.
@thedavidmeister@wollum I feel like one or both of you were working on out-of-order propagation/validation; do you have any insight into this issue?
only that it sounds right what you’re saying @pauldaoust
we have a shopping list of “nice to haves” around dependant validation logic that also @maackle knows a fair bit about
at the moment the basic case you described should work… if a link comes in that needs a base to validate it should loop until it gets what it needs and try again
This is happening for both agents. In the above error that’s Bob’s hdk::AGENT_ADDRESS that is NOT valid!. I’m not sure what this means though. UnexpectedEof seems like it might be having trouble reading in some data?
Maybe this is worth a github issue?
Can you post your implementation of this callback? My guess would be that the type parameter for the EntryValiationData struct is wrong and that the EOF error comes out of serde.