kissjs / node-mongoskin

The wrapper for node-mongodb-native.
MIT License
1.52k stars 164 forks source link

Documentation for god sake! #107

Open fresheneesz opened 11 years ago

fresheneesz commented 11 years ago

I'm trying mongoskin out, and I'm getting a message that tells me to set the default write concern by setting some options. There are a few problems here:

A. The documentation (I'm calling the Readme "the documentation") mentions absolutely nothing about how or where to set the default write concern, nor does it have any mention any of the parameters "w", "journal", or "fsync".

B. The message give the example form new Db(new Server(...), {safe:false}) is clearly out of date or something, since the docs don't use the form "new Db" for anything.

C. Based on the fact that the "safe" parameter was mentioned, and is also actually in the docs explaining mongoskin.db, I tried to investigate the source code to find out where I can set the default write concern. Alas, the commenting in the source code is just as, if not more, confusing. They give links to mongodb's native library for the dbOptions parameter (http://mongodb.github.com/node-mongodb-native/markdown-docs/database.html), but those links also don't mention any of the parameters "w", "journal", or "fsync".

D. The link given in the source as a reference for the replicaset parameter of mongoskin.db is broken!

I'm really trying all avenues here to figure this out, please pay more attention to documentation. I would help if I could figure it out, but its really difficult at the moment.

fresheneesz commented 11 years ago

I submitted this change to the docs, which should hopefully help people who had the same 'wtf' face on that I did https://github.com/kissjs/node-mongoskin/pull/108

basickarl commented 9 years ago

+1 Really irritating that there is no good documentation.

fresheneesz commented 8 years ago

Where the GDF is documentation after FOUR YEARS!? GUYS. This is unacceptable! @guileen @fengmk2 @vkarpov15 @droppedoncaprica @rschmukler @perfaram @wmertens WHERE IS THE DOCUMENATION?

wmertens commented 8 years ago

Welcome to open source development :-)

Writing documentation can be tedious, especially since it is work you mostly do for other people.

I would guess that most people who can't figure out this library instead use mongoose…

On Sat, Nov 7, 2015, 9:01 AM fresheneesz notifications@github.com wrote:

Where the GDF is documentation after TWO YEARS!? GUYS. This is unacceptable! @guileen https://github.com/guileen @fengmk2 https://github.com/fengmk2 @vkarpov15 https://github.com/vkarpov15 @droppedoncaprica https://github.com/droppedoncaprica @rschmukler https://github.com/rschmukler @perfaram https://github.com/perfaram @wmertens https://github.com/wmertens WHERE IS THE DOCUMENATION?

— Reply to this email directly or view it on GitHub https://github.com/kissjs/node-mongoskin/issues/107#issuecomment-154652791 .

Wout. (typed on mobile, excuse terseness)

fresheneesz commented 8 years ago

I spent my time improving the docs in #108 only to have my work and about half of the existing documentation deleted by @guileen https://github.com/kissjs/node-mongoskin/commit/8974492155861e87b62ee5026659b5d40be69424 .

I won't be spending my time sinking energy into this project again.

wmertens commented 8 years ago

Ok that sucks, but to be fair https://github.com/kissjs/node-mongoskin/pull/108/files shows about 15 lines of changes so I can see how a change wipes out half.

On Sat, Nov 7, 2015, 9:02 PM fresheneesz notifications@github.com wrote:

I spent my time improving the docs in #108 https://github.com/kissjs/node-mongoskin/pull/108 only to have my work and about half of the existing documentation deleted by @guileen https://github.com/guileen . I won't be spending my time sinking energy into this project again.

— Reply to this email directly or view it on GitHub https://github.com/kissjs/node-mongoskin/issues/107#issuecomment-154743569 .

Wout. (typed on mobile, excuse terseness)

Albert-IV commented 8 years ago

@fresheneesz I've only put in a change or two in the library personally. I do believe the last time I looked at MongoSkin, it needed work to get up to speed with current MongoDB updates (updated raw drivers, updated docs, readme, etc.)

It's a shame your doc changes were overwritten by that commit. Possibly re-PR the doc changes? Personally I've only used MongoSkin for one-off scripts where reliability isn't that big of a priority.

hustcer commented 8 years ago

+1 We need better documentation.

fresheneesz commented 8 years ago

Even this is better than what exists here: https://docs.omniref.com/js/npm/mongoskin/0.5.0/files/#additional-collection-op

But honestly, since I have had multiple issues where native functionality (that's supposed to be pasesd through) didn't work correctly, I'm just going to switch to straight native. The very few things this library does isn't worth the trouble.

vkarpov15 commented 8 years ago

@fresheneesz see my comments on https://github.com/strongloop/expressjs.com/pull/498#issuecomment-156448858 - in general I'd recommend using the mongodb driver instead of mongoskin, mongoskin was designed to address certain gaps in the mongodb driver's API that have since been fixed.

fresheneesz commented 8 years ago

@vkarpov15 Is that opinion shared by the maintainers of this project? If so, perhaps a deprecation notice on the readme is in order?

Albert-IV commented 8 years ago

There was for a while.

vkarpov15 commented 8 years ago

@droppedoncaprica that's not a deprecation notice.

Re: deprecating, perhaps. In order to formally deprecate I'd like to first get monk off of mongoskin though.

fresheneesz commented 7 years ago

Why would you need to get monk off mongoskin before deprecating? It doesn't affect the utility of the code.