Casbin

Casbin

  • Documents
  • API
  • Editeur
  • Plugins IDE
  • Authentification unique (SSO)
  • Forums
  • Aide
  • Blogue
  • Pricing
  • Contact Sales
  • Languages iconFrançais
    • English
    • 中文
    • 한국어
    • Русский
    • Deutsch
    • 日本語
    • Aider à traduire
  • GitHub

›Extensions

Les Bases

  • Aperçu
  • Commencer
  • Comment ça marche
  • Tutoriels

Modélisation

  • Modèles pris en charge
  • Syntaxe pour les modèles
  • Effet
  • Fonction
  • RBAC
  • RBAC avec motif
  • RBAC avec domaines
  • Casbin RBAC v.s. RBAC96
  • ABAC
  • Modèle de priorité
  • Super Admin

Stockage

  • Stockage du modèle
  • Stockage de la politique
  • Chargement du sous-ensemble de la politique

Extensions

  • Enforcers
  • Adaptateurs
  • Observateurs
  • Répartiteurs
  • Responsables des rôles
  • Moyens
  • Moyens GraphQL
  • Moyens natifs du Cloud

API

  • Aperçu de l'API
  • API de gestion
  • RBAC API
  • RBAC avec API Domains
  • API RoleManager
  • Autorisations des données

Utilisation avancée

  • Multi-threads
  • Benchmarks
  • Optimisation des performances
  • Autorisation de Kubernetes
  • Autorisation de maillage de service par l'envoyé

Gestion

  • Portail Admin
  • Service Casbin
  • Gestion des logs et des erreurs
  • Utilisation du frontend

Editeur

  • Éditeur en ligne
  • Plugins IDE

En savoir plus

  • Nos Adopteurs
  • Contribuer
  • Politique de confidentialité
  • Conditions d'utilisation
Translate

Observateurs

Nous prenons en charge l'utilisation de systèmes de messagerie distribués comme etcd pour garder la cohérence entre plusieurs instances de contrôle de Casbin. Ainsi, nos utilisateurs peuvent utiliser simultanément plusieurs exécuteurs Casbin pour gérer un grand nombre de demandes de vérification des permissions.

Similaire aux adaptateurs de stockage stratégiques, nous ne plaçons pas de code de surveillance dans la bibliothèque principale. Tout support pour un nouveau système de messagerie devrait être mis en œuvre en tant que observateur. Une liste complète des observateurs de Casbin est fournie ci-dessous. Toute contribution de tierce partie sur un nouvel observateur est la bienvenue, s'il vous plaît nous en informer et je vais le mettre dans cette liste:)

Go
Java
Node.js
Python
.NET
Ruby
PHP
ObservateurType de texteAuteurLibellé
Observateur EtcdMagasin KVCasbinObservateur pour etcd
Guetteur RedisMagasin KVCasbinObservateur pour Redis
Guetteur RedisMagasin KV@billcobblerObservateur pour Redis
Guetteur TiKVMagasin KVCasbinObservateur pour TiKV
Guet de KafkaSystème de messagerie@wgarunapObservateur pour Apache Kafka
Observateur NATSSystème de messagerieSolutionObservateur pour NATS
Guetteur ZooKeeperSystème de messagerieGrepsrObservateur pour Apache ZooKeeper
NATS, RabbitMQ, GCP Pub/Sub, AWS SNS & SQS, Kafka, InMemorySystème de messagerie@rusenaskWatcher basé sur Go Cloud Dev Kit qui fonctionne avec les principaux fournisseurs de cloud et les infrastructures auto-hébergées
Observateur de RocketMQSystème de messagerie@fmyxyzObservateur pour Apache RocketMQ
ObservateurType de texteAuteurLibellé
Adaptateur EtcdMagasin KV@mapleafgoObservateur pour etcd
Guetteur RedisMagasin KVCasbinObservateur pour Redis
Guet de KafkaSystème de messagerieCasbinObservateur pour Apache Kafka
ObservateurType de texteAuteurLibellé
Observateur EtcdMagasin KVCasbinObservateur pour etcd
Guetteur RedisMagasin KVCasbinObservateur pour Redis
Pub/sous-observateurSystème de messagerieCasbinObservateur pour Google Cloud Pub/Sub
Observateur de PostgresBase de donnéesMatteo CollinaObservateur pour PostgreSQL
ObservateurType de texteAuteurLibellé
Guetteur RedisMagasin KVScienceLogiqueObservateur pour Redis
Observateur PostgreSQLBase de donnéesCasbinObservateur pour PostgreSQL
ObservateurType de texteAuteurLibellé
Guetteur RedisMagasin KV@SbouObservateur pour Redis
ObservateurType de texteAuteurLibellé
Guetteur RedisMagasin KVCasbinRubyObservateur pour Redis
Observateur Lapin MQSystème de messagerieCasbinRubyObservateur pour LapinsMQ
WatcherTypeAuteurDescription
Redis WatcherKV storeTinywanWatcher for Redis

