Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove collection prefix and default mongo URI #1479

Merged

Conversation

drew-gross
Copy link
Contributor

This removes the collection prefix and default mongo URI from DatabaseAdapter.

The DefaultMongoURI is now duplicated across the MongoAdapter and GridStore but those are separate adapters that will eventually be in separate repos, so it makes sense for them to be duplicated.

@flovilmart
Copy link
Contributor

It starts being so beautiful @drew-gross !

return database.adaptiveCollection(className).then(collection => {
return database.adapter.deleteFields(className, [fieldName], [], database.collectionPrefix, collection);
})
return database.adapter.deleteFields(className, [fieldName], [])
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we expose the deleteFields on the dbController just so we don't call adapter here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't really see the point of having a super thin extra dbController layer that just calls into some other function.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just to hide the internals as they are pretty much hidden everywhere else. but that's ok

@flovilmart
Copy link
Contributor

Just one tiny suggestion, let me know if you wanna do it, otherwise I'll merge.

@codecov-io
Copy link

Current coverage is 92.87%

Merging #1479 into master will increase coverage by +0.02% as of 4b700a3

@@            master   #1479   diff @@
======================================
  Files           87      87       
  Stmts         5499    5491     -8
  Branches      1017    1015     -2
  Methods          0       0       
======================================
- Hit           5106    5100     -6
  Partial         10      10       
+ Missed         383     381     -2

Review entire Coverage Diff as of 4b700a3

Powered by Codecov. Updated on successful CI builds.

@flovilmart flovilmart merged commit fc1cdd4 into parse-community:master Apr 13, 2016
@drew-gross drew-gross deleted the remove-collection-prefix branch April 14, 2016 00:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants