Compare commits

...

9 Commits

Author SHA1 Message Date
Rainer Killinger
b71a30db1f 0.3.1 2022-09-02 16:11:17 +02:00
Rainer Killinger
43c469d66a refactor: update @openstapps/core 2022-09-02 15:56:04 +02:00
Rainer Killinger
608f58ccbf docs: update changelog 2022-08-24 12:31:02 +02:00
Rainer Killinger
dde4a0d1cd 0.3.0 2022-08-24 12:30:57 +02:00
Rainer Killinger
ba07267372 ci: enforce npm audit for production dependencies 2022-08-23 10:56:36 +02:00
Rainer Killinger
001cd4b4de refactor: update some dependencies 2022-08-23 10:56:35 +02:00
Rainer Killinger
c2b0d22a25 refactor: move to express-prom-bundle for monitoring 2022-08-23 10:56:32 +02:00
Jovan Krunić
9e1017edfb refactor: use material symbols for menu 2022-08-22 15:25:00 +00:00
Rainer Killinger
557d050b36 docs: update changelog 2022-08-22 17:16:31 +02:00
8 changed files with 242 additions and 800 deletions

View File

@@ -50,10 +50,7 @@ audit:
dependencies:
- build
script:
- npm audit
allow_failure: true
except:
- schedules
- npm audit --production
pages:
stage: deploy
@@ -66,13 +63,6 @@ pages:
paths:
- public
scheduled-audit:
stage: audit
script:
- npm audit --audit-level=high
only:
- schedules
ci:
stage: test
dependencies:

View File

