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

publish results over legs #359

Merged
merged 13 commits into from
Feb 9, 2022
Merged

publish results over legs #359

merged 13 commits into from
Feb 9, 2022

Conversation

willscott
Copy link
Collaborator

@willscott willscott commented Jan 4, 2022

  • waiting for go-ds-sql datastore compatibility for use as the datastore behind the legs storage
  • the libp2p host used for legs should have a configurable listening address, so that inbound connections can be received
  • Update use of lotus retrieval API to work with version of lotus that supports context data stores

Relates to #342

* [ ] waiting for [go-ds-sql](ipfs/go-ds-sql#25) datastore compatibility for use as the datastore behind the legs storage
@willscott willscott changed the title [wip] publish results over legs publish results over legs Jan 6, 2022
@willscott willscott marked this pull request as ready for review January 6, 2022 08:28
@willscott willscott requested a review from masih January 6, 2022 08:28
Copy link
Contributor

@hannahhoward hannahhoward left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, but I personally would make the suggested change around setting up legs

@@ -144,6 +148,19 @@ func newStateDBWithNotify(ctx context.Context, dbConn DBConnector, migrator Migr
log.Infow("recovered scheduled tasks", "task_count", count)
}

storeLS := storeLS(st.Store(context.Background()))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

part of me would suggest exposing the datastore here, but having instantiation of libp2p and legs be elsewhere. seems like an odd mixing of concerns to setup a whole network transport stack inside of a database instantiation.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I could be wrong but I don't think I actually see any real common deps other than the priv key?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's a good point. i just don't know where i actually want to make it the legs/libp2p host :)

tasks/retrieval_deal.go Outdated Show resolved Hide resolved
}

b := dbDS("legs_data", st.db())
pub, err := dtsync.NewPublisher(host, b, storeLS, "/dealbot/v1.0.0")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we make the topic configurable?

Side note: should this be Pando topic or is the expectation that Pando producers can also specify topic?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

happy to use a pando topic if there is one

Co-authored-by: Masih H. Derkani <m@derkani.org>
@willscott willscott merged commit ded398a into main Feb 9, 2022
@willscott willscott deleted the legs branch February 9, 2022 19:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants