Closed pdp2121 closed 10 months ago
I think this code should mostly be reworked into a tool in this repo to build the initial amendment info json files. That is because the datasources used here will likely always be behind test networks and behind when main net activates and amendment which we should catch when it happens so the data will already be there.
setupAmendmentsInfoTable
should pull from json like the other PR does.
I think this code should mostly be reworked into a tool in this repo to build the initial amendment info json files. That is because the datasources used here will likely always be behind test networks and behind when main net activates and amendment which we should catch when it happens so the data will already be there.
setupAmendmentsInfoTable
should pull from json like the other PR does.
This is done only once anyway when we deploy so I don't think it's necessary to write it to json (it's complicated to write to a json file on the server as I mentioned earlier with the paths complication, reading is simple though). I have moved it to happen immediately after setupTables
before connection began to ensure it happens before any connection, and add a log for future debug. Please let me know if that works.
High Level Overview of Change
Add a table to store amendments information:
Amendment’s hash
Amendment’s name
Enabled rippled version
This will also provide more stable source of truth for AmendmentEnabled transaction in Explorer, which hits 2 repos every time it was called.
This information will be accessed via
/network/amendments/info
endpoint.Type of Change