Skip to content

Commit e57d4fb

Browse files
committed
fix(job): log was too long (closes bleenco#556)
1 parent 88876b9 commit e57d4fb

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

server/store/job/job.go

+3
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,9 @@ func (s jobStore) Create(job *core.Job) error {
5252
func (s jobStore) Update(job *core.Job) error {
5353
log := []byte(job.Log)
5454

55+
if len(job.Log) > 16777215 {
56+
job.Log = job.Log[0:16777215]
57+
}
5558
err := s.db.Model(job).Updates(map[string]interface{}{
5659
"status": job.Status,
5760
"start_time": job.StartTime,

0 commit comments

Comments
 (0)