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

Send individual nodes to daemon #133

Closed
ehmry opened this issue Sep 28, 2014 · 10 comments
Closed

Send individual nodes to daemon #133

ehmry opened this issue Sep 28, 2014 · 10 comments

Comments

@ehmry
Copy link
Contributor

ehmry commented Sep 28, 2014

I wanted to be able to send data to a daemon in a way that does not require the daemon have access to the data on local disk, so I added a command to core for adding a block over RPC.

https://github.com/ehmry/go-ipfs/compare/add_node

There are a few reasons I wanted this,

  • I would prefer my daemon run in restricted virtual filesystem space.
  • I might be pushing data from a mobile machine to a more stationary seed node.
  • I might be encrypting data in my application before publishing.

I've got a utilty that pushes nodes to a daemon, and another utilty for pulling them from a daemon.
So far I've only tested them by piping music in and out of them.

This is just rough draft of what I want, and a RFC.

On a side note, perhaps the RPC interface would be best wrapped in a more traditional manner so that success reponses can be differentiated from errors?

There is of course http://golang.org/pkg/net/rpc/jsonrpc/, though I'm not sure if its too Go centric to reimplent clients in something like javascript.

@ehmry ehmry changed the title Send individual nodes daemon Send individual nodes to daemon Sep 28, 2014
@whyrusleeping
Copy link
Member

this could be pretty easily implemented as a flag to ipfs add, i.e.

echo "mydata" | ipfs add -i

where the 'i' flag could specify to read from 'stdin' and stream the block over.

@whyrusleeping
Copy link
Member

Or even:

ipfs add --remote myfile.txt

could read in and send blocks as opposed to just sending the filename over

@ehmry
Copy link
Contributor Author

ehmry commented Sep 28, 2014

For whatever reason on this branch 'ipfsadd' and 'ipfscat' can add and cat from a single machine, but the blocks don't propagate between peers. Whatever, its a proof-of-concept.

@jbenet
Copy link
Member

jbenet commented Sep 28, 2014

good call, we'll need the API to allow adding blocks. Will be useful for #132 as well.

@llSourcell
Copy link
Contributor

@whyrusleeping
Copy link
Member

@llSourcell but allowing the user to choose is better than either on its own.

@ehmry
Copy link
Contributor Author

ehmry commented Sep 29, 2014

I like the idea of perhaps a protobuf API on a plain socket and an JSON HTTP API.

@llSourcell
Copy link
Contributor

@whyrusleeping true. @ehmry that would some ideal

@jbenet
Copy link
Member

jbenet commented Sep 30, 2014

Please see #132 for API considerations. the APIs should allow format choice in both cases. (yes, also protobufs over http, and json over raw tcp)

@ehmry
Copy link
Contributor Author

ehmry commented Oct 16, 2014

Superceded by #132

@ehmry ehmry closed this as completed Oct 16, 2014
@aschmahmann aschmahmann mentioned this issue Feb 18, 2021
73 tasks
ariescodescream pushed a commit to ariescodescream/go-ipfs that referenced this issue Oct 23, 2021
docs: remove mentions of coral, it's not implemented
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

No branches or pull requests

4 participants