milvus-logo
LFAI
< Docs
  • Python

remove_user()

This method dissociates a user from the current role. After this operation, the user losses access to the privileges that bind to the role.

Invocation

remove_user(username)

Parameters

ParameterDescriptionTypeRequired
usernameName of the user to be associated with the roleStringTrue

Return

No return

Example

from pymilvus import connections
from pymilvus.orm.role import Role
connections.connect()
role = Role(name=role_name)
role.remove_user(username)
users = role.get_users()
print(f"users added to the role: {users}")
Feedback

Was this page helpful?