[CSHARP-554] Implement CopyDatabase Created: 05/Sep/12 Updated: 20/Mar/14 Resolved: 18/Feb/14 |
|
| Status: | Closed |
| Project: | C# Driver |
| Component/s: | None |
| Affects Version/s: | 1.6 |
| Fix Version/s: | None |
| Type: | New Feature | Priority: | Major - P3 |
| Reporter: | Robert Stam | Assignee: | Unassigned |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Description |
|
Implement MongoServer.CopyDatabase. If there is some reason it can't be implemented then remove it from the API. |
| Comments |
| Comment by Githook User [ 18/Feb/14 ] |
|
Author: {u'username': u'craiggwilson', u'name': u'Craig Wilson', u'email': u'craiggwilson@gmail.com'}Message: |
| Comment by Craig Wilson [ 18/Feb/14 ] |
|
We have decided to not implement this feature and will be deprecating it in the API. CopyDatabase is actually fairly complicated and something that shouldn't be a simple one-liner in the driver. We may introduce a way of handling this differently in the future, but there are no current plans to do so. |
| Comment by Robert Stam [ 06/Mar/13 ] |
|
The debate is whether any admin helper methods should be in the C# driver at all, so if that viewpoint prevails there are many other helper methods that would be removed as well (or at least hidden in some hard to find place). Not sure yet whether I agree with that view, but that's what's being debated. As you know, even if an admin helper method is removed (or was never provided in the first place) you can always use the lower level RunCommand to send any command at all to the server. |
| Comment by Christian Sparre [ 05/Mar/13 ] |
|
At the moment the primary reason for using the driver is automation during deployment. I'm not that familiar with the shell so I have no idea if it would be usefull from an automation point of view I can understand that the CopyDatabase helper might not have a place in the driver as it is just a normal command that can be reached using the RunCommand method. I would not complain too loudly if you choose not to implement it |
| Comment by Robert Stam [ 05/Mar/13 ] |
|
I have changed the Fix Version to 2.0. Be advised that there is some discussion as to whether such a helper method even belongs in a driver at all, so there is a chance that we will just choose not to implement this feature (and remove the method from the driver that is currently throwing a NotImplementedException). If you would like to offer reasons why this method would be appropriate to implement in the driver please comment. Out of curiosity, what is the reason you need to invoke CopyDatabase in the driver instead of using the MongoDB shell? |
| Comment by Christian Sparre [ 05/Mar/13 ] |
|
Any idea when this will make it into the driver? Also the fromHost version should really be included. I'm actually in a situation right now where we need to copy databases from production and staging servers to quality assurance. We have our own implementation right now but would like official driver support for it |
| Comment by Brian Knight [ 08/Jan/13 ] |
|
Submitted Pull Request #146. Did not include a fromHost parameter for now, as I figured we could add an overload in the future. To do that, we'd need a way to handle authentication on the host server of the original database. I added a test to the MongoServerTests. |