@ GetMapping ( value = "/v1/dbs" ) @ ResponseBody public List < String > dbs ( ) { logger . info ( "Gettting list of DBs" ) ; final List < String > list = new ArrayList <> ( ) ; for ( final RootDocument mongo : repositoryManager . getRootDocumentRepository ( ) . findAll ( ) ) { list . add ( mongo . getDbName ( ) ) ; } logger . info ( "length: " + list . size ( ) ) ; return list ; }
Controller to get the currently loaded data sets .