format@@0 WatcherEx

In order to support incremental synchronization between multiple instances, we provide the WatcherEx interface. We hope it can notify other instances when the policy changes, but there is currently no implementation of WatcherEx. We recommend that you use dispatcher to achieve this.

Compared with Watcher interface, WatcherEx can distinguish what type of update action is received, e.g., AddPolicy and RemovePolicy.

WatcherEx Apis:

apidescription
SetUpdateCallback(func(string)) errorSetUpdateCallback sets the callback function that the watcher will call, when the policy in DB has been changed by other instances. A classic callback is Enforcer.LoadPolicy().
Update() errorUpdate calls the update callback of other instances to synchronize their policy. It is usually called after changing the policy in DB, like Enforcer.SavePolicy(), Enforcer.AddPolicy(), Enforcer.RemovePolicy(), etc.
Close()Close stops and releases the watcher, the callback function will not be called any more.
UpdateForAddPolicy(sec, ptype string, params ...string) errorUpdateForAddPolicy calls the update callback of other instances to synchronize their policy. It is called after a policy is added via Enforcer.AddPolicy(), Enforcer.AddNamedPolicy(), Enforcer.AddGroupingPolicy() and Enforcer.AddNamedGroupingPolicy().
UpdateForRemovePolicy(sec, ptype string, params ...string) errorUPdateForRemovePolicy calls the update callback of other instances to synchronize their policy. It is called after a policy is removed by Enforcer.RemovePolicy(), Enforcer.RemoveNamedPolicy(), Enforcer.RemoveGroupingPolicy() and Enforcer.RemoveNamedGroupingPolicy().
UpdateForRemoveFilteredPolicy(sec, ptype string, fieldIndex int, fieldValues ...string) errorUpdateForRemoveFilteredPolicy calls the update callback of other instances to synchronize their policy. It is called after Enforcer.RemoveFilteredPolicy(), Enforcer.RemoveFilteredNamedPolicy(), Enforcer.RemoveFilteredGroupingPolicy() and Enforcer.RemoveFilteredNamedGroupingPolicy().
UpdateForSavePolicy(model model.Model) errorUpdateForSavePolicy calls the update callback of other instances to synchronize their policy. It is called after Enforcer.SavePolicy()
UpdateForAddPolicies(sec string, ptype string, rules ...[]string) errorUpdateForAddPolicies calls the update callback of other instances to synchronize their policy. It is called after Enforcer.AddPolicies(), Enforcer.AddNamedPolicies(), Enforcer.AddGroupingPolicies() and Enforcer.AddNamedGroupingPolicies().
UpdateForRemovePolicies(sec string, ptype string, rules ...[]string) errorUpdateForRemovePolicies calls the update callback of other instances to synchronize their policy. It is called after Enforcer.RemovePolicies(), Enforcer.RemoveNamedPolicies(), Enforcer.RemoveGroupingPolicies() and Enforcer.RemoveNamedGroupingPolicies().
← AdaptateursRépartiteurs →
  • format@@0 WatcherEx
Casbin
Docs
Getting StartedManagement APIRBAC APIMiddlewares
Community
Who's using Casbin?Stack Overflow
Casbin          jCasbin
Node-Casbin   PHP-CasbinPyCasbin          Casbin.NETCasbin-CPP        Casbin-RS
Follow @casbinHQ
Copyright © 2022 Casbin Organization