MARTIMM / raku-mongodb-driver

MongoDB driver for Raku
Artistic License 2.0
18 stars 8 forks source link

Windows support #28

Open ifrguy opened 6 years ago

ifrguy commented 6 years ago

Is mongo-perl6-driver supported for Windows platforms? So far I have not been able to get a successful return from the Mongo server running on localhost. It appears to connect and locate a collection, but fails to return anything gives the error:

←[1;37;48;2;255;0;0m2017-10-10 14:32:51.673758 [E] 1: No server object for quer y. At site#sources\A9A2F3AEE7E91396B118935B2318B5F8F53E6D6A (MongoDB::Collection ):54 in find()←[0m

Is there a support wiki?

MARTIMM commented 6 years ago

Sorry for the late response, I've been away.

I've not tested the driver explicitly on a windows platform but was going to using the AppVeyor test site.

The error you write about happens at the start of the find method where it tries to get server information from the client object. If you try to tune up the error level to Info before calling Client.new(), you would be able to see if the client has come in a proper state(topology), and found a server to work with. Anything but an unknown state would be ok.

use MongoDB;
modify-send-to( 'screen', :level(MongoDB::MdbLoglevels::Info));

Then somewhere, messages should appear like the following (in this example from a replica server setup)

2017-10-15 19:22:15.270609 [I]  9: Server status of 192.168.0.253:65140 is SS-RSPrimary
2017-10-15 19:22:15.272708 [I]  9: Client topology is TT-Single
2017-10-15 19:22:15.319175 [I] 10: Client topology is TT-Single
2017-10-15 19:22:15.325682 [I] 10: Client topology is TT-ReplicaSetWithPrimary

There are some state changes until it gets stable. It changes again when servers are changing.

Btw, there is a wiki page here but is not yet a big supporting help for every one. I've not yet much info about user experience to write about specific things.

The following doc setup (some of it is there) would eventually crystallize;

ifrguy commented 6 years ago

Marcel;

Thanks for the reply. I will try your suggestion when I have time. I just assumed everything was normal when the Client and collection objects appeared to have the proper information in them.

I was a heavy perl dev previously. But had to switch to Python for support of things like Google API and MongoDB with a need for cross platform support. My current project is developed on Linux, but needs to run on Windows.

I decided to give perl6 a test after listening to the Larry Wall interview a couple of weeks ago and finding the Mongo package.

Thanks, -Marsh

Sent from my iPad

On Oct 15, 2017, at 14:03, Marcel Timmerman notifications@github.com wrote:

Sorry for the late response, I've been away.

I've not tested the driver explicitly on a windows platform but was going to using the AppVeyor test site.

The error you write about happens at the start of the find method where it tries to get server information from the client object. If you try to tune up the error level to Info before calling Client.new(), you would be able to see if the client has come in a proper state(topology), and found a server to work with. Anything but an unknown state would be ok.

use MongoDB; modify-send-to( 'screen', :level(MongoDB::MdbLoglevels::Info)); Then somewhere, messages should appear like the following (in this example from a replica server setup)

2017-10-15 19:22:15.270609 [I] 9: Server status of 192.168.0.253:65140 is SS-RSPrimary 2017-10-15 19:22:15.272708 [I] 9: Client topology is TT-Single 2017-10-15 19:22:15.319175 [I] 10: Client topology is TT-Single 2017-10-15 19:22:15.325682 [I] 10: Client topology is TT-ReplicaSetWithPrimary There are some state changes until it gets stable. It changes again when servers are changing.

Btw, there is a wiki page here but is not yet a big supporting help for every one. I've not yet much info about user experience to write about specific things.

The following doc setup (some of it is there) would eventually crystallize;

The readme with all sorts of links to: Todo and bugs Release changes Mongodb site Pdf files from pod docs in doc dir. Some pod files must be added or modified. Pdf manual, also in doc dir. Not finished. — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.