Remove collection prefix and default mongo URI (#1479)

* Remove collection prefix from DB Controller

* Remove collection prefix from cache

* Revert "Remove collection prefix from cache"

This reverts commit 529d67dd617b64c69c36a8a63382456e95edcab8.

* Remove knowledge of default mongo URI from Parse Server

* Remove adaptive collection paramater from deleteFields

* Tidy up DBAdapter.js
This commit is contained in:
Drew
2016-04-13 16:45:07 -07:00
committed by Florent Vilmart
parent 3fb3ce1ab7
commit fc1cdd4408
8 changed files with 43 additions and 76 deletions

View File

@@ -7,13 +7,15 @@
*/
import { MongoClient, GridStore, Db} from 'mongodb';
import { FilesAdapter } from './FilesAdapter';
import { FilesAdapter } from './FilesAdapter';
const DefaultMongoURI = 'mongodb://localhost:27017/parse';
export class GridStoreAdapter extends FilesAdapter {
_databaseURI: string;
_connectionPromise: Promise<Db>;
constructor(mongoDatabaseURI: string) {
constructor(mongoDatabaseURI = DefaultMongoURI) {
super();
this._databaseURI = mongoDatabaseURI;
this._connect();