4

I need a reliable ACID database with complex transactions. It is a hassle to do this in Java or other high level languages, especially if the database spans multiple systems and networks. For this purpose, I wanted to use the ACID features of smart contracts (if an error then the blockchain is rolled back) to implement my internal app (a one or two node private network).

Does this make sense? Will there be performance issues? I can wait a second or so before the response.

2 Answers 2

4

I can wait a second or so before the response.

This is a crucial requirement, because reading is way slower than with MySQL at al. What you need to do is to

  • set up a private network

  • learn about writing and reading data to/from smart contracts (what is possible, and what's not yet)

  • create a private network
  • make one node mine
  • connect your applications through web3, hook web3 up into nodejs microservices or use https://github.com/ethereum/ethereumj for java.

But be aware, this is not done in a week for Ethereum beginners.

Good Luck !

2
  • In terms of costs, is it a good idea to use ethereum as a DB ? I think It is too costly or not ?
    – Adelin
    Dec 19, 2018 at 9:20
  • If your application still works when writing one bit to the database costs $20, then this technology might be acceptable for you. Mar 9, 2022 at 15:30
0

No, solidity is not ACID compliant. Particularly the isolation1 part of ACID. For example, when running a for-loop that runs transactions or loops through values, if a secondary user runs the program at the same time and executes the same function, the loop will auto-increment to 0 since it's starting over. Solidity in now way should be used as a database and is not ACID compliant, although it is very durable and very consistent, it lacks isolation and atomicity to the fullest extent.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.