Chapter 13. Making a Dapp production ready

 

This chapter covers

  • How to generate event logs
  • How to upgrade your libraries after deploying them
  • How to upgrade your contracts after deploying them

In the previous chapter, you built an end-to-end Dapp from scratch for the first time, using most of the knowledge you’d acquired throughout the book and most of the available Ethereum development tools. Although it was a good exercise that helped you to consolidate your Ethereum development skills, you might not be ready to deploy your first Dapp into the public production network. Before doing so, you might want to consider strengthening your Dapp so it can cope with real-world operational requirements, such as being able to generate, store (on the blockchain), and query (from the blockchain) event logs; upgrade your libraries after deploying them; and upgrade your contracts after deploying them.

I’ve already touched on some of these topics briefly, but in this chapter, I’ll revisit them in more detail. I’ll keep my usual pragmatic approach, and I’ll walk you through examples and code. Designing an upgradeable library or contract, though, requires advanced techniques whose implementation touches Solidity syntax that’s outside the scope of this book. But I still believe you should be aware of the concepts, which I’ll try to explain by sketching some contract or sequence diagrams.

13.1. Event logging

13.2. Designing an upgradeable library

13.3. Designing an upgradeable contract

Summary