The database will only store the “/changes” associated with the DICOM resources (patients, studies, series, instances) that are still present in Orthanc.
Once resources get deleted, their associated “/changes” entries are removed from the database. This prevents the database from growing indefinitely: At any time, the size of “/changes” cannot be bigger than the number of stored resources.