What is a Pastebin?
A pastebin or text storage site[1][2][3] is a type of online content hosting service where users can store plain text, e.g. to source code snippets for code review via Internet Relay Chat (IRC). The first pastebin was the eponymous pastebin.com. Other sites with the same functionality have appeared, and several open-source pastebin scripts are available. Pastebins may allow commenting where readers can post feedback directly on the page. GitHub Gists are a type of pastebin with version control. - see related wikipedia page
A decentralized pastebin appliacation on STEEM
Is it possible? First thoughts:
- Storing unrelated, out of context data as steem posts are inefficient.
- You cannot post more than once in 5 minutes.
- Most of the data you push to Pastebin websites are not worth rewarding.
Steemit, Busy shouldn't show that information to your followers. So, what to do?
custom_json
STEEM blockchain allows any type of JSON data into blockchain with a custom_json operation. See this post for an example.
A simple data structure with custom_json to store text data:
{
required_auths: [],
required_posting_auths: [<account>],
id: "paste",
json: [
<add>,
{
title: "title of the paste",
body: "the text"
tags: ["a", "b", "c"]
}
]
}
This would do the job. Plus, no garbage content on interfaces like Steemit or Busy. A simple form with these inputs -on a web page- can broadcast this into blockchain.
However, how can we browse them?
indexer (backend)
Our custom operation is not a part of blockchain consensus, we need an indexer.
A background process should listen to all custom_json operations signed with the paste id and store them in a separate database. (MongoDB?)
Then we can query any item by accounts, tags, or search text with the title.
Eg: "Fetch the entries including 'python'". A simple REST HTTP API can expose MongoDB queries.
api/v1/latest
Return latest entries.
api/v1//bin
Return entries related to account.
api/v1/search/title/<text>
Search entries including <text> on title field.
api/v1/search/tag/<tag>
Search entries having <tag> on tags field.
I will probably implement a simple decentralized Pastebin app with that design, in my free time. Thoughts?
Excellent idea, you have my witness vote.
I would love to see this work!
Keep steeming Buddy you got my witness upvote 😇
Thank you! :)
Pastebin.steem.rocks?
That would be fun
Id:"Pastebin" would be better
Oh no...this couldn't go wrong at all... /sarcasm
what could go wrong? :)
I honestly don't know. I only have an impending sense of dread of what someone might post from a syslog or something...which will forever be on the blockchain.
haha, yeah I know what you mean. Sensitive data shouldn't be posted in a service like that :)
🙋🙋🙋
please, dont comment on the posts you did not understand.
Meraba. Nasilsin?
Bir ricada bulunacakdim. Destek olarak sbd gondere bilirmisin lutfen. Bu gun yarin buyuyunce sana 3 katini gonderecegine soz veriyom. 1 veya az olur. Sevinirim. Tesekkurler . Iyi gunler.
Hey @emrebeyler , great post! I enjoyed your content. Keep up the good work! It's always nice to see good content here on Steemit! Cheers :)
.
Not sure about the transaction size limits and I don't think it's normal to break it with the normal text bin data. :)
I'm not familiar with pastebin.com, I'm not sure if it supports editing or versioning. This could be a trick to solve in blockchain.
As an alternative idea for storing (since you don't need to sort as trending/hot or else) one of sam's solutions which he used for @finallycomments. These can be stored under a main post as comments without needing any extra server costs.
Another concern is privacy, these can't be shared to specific people. (unless you find a solution for it:D)
There is no privacy - Everything is transparent :D
I really like this idea. I currently use https://hackmd.io/ sometimes. I like that files can be stored and reloaded there. I use pastebin sometimes, it's very handy for a variety of code. Although I wish I could have private links. Maybe I haven't quite figured it out yet.
Frontend: have you seen https://www.parley.io They do something to only show content from their tag I think. Doesn't go both ways though.