Skip to content
This repository was archived by the owner on Mar 13, 2025. It is now read-only.

Commit a12f7a5

Browse files
committed
1 parent a06dfac commit a12f7a5

File tree

9 files changed

+629
-532
lines changed

9 files changed

+629
-532
lines changed

.eslintrc

+1
Original file line numberDiff line numberDiff line change
@@ -43,5 +43,6 @@
4343
}
4444
],
4545
"max-lines": 0,
46+
"max-statements": 0
4647
}
4748
}

README.md

+5
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,12 @@ The following config parameters are supported, they are defined in `config/defau
4343
|GITLAB_API_BASE_URL| the URL for gitlab host| defaults to `https://gitlab.com`|
4444
|PAID_ISSUE_LABEL|the label name for paid, should be one of the label configured in topcoder x ui|'tcx_Paid'|
4545
|FIX_ACCEPTED_ISSUE_LABEL|the label name for fix accepted, should be one of the label configured in topcoder x ui|'tcx_FixAccepted'|
46+
|ASSIGNED_ISSUE_LABEL| the label name for assigned, should be one of the label configured in topcoder x ui| 'tcx_Assigned'|
47+
|OPEN_FOR_PICKUP_ISSUE_LABEL| the label name for open for pickup, should be one of the label configured in topcoder x ui| 'tcx_OpenForPickup'|
4648
|TC_OR_DETAIL_LINK|the link to online review detail of challenge| see `default.js`, OR link for dev environment|
49+
|RETRY_COUNT| the number of times an event should be retried to process| 3|
50+
|RETRY_INTERVAL| the interval at which the event should be retried to process in milliseconds | 120000|
51+
|READY_FOR_REVIEW_ISSUE_LABEL| the label name for ready for review, should be one of the label configured in topcoder x ui|'tcx_ReadyForReview'|
4752

4853
KAFKA_OPTIONS should be object as described in https://github.com/oleksiyk/kafka#ssl
4954
For using with SSL, the options should be as

config/default.js

+2
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,8 @@ module.exports = {
8484
PAID_ISSUE_LABEL: process.env.PAID_ISSUE_LABEL || 'tcx_Paid',
8585
FIX_ACCEPTED_ISSUE_LABEL: process.env.FIX_ACCEPTED_ISSUE_LABEL || 'tcx_FixAccepted',
8686
READY_FOR_REVIEW_ISSUE_LABEL: process.env.READY_FOR_REVIEW_ISSUE_LABEL || 'tcx_ReadyForReview',
87+
ASSIGNED_ISSUE_LABEL: process.env.READY_FOR_REVIEW_ISSUE_LABEL || 'tcx_Assigned',
88+
OPEN_FOR_PICKUP_ISSUE_LABEL: process.env.READY_FOR_REVIEW_ISSUE_LABEL || 'tcx_OpenForPickup',
8789
TC_OR_DETAIL_LINK: process.env.TC_OR_DETAIL_LINK || 'https://software.topcoder-dev.com/review/actions/ViewProjectDetails?pid=',
8890
RETRY_COUNT: process.env.RETRY_COUNT || 3,
8991
RETRY_INTERVAL: process.env.RETRY_INTERVAL || 120000, // 2 minutes

configuration.md

+2
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ The following config parameters are supported, they are defined in `config/defau
2525
|GITLAB_API_BASE_URL| the URL for gitlab host| defaults to `https://gitlab.com`|
2626
|PAID_ISSUE_LABEL|the label name for paid, should be one of the label configured in topcoder x ui|'tcx_Paid'|
2727
|FIX_ACCEPTED_ISSUE_LABEL|the label name for fix accepted, should be one of the label configured in topcoder x ui|'tcx_FixAccepted'|
28+
|ASSIGNED_ISSUE_LABEL| the label name for assigned, should be one of the label configured in topcoder x ui| 'tcx_Assigned'|
29+
|OPEN_FOR_PICKUP_ISSUE_LABEL| the label name for open for pickup, should be one of the label configured in topcoder x ui| 'tcx_OpenForPickup'|
2830
|TC_OR_DETAIL_LINK|the link to online review detail of challenge| see `default.js`, OR link for dev environment|
2931
|RETRY_COUNT| the number of times an event should be retried to process| 3|
3032
|RETRY_INTERVAL| the interval at which the event should be retried to process in milliseconds | 120000|

models/Issue.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,9 @@ const schema = new mongoose.Schema({
2525
default: Date.now
2626
},
2727
// From topcoder api
28-
challengeId: {type: Number, required: true, unique: true},
29-
projectId: {type: mongoose.Schema.Types.ObjectId, ref: 'Project'}
28+
challengeId: {type: Number, required: false, unique: true},
29+
projectId: {type: mongoose.Schema.Types.ObjectId, ref: 'Project'},
30+
status: {type: String}
3031
});
3132

3233
// Issue number, provider, repositoryId must be unique

0 commit comments

Comments
 (0)