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

wip changes for #14,#13,#18 #1

Merged
merged 1 commit into from
Jun 20, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 20 additions & 10 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -3,11 +3,17 @@
"node": true
},
"parserOptions": {
"ecmaVersion": 8
"ecmaVersion": 8,
"ecmaFeatures": {
"experimentalObjectRestSpread": true
}
},
"extends": "eslint-config-topcoder/nodejs",
"rules": {
"max-len": ["error", 160],
"max-len": [
"error",
160
],
"indent": [
"error",
2
@@ -25,12 +31,16 @@
"always"
],
"no-console": 0,
"comma-dangle": ["error", {
"arrays": "never",
"objects": "never",
"imports": "never",
"exports": "never",
"functions": "ignore"
}]
"comma-dangle": [
"error",
{
"arrays": "never",
"objects": "never",
"imports": "never",
"exports": "never",
"functions": "ignore"
}
],
"max-lines": 0,
}
}
}
5 changes: 4 additions & 1 deletion config/default.js
Original file line number Diff line number Diff line change
@@ -82,5 +82,8 @@ module.exports = {
GITLAB_API_BASE_URL: process.env.GITLAB_API_BASE_URL || 'https://gitlab.com',
PAID_ISSUE_LABEL: process.env.PAID_ISSUE_LABEL || 'Paid',
FIX_ACCEPTED_ISSUE_LABEL: process.env.FIX_ACCEPTED_ISSUE_LABEL || 'Fix accepted',
TC_OR_DETAIL_LINK: process.env.TC_OR_DETAIL_LINK || 'https://software.topcoder-dev.com/review/actions/ViewProjectDetails?pid='
READY_FOR_REVIEW_ISSUE_LABEL: process.env.READY_FOR_REVIEW_ISSUE_LABEL || 'Ready for review',
TC_OR_DETAIL_LINK: process.env.TC_OR_DETAIL_LINK || 'https://software.topcoder-dev.com/review/actions/ViewProjectDetails?pid=',
RETRY_COUNT: process.env.RETRY_COUNT || 3,
RETRY_INTERVAL: process.env.RETRY_INTERVAL || 120000, // 2 minutes
};
3 changes: 3 additions & 0 deletions configuration.md
Original file line number Diff line number Diff line change
@@ -26,6 +26,9 @@ The following config parameters are supported, they are defined in `config/defau
|PAID_ISSUE_LABEL|the label name for paid, should be one of the label configured in topcoder x ui|'Paid'|
|FIX_ACCEPTED_ISSUE_LABEL|the label name for fix accepted, should be one of the label configured in topcoder x ui|'Fix Accepted'|
|TC_OR_DETAIL_LINK|the link to online review detail of challenge| see `default.js`, OR link for dev environment|
|RETRY_COUNT| the number of times an event should be retried to process| 3|
|RETRY_INTERVAL| the interval at which the event should be retried to process in milliseconds | 120000|
|READY_FOR_REVIEW_ISSUE_LABEL| the label name for ready for review, should be one of the label configured in topcoder x ui|'Ready for review'|

KAFKA_OPTIONS should be object as described in https://github.com/SOHU-Co/kafka-node#kafkaclient
For using with SSL, the options should be as
5 changes: 4 additions & 1 deletion constants.js
Original file line number Diff line number Diff line change
@@ -22,7 +22,10 @@ const USER_ROLES = {
OWNER: 'owner'
};

const SERVICE_ERROR_STATUS = 500;

module.exports = {
USER_ROLES,
USER_TYPES
USER_TYPES,
SERVICE_ERROR_STATUS
};
Loading