musicoin / hurricane Goto Github PK
View Code? Open in Web Editor NEWExperiments to utilize Web Monetization protocol upon Musicoin blockchain and workflow.
License: MIT License
Experiments to utilize Web Monetization protocol upon Musicoin blockchain and workflow.
License: MIT License
For the conversion itself we have created a webpage that connects to metamask and allows the user to send musicoin to a specific address so we can then send the right ratio of the tokens back to that same address in metamask.
Because of double spending we have to make sure we can verify the transaction is confirmed on the blockchain so we can then make sure it is done only once in case someone tries to do it multiple times.
I still think the best way to do it is to save the transaction to the db and make some kind of queue where we can then poll every x amount of time to see if the transaction has been confirmed by the blockchain (since it could take a few days even with the old chain) and when it is confirmed we can send the tokens from the backend, this could also double as a log in case there are some issues so I wouldn't delete the records but just put their status as "migrated" or something.
the only piece of the puzzle I need to know is how we can check the queue every hour or a few times a day or something
so I think it's best I just keep the musicoin transaction in hurricane and put all the rest in our existing backend, or we could do it with a separate app and db too but then we would have to set that up ofcourse.
First I was thinking of creating a node app to just subscribe to blockchain events, for example listen to transactions sent to a specific address. But if the app is down for some reason some events may be missed so that's why I think it's better to use the db approach here.
what do you think @immartian ?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.