2 # ---------------------------------------------------------------------
3 # Generic databse object dumper.
4 # ./object_dumper.pl <bootstrap_config> <type>, <type>, ...
5 # ./object_dumper.pl /openils/conf/opensrf_core.xml permission.grp_tree
6 # ---------------------------------------------------------------------
10 use OpenSRF::Utils::JSON;
12 use OpenILS::Utils::Fieldmapper;
13 use OpenSRF::Utils::SettingsClient;
15 my $config = shift || die "bootstrap config required\n";
17 OpenSRF::System->bootstrap_client( config_file => $config );
20 require OpenILS::Utils::CStoreEditor;
21 my $e = OpenILS::Utils::CStoreEditor->new;
25 my $m = "retrieve_all_$t";
27 print OpenSRF::Utils::JSON->perl2JSON($_) . "\n" for @$d;