Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
C
console
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
MyCard
console
Commits
13e4c829
Commit
13e4c829
authored
Oct 09, 2025
by
nanahira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
change default partSize
parent
9863c81c
Pipeline
#40973
passed with stages
in 2 minutes and 47 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
6 deletions
+2
-6
console-api/src/s3/s3.service.ts
console-api/src/s3/s3.service.ts
+2
-6
No files found.
console-api/src/s3/s3.service.ts
View file @
13e4c829
import
{
ConsoleLogger
}
from
'
@nestjs/common
'
;
import
{
ConsoleLogger
}
from
'
@nestjs/common
'
;
import
{
ConfigService
}
from
'
@nestjs/config
'
;
import
{
ConfigService
}
from
'
@nestjs/config
'
;
import
{
import
{
_Object
,
DeleteObjectsCommand
,
DeleteObjectsCommand
,
GetObjectCommand
,
GetObjectCommand
,
HeadObjectCommand
,
HeadObjectCommand
,
...
@@ -15,11 +14,6 @@ import { createHash } from 'crypto';
...
@@ -15,11 +14,6 @@ import { createHash } from 'crypto';
import
internal
from
'
stream
'
;
import
internal
from
'
stream
'
;
import
{
Upload
}
from
'
@aws-sdk/lib-storage
'
;
import
{
Upload
}
from
'
@aws-sdk/lib-storage
'
;
export
interface
S3StreamUploadResult
{
url
:
string
;
object
:
_Object
;
}
export
class
S3Service
extends
ConsoleLogger
{
export
class
S3Service
extends
ConsoleLogger
{
private
getConfig
(
field
:
string
)
{
private
getConfig
(
field
:
string
)
{
return
this
.
config
.
get
(
`
${
this
.
servicePrefix
}
_
${
field
}
`
)
||
this
.
config
.
get
(
field
);
return
this
.
config
.
get
(
`
${
this
.
servicePrefix
}
_
${
field
}
`
)
||
this
.
config
.
get
(
field
);
...
@@ -176,6 +170,8 @@ export class S3Service extends ConsoleLogger {
...
@@ -176,6 +170,8 @@ export class S3Service extends ConsoleLogger {
Body
:
stream
,
Body
:
stream
,
...
extras
,
...
extras
,
},
},
queueSize
:
4
,
partSize
:
16
*
1024
*
1024
,
});
});
await
upload
.
done
();
await
upload
.
done
();
const
object
=
await
this
.
s3
.
send
(
const
object
=
await
this
.
s3
.
send
(
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment