Casbin = way to authorization
A place for Casbin developers and users
现在注册
已注册用户请  登录
主题样式选择
默认主题样式 ✅
知乎主题样式 
Kingside
Casnode  ›  Casbin

Why not JSON Format for Models and policy

  •  
  •  
    Kingside · 5年前 · 59 次点击 
    这是一个创建于 1926 天前的主题,其中的信息可能已经有所发展或是发生改变。

    This is my 3. topic. I apologice if it is to much. But I have different questions :-) Why do you choose this kind of format for the models and policy? I mean JSON is so much more handy and standard. JSON can be stored in a document Database or with YesSQL. Even SQL Server supports JSON and you can query inside JSON. You can pass JSON to the Client. Its so much easier. Is it about perfomance? To parse JSON is also very fast.

    59 次点击  ∙  0 人收藏  
      Tweet Weibo 忽略主题 
    1 条回复   2021-01-22 00:26:35 +08:00
    hsluoyz
    hsluoyz5年前

    Model is so short, so I think we don't need to discuss it. We already provide several friendly APIs to manipulate the model: https://casbin.org/docs/en/model-storage

    About policy, we have a JSON Adapter: https://casbin.org/docs/en/adapters . You can also write your own adapter.

    image.png

    关于   ·   FAQ   ·   API   ·   我们的愿景   ·   广告投放   ·   感谢   ·   实用小工具   ·   51 人在线   最高记录 52   ·     选择语言  ·     选择编辑器
    创意工作者们的社区
    World is powered by code
    VERSION: c3b0ae8 · 10ms · UTC 14:10 · PVG 22:10 · LAX 07:10 · JFK 10:10
    ♥ Do have faith in what you're doing.