Pull request #435: RED-3842 filesize
Merge in RED/persistence-service from RED-3842 to master * commit 'bba7124cac88cdd5fad07759a66275436bfcac74': RED-3842 filesize
This commit is contained in:
commit
4e7f5954d1
@ -25,7 +25,7 @@ public class FileModel {
|
|||||||
private ProcessingStatus processingStatus;
|
private ProcessingStatus processingStatus;
|
||||||
private WorkflowStatus workflowStatus;
|
private WorkflowStatus workflowStatus;
|
||||||
private int numberOfPages;
|
private int numberOfPages;
|
||||||
private long fileSize;
|
private Long fileSize;
|
||||||
private OffsetDateTime added;
|
private OffsetDateTime added;
|
||||||
private OffsetDateTime lastUpdated;
|
private OffsetDateTime lastUpdated;
|
||||||
private OffsetDateTime deleted;
|
private OffsetDateTime deleted;
|
||||||
|
|||||||
@ -56,7 +56,7 @@ public class FileEntity {
|
|||||||
private int numberOfPages;
|
private int numberOfPages;
|
||||||
|
|
||||||
@Column
|
@Column
|
||||||
private long fileSize;
|
private Long fileSize;
|
||||||
|
|
||||||
@Column
|
@Column
|
||||||
private OffsetDateTime added;
|
private OffsetDateTime added;
|
||||||
|
|||||||
@ -1,24 +1,16 @@
|
|||||||
package com.iqser.red.service.peristence.v1.server.migration;
|
package com.iqser.red.service.peristence.v1.server.migration;
|
||||||
|
|
||||||
|
import com.iqser.red.service.peristence.v1.server.migration.migrations.*;
|
||||||
|
import com.iqser.red.service.peristence.v1.server.settings.FileManagementServiceSettings;
|
||||||
|
import com.iqser.red.service.persistence.management.v1.processor.service.persistence.MigrationPersistenceService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.springframework.boot.SpringApplication;
|
import org.springframework.boot.SpringApplication;
|
||||||
import org.springframework.boot.context.event.ApplicationReadyEvent;
|
import org.springframework.boot.context.event.ApplicationReadyEvent;
|
||||||
import org.springframework.context.ApplicationContext;
|
import org.springframework.context.ApplicationContext;
|
||||||
import org.springframework.context.event.EventListener;
|
import org.springframework.context.event.EventListener;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
import com.iqser.red.service.peristence.v1.server.migration.migrations.DeleteRemovedManualAddRedactions7;
|
|
||||||
import com.iqser.red.service.peristence.v1.server.migration.migrations.DictionaryToEntityMigration2;
|
|
||||||
import com.iqser.red.service.peristence.v1.server.migration.migrations.EntityTypesMigration4;
|
|
||||||
import com.iqser.red.service.peristence.v1.server.migration.migrations.IndexMigration1;
|
|
||||||
import com.iqser.red.service.peristence.v1.server.migration.migrations.MigrateHighlights3;
|
|
||||||
import com.iqser.red.service.peristence.v1.server.migration.migrations.RemoveFalsePositiveManualRedactions6;
|
|
||||||
import com.iqser.red.service.peristence.v1.server.migration.migrations.TypeToEntityMigration5;
|
|
||||||
import com.iqser.red.service.peristence.v1.server.settings.FileManagementServiceSettings;
|
|
||||||
import com.iqser.red.service.persistence.management.v1.processor.service.persistence.MigrationPersistenceService;
|
|
||||||
|
|
||||||
import lombok.RequiredArgsConstructor;
|
|
||||||
import lombok.extern.slf4j.Slf4j;
|
|
||||||
|
|
||||||
@Slf4j
|
@Slf4j
|
||||||
@Service
|
@Service
|
||||||
@RequiredArgsConstructor
|
@RequiredArgsConstructor
|
||||||
@ -40,6 +32,8 @@ public class MigrationStarterService {
|
|||||||
private final ApplicationContext ctx;
|
private final ApplicationContext ctx;
|
||||||
private final MigrationPersistenceService migrationPersistenceService;
|
private final MigrationPersistenceService migrationPersistenceService;
|
||||||
|
|
||||||
|
private final FileSizeMigration8 fileSizeMigration8;
|
||||||
|
|
||||||
|
|
||||||
@EventListener(ApplicationReadyEvent.class)
|
@EventListener(ApplicationReadyEvent.class)
|
||||||
public void migrate() {
|
public void migrate() {
|
||||||
@ -58,6 +52,7 @@ public class MigrationStarterService {
|
|||||||
typeToEntityMigration5.run();
|
typeToEntityMigration5.run();
|
||||||
removeFalsePositiveManualRedactions6.run();
|
removeFalsePositiveManualRedactions6.run();
|
||||||
deleteRemovedManualAddRedactions7.run();
|
deleteRemovedManualAddRedactions7.run();
|
||||||
|
fileSizeMigration8.run();
|
||||||
|
|
||||||
log.info("Migration is finished");
|
log.info("Migration is finished");
|
||||||
System.exit(SpringApplication.exit(ctx, () -> 0));
|
System.exit(SpringApplication.exit(ctx, () -> 0));
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user