Revert "MAX_OBJECT_SIZE_MB should be configurable in the fileimport service (#1837)" (#1838)

This reverts commit 4973622c18.
This commit is contained in:
Iain Sproat
2023-10-26 16:24:18 +01:00
committed by GitHub
parent 4973622c18
commit 7bad5abed6
7 changed files with 4 additions and 23 deletions
-2
View File
@@ -51,7 +51,6 @@ services:
S3_CREATE_BUCKET: 'true'
S3_REGION: '' # optional, defaults to 'us-east-1'
FILE_SIZE_LIMIT_MB: 100
MAX_OBJECT_SIZE_MB: 10
EMAIL_FROM: 'no-reply@example.org'
preview-service:
@@ -87,4 +86,3 @@ services:
PG_CONNECTION_STRING: 'postgres://speckle:speckle@postgres/speckle'
SPECKLE_SERVER_URL: 'http://speckle-server:3000'
FILE_IMPORT_TIME_LIMIT_MIN: 10
MAX_OBJECT_SIZE_MB: 10
+1 -2
View File
@@ -4,7 +4,6 @@ const crs = require('crypto-random-string')
const bcrypt = require('bcrypt')
const { chunk } = require('lodash')
const { logger: parentLogger } = require('../observability/logging')
const { getMaximumObjectSizeMB } = require('@/modules/shared/helpers/envHelper')
const knex = require('../knex')
const { Observability } = require('@speckle/shared')
@@ -151,7 +150,7 @@ module.exports = class ServerAPI {
}
prepInsertionObject(streamId, obj) {
const MAX_OBJECT_SIZE = getMaximumObjectSizeMB() * 1024 * 1024
const MAX_OBJECT_SIZE = 10 * 1024 * 1024
if (obj.hash) obj.id = obj.hash
else
@@ -91,7 +91,6 @@ services:
S3_REGION: '' # optional, defaults to 'us-east-1'
FILE_SIZE_LIMIT_MB: 100
MAX_OBJECT_SIZE_MB: 10
speckle-preview-service:
image: speckle/speckle-preview-service:2
@@ -85,9 +85,6 @@ spec:
- name: FILE_IMPORT_TIME_LIMIT_MIN
value: {{ .Values.fileimport_service.time_limit_min | quote }}
- name: MAX_OBJECT_SIZE_MB
value: {{ .Values.max_object_size_mb | quote }}
{{- if .Values.fileimport_service.affinity }}
affinity: {{- include "speckle.renderTpl" (dict "value" .Values.fileimport_service.affinity "context" $) | nindent 8 }}
{{- end }}
@@ -123,12 +123,8 @@ spec:
value: {{ .Values.file_size_limit_mb | quote }}
- name: MAX_OBJECT_SIZE_MB
{{- if .Values.max_object_size_mb }}
value: {{ .Values.max_object_size_mb | quote }}
{{- else }}
{{- /* provided for backwards-compatibility */ -}}
value: {{ .Values.server.max_object_size_mb | quote }}
{{- end }}
- name: SPECKLE_AUTOMATE_URL
value: {{ .Values.server.speckleAutomateUrl }}
+1 -6
View File
@@ -97,11 +97,6 @@
"description": "This maximum size of any single file (unit is Megabytes) that can be uploaded to Speckle",
"default": 100
},
"max_object_size_mb": {
"type": "number",
"description": "The maximum size of an individual object which can be uploaded to the server via the API or fileimport service.",
"default": 10
},
"enable_prometheus_monitoring": {
"type": "boolean",
"description": "If enabled, Speckle deploys a Prometheus ServiceMonitor resource",
@@ -513,7 +508,7 @@
},
"max_object_size_mb": {
"type": "number",
"description": "**DEPRECATED** Use max_object_size_mb at the root instead. The maximum size of an individual object which can be uploaded to the server.",
"description": "The maximum size of an individual object which can be uploaded to the server",
"default": 10
},
"speckleAutomateUrl": {
+1 -4
View File
@@ -84,9 +84,6 @@ secretName: server-vars
##
file_size_limit_mb: 100
## @param max_object_size_mb The maximum size of an individual object which can be uploaded to the server via the API or fileimport service.
max_object_size_mb: 10
## @section Monitoring
## @descriptionStart
## This enables metrics generated by Speckle to be ingested by Prometheus: https://prometheus.io/
@@ -396,7 +393,7 @@ server:
adminOverrideEnabled: false
## @param server.onboardingStreamId The id of the stream to be used for onboarding new users
onboardingStreamId: ''
## @param server.max_object_size_mb **DEPRECATED** Use max_object_size_mb at the root instead. The maximum size of an individual object which can be uploaded to the server.
## @param server.max_object_size_mb The maximum size of an individual object which can be uploaded to the server
max_object_size_mb: 10
## @param server.speckleAutomateUrl The url of the Speckle Automate instance
speckleAutomateUrl: 'https://automate.speckle.systems'