Skip to content

Commit a2768c9

Browse files
authored
Merge pull request #75 from back4app/slow-requests
Slow requests
2 parents 5021ed9 + cb3e634 commit a2768c9

File tree

14 files changed

+884
-96
lines changed

14 files changed

+884
-96
lines changed

.eslintrc.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,5 +23,8 @@
2323
"react/react-in-jsx-scope": 1,
2424
"no-console": 0,
2525
"no-case-declarations": 0
26+
},
27+
"globals": {
28+
"b4aSettings": true
2629
}
2730
}

Parse-Dashboard/app.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ function checkIfIconsExistForApps(apps, iconsFolder) {
3434

3535
fs.stat(path, function(err) {
3636
if (err) {
37-
if ('ENOENT' == err.code) {// file does not exist
37+
if ('ENOENT' === err.code) {// file does not exist
3838
console.warn("Icon with file name: " + iconName +" couldn't be found in icons folder!");
3939
} else {
4040
console.log(
@@ -66,12 +66,12 @@ module.exports = function(config, options) {
6666

6767
// Reads files from public/bundles folder, looking for dashboard.<hash>.js and login.<hash>.js
6868
fs.readdir(path.join(__dirname, 'public', 'bundles'), function(err, items) {
69-
dashboardUrl = items.filter(file => file.indexOf('dashboard.') === 0)[0] || 'dashboard.bundle.js';
70-
loginUrl = items.filter(file => file.indexOf('login.') === 0)[0] || 'login.bundle.js';
69+
dashboardUrl = items && items.filter(file => file.indexOf('dashboard.') === 0)[0] || 'dashboard.bundle.js';
70+
loginUrl = items && items.filter(file => file.indexOf('login.') === 0)[0] || 'login.bundle.js';
7171
});
7272

7373
const users = config.users;
74-
const useEncryptedPasswords = config.useEncryptedPasswords ? true : false;
74+
const useEncryptedPasswords = !!config.useEncryptedPasswords;
7575
const authInstance = new Authentication(users, useEncryptedPasswords, mountPath);
7676
authInstance.initialize(app, { cookieSessionSecret: options.cookieSessionSecret });
7777

Lines changed: 78 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,80 @@
11
{
2-
"apps": []
2+
"apps": [
3+
{
4+
"apiKey": "33234033-ff53-4857-9822-7c095b29d1a1",
5+
"appNameForURL": "33234033-ff53-4857-9822-7c095b29d1a1",
6+
"id": "33234033-ff53-4857-9822-7c095b29d1a1",
7+
"loggerAdapter": {
8+
"module": "@back4app/back4app-logger-adapter",
9+
"options": {
10+
"udp": true,
11+
"logBody": true,
12+
"logBodyMillis": 100,
13+
"checkMasterKey": false,
14+
"defaults": {
15+
"timeout": 1000
16+
},
17+
"logServer": true,
18+
"logServerUrl": "http://loggerproxy.back4app.com:9900/apps_server",
19+
"logServerUdpHost": "loggerproxy.back4app.com",
20+
"logServerUdpPort": 49003,
21+
"logRequests": true,
22+
"logRequestsUrl": "http://loggerproxy.back4app.com:9900/apps_requests",
23+
"logRequestsUdpHost": "loggerproxy.back4app.com",
24+
"logRequestsUdpPort": 49002,
25+
"logConsole": true,
26+
"logConsoleUrl": "http://loggerproxy.back4app.com:9900/apps_console",
27+
"logConsoleUdpHost": "loggerproxy.back4app.com",
28+
"logConsoleUdpPort": 49001
29+
}
30+
},
31+
"databaseURI": "mongodb://admin:[email protected]/1092c422a65f4601b4853eca907e5f2d?connectTimeoutMS=30000",
32+
"appId": "DrcS4pwOkxngrYsikDRAbfCZjZMq6ZruzvdM2y7M",
33+
"masterKey": "rBWuaMCFiZzPy4IjkVFQVaeZPWb3ES3jdxIp5x8s",
34+
"restAPIKey": "w2iCq0AeshoUU8NbVjTGowFMFv1YvQ478EvEgueK",
35+
"javascriptKey": "0F2x31ceRPn871tO3Wc5Ua8a3mShFjb3V1kz3SrN",
36+
"clientKey": "hPjnbxiI6c0QVpJWzG5iUMerF1DXIuMlHIxhAWbE",
37+
"fileKey": "c71eb128-0e57-4cde-af58-808f90e397a1",
38+
"dotNetKey": "JH8AS3LO6GlogstmWevuKbs72UrRRJldnfIG9EIK4Vwc",
39+
"webhookKey": "QhO0QZZM9pJ632rzCqEYWSp4A9fO3vCah045ZNe7",
40+
"cloud": "cloudCodeWrapper.js",
41+
"logsFolder": "./data/parseLogs/",
42+
"verbose": false,
43+
"serverURL": "http://localhost:3333",
44+
"publicServerURL": "http://localhost:3333",
45+
"appName": "teste queijo",
46+
"emailAdapter": {
47+
"module": "parse-server-mandrill-adapter",
48+
"options": {
49+
"apiKey": "C6rFORDBBMHYgdPQZYxKqQ",
50+
"fromEmail": "[email protected]",
51+
"replyTo": "[email protected]",
52+
"displayName": "",
53+
"verificationSubject": "",
54+
"verificationBody": "",
55+
"passwordResetSubject": "",
56+
"passwordResetBody": ""
57+
}
58+
},
59+
"push": {
60+
"osx": [
61+
{
62+
"_id": "c5ecc30c-415d-4feb-885e-93d59eadd7c0",
63+
"pfx": "/Users/paiva/b4a/com.back4app.macos.p12",
64+
"bundleId": "com.back4app.macos",
65+
"production": true,
66+
"expiresAt": "2019-07-19T12:37:17.000Z"
67+
},
68+
{
69+
"_id": "c5ecc30c-415d-4feb-885e-93d59eadd7c1",
70+
"pfx": "/Users/paiva/b4a/com.back4app.macos_developer.p12",
71+
"bundleId": "com.back4app.macos",
72+
"production": false,
73+
"expiresAt": "2019-07-19T12:37:17.000Z"
74+
}
75+
]
76+
},
77+
"production": true
78+
}
79+
]
380
}

0 commit comments

Comments
 (0)