RED-9139: move document to module in redaction-service
* add TableOfContents node
This commit is contained in:
parent
4755243253
commit
85777d64c5
@ -13,7 +13,7 @@ dependencies {
|
|||||||
implementation(project(":layoutparser-service-internal-api"))
|
implementation(project(":layoutparser-service-internal-api"))
|
||||||
implementation(project(":viewer-doc-processor"))
|
implementation(project(":viewer-doc-processor"))
|
||||||
|
|
||||||
implementation("com.iqser.red.service:document:${rootProject.extra.get("documentVersion")}")
|
implementation("com.knecon.fforesight:${rootProject.extra.get("documentVersion")}")
|
||||||
implementation("com.iqser.red.service:persistence-service-shared-api-v1:2.564.0-RED9010.0") {
|
implementation("com.iqser.red.service:persistence-service-shared-api-v1:2.564.0-RED9010.0") {
|
||||||
exclude("org.springframework.boot", "spring-boot-starter-security")
|
exclude("org.springframework.boot", "spring-boot-starter-security")
|
||||||
exclude("org.springframework.boot", "spring-boot-starter-validation")
|
exclude("org.springframework.boot", "spring-boot-starter-validation")
|
||||||
|
|||||||
@ -30,7 +30,7 @@ dependencies {
|
|||||||
implementation(project(":layoutparser-service-internal-api"))
|
implementation(project(":layoutparser-service-internal-api"))
|
||||||
|
|
||||||
implementation("com.iqser.red.commons:storage-commons:2.50.0")
|
implementation("com.iqser.red.commons:storage-commons:2.50.0")
|
||||||
implementation("com.knecon.fforesight:tenant-commons:0.30.0")
|
implementation("com.knecon.fforesight:tenant-commons:0.31.0")
|
||||||
implementation("com.knecon.fforesight:tracing-commons:0.5.0")
|
implementation("com.knecon.fforesight:tracing-commons:0.5.0")
|
||||||
implementation("com.knecon.fforesight:lifecycle-commons:0.6.0")
|
implementation("com.knecon.fforesight:lifecycle-commons:0.6.0")
|
||||||
implementation("org.springframework.boot:spring-boot-starter-actuator:${springBootStarterVersion}")
|
implementation("org.springframework.boot:spring-boot-starter-actuator:${springBootStarterVersion}")
|
||||||
@ -46,7 +46,7 @@ dependencies {
|
|||||||
testImplementation(project(":viewer-doc-processor"))
|
testImplementation(project(":viewer-doc-processor"))
|
||||||
testImplementation(project(":layoutparser-service-internal-api"))
|
testImplementation(project(":layoutparser-service-internal-api"))
|
||||||
|
|
||||||
testImplementation("com.iqser.red.service:document:${rootProject.extra.get("documentVersion")}")
|
testImplementation("com.knecon.fforesight:document:${rootProject.extra.get("documentVersion")}")
|
||||||
|
|
||||||
testImplementation("org.springframework.boot:spring-boot-starter-amqp:${springBootStarterVersion}")
|
testImplementation("org.springframework.boot:spring-boot-starter-amqp:${springBootStarterVersion}")
|
||||||
testImplementation("org.springframework.boot:spring-boot-starter-test:${springBootStarterVersion}")
|
testImplementation("org.springframework.boot:spring-boot-starter-test:${springBootStarterVersion}")
|
||||||
|
|||||||
@ -1,64 +0,0 @@
|
|||||||
package com.knecon.fforesight.service.layoutparser.server.queue;
|
|
||||||
|
|
||||||
import java.util.Set;
|
|
||||||
|
|
||||||
import org.springframework.amqp.rabbit.annotation.RabbitHandler;
|
|
||||||
import org.springframework.amqp.rabbit.annotation.RabbitListener;
|
|
||||||
import org.springframework.boot.context.event.ApplicationReadyEvent;
|
|
||||||
import org.springframework.context.event.EventListener;
|
|
||||||
import org.springframework.stereotype.Service;
|
|
||||||
|
|
||||||
import com.knecon.fforesight.service.layoutparser.internal.api.queue.LayoutParsingQueueNames;
|
|
||||||
import com.knecon.fforesight.tenantcommons.TenantProvider;
|
|
||||||
import com.knecon.fforesight.tenantcommons.model.TenantCreatedEvent;
|
|
||||||
import com.knecon.fforesight.tenantcommons.model.TenantQueueConfiguration;
|
|
||||||
import com.knecon.fforesight.tenantcommons.model.TenantResponse;
|
|
||||||
import com.knecon.fforesight.tenantcommons.queue.RabbitQueueFromExchangeService;
|
|
||||||
import com.knecon.fforesight.tenantcommons.queue.TenantExchangeMessageReceiver;
|
|
||||||
|
|
||||||
@Service
|
|
||||||
public class TenantExchangeMessageReceiverImpl extends TenantExchangeMessageReceiver {
|
|
||||||
|
|
||||||
public TenantExchangeMessageReceiverImpl(RabbitQueueFromExchangeService rabbitQueueService, TenantProvider tenantProvider) {
|
|
||||||
|
|
||||||
super(rabbitQueueService, tenantProvider);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
@Override
|
|
||||||
protected Set<TenantQueueConfiguration> getTenantQueueConfigs() {
|
|
||||||
|
|
||||||
return Set.of(TenantQueueConfiguration.builder()
|
|
||||||
.listenerId(MessageHandler.LAYOUT_PARSING_REQUEST_LISTENER_ID)
|
|
||||||
.exchangeName(LayoutParsingQueueNames.LAYOUT_PARSING_REQUEST_EXCHANGE)
|
|
||||||
.queuePrefix(LayoutParsingQueueNames.LAYOUT_PARSING_REQUEST_QUEUE_PREFIX)
|
|
||||||
.dlqName(LayoutParsingQueueNames.LAYOUT_PARSING_DLQ)
|
|
||||||
.build());
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
@EventListener(ApplicationReadyEvent.class)
|
|
||||||
public void onApplicationReady() {
|
|
||||||
|
|
||||||
System.out.println("application ready invoked");
|
|
||||||
super.initializeQueues();
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
@RabbitHandler
|
|
||||||
@RabbitListener(queues = "#{tenantMessagingConfigurationImpl.getTenantCreatedQueueName()}")
|
|
||||||
public void reactToTenantCreation(TenantCreatedEvent tenantCreatedEvent) {
|
|
||||||
|
|
||||||
super.reactToTenantCreation(tenantCreatedEvent);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
@RabbitHandler
|
|
||||||
@RabbitListener(queues = "#{tenantMessagingConfigurationImpl.getTenantDeletedQueueName()}")
|
|
||||||
public void reactToTenantDeletion(TenantResponse tenantResponse) {
|
|
||||||
|
|
||||||
super.reactToTenantDeletion(tenantResponse);
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
@ -0,0 +1,26 @@
|
|||||||
|
package com.knecon.fforesight.service.layoutparser.server.queue;
|
||||||
|
|
||||||
|
import java.util.Set;
|
||||||
|
|
||||||
|
import org.springframework.context.annotation.Bean;
|
||||||
|
import org.springframework.context.annotation.Configuration;
|
||||||
|
|
||||||
|
import com.knecon.fforesight.service.layoutparser.internal.api.queue.LayoutParsingQueueNames;
|
||||||
|
import com.knecon.fforesight.tenantcommons.model.TenantQueueConfiguration;
|
||||||
|
import com.knecon.fforesight.tenantcommons.model.TenantQueueProvider;
|
||||||
|
|
||||||
|
@Configuration
|
||||||
|
public class TenantQueueConfig {
|
||||||
|
|
||||||
|
@Bean
|
||||||
|
protected TenantQueueProvider getTenantQueueConfigs() {
|
||||||
|
|
||||||
|
return new TenantQueueProvider(Set.of(TenantQueueConfiguration.builder()
|
||||||
|
.listenerId(MessageHandler.LAYOUT_PARSING_REQUEST_LISTENER_ID)
|
||||||
|
.exchangeName(LayoutParsingQueueNames.LAYOUT_PARSING_REQUEST_EXCHANGE)
|
||||||
|
.queuePrefix(LayoutParsingQueueNames.LAYOUT_PARSING_REQUEST_QUEUE_PREFIX)
|
||||||
|
.dlqName(LayoutParsingQueueNames.LAYOUT_PARSING_DLQ)
|
||||||
|
.build()));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
Loading…
x
Reference in New Issue
Block a user