Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

retrieval hangs when using IpfsOnlineMode=true #5361

Open
jsign opened this issue Jan 15, 2021 · 1 comment · Fixed by #5492
Open

retrieval hangs when using IpfsOnlineMode=true #5361

jsign opened this issue Jan 15, 2021 · 1 comment · Fixed by #5492
Assignees
Labels
team/ignite Issues and PRs being tracked by Team Ignite at Protocol Labs

Comments

@jsign
Copy link
Contributor

jsign commented Jan 15, 2021

In the context of using Lotus with a go-ipfs node as the underlying blockstore, I've faced what seems to be a bug.
When running with the default [Client] IpfsOnlineMode = false, retrievals works fine, but with true they hang.

If I run with "online"=true, the retrieval hangs with the last retrieval-event being:
retrieval event {"name": "ClientEventLastPaymentRequested", "deal ID": "0", "state": "DealStatusFundsNeededLastPayment", "message": ""}
After that, it simply hangs.
(BTW, that "deal ID": 0 might be another thing to fix, it also prints that on successful retrievals. It isn't the correct Deal ID.)

I came up with a simple way to let anyone reproduce this.

Preparation:

  • git clone https://github.com/jsign/lotus && cd lotus && git checkout jsign/onlinefailretrieval && make deps
    (it's based on Lotus master)

Test-flow:

  1. docker run -p 5001:5001 --rm --name ipfs ipfs/go-ipfs:v0.7.0
  2. go test ./node -race -v -run=TestAPIDealFlow/TestFastRetrievalDealFlow -count 1
  3. Wait for the result (PASS or hangs (more on this below)
  4. After that, Ctrl+C the docker run ... window, as to clean up things.
    The cloned branch will test a setup with onlineMode := true, so you should see the test hanging.

To check that running in onlineMode := false pass the test, simply change the onlineMode := value in line 406 node/test/builder.go. Nothing else needs to be changed. Then just do Test-Flow steps again.

This is a somewhat modified existing test. It has minimal changes to create this scenario, and reproduce the problem. Obviously, doing git diff with Louts master can show changes.

@dineshshenoy dineshshenoy added this to the 💹Storage Deal Success milestone Jan 18, 2021
@magik6k magik6k assigned magik6k and unassigned dirkmc Feb 1, 2021
@magik6k magik6k reopened this Feb 9, 2021
@raulk raulk added the team/ignite Issues and PRs being tracked by Team Ignite at Protocol Labs label Feb 23, 2021
@jsign
Copy link
Contributor Author

jsign commented Mar 22, 2021

For our purposes, this problem isn't a high priority anymore since we worked around relying on IpfsOnlineMode=true.

@jennijuju jennijuju removed this from the 🤝 Deal Success milestone Mar 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
team/ignite Issues and PRs being tracked by Team Ignite at Protocol Labs
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants