Saving Data Snapshots

A collector content can be saved in and loaded from multiple formats.

  • zipped csv, which is a set of CSV files put into a zip archive. This format is the default one.

  • dbrf, which is a CSV based format

  • xlsx, which is the Excel format.

Only the Excel format can be edited manually.

To save or load a collector, you should call the following functions:

  File snapshot = new File("xxx"); // File format will be deducted from the file extension (.xlsx, .zip, .dbrf, .dbrf.gz).
  coll.saveSnapshot(snapshot);
  coll.loadSnapshot(snapshot);

In Python the zipped csv is the only format supported. One can call the following functions to save or load a collector:

snapshot_file = "xxx"
# When manipulating a collector structure 
coll = load_collector(snapshot_file)
save_collector(coll, snapshot_file)
# When manipulating dataframe structures
dataframe_dict = load_data_frame_dict(snapshot_file)
save_data_frame_dict(dataframe_dict, snapshot_file)
Note:

Note that snapshots are tightly linked with the business data model. They include references to class names and packages.