-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Multiple calls to refreshSession failing #54
Comments
@jguadagno There's an understatement :) Given you are creating a new agent instance which in turn creates a new session with every operation and then throwing the agent away it shouldn't be refreshing a session at all. I'm wonder if the GC hasn't caught up yet, and they're all hanging around refreshing until they get collected. A couple of things to try
If neither of those work I'm adding more logging to the refresh code (and giving each session an internal identifier to help correlate), and we'll start gathering logs to see what the heck is going on. |
The thing that is weird is that the method (Azure Function) to post a Bluesky skeet should only be called twice a day or additionally if there is a recent blog post/video, which there hasn't been. I've since updated the code and added a |
The thing that is weird is that the method (Azure Function) to post a Bluesky skeet should only be called twice a day or additionally if there is a new blog post/video, which there hasn't been. I've since updated the code and added a |
Don't you head down that route of calling them skeets! Let's see if that solves it, if it doesn't, I'll build a version with the debug logging, which presumably you can hook up in a function somewhere |
#62 might be the root cause here. v0.2.1-prerelease is on nuget now if you want to try that as well. |
Bug report
Details
Describe the bug
After installing release
0.1.3-prerelease
I am getting a lot of failed (429) POST calls tohttps://puffball.us-east.host.bsky.network/xrpc/com.atproto.server.refreshSession
. Around 3 million a day, some are successful, but most are failing.Expected behavior
The agent should not refresh the token so frequently
Actual behavior
The agent attempts to refresh the token multiple times a second.
Helpful Extra information
What operating system(s) are you using?
Reproduction code
I have the code for the login available here: https://github.com/jguadagno/jjgnet-broadcast/blob/c43206129fbc9056659115f1770f1da747fe668a/src/JosephGuadagno.Broadcasting.Managers.Bluesky/BlueskyManager.cs#L20
The text was updated successfully, but these errors were encountered: