node-casbin / mongoose-adapter

Mongoose adapter for Casbin
https://github.com/casbin/node-casbin
Apache License 2.0
33 stars 32 forks source link

Not supported mongo shard cluster? #77

Closed taitasu555 closed 5 months ago

taitasu555 commented 7 months ago

version

problem

const casbinMongooseAdapter = await MongooseAdapter.newAdapter(
          URL,
          option
        );
const casbin = await newEnforcer(
          model,
          casbinMongooseAdapter
        );

The above code works fine and connects to mongo. but casbin.addPolicy execute and create policy and casbin.getPolicy(). Under usual circumstances, get created data from casbin.getPolicy() but cannot get it. I saw the database and created data inserted. I don`t know why it does not get data even if inserted into the DB.

casbin-bot commented 7 months ago

@nodece @Shivansh-yadav13

hsluoyz commented 5 months ago

@taitasu555 why close?