Author Topic: How to delete deprecated app configuration data?  (Read 288 times)

akirot

  • Full Member
  • **
  • Posts: 235
How to delete deprecated app configuration data?
« on: March 10, 2022, 05:57:59 PM »
This might have been asked and answered before but I can't find the respective thread.
App configuration settings are stored via the v1/data endpoint.
In the course of time various (self written, long deprecated) apps might have left their traces there.
Documentation of the once used data structure is not longer available.
Currently I'm cleaning up my IMatch database.
How can this old data be deleted?
Even brute force (deletion of all! self defined [app configuration] data) will do.
Every hint is welcome :-)

Mario

  • IMatch Developer
  • Administrator
  • *****
  • Posts: 31554
Re: How to delete deprecated app configuration data?
« Reply #1 on: March 10, 2022, 06:19:36 PM »
v1/data/list to list all data, then DELETE requests for the data you want to delete?
Note: Make sure not to delete data of other apps, this might break many things.

akirot

  • Full Member
  • **
  • Posts: 235
Re: How to delete deprecated app configuration data?
« Reply #2 on: March 11, 2022, 07:06:59 AM »
Will do - nevertheless I have a gut feeling this already has been addressed/scripted and I just don't want to reinvent the wheel :-)

Mario

  • IMatch Developer
  • Administrator
  • *****
  • Posts: 31554
Re: How to delete deprecated app configuration data?
« Reply #3 on: March 11, 2022, 08:42:53 AM »
Why should this have been scripted?

Each app maintains its own set of configuration data and is responsible for maintenance, migration and deletion.
Apps usually know what they store and when they don't stuff no more and can delete it.

Stuff stored by distinct apps does not cause any issues. IMatch just ignores it and the data volume is usually negligible.