0

How to keep track of your smart contracts without a centralized server? Let’s say I have a dapp that creates smart contracts. Is there a way I can keep track of all the smart contracts my dapp has made without relying on a centralized database to store their addresses?

1

You could have a contract which stores the addresses of each of your deployed contracts. Perhaps with mapping(bytes32 => address) public contract_addresses;

It could have a function exposed for adding new records to that mapping, which you could make a call to in the constructor of each contract. Just remember to make sure the deploying address is authorized.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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