@tramvai/module-server 1.97.0 → 1.101.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/server.es.js CHANGED
@@ -9,8 +9,8 @@ import { CacheWarmupModule } from '@tramvai/module-cache-warmup';
9
9
  import http from 'http';
10
10
  import fastify from 'fastify';
11
11
  import express from 'express';
12
- import { fastifyCookie } from 'fastify-cookie';
13
- import fastifyFormBody from 'fastify-formbody';
12
+ import { fastifyCookie } from '@fastify/cookie';
13
+ import fastifyFormBody from '@fastify/formbody';
14
14
  import fp from 'fastify-plugin';
15
15
  import symbols from 'fastify/lib/symbols';
16
16
  import isNil from '@tinkoff/utils/is/nil';
@@ -25,7 +25,7 @@ import { create, middlewares, getPapiParameters, createPapiMethod } from '@tramv
25
25
  import { createChildContainer } from '@tinkoff/dippy';
26
26
  import eachObj from '@tinkoff/utils/object/each';
27
27
  import { resolve } from 'path';
28
- import FastifyStatic from 'fastify-static';
28
+ import FastifyStatic from '@fastify/static';
29
29
  import { createTerminus } from '@tinkoff/terminus';
30
30
  import { parse } from '@tinkoff/url';
31
31
  import { EventEmitter } from 'events';
@@ -789,7 +789,7 @@ ServerProxyModule = __decorate([
789
789
  Module({
790
790
  providers: [
791
791
  {
792
- // TODO: tramvai@2 migrate to `fastify` and `fastify-http-proxy`
792
+ // TODO: tramvai@2 migrate to `fastify` and `@fastify/http-proxy`
793
793
  // interfaces for the proxies are not compatible so some migration from the app is needed
794
794
  provide: WEB_APP_BEFORE_INIT_TOKEN,
795
795
  useFactory: ({ app, defaultProxies }) => {
package/lib/server.js CHANGED
@@ -12,8 +12,8 @@ var moduleCacheWarmup = require('@tramvai/module-cache-warmup');
12
12
  var http = require('http');
13
13
  var fastify = require('fastify');
14
14
  var express = require('express');
15
- var fastifyCookie = require('fastify-cookie');
16
- var fastifyFormBody = require('fastify-formbody');
15
+ var cookie = require('@fastify/cookie');
16
+ var fastifyFormBody = require('@fastify/formbody');
17
17
  var fp = require('fastify-plugin');
18
18
  var symbols = require('fastify/lib/symbols');
19
19
  var isNil = require('@tinkoff/utils/is/nil');
@@ -28,7 +28,7 @@ var papi = require('@tramvai/papi');
28
28
  var dippy = require('@tinkoff/dippy');
29
29
  var eachObj = require('@tinkoff/utils/object/each');
30
30
  var path = require('path');
31
- var FastifyStatic = require('fastify-static');
31
+ var FastifyStatic = require('@fastify/static');
32
32
  var terminus = require('@tinkoff/terminus');
33
33
  var url = require('@tinkoff/url');
34
34
  var events = require('events');
@@ -244,7 +244,7 @@ const webAppInitCommand = ({ app, expressApp, logger, commandLineRunner, beforeI
244
244
  });
245
245
  await app.register(async (instance) => {
246
246
  await runHandlers(instance, limiterRequest, expressLimiterRequest);
247
- await app.register(fastifyCookie.fastifyCookie);
247
+ await app.register(cookie.fastifyCookie);
248
248
  await app.register(fastifyFormBody__default["default"], { bodyLimit: 2097152 }); // 2mb
249
249
  await runHandlers(instance, init, expressInit);
250
250
  // force express to execute to update server's request and response instances
@@ -814,7 +814,7 @@ ServerProxyModule = tslib.__decorate([
814
814
  core.Module({
815
815
  providers: [
816
816
  {
817
- // TODO: tramvai@2 migrate to `fastify` and `fastify-http-proxy`
817
+ // TODO: tramvai@2 migrate to `fastify` and `@fastify/http-proxy`
818
818
  // interfaces for the proxies are not compatible so some migration from the app is needed
819
819
  provide: tokensServer.WEB_APP_BEFORE_INIT_TOKEN,
820
820
  useFactory: ({ app, defaultProxies }) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tramvai/module-server",
3
- "version": "1.97.0",
3
+ "version": "1.101.2",
4
4
  "description": "",
5
5
  "browser": "lib/browser.js",
6
6
  "main": "lib/server.js",
@@ -21,30 +21,30 @@
21
21
  "dependencies": {
22
22
  "@tinkoff/errors": "0.2.20",
23
23
  "@tinkoff/monkeypatch": "1.3.3",
24
- "@tinkoff/terminus": "0.0.2",
24
+ "@tinkoff/terminus": "0.0.3",
25
25
  "@tinkoff/url": "0.7.37",
26
- "@tramvai/module-cache-warmup": "1.97.0",
27
- "@tramvai/module-metrics": "1.97.0",
28
- "@tramvai/papi": "1.97.0",
29
- "@tramvai/tokens-server": "1.97.0",
30
- "@tramvai/tokens-server-private": "1.97.0",
26
+ "@tramvai/module-cache-warmup": "1.101.2",
27
+ "@tramvai/module-metrics": "1.101.2",
28
+ "@tramvai/papi": "1.101.2",
29
+ "@tramvai/tokens-server": "1.101.2",
30
+ "@tramvai/tokens-server-private": "1.101.2",
31
31
  "compression": "^1.7.4",
32
32
  "express": "^4.17.1",
33
- "fastify": "^3.27.4",
34
- "fastify-cookie": "^5.6.0",
35
- "fastify-formbody": "^5.2.0",
33
+ "fastify": "^3.29.0",
36
34
  "fastify-plugin": "^3.0.1",
37
- "fastify-static": "^4.6.1",
35
+ "@fastify/cookie": "^6.0.0",
36
+ "@fastify/formbody": "^6.0.1",
37
+ "@fastify/static": "^5.0.2",
38
38
  "http-proxy-middleware": "^2.0.2"
39
39
  },
40
40
  "peerDependencies": {
41
41
  "@tinkoff/dippy": "0.7.39",
42
42
  "@tinkoff/utils": "^2.1.2",
43
- "@tramvai/cli": "1.97.0",
44
- "@tramvai/core": "1.97.0",
45
- "@tramvai/module-common": "1.97.0",
46
- "@tramvai/module-environment": "1.97.0",
47
- "@tramvai/tokens-common": "1.97.0",
43
+ "@tramvai/cli": "1.101.2",
44
+ "@tramvai/core": "1.101.2",
45
+ "@tramvai/module-common": "1.101.2",
46
+ "@tramvai/module-environment": "1.101.2",
47
+ "@tramvai/tokens-common": "1.101.2",
48
48
  "tslib": "^2.0.3"
49
49
  },
50
50
  "devDependencies": {