What is the best way of storing data on EOS blockchain?

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
3
down vote

favorite












I come across a situation where i need to implement a relational database for an application.
Now my question is how to implement it and where should i save the data? also i don't want to save data on RAM as it get very expensive when data size grows.







share|improve this question


























    up vote
    3
    down vote

    favorite












    I come across a situation where i need to implement a relational database for an application.
    Now my question is how to implement it and where should i save the data? also i don't want to save data on RAM as it get very expensive when data size grows.







    share|improve this question
























      up vote
      3
      down vote

      favorite









      up vote
      3
      down vote

      favorite











      I come across a situation where i need to implement a relational database for an application.
      Now my question is how to implement it and where should i save the data? also i don't want to save data on RAM as it get very expensive when data size grows.







      share|improve this question














      I come across a situation where i need to implement a relational database for an application.
      Now my question is how to implement it and where should i save the data? also i don't want to save data on RAM as it get very expensive when data size grows.









      share|improve this question













      share|improve this question




      share|improve this question








      edited Sep 8 at 9:22

























      asked Sep 6 at 7:00









      Abdul Manan

      1557




      1557




















          2 Answers
          2






          active

          oldest

          votes

















          up vote
          2
          down vote



          accepted










          A good way would be to use the demux-js library. It listens for specified actions and allows updating logic for whatever kind of database you like. This is a RAM free option which essentially allows you to achieve CRUD functionality by creating a mirror image of what the blockchain would show if you played through all of your actions.



          Mind the mess, but you can see me implement demux here.






          share|improve this answer




















          • blockchain is decentralized and so the data is just want to confirm by using demux the data will be centralized.is it good for a dapp?
            – Abdul Manan
            Sep 6 at 9:37






          • 1




            Demux provides a mirror of the chain for ease of use. You can still verify on chain.
            – Nat
            Sep 6 at 9:40










          • that's great !! if i setup mongo db at my local server and do save data before every transaction ! is it good practice ?
            – Abdul Manan
            Sep 6 at 11:19


















          up vote
          1
          down vote













          Another option is to use eosio mongodb_plugin for archive blockchain log into mongodb by running a node then apply queries on it.



          https://developers.eos.io/eosio-nodeos/docs/mongo_db_plugin



          @Nat i need your opinion about that option.






          share|improve this answer
















          • 3




            It may be viable, but I think demux is more flexible because you can use almost every db you like.
            – TeeAttack42♦
            Sep 6 at 7:59










          • Yeah, that one of plus point. we want to save data in decentralized database and give data ownership to user. is there any decentralized db who work well in that situation ??
            – Farhan-TroonTechnologies
            Sep 6 at 8:03







          • 1




            To be honest, I haven't touched that plugin. I'm still compiling contracts on 1.07 :). I'll update when the docs do. They're working hard at b1 right now and short handed in that department. I agree with TeeAttack42.
            – Nat
            Sep 6 at 8:16











          • Thank you so much Nat & TeeAttack42 for your quick response. That help us a lot.
            – Farhan-TroonTechnologies
            Sep 6 at 8:28










          Your Answer







          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "696"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          convertImagesToLinks: false,
          noModals: false,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













           

          draft saved


          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2feosio.stackexchange.com%2fquestions%2f2247%2fwhat-is-the-best-way-of-storing-data-on-eos-blockchain%23new-answer', 'question_page');

          );

          Post as a guest






























          2 Answers
          2






          active

          oldest

          votes








          2 Answers
          2






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes








          up vote
          2
          down vote



          accepted










          A good way would be to use the demux-js library. It listens for specified actions and allows updating logic for whatever kind of database you like. This is a RAM free option which essentially allows you to achieve CRUD functionality by creating a mirror image of what the blockchain would show if you played through all of your actions.



          Mind the mess, but you can see me implement demux here.






          share|improve this answer




















          • blockchain is decentralized and so the data is just want to confirm by using demux the data will be centralized.is it good for a dapp?
            – Abdul Manan
            Sep 6 at 9:37






          • 1




            Demux provides a mirror of the chain for ease of use. You can still verify on chain.
            – Nat
            Sep 6 at 9:40










          • that's great !! if i setup mongo db at my local server and do save data before every transaction ! is it good practice ?
            – Abdul Manan
            Sep 6 at 11:19















          up vote
          2
          down vote



          accepted










          A good way would be to use the demux-js library. It listens for specified actions and allows updating logic for whatever kind of database you like. This is a RAM free option which essentially allows you to achieve CRUD functionality by creating a mirror image of what the blockchain would show if you played through all of your actions.



          Mind the mess, but you can see me implement demux here.






          share|improve this answer




















          • blockchain is decentralized and so the data is just want to confirm by using demux the data will be centralized.is it good for a dapp?
            – Abdul Manan
            Sep 6 at 9:37






          • 1




            Demux provides a mirror of the chain for ease of use. You can still verify on chain.
            – Nat
            Sep 6 at 9:40










          • that's great !! if i setup mongo db at my local server and do save data before every transaction ! is it good practice ?
            – Abdul Manan
            Sep 6 at 11:19













          up vote
          2
          down vote



          accepted







          up vote
          2
          down vote



          accepted






          A good way would be to use the demux-js library. It listens for specified actions and allows updating logic for whatever kind of database you like. This is a RAM free option which essentially allows you to achieve CRUD functionality by creating a mirror image of what the blockchain would show if you played through all of your actions.



          Mind the mess, but you can see me implement demux here.






          share|improve this answer












          A good way would be to use the demux-js library. It listens for specified actions and allows updating logic for whatever kind of database you like. This is a RAM free option which essentially allows you to achieve CRUD functionality by creating a mirror image of what the blockchain would show if you played through all of your actions.



          Mind the mess, but you can see me implement demux here.







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Sep 6 at 7:48









          Nat

          1,673114




          1,673114











          • blockchain is decentralized and so the data is just want to confirm by using demux the data will be centralized.is it good for a dapp?
            – Abdul Manan
            Sep 6 at 9:37






          • 1




            Demux provides a mirror of the chain for ease of use. You can still verify on chain.
            – Nat
            Sep 6 at 9:40










          • that's great !! if i setup mongo db at my local server and do save data before every transaction ! is it good practice ?
            – Abdul Manan
            Sep 6 at 11:19

















          • blockchain is decentralized and so the data is just want to confirm by using demux the data will be centralized.is it good for a dapp?
            – Abdul Manan
            Sep 6 at 9:37






          • 1




            Demux provides a mirror of the chain for ease of use. You can still verify on chain.
            – Nat
            Sep 6 at 9:40










          • that's great !! if i setup mongo db at my local server and do save data before every transaction ! is it good practice ?
            – Abdul Manan
            Sep 6 at 11:19
















          blockchain is decentralized and so the data is just want to confirm by using demux the data will be centralized.is it good for a dapp?
          – Abdul Manan
          Sep 6 at 9:37




          blockchain is decentralized and so the data is just want to confirm by using demux the data will be centralized.is it good for a dapp?
          – Abdul Manan
          Sep 6 at 9:37




          1




          1




          Demux provides a mirror of the chain for ease of use. You can still verify on chain.
          – Nat
          Sep 6 at 9:40




          Demux provides a mirror of the chain for ease of use. You can still verify on chain.
          – Nat
          Sep 6 at 9:40












          that's great !! if i setup mongo db at my local server and do save data before every transaction ! is it good practice ?
          – Abdul Manan
          Sep 6 at 11:19





          that's great !! if i setup mongo db at my local server and do save data before every transaction ! is it good practice ?
          – Abdul Manan
          Sep 6 at 11:19











          up vote
          1
          down vote













          Another option is to use eosio mongodb_plugin for archive blockchain log into mongodb by running a node then apply queries on it.



          https://developers.eos.io/eosio-nodeos/docs/mongo_db_plugin



          @Nat i need your opinion about that option.






          share|improve this answer
















          • 3




            It may be viable, but I think demux is more flexible because you can use almost every db you like.
            – TeeAttack42♦
            Sep 6 at 7:59










          • Yeah, that one of plus point. we want to save data in decentralized database and give data ownership to user. is there any decentralized db who work well in that situation ??
            – Farhan-TroonTechnologies
            Sep 6 at 8:03







          • 1




            To be honest, I haven't touched that plugin. I'm still compiling contracts on 1.07 :). I'll update when the docs do. They're working hard at b1 right now and short handed in that department. I agree with TeeAttack42.
            – Nat
            Sep 6 at 8:16











          • Thank you so much Nat & TeeAttack42 for your quick response. That help us a lot.
            – Farhan-TroonTechnologies
            Sep 6 at 8:28














          up vote
          1
          down vote













          Another option is to use eosio mongodb_plugin for archive blockchain log into mongodb by running a node then apply queries on it.



          https://developers.eos.io/eosio-nodeos/docs/mongo_db_plugin



          @Nat i need your opinion about that option.






          share|improve this answer
















          • 3




            It may be viable, but I think demux is more flexible because you can use almost every db you like.
            – TeeAttack42♦
            Sep 6 at 7:59










          • Yeah, that one of plus point. we want to save data in decentralized database and give data ownership to user. is there any decentralized db who work well in that situation ??
            – Farhan-TroonTechnologies
            Sep 6 at 8:03







          • 1




            To be honest, I haven't touched that plugin. I'm still compiling contracts on 1.07 :). I'll update when the docs do. They're working hard at b1 right now and short handed in that department. I agree with TeeAttack42.
            – Nat
            Sep 6 at 8:16











          • Thank you so much Nat & TeeAttack42 for your quick response. That help us a lot.
            – Farhan-TroonTechnologies
            Sep 6 at 8:28












          up vote
          1
          down vote










          up vote
          1
          down vote









          Another option is to use eosio mongodb_plugin for archive blockchain log into mongodb by running a node then apply queries on it.



          https://developers.eos.io/eosio-nodeos/docs/mongo_db_plugin



          @Nat i need your opinion about that option.






          share|improve this answer












          Another option is to use eosio mongodb_plugin for archive blockchain log into mongodb by running a node then apply queries on it.



          https://developers.eos.io/eosio-nodeos/docs/mongo_db_plugin



          @Nat i need your opinion about that option.







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Sep 6 at 7:58









          Farhan-TroonTechnologies

          437




          437







          • 3




            It may be viable, but I think demux is more flexible because you can use almost every db you like.
            – TeeAttack42♦
            Sep 6 at 7:59










          • Yeah, that one of plus point. we want to save data in decentralized database and give data ownership to user. is there any decentralized db who work well in that situation ??
            – Farhan-TroonTechnologies
            Sep 6 at 8:03







          • 1




            To be honest, I haven't touched that plugin. I'm still compiling contracts on 1.07 :). I'll update when the docs do. They're working hard at b1 right now and short handed in that department. I agree with TeeAttack42.
            – Nat
            Sep 6 at 8:16











          • Thank you so much Nat & TeeAttack42 for your quick response. That help us a lot.
            – Farhan-TroonTechnologies
            Sep 6 at 8:28












          • 3




            It may be viable, but I think demux is more flexible because you can use almost every db you like.
            – TeeAttack42♦
            Sep 6 at 7:59










          • Yeah, that one of plus point. we want to save data in decentralized database and give data ownership to user. is there any decentralized db who work well in that situation ??
            – Farhan-TroonTechnologies
            Sep 6 at 8:03







          • 1




            To be honest, I haven't touched that plugin. I'm still compiling contracts on 1.07 :). I'll update when the docs do. They're working hard at b1 right now and short handed in that department. I agree with TeeAttack42.
            – Nat
            Sep 6 at 8:16











          • Thank you so much Nat & TeeAttack42 for your quick response. That help us a lot.
            – Farhan-TroonTechnologies
            Sep 6 at 8:28







          3




          3




          It may be viable, but I think demux is more flexible because you can use almost every db you like.
          – TeeAttack42♦
          Sep 6 at 7:59




          It may be viable, but I think demux is more flexible because you can use almost every db you like.
          – TeeAttack42♦
          Sep 6 at 7:59












          Yeah, that one of plus point. we want to save data in decentralized database and give data ownership to user. is there any decentralized db who work well in that situation ??
          – Farhan-TroonTechnologies
          Sep 6 at 8:03





          Yeah, that one of plus point. we want to save data in decentralized database and give data ownership to user. is there any decentralized db who work well in that situation ??
          – Farhan-TroonTechnologies
          Sep 6 at 8:03





          1




          1




          To be honest, I haven't touched that plugin. I'm still compiling contracts on 1.07 :). I'll update when the docs do. They're working hard at b1 right now and short handed in that department. I agree with TeeAttack42.
          – Nat
          Sep 6 at 8:16





          To be honest, I haven't touched that plugin. I'm still compiling contracts on 1.07 :). I'll update when the docs do. They're working hard at b1 right now and short handed in that department. I agree with TeeAttack42.
          – Nat
          Sep 6 at 8:16













          Thank you so much Nat & TeeAttack42 for your quick response. That help us a lot.
          – Farhan-TroonTechnologies
          Sep 6 at 8:28




          Thank you so much Nat & TeeAttack42 for your quick response. That help us a lot.
          – Farhan-TroonTechnologies
          Sep 6 at 8:28

















           

          draft saved


          draft discarded















































           


          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2feosio.stackexchange.com%2fquestions%2f2247%2fwhat-is-the-best-way-of-storing-data-on-eos-blockchain%23new-answer', 'question_page');

          );

          Post as a guest













































































          Comments

          Popular posts from this blog

          What does second last employer means? [closed]

          Installing NextGIS Connect into QGIS 3?

          One-line joke