зеркало из https://github.com/microsoft/ghcrawler.git
update guid to be deliveryId
This commit is contained in:
Родитель
8858197a0b
Коммит
ca135a9252
|
@ -818,7 +818,7 @@ class GitHubProcessor {
|
|||
orgId = document.organization ? document.organization.id : null;
|
||||
}
|
||||
qualifier = qualifier || (repo ? `urn:repo:${repo}` : `urn:org:${orgId}`);
|
||||
const id = document.id || request.payload.guid;
|
||||
const id = document.id || request.payload.deliveryId;
|
||||
request.linkResource('self', `${qualifier}:${request.type}:${id}`);
|
||||
request.linkSiblings(`${qualifier}:${request.type}s`);
|
||||
|
||||
|
|
|
@ -32,7 +32,7 @@ router.post('/', wrap(function* (request, response, next) {
|
|||
const event = JSON.parse(request.body);
|
||||
const eventsUrl = event.repository ? event.repository.events_url : event.organization.events_url;
|
||||
const result = new Request('event_trigger', `${eventsUrl}/${deliveryId}`);
|
||||
result.payload = { body: event, etag: 1, fetchedAt: moment.utc().toISOString(), type: eventType, guid: deliveryId };
|
||||
result.payload = { body: event, etag: 1, fetchedAt: moment.utc().toISOString(), type: eventType, deliveryId: deliveryId };
|
||||
// requests off directly off the event feed do not need exclusivity
|
||||
result.requiresLock = false;
|
||||
// if the event is for a private repo, mark the request as needing private access.
|
||||
|
|
Загрузка…
Ссылка в новой задаче