@@ -1,3 +1,16 @@
# [0.3.0](https://gitlab.com/openstapps/backend/compare/v0.2.0...v0.3.0) (2022-08-24)
# [0.2.0](https://gitlab.com/openstapps/backend/compare/v0.1.0...v0.2.0) (2022-08-22)
### Bug Fixes
* update PAIA API URL ([a20200e](https://gitlab.com/openstapps/backend/commit/a20200e52a725ede42cb5e026a5a693b1ba3d149))
# [0.1.0](https://gitlab.com/openstapps/backend/compare/16bbb7e9e36b7adf27452e1b09f7970e98aa27df...v0.1.0) (2022-06-30)

View File

@@ -3,19 +3,20 @@
import {SCAboutPageContentType, SCConfigFile, SCLanguageCode} from '@openstapps/core';
import {RecursivePartial} from '@openstapps/logger/lib/common';
const markdownSources: {[key in SCLanguageCode]?: {
/**
* Privacy policy markdown
*/
privacyPolicy?: string;
/**
* Terms and conditions markdown
*/
termsAndConditions?: string;
}} = {en: {}, de: {}};
const markdownSources: {
[key in SCLanguageCode]?: {
/**
* Privacy policy markdown
*/
privacyPolicy?: string;
/**
* Terms and conditions markdown
*/
termsAndConditions?: string;
};
} = {en: {}, de: {}};
markdownSources.de!.privacyPolicy =
`
markdownSources.de!.privacyPolicy = `
Diese Datenschutzerklärung dient zur Erfüllung der nach Artikel 13 EU DSGVO geforderten Informationspflicht bei Erhebung von Daten zum Zeitpunkt der Erhebung bei betroffenen Personen.
# **Name und Anschrift des Verantwortlichen**
@@ -176,8 +177,7 @@ Pseudonymisierung gehören kann.</li>
</ol>
`;
markdownSources.de!.termsAndConditions =
`
markdownSources.de!.termsAndConditions = `
<p>Stand: 04. November 2015</p>
<p>Es gilt der jeweilige Datenschutz der Hochschule im jeweiligen Bundesland. Darüber hinaus gelten die folgenden Vereinbarungen. Mit der Installation erklären Sie sich bereit die folgenden Bedingungen zu akzeptieren. <br>
</p>
@@ -282,8 +282,7 @@ markdownSources.de!.termsAndConditions =
<p>Fragen oder Anmerkungen zu dieser AGB richten Sie bitte an: <a href="mailto:app@rz.uni-frankfurt.de">app@rz.uni-frankfurt.de</a></p>
`;
markdownSources.en!.privacyPolicy =
`
markdownSources.en!.privacyPolicy = `
This data protection declaration serves to fulfill the information obligation required under Article 13 EU DSGVO when data is collected at the time of collection from data subjects.
# **Name and address of the responsible person**
@@ -445,8 +444,7 @@ Pseudonymization may include.</li>
</ol>
`;
markdownSources.en!.termsAndConditions =
`
markdownSources.en!.termsAndConditions = `
<p>As of November 04, 2015</p>
<p>The respective data protection of the university in the respective federal state applies. In addition, the following agreements apply. By installing you agree to accept the following terms and conditions. <br>
</p>
@@ -551,7 +549,6 @@ markdownSources.en!.termsAndConditions =
<p>If you have any questions or comments about these terms and conditions, please contact: <a href="mailto:app@rz.uni-frankfurt.de">app@rz.uni-frankfurt.de</a></p>
`;
/**
* This is the default configuration for the Goethe university of Frankfurt
*/
@@ -598,8 +595,7 @@ const config: RecursivePartial<SCConfigFile> = {
title: 'Über das StApps Projekt',
content: [
{
title:
'Verbundprojekt mehrerer Hochschulen für eine generische Studierenden-App',
title: 'Verbundprojekt mehrerer Hochschulen für eine generische Studierenden-App',
content: {
type: SCAboutPageContentType.MARKDOWN,
value: `
@@ -622,8 +618,7 @@ const config: RecursivePartial<SCConfigFile> = {
},
translations: {
en: {
title:
'Collaborative project of multiple universities for a single generic study app',
title: 'Collaborative project of multiple universities for a single generic study app',
},
},
type: SCAboutPageContentType.SECTION,
@@ -649,8 +644,7 @@ const config: RecursivePartial<SCConfigFile> = {
Norbert-Wollheim-Platz 1<br>
60629 Frankfurt
`,
translations: {
},
translations: {},
type: SCAboutPageContentType.MARKDOWN,
},
],
@@ -669,8 +663,7 @@ const config: RecursivePartial<SCConfigFile> = {
'[app@rz.uni-frankfurt.de](mailto:app@rz.uni-frankfurt.de)<br>' +
'[+49 69 798 32936](tel:+496979832936)<br>' +
'[https://app.rz.uni-frankfurt.de](https://app.rz.uni-frankfurt.de)',
translations: {
},
translations: {},
type: SCAboutPageContentType.MARKDOWN,
},
],
@@ -696,7 +689,7 @@ const config: RecursivePartial<SCConfigFile> = {
type: SCAboutPageContentType.ROUTER_LINK,
},
{
icon: 'document',
icon: 'description',
title: 'Impressum',
link: 'imprint',
translations: {
@@ -707,7 +700,7 @@ const config: RecursivePartial<SCConfigFile> = {
type: SCAboutPageContentType.ROUTER_LINK,
},
{
icon: 'shield-half',
icon: 'policy',
title: 'Datenschutz',
link: 'privacy',
translations: {
@@ -718,7 +711,7 @@ const config: RecursivePartial<SCConfigFile> = {
type: SCAboutPageContentType.ROUTER_LINK,
},
{
icon: 'reader',
icon: 'text_snippet',
title: 'Allgemeine Geschäftsbedingungen',
link: 'terms',
translations: {
@@ -729,7 +722,7 @@ const config: RecursivePartial<SCConfigFile> = {
type: SCAboutPageContentType.ROUTER_LINK,
},
{
icon: 'library',
icon: 'copyright',
title: 'Bibliotheken und Lizenzen',
link: 'licenses',
translations: {

View File

@@ -10,39 +10,37 @@ import {
SCUserGroupSetting,
} from '@openstapps/core';
import {readFileSync} from 'fs';
import {resolve} from 'path';
import path from 'path';
/**
* Evaluates if a number is within the given range
*
* @param num The number that should be checked
* @param number_ The number that should be checked
* @param range Array of two numbers representing a range (inclusive interval)
*/
export function inRangeInclusive(num: number, range: number[]): boolean {
return num >= range[0] && num <= range[1];
export function inRangeInclusive(number_: number, range: number[]): boolean {
return number_ >= range[0] && number_ <= range[1];
}
const sommerRange = [4, 9];
const winterRange = [10, 3];
const month = new Date().getMonth();
const year = new Date().getFullYear();
const winterYearOffset = (month < winterRange[0] ? -1 : 0);
const winterYearOffset = month < winterRange[0] ? -1 : 0;
const sommerYear = year + (month <= winterRange[1] ? -1 : 0);
const winterYear = `${year + winterYearOffset}/${(year + 1 + winterYearOffset)
.toString()
.slice(-2)}`;
const winterYear = `${year + winterYearOffset}/${(year + 1 + winterYearOffset).toString().slice(-2)}`;
const wsAcronymShort = `WS ${winterYear}`;
const ssAcronymShort = `SS ${sommerYear}`;
const wsAcronymLong = `WiSe ${winterYear}`;
const ssAcronymLong = `SoSe ${sommerYear}`;
const userGroupSetting: SCUserGroupSetting = {
categories: ['profile'],
defaultValue: 'students',
description: 'The user group the app is going to be used.'
+ 'This settings for example is getting used for the predefined price category of mensa meals.',
description:
'The user group the app is going to be used.' +
'This settings for example is getting used for the predefined price category of mensa meals.',
inputType: SCSettingInputType.SingleChoice,
name: 'group',
order: 1,
@@ -53,24 +51,17 @@ const userGroupSetting: SCUserGroupSetting = {
},
translations: {
de: {
description: 'Mit welcher Benutzergruppe soll die App verwendet werden?'
+ ' Die Einstellung wird beispielsweise für die Vorauswahl der Preiskategorie der Mensa verwendet.',
description:
'Mit welcher Benutzergruppe soll die App verwendet werden?' +
' Die Einstellung wird beispielsweise für die Vorauswahl der Preiskategorie der Mensa verwendet.',
name: 'Gruppe',
values: [
'Student',
'Angestellter',
'Gast',
],
values: ['Student', 'Angestellter', 'Gast'],
},
en: {
description: `The user group the app is going to be used.'
+ ' This settings for example is getting used for the predefined price category of mensa meals.`,
name: 'Group',
values: [
'student',
'employee',
'guest',
],
values: ['student', 'employee', 'guest'],
},
},
type: SCThingType.Setting,
@@ -94,18 +85,12 @@ const languageSetting: SCLanguageSetting = {
de: {
description: 'Die Sprache in der die App angezeigt wird.',
name: 'Sprache',
values: [
'Deutsch',
'English',
],
values: ['Deutsch', 'English'],
},
en: {
description: 'The language this app is going to use.',
name: 'Language',
values: [
'Deutsch',
'English',
],
values: ['Deutsch', 'English'],
},
},
type: SCThingType.Setting,
@@ -132,8 +117,7 @@ const config: Partial<SCConfigFile> = {
title: 'Über das StApps Projekt',
content: [
{
title:
'Verbundprojekt mehrerer Hochschulen für eine generische Studierenden-App',
title: 'Verbundprojekt mehrerer Hochschulen für eine generische Studierenden-App',
content: {
type: SCAboutPageContentType.MARKDOWN,
value: `
@@ -154,8 +138,7 @@ const config: Partial<SCConfigFile> = {
},
translations: {
en: {
title:
'Collaborative project of multiple universities for a single generic study app',
title: 'Collaborative project of multiple universities for a single generic study app',
},
},
type: SCAboutPageContentType.SECTION,
@@ -200,10 +183,7 @@ const config: Partial<SCConfigFile> = {
type: SCAboutPageContentType.MARKDOWN,
},
{
value:
'[mail]()<br>' +
'[+49 12 345 67890]()<br>' +
'[https://localhost/]()',
value: '[mail]()<br>' + '[+49 12 345 67890]()<br>' + '[https://localhost/]()',
translations: {
en: {
value: 'This would be the english contact information',
@@ -223,7 +203,7 @@ const config: Partial<SCConfigFile> = {
type: SCAboutPageContentType.SECTION,
},
{
icon: 'newspaper',
icon: 'campaign',
title: 'Neue Funktionen / Gelöste Probleme',
link: 'changelog',
translations: {
@@ -234,7 +214,7 @@ const config: Partial<SCConfigFile> = {
type: SCAboutPageContentType.ROUTER_LINK,
},
{
icon: 'document',
icon: 'description',
title: 'Impressum',
link: 'imprint',
translations: {
@@ -245,7 +225,7 @@ const config: Partial<SCConfigFile> = {
type: SCAboutPageContentType.ROUTER_LINK,
},
{
icon: 'shield-half',
icon: 'policy',
title: 'Datenschutz',
link: 'privacy',
translations: {
@@ -256,7 +236,7 @@ const config: Partial<SCConfigFile> = {
type: SCAboutPageContentType.ROUTER_LINK,
},
{
icon: 'reader',
icon: 'text_snippet',
title: 'Allgemeine Geschäftsbedingungen',
link: 'terms',
translations: {
@@ -267,7 +247,7 @@ const config: Partial<SCConfigFile> = {
type: SCAboutPageContentType.ROUTER_LINK,
},
{
icon: 'library',
icon: 'copyright',
title: 'Bibliotheken und Lizenzen',
link: 'licenses',
translations: {
@@ -363,26 +343,11 @@ const config: Partial<SCConfigFile> = {
campusPolygon: {
coordinates: [
[
[
8.660432999690723,
50.123027017044436,
],
[
8.675496285518358,
50.123027017044436,
],
[
8.675496285518358,
50.13066176448642,
],
[
8.660432999690723,
50.13066176448642,
],
[
8.660432999690723,
50.123027017044436,
],
[8.660_432_999_690_723, 50.123_027_017_044_436],
[8.675_496_285_518_358, 50.123_027_017_044_436],
[8.675_496_285_518_358, 50.130_661_764_486_42],
[8.660_432_999_690_723, 50.130_661_764_486_42],
[8.660_432_999_690_723, 50.123_027_017_044_436],
],
],
type: 'Polygon',
@@ -397,6 +362,7 @@ const config: Partial<SCConfigFile> = {
},
menus: [
{
// unused
icon: 'menu',
id: 'main',
items: [
@@ -427,7 +393,7 @@ const config: Partial<SCConfigFile> = {
},
},
{
icon: 'calendar',
icon: 'calendar_month',
route: '/schedule',
title: 'schedule',
translations: {
@@ -440,7 +406,7 @@ const config: Partial<SCConfigFile> = {
},
},
{
icon: 'cafe',
icon: 'local_cafe',
route: '/canteen',
title: 'canteen',
translations: {
@@ -453,7 +419,7 @@ const config: Partial<SCConfigFile> = {
},
},
{
icon: 'search',
icon: 'local_library',
route: '/hebis-search',
title: 'library catalog',
translations: {
@@ -466,7 +432,7 @@ const config: Partial<SCConfigFile> = {
},
},
{
icon: 'folder',
icon: 'inventory_2',
route: '/catalog',
title: 'course catalog',
translations: {
@@ -503,11 +469,13 @@ const config: Partial<SCConfigFile> = {
},
},
{
icon: 'person',
// unused
icon: 'account_circle',
id: 'personal',
items: [
{
icon: 'library',
authProvider: 'paia',
icon: 'account_circle',
route: '/library-account',
title: 'library account',
translations: {
@@ -519,6 +487,20 @@ const config: Partial<SCConfigFile> = {
},
},
},
{
authProvider: 'default',
icon: 'task',
route: '/assessments',
title: 'summary of grades',
translations: {
de: {
title: 'Notenspiegel',
},
en: {
title: 'summary of grades',
},
},
},
{
icon: 'star',
route: '/favorites',
@@ -533,7 +515,7 @@ const config: Partial<SCConfigFile> = {
},
},
{
icon: 'person',
icon: 'account_circle',
route: '/profile',
title: 'profile',
translations: {
@@ -559,7 +541,7 @@ const config: Partial<SCConfigFile> = {
},
},
{
icon: 'information',
icon: 'info',
route: '/about',
title: 'about',
translations: {
@@ -572,7 +554,7 @@ const config: Partial<SCConfigFile> = {
},
},
{
icon: 'chatbubbles',
icon: 'rate_review',
route: '/feedback',
title: 'feedback',
translations: {
@@ -598,10 +580,7 @@ const config: Partial<SCConfigFile> = {
],
name: 'Goethe-Uni',
privacyPolicyUrl: 'https://mobile.server.uni-frankfurt.de/_static/privacy.md',
settings: [
userGroupSetting,
languageSetting,
],
settings: [userGroupSetting, languageSetting],
},
auth: {
paia: {
@@ -611,7 +590,8 @@ const config: Partial<SCConfigFile> = {
url: 'https://hds.hebis.de/Shibboleth.sso/UBFFM?target=https://hds.hebis.de/ubffm/paia_login_stub.php',
},
endpoints: {
authorization: 'https://hds.hebis.de/Shibboleth.sso/UBFFM?target=https://hds.hebis.de/ubffm/paia_login_stub.php',
authorization:
'https://hds.hebis.de/Shibboleth.sso/UBFFM?target=https://hds.hebis.de/ubffm/paia_login_stub.php',
mapping: {
id: '$.email',
name: '$.name',
@@ -623,14 +603,10 @@ const config: Partial<SCConfigFile> = {
},
},
backend: {
SCVersion: JSON.parse((readFileSync(resolve('.', '.', 'package.json'), 'utf-8')).toString())
.dependencies['@openstapps/core'],
SCVersion: JSON.parse(readFileSync(path.resolve('.', '.', 'package.json'), 'utf8').toString())
.dependencies['@openstapps/core'],
externalRequestTimeout: 5000,
hiddenTypes: [
SCThingType.DateSeries,
SCThingType.Diff,
SCThingType.Floor,
],
hiddenTypes: [SCThingType.DateSeries, SCThingType.Diff, SCThingType.Floor],
mappingIgnoredTags: ['minlength', 'pattern', 'see', 'tjs-format'],
maxMultiSearchRouteQueries: 5,
maxRequestBodySize: 512 * 1024,
@@ -659,20 +635,12 @@ const config: Partial<SCConfigFile> = {
},
{
fieldName: 'geo',
onlyOnTypes: [
SCThingType.Building,
SCThingType.PointOfInterest,
SCThingType.Room,
],
onlyOnTypes: [SCThingType.Building, SCThingType.PointOfInterest, SCThingType.Room],
sortTypes: ['distance'],
},
{
fieldName: 'geo',
onlyOnTypes: [
SCThingType.Building,
SCThingType.PointOfInterest,
SCThingType.Room,
],
onlyOnTypes: [SCThingType.Building, SCThingType.PointOfInterest, SCThingType.Room],
sortTypes: ['distance'],
},
{
@@ -690,9 +658,7 @@ const config: Partial<SCConfigFile> = {
},
{
fieldName: 'offers',
onlyOnTypes: [
SCThingType.Dish,
],
onlyOnTypes: [SCThingType.Dish],
sortTypes: ['price'],
},
],
@@ -725,31 +691,19 @@ const config: Partial<SCConfigFile> = {
},
{
fieldName: 'academicTerms.acronym',
onlyOnTypes: [
SCThingType.AcademicEvent,
SCThingType.SportCourse,
],
onlyOnTypes: [SCThingType.AcademicEvent, SCThingType.SportCourse],
},
{
fieldName: 'academicTerm.acronym',
onlyOnTypes: [
SCThingType.Catalog,
],
onlyOnTypes: [SCThingType.Catalog],
},
{
fieldName: 'majors',
onlyOnTypes: [
SCThingType.AcademicEvent,
],
onlyOnTypes: [SCThingType.AcademicEvent],
},
{
fieldName: 'keywords',
onlyOnTypes: [
SCThingType.Article,
SCThingType.Book,
SCThingType.Message,
SCThingType.Video,
],
onlyOnTypes: [SCThingType.Article, SCThingType.Book, SCThingType.Message, SCThingType.Video],
},
{
fieldName: 'type',
@@ -772,7 +726,7 @@ const config: Partial<SCConfigFile> = {
{
factor: 1,
fields: {
'categories': {
categories: {
'course': 1.08,
'integrated course': 1.08,
'introductory class': 1.05,
@@ -790,11 +744,11 @@ const config: Partial<SCConfigFile> = {
{
factor: 1,
fields: {
'categories': {
'cafe': 1.1,
'learn': 1.1,
'library': 1.2,
'restaurant': 1.1,
categories: {
cafe: 1.1,
learn: 1.1,
library: 1.2,
restaurant: 1.1,
},
},
type: SCThingType.PointOfInterest,
@@ -802,7 +756,7 @@ const config: Partial<SCConfigFile> = {
{
factor: 1,
fields: {
'categories': {
categories: {
'main dish': 2,
},
},
@@ -813,7 +767,7 @@ const config: Partial<SCConfigFile> = {
{
factor: 1,
fields: {
'categories': {
categories: {
'cafe': 2,
'canteen': 2,
'restaurant': 2,

View File

@@ -1,7 +1,10 @@
{
"metricsPath": "/metrics",
"collectDefaultMetrics": true,
"requestDurationBuckets": [0.1, 0.5, 1, 2, 5, 10, 20],
"requestLengthBuckets": [512, 1024, 5120, 10240, 51200, 102400],
"responseLengthBuckets": [512, 1024, 5120, 10240, 51200, 102400]
"includeMethod": true,
"includePath": true,
"promClient": {
"collectDefaultMetrics": {
}
},
"for-more-options-see": "https://github.com/jochen-schweizer/express-prom-bundle#options"
}

727
package-lock.json generated
View File

@@ -1,6 +1,6 @@
{
"name": "@openstapps/backend",
"version": "0.2.0",
"version": "0.3.1",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
@@ -23,27 +23,27 @@
}
},
"@babel/compat-data": {
"version": "7.18.8",
"resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.18.8.tgz",
"integrity": "sha512-HSmX4WZPPK3FUxYp7g2T6EyO8j96HlZJlxmKPSh6KAcqwyDrfx7hKjXpAW/0FhFfTJsR0Yt4lAjLI2coMptIHQ==",
"version": "7.18.13",
"resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.18.13.tgz",
"integrity": "sha512-5yUzC5LqyTFp2HLmDoxGQelcdYgSpP9xsnMWBphAscOdFrHSAVbLNzWiy32sVNDqJRDiJK6klfDnAgu6PAGSHw==",
"dev": true
},
"@babel/core": {
"version": "7.18.10",
"resolved": "https://registry.npmjs.org/@babel/core/-/core-7.18.10.tgz",
"integrity": "sha512-JQM6k6ENcBFKVtWvLavlvi/mPcpYZ3+R+2EySDEMSMbp7Mn4FexlbbJVrx2R7Ijhr01T8gyqrOaABWIOgxeUyw==",
"version": "7.18.13",
"resolved": "https://registry.npmjs.org/@babel/core/-/core-7.18.13.tgz",
"integrity": "sha512-ZisbOvRRusFktksHSG6pjj1CSvkPkcZq/KHD45LAkVP/oiHJkNBZWfpvlLmX8OtHDG8IuzsFlVRWo08w7Qxn0A==",
"dev": true,
"requires": {
"@ampproject/remapping": "^2.1.0",
"@babel/code-frame": "^7.18.6",
"@babel/generator": "^7.18.10",
"@babel/generator": "^7.18.13",
"@babel/helper-compilation-targets": "^7.18.9",
"@babel/helper-module-transforms": "^7.18.9",
"@babel/helpers": "^7.18.9",
"@babel/parser": "^7.18.10",
"@babel/parser": "^7.18.13",
"@babel/template": "^7.18.10",
"@babel/traverse": "^7.18.10",
"@babel/types": "^7.18.10",
"@babel/traverse": "^7.18.13",
"@babel/types": "^7.18.13",
"convert-source-map": "^1.7.0",
"debug": "^4.1.0",
"gensync": "^1.0.0-beta.2",
@@ -60,12 +60,12 @@
}
},
"@babel/generator": {
"version": "7.18.12",
"resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.18.12.tgz",
"integrity": "sha512-dfQ8ebCN98SvyL7IxNMCUtZQSq5R7kxgN+r8qYTGDmmSion1hX2C0zq2yo1bsCDhXixokv1SAWTZUMYbO/V5zg==",
"version": "7.18.13",
"resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.18.13.tgz",
"integrity": "sha512-CkPg8ySSPuHTYPJYo7IRALdqyjM9HCbt/3uOBEFbzyGVP6Mn8bwFPB0jX6982JVNBlYzM1nnPkfjuXSOPtQeEQ==",
"dev": true,
"requires": {
"@babel/types": "^7.18.10",
"@babel/types": "^7.18.13",
"@jridgewell/gen-mapping": "^0.3.2",
"jsesc": "^2.5.1"
},
@@ -256,9 +256,9 @@
}
},
"@babel/parser": {
"version": "7.18.11",
"resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.18.11.tgz",
"integrity": "sha512-9JKn5vN+hDt0Hdqn1PiJ2guflwP+B6Ga8qbDuoF0PzzVhrzsKIJo8yGqVk6CmMHiMei9w1C1Bp9IMJSIK+HPIQ==",
"version": "7.18.13",
"resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.18.13.tgz",
"integrity": "sha512-dgXcIfMuQ0kgzLB2b9tRZs7TTFFaGM2AbtA4fJgUUYukzGH4jwsS7hzQHEGs67jdehpm22vkgKwvbU+aEflgwg==",
"dev": true
},
"@babel/template": {
@@ -273,19 +273,19 @@
}
},
"@babel/traverse": {
"version": "7.18.11",
"resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.18.11.tgz",
"integrity": "sha512-TG9PiM2R/cWCAy6BPJKeHzNbu4lPzOSZpeMfeNErskGpTJx6trEvFaVCbDvpcxwy49BKWmEPwiW8mrysNiDvIQ==",
"version": "7.18.13",
"resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.18.13.tgz",
"integrity": "sha512-N6kt9X1jRMLPxxxPYWi7tgvJRH/rtoU+dbKAPDM44RFHiMH8igdsaSBgFeskhSl/kLWLDUvIh1RXCrTmg0/zvA==",
"dev": true,
"requires": {
"@babel/code-frame": "^7.18.6",
"@babel/generator": "^7.18.10",
"@babel/generator": "^7.18.13",
"@babel/helper-environment-visitor": "^7.18.9",
"@babel/helper-function-name": "^7.18.9",
"@babel/helper-hoist-variables": "^7.18.6",
"@babel/helper-split-export-declaration": "^7.18.6",
"@babel/parser": "^7.18.11",
"@babel/types": "^7.18.10",
"@babel/parser": "^7.18.13",
"@babel/types": "^7.18.13",
"debug": "^4.1.0",
"globals": "^11.1.0"
},
@@ -299,9 +299,9 @@
}
},
"@babel/types": {
"version": "7.18.10",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.18.10.tgz",
"integrity": "sha512-MJvnbEiiNkpjo+LknnmRrqbY1GPUUggjv+wQVjetM/AONoupqRALB7I6jGqNUAZsKcRIEu2J6FRFvsczljjsaQ==",
"version": "7.18.13",
"resolved": "https://registry.npmjs.org/@babel/types/-/types-7.18.13.tgz",
"integrity": "sha512-ePqfTihzW0W6XAU+aMw2ykilisStJfDnsejDCXRchCcMJ4O0+8DhPXf2YUbZ6wjBlsEmZwLK/sPweWtu8hcJYQ==",
"dev": true,
"requires": {
"@babel/helper-string-parser": "^7.18.10",
@@ -587,9 +587,9 @@
}
},
"@openstapps/core": {
"version": "0.69.0",
"resolved": "https://registry.npmjs.org/@openstapps/core/-/core-0.69.0.tgz",
"integrity": "sha512-IaUb10IfldokrqopdqsyHl5j3rVvg8CA10s2E+WpVOjgkXnW8SP9jVg5AP0jx3vgN3e0xHsrPtvrZWTPgyoSRQ==",
"version": "0.70.0",
"resolved": "https://registry.npmjs.org/@openstapps/core/-/core-0.70.0.tgz",
"integrity": "sha512-obLFSiI5P0cEAeadxEQ1Wbbe/FDiSi0p4azpmszUPyshpSXKqt4y6F4Z+dnswBSe85wtPg/PuHC1MYZ79SJB4g==",
"requires": {
"@openstapps/core-tools": "0.32.0",
"@types/geojson": "1.0.6",
@@ -797,6 +797,7 @@
"version": "1.19.2",
"resolved": "https://registry.npmjs.org/@types/body-parser/-/body-parser-1.19.2.tgz",
"integrity": "sha512-ALYone6pm6QmwZoAgeyNksccT9Q4AWZQ6PvfwR37GT6r6FWUPguq6sUmNGSMV2Wr761oQoBxwGGa6DR5o1DC9g==",
"dev": true,
"requires": {
"@types/connect": "*",
"@types/node": "*"
@@ -838,6 +839,7 @@
"version": "3.4.35",
"resolved": "https://registry.npmjs.org/@types/connect/-/connect-3.4.35.tgz",
"integrity": "sha512-cdeYyv4KWoEgpBISTxWvqYsVy444DOqehiF3fM3ne10AmJ62RSyNkUnxMJXHQWRQQX2eR94m5y1IZyDwBjV9FQ==",
"dev": true,
"requires": {
"@types/node": "*"
}
@@ -864,6 +866,7 @@
"version": "4.17.13",
"resolved": "https://registry.npmjs.org/@types/express/-/express-4.17.13.tgz",
"integrity": "sha512-6bSZTPaTIACxn48l50SR+axgrqm6qXFIxrdAKaG6PaJk3+zuUr35hBlgT7vOmJcum+OEaIBLtHV/qloEAFITeA==",
"dev": true,
"requires": {
"@types/body-parser": "*",
"@types/express-serve-static-core": "^4.17.18",
@@ -871,18 +874,11 @@
"@types/serve-static": "*"
}
},
"@types/express-prometheus-middleware": {
"version": "1.2.1",
"resolved": "https://registry.npmjs.org/@types/express-prometheus-middleware/-/express-prometheus-middleware-1.2.1.tgz",
"integrity": "sha512-5bAqiUHo+UlGsWmVr9oV9eiFd7SnkIgU53RSp/txd8KMDU73Yrdva7WezIJazbW+CldGJu0zF3DPqk8KSJVYDQ==",
"requires": {
"@types/express": "*"
}
},
"@types/express-serve-static-core": {
"version": "4.17.30",
"resolved": "https://registry.npmjs.org/@types/express-serve-static-core/-/express-serve-static-core-4.17.30.tgz",
"integrity": "sha512-gstzbTWro2/nFed1WXtf+TtrpwxH7Ggs4RLYTLbeVgIkUQOI3WG/JKjgeOU1zXDvezllupjrf8OPIdvTbIaVOQ==",
"dev": true,
"requires": {
"@types/node": "*",
"@types/qs": "*",
@@ -925,7 +921,8 @@
"@types/mime": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@types/mime/-/mime-3.0.1.tgz",
"integrity": "sha512-Y4XFY5VJAuw0FgAqPNd6NNoV44jbq9Bz2L7Rh/J6jLTiHBSBJa9fxqQIvkIld4GsoDOcCbvzOUAbLPsSKKg+uA=="
"integrity": "sha512-Y4XFY5VJAuw0FgAqPNd6NNoV44jbq9Bz2L7Rh/J6jLTiHBSBJa9fxqQIvkIld4GsoDOcCbvzOUAbLPsSKKg+uA==",
"dev": true
},
"@types/minimist": {
"version": "1.2.2",
@@ -982,12 +979,14 @@
"@types/qs": {
"version": "6.9.7",
"resolved": "https://registry.npmjs.org/@types/qs/-/qs-6.9.7.tgz",
"integrity": "sha512-FGa1F62FT09qcrueBA6qYTrJPVDzah9a+493+o2PCXsesWHIn27G98TsSMs3WPNbZIEj4+VJf6saSFpvD+3Zsw=="
"integrity": "sha512-FGa1F62FT09qcrueBA6qYTrJPVDzah9a+493+o2PCXsesWHIn27G98TsSMs3WPNbZIEj4+VJf6saSFpvD+3Zsw==",
"dev": true
},
"@types/range-parser": {
"version": "1.2.4",
"resolved": "https://registry.npmjs.org/@types/range-parser/-/range-parser-1.2.4.tgz",
"integrity": "sha512-EEhsLsD6UsDM1yFhAvy0Cjr6VwmpMWqFBCb9w07wVugF7w9nfajxLuVmngTIpgS6svCnm6Vaw+MZhoDCKnOfsw=="
"integrity": "sha512-EEhsLsD6UsDM1yFhAvy0Cjr6VwmpMWqFBCb9w07wVugF7w9nfajxLuVmngTIpgS6svCnm6Vaw+MZhoDCKnOfsw==",
"dev": true
},
"@types/responselike": {
"version": "1.0.0",
@@ -1007,6 +1006,7 @@
"version": "1.15.0",
"resolved": "https://registry.npmjs.org/@types/serve-static/-/serve-static-1.15.0.tgz",
"integrity": "sha512-z5xyF6uh8CbjAu9760KDKsH2FcDxZ2tFCsA4HIMWE6IkiYMXfVoa+4f9KX+FN0ZLsaMw1WNG2ETLA6N+/YA+cg==",
"dev": true,
"requires": {
"@types/mime": "*",
"@types/node": "*"
@@ -1072,14 +1072,14 @@
}
},
"@typescript-eslint/eslint-plugin": {
"version": "5.33.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.33.1.tgz",
"integrity": "sha512-S1iZIxrTvKkU3+m63YUOxYPKaP+yWDQrdhxTglVDVEVBf+aCSw85+BmJnyUaQQsk5TXFG/LpBu9fa+LrAQ91fQ==",
"version": "5.34.0",
"resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.34.0.tgz",
"integrity": "sha512-eRfPPcasO39iwjlUAMtjeueRGuIrW3TQ9WseIDl7i5UWuFbf83yYaU7YPs4j8+4CxUMIsj1k+4kV+E+G+6ypDQ==",
"dev": true,
"requires": {
"@typescript-eslint/scope-manager": "5.33.1",
"@typescript-eslint/type-utils": "5.33.1",
"@typescript-eslint/utils": "5.33.1",
"@typescript-eslint/scope-manager": "5.34.0",
"@typescript-eslint/type-utils": "5.34.0",
"@typescript-eslint/utils": "5.34.0",
"debug": "^4.3.4",
"functional-red-black-tree": "^1.0.1",
"ignore": "^5.2.0",
@@ -1089,52 +1089,52 @@
}
},
"@typescript-eslint/parser": {
"version": "5.33.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-5.33.1.tgz",
"integrity": "sha512-IgLLtW7FOzoDlmaMoXdxG8HOCByTBXrB1V2ZQYSEV1ggMmJfAkMWTwUjjzagS6OkfpySyhKFkBw7A9jYmcHpZA==",
"version": "5.34.0",
"resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-5.34.0.tgz",
"integrity": "sha512-SZ3NEnK4usd2CXkoV3jPa/vo1mWX1fqRyIVUQZR4As1vyp4fneknBNJj+OFtV8WAVgGf+rOHMSqQbs2Qn3nFZQ==",
"dev": true,
"requires": {
"@typescript-eslint/scope-manager": "5.33.1",
"@typescript-eslint/types": "5.33.1",
"@typescript-eslint/typescript-estree": "5.33.1",
"@typescript-eslint/scope-manager": "5.34.0",
"@typescript-eslint/types": "5.34.0",
"@typescript-eslint/typescript-estree": "5.34.0",
"debug": "^4.3.4"
}
},
"@typescript-eslint/scope-manager": {
"version": "5.33.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-5.33.1.tgz",
"integrity": "sha512-8ibcZSqy4c5m69QpzJn8XQq9NnqAToC8OdH/W6IXPXv83vRyEDPYLdjAlUx8h/rbusq6MkW4YdQzURGOqsn3CA==",
"version": "5.34.0",
"resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-5.34.0.tgz",
"integrity": "sha512-HNvASMQlah5RsBW6L6c7IJ0vsm+8Sope/wu5sEAf7joJYWNb1LDbJipzmdhdUOnfrDFE6LR1j57x1EYVxrY4ow==",
"dev": true,
"requires": {
"@typescript-eslint/types": "5.33.1",
"@typescript-eslint/visitor-keys": "5.33.1"
"@typescript-eslint/types": "5.34.0",
"@typescript-eslint/visitor-keys": "5.34.0"
}
},
"@typescript-eslint/type-utils": {
"version": "5.33.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-5.33.1.tgz",
"integrity": "sha512-X3pGsJsD8OiqhNa5fim41YtlnyiWMF/eKsEZGsHID2HcDqeSC5yr/uLOeph8rNF2/utwuI0IQoAK3fpoxcLl2g==",
"version": "5.34.0",
"resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-5.34.0.tgz",
"integrity": "sha512-Pxlno9bjsQ7hs1pdWRUv9aJijGYPYsHpwMeCQ/Inavhym3/XaKt1ZKAA8FIw4odTBfowBdZJDMxf2aavyMDkLg==",
"dev": true,
"requires": {
"@typescript-eslint/utils": "5.33.1",
"@typescript-eslint/utils": "5.34.0",
"debug": "^4.3.4",
"tsutils": "^3.21.0"
}
},
"@typescript-eslint/types": {
"version": "5.33.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-5.33.1.tgz",
"integrity": "sha512-7K6MoQPQh6WVEkMrMW5QOA5FO+BOwzHSNd0j3+BlBwd6vtzfZceJ8xJ7Um2XDi/O3umS8/qDX6jdy2i7CijkwQ==",
"version": "5.34.0",
"resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-5.34.0.tgz",
"integrity": "sha512-49fm3xbbUPuzBIOcy2CDpYWqy/X7VBkxVN+DC21e0zIm3+61Z0NZi6J9mqPmSW1BDVk9FIOvuCFyUPjXz93sjA==",
"dev": true
},
"@typescript-eslint/typescript-estree": {
"version": "5.33.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-5.33.1.tgz",
"integrity": "sha512-JOAzJ4pJ+tHzA2pgsWQi4804XisPHOtbvwUyqsuuq8+y5B5GMZs7lI1xDWs6V2d7gE/Ez5bTGojSK12+IIPtXA==",
"version": "5.34.0",
"resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-5.34.0.tgz",
"integrity": "sha512-mXHAqapJJDVzxauEkfJI96j3D10sd567LlqroyCeJaHnu42sDbjxotGb3XFtGPYKPD9IyLjhsoULML1oI3M86A==",
"dev": true,
"requires": {
"@typescript-eslint/types": "5.33.1",
"@typescript-eslint/visitor-keys": "5.33.1",
"@typescript-eslint/types": "5.34.0",
"@typescript-eslint/visitor-keys": "5.34.0",
"debug": "^4.3.4",
"globby": "^11.1.0",
"is-glob": "^4.0.3",
@@ -1143,15 +1143,15 @@
}
},
"@typescript-eslint/utils": {
"version": "5.33.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-5.33.1.tgz",
"integrity": "sha512-uphZjkMaZ4fE8CR4dU7BquOV6u0doeQAr8n6cQenl/poMaIyJtBu8eys5uk6u5HiDH01Mj5lzbJ5SfeDz7oqMQ==",
"version": "5.34.0",
"resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-5.34.0.tgz",
"integrity": "sha512-kWRYybU4Rn++7lm9yu8pbuydRyQsHRoBDIo11k7eqBWTldN4xUdVUMCsHBiE7aoEkFzrUEaZy3iH477vr4xHAQ==",
"dev": true,
"requires": {
"@types/json-schema": "^7.0.9",
"@typescript-eslint/scope-manager": "5.33.1",
"@typescript-eslint/types": "5.33.1",
"@typescript-eslint/typescript-estree": "5.33.1",
"@typescript-eslint/scope-manager": "5.34.0",
"@typescript-eslint/types": "5.34.0",
"@typescript-eslint/typescript-estree": "5.34.0",
"eslint-scope": "^5.1.1",
"eslint-utils": "^3.0.0"
},
@@ -1175,12 +1175,12 @@
}
},
"@typescript-eslint/visitor-keys": {
"version": "5.33.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-5.33.1.tgz",
"integrity": "sha512-nwIxOK8Z2MPWltLKMLOEZwmfBZReqUdbEoHQXeCpa+sRVARe5twpJGHCB4dk9903Yaf0nMAlGbQfaAH92F60eg==",
"version": "5.34.0",
"resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-5.34.0.tgz",
"integrity": "sha512-O1moYjOSrab0a2fUvFpsJe0QHtvTC+cR+ovYpgKrAVXzqQyc74mv76TgY6z+aEtjQE2vgZux3CQVtGryqdcOAw==",
"dev": true,
"requires": {
"@typescript-eslint/types": "5.33.1",
"@typescript-eslint/types": "5.34.0",
"eslint-visitor-keys": "^3.3.0"
}
},
@@ -1623,9 +1623,9 @@
}
},
"caniuse-lite": {
"version": "1.0.30001378",
"resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001378.tgz",
"integrity": "sha512-JVQnfoO7FK7WvU4ZkBRbPjaot4+YqxogSDosHv0Hv5mWpUESmN+UubMU6L/hGz8QlQ2aY5U0vR6MOs6j/CXpNA==",
"version": "1.0.30001382",
"resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001382.tgz",
"integrity": "sha512-2rtJwDmSZ716Pxm1wCtbPvHtbDWAreTPxXbkc5RkKglow3Ig/4GNGazDI9/BVnXbG/wnv6r3B5FEbkfg9OcTGg==",
"dev": true
},
"chai": {
@@ -2284,9 +2284,9 @@
"integrity": "sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow=="
},
"electron-to-chromium": {
"version": "1.4.222",
"resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.222.tgz",
"integrity": "sha512-gEM2awN5HZknWdLbngk4uQCVfhucFAfFzuchP3wM3NN6eow1eDU0dFy2kts43FB20ZfhVFF0jmFSTb1h5OhyIg==",
"version": "1.4.226",
"resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.226.tgz",
"integrity": "sha512-CvevLaSiUp0u12K0e+QhMX1hn724nSUNO9ToBek+FMHk/5RofrQs5MChjrD0re0IwqxDFxFMSZD+uic05i2Z5w==",
"dev": true
},
"emoji-regex": {
@@ -2735,13 +2735,12 @@
}
}
},
"express-prometheus-middleware": {
"version": "1.2.0",
"resolved": "https://registry.npmjs.org/express-prometheus-middleware/-/express-prometheus-middleware-1.2.0.tgz",
"integrity": "sha512-efSwft67rdtiW40D0im1f7Rz1TCGHGzPj6lfK0MxZDcPj6z4f/Ab5VNkWPYZEjvLqZiZ7fbS00CYzpigO8tS+g==",
"express-prom-bundle": {
"version": "6.5.0",
"resolved": "https://registry.npmjs.org/express-prom-bundle/-/express-prom-bundle-6.5.0.tgz",
"integrity": "sha512-paFAm0FK7TV1Ln6Blh9edDt2mJ4Pk6Py/fjhZDMcoMHENYryBjCpnXDXuCu8NE1kkvp58IrPcAAkNeNqdvZnnw==",
"requires": {
"prometheus-gc-stats": "^0.6.2",
"response-time": "^2.3.2",
"on-finished": "^2.3.0",
"url-value-parser": "^2.0.0"
}
},
@@ -3008,487 +3007,6 @@
"wide-align": "^1.1.5"
}
},
"gc-stats": {
"version": "1.4.0",
"resolved": "https://registry.npmjs.org/gc-stats/-/gc-stats-1.4.0.tgz",
"integrity": "sha512-4FcCj9e8j8rCjvLkqRpGZBLgTC/xr9XEf5By3x77cDucWWB3pJK6FEwXZCTCbb4z8xdaOoi4owBNrvn3ciDdxA==",
"optional": true,
"requires": {
"nan": "^2.13.2",
"node-pre-gyp": "^0.13.0"
},
"dependencies": {
"abbrev": {
"version": "1.1.1",
"bundled": true,
"optional": true
},
"ansi-regex": {
"version": "2.1.1",
"bundled": true,
"optional": true
},
"aproba": {
"version": "1.2.0",
"bundled": true,
"optional": true
},
"are-we-there-yet": {
"version": "1.1.5",
"bundled": true,
"optional": true,
"requires": {
"delegates": "^1.0.0",
"readable-stream": "^2.0.6"
}
},
"balanced-match": {
"version": "1.0.0",
"bundled": true,
"optional": true
},
"brace-expansion": {
"version": "1.1.11",
"bundled": true,
"optional": true,
"requires": {
"balanced-match": "^1.0.0",
"concat-map": "0.0.1"
}
},
"chownr": {
"version": "1.1.1",
"bundled": true,
"optional": true
},
"code-point-at": {
"version": "1.1.0",
"bundled": true,
"optional": true
},
"concat-map": {
"version": "0.0.1",
"bundled": true,
"optional": true
},
"console-control-strings": {
"version": "1.1.0",
"bundled": true,
"optional": true
},
"core-util-is": {
"version": "1.0.2",
"bundled": true,
"optional": true
},
"debug": {
"version": "4.1.1",
"bundled": true,
"optional": true,
"requires": {
"ms": "^2.1.1"
}
},
"deep-extend": {
"version": "0.6.0",
"bundled": true,
"optional": true
},
"delegates": {
"version": "1.0.0",
"bundled": true,
"optional": true
},
"detect-libc": {
"version": "1.0.3",
"bundled": true,
"optional": true
},
"fs-minipass": {
"version": "1.2.5",
"bundled": true,
"optional": true,
"requires": {
"minipass": "^2.2.1"
}
},
"fs.realpath": {
"version": "1.0.0",
"bundled": true,
"optional": true
},
"gauge": {
"version": "2.7.4",
"bundled": true,
"optional": true,
"requires": {
"aproba": "^1.0.3",
"console-control-strings": "^1.0.0",
"has-unicode": "^2.0.0",
"object-assign": "^4.1.0",
"signal-exit": "^3.0.0",
"string-width": "^1.0.1",
"strip-ansi": "^3.0.1",
"wide-align": "^1.1.0"
}
},
"glob": {
"version": "7.1.3",
"bundled": true,
"optional": true,
"requires": {
"fs.realpath": "^1.0.0",
"inflight": "^1.0.4",
"inherits": "2",
"minimatch": "^3.0.4",
"once": "^1.3.0",
"path-is-absolute": "^1.0.0"
}
},
"has-unicode": {
"version": "2.0.1",
"bundled": true,
"optional": true
},
"iconv-lite": {
"version": "0.4.24",
"bundled": true,
"optional": true,
"requires": {
"safer-buffer": ">= 2.1.2 < 3"
}
},
"ignore-walk": {
"version": "3.0.1",
"bundled": true,
"optional": true,
"requires": {
"minimatch": "^3.0.4"
}
},
"inflight": {
"version": "1.0.6",
"bundled": true,
"optional": true,
"requires": {
"once": "^1.3.0",
"wrappy": "1"
}
},
"inherits": {
"version": "2.0.3",
"bundled": true,
"optional": true
},
"ini": {
"version": "1.3.5",
"bundled": true,
"optional": true
},
"is-fullwidth-code-point": {
"version": "1.0.0",
"bundled": true,
"optional": true,
"requires": {
"number-is-nan": "^1.0.0"
}
},
"isarray": {
"version": "1.0.0",
"bundled": true,
"optional": true
},
"minimatch": {
"version": "3.0.4",
"bundled": true,
"optional": true,
"requires": {
"brace-expansion": "^1.1.7"
}
},
"minimist": {
"version": "0.0.8",
"bundled": true,
"optional": true
},
"minipass": {
"version": "2.3.5",
"bundled": true,
"optional": true,
"requires": {
"safe-buffer": "^5.1.2",
"yallist": "^3.0.0"
}
},
"minizlib": {
"version": "1.2.1",
"bundled": true,
"optional": true,
"requires": {
"minipass": "^2.2.1"
}
},
"mkdirp": {
"version": "0.5.1",
"bundled": true,
"optional": true,
"requires": {
"minimist": "0.0.8"
}
},
"ms": {
"version": "2.1.1",
"bundled": true,
"optional": true
},
"needle": {
"version": "2.3.1",
"bundled": true,
"optional": true,
"requires": {
"debug": "^4.1.0",
"iconv-lite": "^0.4.4",
"sax": "^1.2.4"
}
},
"node-pre-gyp": {
"version": "0.13.0",
"bundled": true,
"optional": true,
"requires": {
"detect-libc": "^1.0.2",
"mkdirp": "^0.5.1",
"needle": "^2.2.1",
"nopt": "^4.0.1",
"npm-packlist": "^1.1.6",
"npmlog": "^4.0.2",
"rc": "^1.2.7",
"rimraf": "^2.6.1",
"semver": "^5.3.0",
"tar": "^4"
}
},
"nopt": {
"version": "4.0.1",
"bundled": true,
"optional": true,
"requires": {
"abbrev": "1",
"osenv": "^0.1.4"
}
},
"npm-bundled": {
"version": "1.0.6",
"bundled": true,
"optional": true
},
"npm-packlist": {
"version": "1.4.1",
"bundled": true,
"optional": true,
"requires": {
"ignore-walk": "^3.0.1",
"npm-bundled": "^1.0.1"
}
},
"npmlog": {
"version": "4.1.2",
"bundled": true,
"optional": true,
"requires": {
"are-we-there-yet": "~1.1.2",
"console-control-strings": "~1.1.0",
"gauge": "~2.7.3",
"set-blocking": "~2.0.0"
}
},
"number-is-nan": {
"version": "1.0.1",
"bundled": true,
"optional": true
},
"object-assign": {
"version": "4.1.1",
"bundled": true,
"optional": true
},
"once": {
"version": "1.4.0",
"bundled": true,
"optional": true,
"requires": {
"wrappy": "1"
}
},
"os-homedir": {
"version": "1.0.2",
"bundled": true,
"optional": true
},
"os-tmpdir": {
"version": "1.0.2",
"bundled": true,
"optional": true
},
"osenv": {
"version": "0.1.5",
"bundled": true,
"optional": true,
"requires": {
"os-homedir": "^1.0.0",
"os-tmpdir": "^1.0.0"
}
},
"path-is-absolute": {
"version": "1.0.1",
"bundled": true,
"optional": true
},
"process-nextick-args": {
"version": "2.0.0",
"bundled": true,
"optional": true
},
"rc": {
"version": "1.2.8",
"bundled": true,
"optional": true,
"requires": {
"deep-extend": "^0.6.0",
"ini": "~1.3.0",
"minimist": "^1.2.0",
"strip-json-comments": "~2.0.1"
},
"dependencies": {
"minimist": {
"version": "1.2.0",
"bundled": true,
"optional": true
}
}
},
"readable-stream": {
"version": "2.3.6",
"bundled": true,
"optional": true,
"requires": {
"core-util-is": "~1.0.0",
"inherits": "~2.0.3",
"isarray": "~1.0.0",
"process-nextick-args": "~2.0.0",
"safe-buffer": "~5.1.1",
"string_decoder": "~1.1.1",
"util-deprecate": "~1.0.1"
}
},
"rimraf": {
"version": "2.6.3",
"bundled": true,
"optional": true,
"requires": {
"glob": "^7.1.3"
}
},
"safe-buffer": {
"version": "5.1.2",
"bundled": true,
"optional": true
},
"safer-buffer": {
"version": "2.1.2",
"bundled": true,
"optional": true
},
"sax": {
"version": "1.2.4",
"bundled": true,
"optional": true
},
"semver": {
"version": "5.7.0",
"bundled": true,
"optional": true
},
"set-blocking": {
"version": "2.0.0",
"bundled": true,
"optional": true
},
"signal-exit": {
"version": "3.0.2",
"bundled": true,
"optional": true
},
"string-width": {
"version": "1.0.2",
"bundled": true,
"optional": true,
"requires": {
"code-point-at": "^1.0.0",
"is-fullwidth-code-point": "^1.0.0",
"strip-ansi": "^3.0.0"
}
},
"string_decoder": {
"version": "1.1.1",
"bundled": true,
"optional": true,
"requires": {
"safe-buffer": "~5.1.0"
}
},
"strip-ansi": {
"version": "3.0.1",
"bundled": true,
"optional": true,
"requires": {
"ansi-regex": "^2.0.0"
}
},
"strip-json-comments": {
"version": "2.0.1",
"bundled": true,
"optional": true
},
"tar": {
"version": "4.4.8",
"bundled": true,
"optional": true,
"requires": {
"chownr": "^1.1.1",
"fs-minipass": "^1.2.5",
"minipass": "^2.3.4",
"minizlib": "^1.1.1",
"mkdirp": "^0.5.0",
"safe-buffer": "^5.1.2",
"yallist": "^3.0.2"
}
},
"util-deprecate": {
"version": "1.0.2",
"bundled": true,
"optional": true
},
"wide-align": {
"version": "1.1.3",
"bundled": true,
"optional": true,
"requires": {
"string-width": "^1.0.2 || 2"
}
},
"wrappy": {
"version": "1.0.2",
"bundled": true,
"optional": true
},
"yallist": {
"version": "3.0.3",
"bundled": true,
"optional": true
}
}
},
"gensync": {
"version": "1.0.0-beta.2",
"resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.2.tgz",
@@ -4305,9 +3823,9 @@
"dev": true
},
"keyv": {
"version": "4.3.3",
"resolved": "https://registry.npmjs.org/keyv/-/keyv-4.3.3.tgz",
"integrity": "sha512-AcysI17RvakTh8ir03+a3zJr5r0ovnAH/XTXei/4HIv3bL2K/jzvgivLK9UuI/JbU1aJjM3NSAnVvVVd3n+4DQ==",
"version": "4.4.1",
"resolved": "https://registry.npmjs.org/keyv/-/keyv-4.4.1.tgz",
"integrity": "sha512-PzByhNxfBLnSBW2MZi1DF+W5+qB/7BMpOokewqIvqS8GFtP7xHm2oeGU72Y1fhtfOv/FiEnI4+nyViYDmUChnw==",
"requires": {
"compress-brotli": "^1.3.8",
"json-buffer": "3.0.1"
@@ -4728,9 +4246,9 @@
}
},
"minipass-fetch": {
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/minipass-fetch/-/minipass-fetch-2.1.0.tgz",
"integrity": "sha512-H9U4UVBGXEyyWJnqYDCLp1PwD8XIkJ4akNHp1aGVI+2Ym7wQMlxDKi4IB4JbmyU+pl9pEs/cVrK6cOuvmbK4Sg==",
"version": "2.1.2",
"resolved": "https://registry.npmjs.org/minipass-fetch/-/minipass-fetch-2.1.2.tgz",
"integrity": "sha512-LT49Zi2/WMROHYoqGgdlQIZh8mLPZmOrN2NdJjMXxYe4nkN6FUyuPuOAOedNJDrx0IRGg9+4guZewtp8hE6TxA==",
"requires": {
"encoding": "^0.1.13",
"minipass": "^3.1.6",
@@ -5350,12 +4868,6 @@
"resolved": "https://registry.npmjs.org/openapi-types/-/openapi-types-12.0.0.tgz",
"integrity": "sha512-6Wd9k8nmGQHgCbehZCP6wwWcfXcvinhybUTBatuhjRsCxUIujuYFZc9QnGeae75CyHASewBtxs0HX/qwREReUw=="
},
"optional": {
"version": "0.1.4",
"resolved": "https://registry.npmjs.org/optional/-/optional-0.1.4.tgz",
"integrity": "sha512-gtvrrCfkE08wKcgXaVwQVgwEQ8vel2dc5DDBn9RLQZ3YtmtkBss6A2HY6BnJH4N/4Ku97Ri/SF8sNWE2225WJw==",
"optional": true
},
"optionator": {
"version": "0.9.1",
"resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.1.tgz",
@@ -5631,16 +5143,6 @@
"tdigest": "^0.1.1"
}
},
"prometheus-gc-stats": {
"version": "0.6.3",
"resolved": "https://registry.npmjs.org/prometheus-gc-stats/-/prometheus-gc-stats-0.6.3.tgz",
"integrity": "sha512-vCX+HZ1jZHkha25r5dAcRSNjue+K3Hn0B33EcZl7y3hgp3o1YsQ4Y3x7oJWKvDdbelFIL0McsXGmRg3zBrmq+g==",
"optional": true,
"requires": {
"gc-stats": "^1.4.0",
"optional": "^0.1.3"
}
},
"promise-inflight": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/promise-inflight/-/promise-inflight-1.0.1.tgz",
@@ -5919,9 +5421,9 @@
}
},
"redoc-cli": {
"version": "0.13.18",
"resolved": "https://registry.npmjs.org/redoc-cli/-/redoc-cli-0.13.18.tgz",
"integrity": "sha512-ywV4WnIGKlfVUJ8w3mrkDT4hBYVLqkOgOvcIGaiG+D77ZrkwiH6p0TzjlE8BDrAfhSAgrLza5ncPVjLz843OXg==",
"version": "0.13.19",
"resolved": "https://registry.npmjs.org/redoc-cli/-/redoc-cli-0.13.19.tgz",
"integrity": "sha512-CiVC66jwtC1jcdCAGr35ZbYLrG6lG8LJTJtOOe5a5IhoZJqslhBJx9GW4eMaUsNbiv8jabmutxIqKiGQYcMkAw==",
"dev": true,
"requires": {
"chokidar": "^3.5.1",
@@ -5932,7 +5434,7 @@
"node-libs-browser": "^2.2.1",
"react": "^17.0.1",
"react-dom": "^17.0.1",
"redoc": "2.0.0-rc.75",
"redoc": "2.0.0-rc.76",
"styled-components": "^5.3.0",
"update-notifier": "^5.0.1",
"yargs": "^17.3.1"
@@ -8359,9 +7861,9 @@
}
},
"redoc": {
"version": "2.0.0-rc.75",
"resolved": "https://registry.npmjs.org/redoc/-/redoc-2.0.0-rc.75.tgz",
"integrity": "sha512-TCVNjvcBL9x5zSBiPMktA3zyykNN352mXyisfXgriZolct9bASqMdII+a4+tvUH1sA8YgdE1A4mW3YfXD6cR4w==",
"version": "2.0.0-rc.76",
"resolved": "https://registry.npmjs.org/redoc/-/redoc-2.0.0-rc.76.tgz",
"integrity": "sha512-7PbH/0GUaH9GoGjaCI8tfCvkzVQY3BGhiBX9lLgpJ6oGAhvioiac7kjTwltRxl5+sDr58AyyB/4XyTBEPqbupw==",
"dev": true,
"requires": {
"@redocly/openapi-core": "^1.0.0-beta.104",
@@ -9248,15 +8750,6 @@
"resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz",
"integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g=="
},
"response-time": {
"version": "2.3.2",
"resolved": "https://registry.npmjs.org/response-time/-/response-time-2.3.2.tgz",
"integrity": "sha512-MUIDaDQf+CVqflfTdQ5yam+aYCkXj1PY8fjlPDQ6ppxJlmgZb864pHtA750mayywNg8tx4rS7qH9JXd/OF+3gw==",
"requires": {
"depd": "~1.1.0",
"on-headers": "~1.0.1"
}
},
"responselike": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/responselike/-/responselike-2.0.1.tgz",
@@ -9600,9 +9093,9 @@
}
},
"spdx-license-ids": {
"version": "3.0.11",
"resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.11.tgz",
"integrity": "sha512-Ctl2BrFiM0X3MANYgj3CkygxhRmr9mi6xhejbdO960nF6EDJApTYpn0BQnDKlnNBULKiCN1n3w9EBkHK8ZWg+g==",
"version": "3.0.12",
"resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.12.tgz",
"integrity": "sha512-rr+VVSXtRhO4OHbXUiAF7xW3Bo9DuuF6C5jH+q/x15j2jniycgKbxU09Hr0WqlSLUs4i4ltHGXqTe7VHclYWyA==",
"dev": true
},
"split": {
@@ -10045,9 +9538,9 @@
}
},
"marked": {
"version": "4.0.18",
"resolved": "https://registry.npmjs.org/marked/-/marked-4.0.18.tgz",
"integrity": "sha512-wbLDJ7Zh0sqA0Vdg6aqlbT+yPxqLblpAZh1mK2+AO2twQkPywvvqQNfEPVwSSRjZ7dZcdeVBIAgiO7MMp3Dszw==",
"version": "4.0.19",
"resolved": "https://registry.npmjs.org/marked/-/marked-4.0.19.tgz",
"integrity": "sha512-rgQF/OxOiLcvgUAj1Q1tAf4Bgxn5h5JZTp04Fx4XUkVhs7B+7YA9JEWJhJpoO8eJt8MkZMwqLCNeNqj1bCREZQ==",
"dev": true
},
"minimatch": {

View File

@@ -1,6 +1,6 @@
{
"name": "@openstapps/backend",
"version": "0.2.0",
"version": "0.3.1",
"description": "A reference implementation for a StApps backend",
"license": "AGPL-3.0-only",
"author": "André Bierlein <andre.mt.bierlein@gmail.com>",
@@ -34,15 +34,14 @@
},
"dependencies": {
"@elastic/elasticsearch": "5.6.22",
"@openstapps/core": "0.69.0",
"@openstapps/core": "0.70.0",
"@openstapps/core-tools": "0.32.0",
"@openstapps/logger": "1.0.0",
"@types/express-prometheus-middleware": "1.2.1",
"@types/node": "14.18.24",
"config": "3.3.7",
"cors": "2.8.5",
"express": "4.18.1",
"express-prometheus-middleware": "1.2.0",
"express-prom-bundle": "6.5.0",
"express-promise-router": "4.1.1",
"got": "11.8.5",
"moment": "2.29.4",
@@ -76,8 +75,8 @@
"@types/sinon-express-mock": "1.3.9",
"@types/supertest": "2.0.12",
"@types/uuid": "8.3.4",
"@typescript-eslint/eslint-plugin": "5.33.1",
"@typescript-eslint/parser": "5.33.1",
"@typescript-eslint/eslint-plugin": "5.34.0",
"@typescript-eslint/parser": "5.34.0",
"chai": "4.3.6",
"chai-as-promised": "7.1.1",
"conventional-changelog-cli": "2.2.2",
@@ -92,7 +91,7 @@
"nyc": "15.1.0",
"prepend-file-cli": "1.0.6",
"prettier": "2.7.1",
"redoc-cli": "0.13.18",
"redoc-cli": "0.13.19",
"rimraf": "3.0.2",
"sinon": "14.0.0",
"sinon-express-mock": "2.2.1",

View File

@@ -13,13 +13,10 @@
* this program. If not, see <https://www.gnu.org/licenses/>.
*/
import {Logger} from '@openstapps/logger';
import express from 'express';
import expressPrometheusMiddleware from 'express-prometheus-middleware';
import express_prom_bundle from 'express-prom-bundle';
import fs from 'fs';
import path from 'path';
type UserOptions = Parameters<typeof expressPrometheusMiddleware>[0];
/**
* Create and configure a new Express Prometheus Middleware instance
*
@@ -29,15 +26,15 @@ type UserOptions = Parameters<typeof expressPrometheusMiddleware>[0];
*
* @returns express.Express
*/
export function getPrometheusMiddleware(): express.Express {
export function getPrometheusMiddleware(): express_prom_bundle.Middleware {
const configFileName = path.join('./config', 'prometheus.json');
let options: UserOptions = {};
let options: express_prom_bundle.Opts = {};
try {
options = JSON.parse(fs.readFileSync(configFileName, 'utf8'));
} catch (error) {
Logger.warn('Could not get options for Prometheus Middleware.', error);
Logger.warn("Couldn't get options from config file for Prometheus Middleware.", error);
}
return expressPrometheusMiddleware(options);
return express_prom_bundle(options);
}