Commit 813e93e
committed
[vdk-plugins] vdk-kerberos-auth: Separate async event loop
The `VdkAioKerberosClient` implementation that we currently have, utilizes async/await constructs
to speed up some operations. The minikerberos authenticator is the only client that uses the aforementioned
async kerberos client. It uses `asyncio.run()` to execute the async operations, which works with the asyncio
main thread. This is fine in general, as long as other components don't use async/await.
If they do, however, we could end up in a situation, where the kerberos plugin closes the asyncio
main event loop, and breaks the other components that rely on the same thread.
To avoid race conditions and other issues with the asyncio thread, this change introduces a separate
event loop for the minikerberos authenticator.
Testing done: Functional test added.
Signed-off-by: Andon Andonov <andonova@vmware.com>1 parent 7345c14 commit 813e93e
File tree
2 files changed
+23
-1
lines changed- projects/vdk-plugins/vdk-kerberos-auth
- src/vdk/plugin/kerberos
- tests/jobs/test-job
2 files changed
+23
-1
lines changedLines changed: 6 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
75 | 75 | | |
76 | 76 | | |
77 | 77 | | |
78 | | - | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
79 | 84 | | |
80 | 85 | | |
81 | 86 | | |
| |||
Lines changed: 17 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
0 commit comments