mirror of
https://iceshrimp.dev/limepotato/jormungandr-bite.git
synced 2024-11-25 03:17:38 -07:00
Make sure unresponsive split domain instances that come back to life don't get stuck isNotResponding
This commit is contained in:
parent
7ed43b76b5
commit
a1460503cf
1 changed files with 21 additions and 0 deletions
|
@ -194,6 +194,27 @@ export default async (job: Bull.Job<InboxJobData>): Promise<string> => {
|
|||
federationChart.inbox(i.host);
|
||||
});
|
||||
|
||||
const inbox = authUser.user.sharedInbox ?? authUser.user.inbox;
|
||||
if (inbox !== null) {
|
||||
const { host: inboxHost } = new URL(inbox);
|
||||
|
||||
if (inboxHost !== authUser.user.host) {
|
||||
registerOrFetchInstanceDoc(inboxHost).then((i) => {
|
||||
Instances.update(i.id, {
|
||||
latestRequestReceivedAt: new Date(),
|
||||
lastCommunicatedAt: new Date(),
|
||||
isNotResponding: false,
|
||||
});
|
||||
|
||||
fetchInstanceMetadata(i);
|
||||
|
||||
instanceChart.requestReceived(i.host);
|
||||
apRequestChart.inbox();
|
||||
federationChart.inbox(i.host);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
// アクティビティを処理
|
||||
await perform(authUser.user, activity);
|
||||
return "ok";
|
||||
|
|
Loading…
Reference in a new issue