Skip to content
This repository was archived by the owner on Apr 6, 2019. It is now read-only.
This repository was archived by the owner on Apr 6, 2019. It is now read-only.

Sample client deadlocks using vcpkg and Visual Studio 2017 #184

Open

Description

@unclevlad

We've heard nothing but good things about this library, so when we needed a Windows client for redis and saw this was supported by vcpkg, we jumped at the chance to use it.

And we were stopped dead in our tracks at the proof-of-concept phase. As every single example that actually tries to communicate with redis deadlocks. (The logger example works just fine,)

Steps to reproduce minimal example:

  1. Install cpp_redis in vcpkg
  2. Create brand new solution in VS 2017 - Windows console application - Debug - 64bit
  3. Gut all the precompiled header stuff
  4. Cut and paste https://github.com/Cylix/cpp_redis/blob/master/examples/cpp_redis_client.cpp
  5. Build and run
  6. Watch the deadlock in tacopie::io_service::thread_pool::stop( ) line 85

Activity

  1. unclevlad commented on Jun 24, 2018

    @unclevlad
    Author

    We have tried:

    Increasing the number of workers via cpp_redis::network::set_default_nb_workers - No impact

    Call client.disconnect( false ) - Throws an exception "Microsoft C++ exception: tacopie::tacopie_error at memory location 0x007FF318."

    Call client.disconnect( true ) - Changes location of hang to tacopie::io_service::wait_for_removal line 348

  2. unclevlad commented on Jun 24, 2018

    @unclevlad
    Author

    During more testing and debugging, we encountered several sparadic, but inconsistent, instances of

    f:\dd\vctools\crt\crtw32\stdcpp\thr\mutex.c(51): mutex destroyed while busy

    which is mentioned in at least one other open issue.

  3. unclevlad commented on Jun 25, 2018

    @unclevlad
    Author

    This appears to be an issue with the version deployed via vcpkg. I cloned the current repository, built it, and the examples work.

  4. Cylix commented on Jun 27, 2018

    @Cylix
    Owner

    Hi,

    Sorry for the delayed response.
    This library does not officially support the vcpkg package, so I am not sure how cpp_redis is available on it, and thus which version is packaged.

    I will keep the issue opened though: seems this is not the first time someone request cpp_redis to be available on vcpkg, so better officially support it than leaving a malfunctioned unofficial package out there.

    Best

  5. unclevlad commented on Jun 27, 2018

    @unclevlad
    Author
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions