Class GrpcEventTransformationService
- java.lang.Object
-
- io.axoniq.axonserver.connector.event.transformation.impl.grpc.GrpcEventTransformationService
-
- All Implemented Interfaces:
EventTransformationService
public class GrpcEventTransformationService extends Object implements EventTransformationService
- Since:
- 2023.0.0
- Author:
- Sara Pellegrini
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface io.axoniq.axonserver.connector.event.transformation.impl.EventTransformationService
EventTransformationService.TransformationStream
-
-
Constructor Summary
Constructors Constructor Description GrpcEventTransformationService(AxonServerManagedChannel axonServerManagedChannel)GrpcEventTransformationService(EventTransformationServiceGrpc.EventTransformationServiceStub stub)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CompletableFuture<Void>cancel(String transformationId)Requests to AxonServer to cancel the transformation with the specified identifier.CompletableFuture<String>newTransformation(String description)Creates a new transformation.CompletableFuture<Void>startApplying(String transformationId, Long sequence)Requests to AxonServer to apply the transformation with the specified identifier.CompletableFuture<Void>startCompacting()Requests to AxonServer to compact the event store.CompletableFuture<EventTransformation>transformationById(String id)Returns the Event Transformations with the specified id.CompletableFuture<Iterable<EventTransformation>>transformations()Returns all the existing Event Transformations.EventTransformationService.TransformationStreamtransformationStream(String transformationId)Opens aEventTransformationService.TransformationStreamtowards the transformation, that can be used to register the required changes.
-
-
-
Constructor Detail
-
GrpcEventTransformationService
public GrpcEventTransformationService(AxonServerManagedChannel axonServerManagedChannel)
-
GrpcEventTransformationService
public GrpcEventTransformationService(EventTransformationServiceGrpc.EventTransformationServiceStub stub)
-
-
Method Detail
-
transformations
public CompletableFuture<Iterable<EventTransformation>> transformations()
Description copied from interface:EventTransformationServiceReturns all the existing Event Transformations.- Specified by:
transformationsin interfaceEventTransformationService- Returns:
- a
CompletableFutureof the Event Transformations
-
transformationById
public CompletableFuture<EventTransformation> transformationById(String id)
Description copied from interface:EventTransformationServiceReturns the Event Transformations with the specified id.- Specified by:
transformationByIdin interfaceEventTransformationService- Parameters:
id- the id of theEventTransformationto be returned.- Returns:
- a
CompletableFutureof theEventTransformationwith the specified id.
-
newTransformation
public CompletableFuture<String> newTransformation(String description)
Description copied from interface:EventTransformationServiceCreates a new transformation.- Specified by:
newTransformationin interfaceEventTransformationService- Parameters:
description- the description of the transformation to create.- Returns:
- a
CompletableFutureof the identifier of the newly created transformation.
-
transformationStream
public EventTransformationService.TransformationStream transformationStream(String transformationId)
Description copied from interface:EventTransformationServiceOpens aEventTransformationService.TransformationStreamtowards the transformation, that can be used to register the required changes.- Specified by:
transformationStreamin interfaceEventTransformationService- Parameters:
transformationId- the identifier of the transformation- Returns:
- the
EventTransformationService.TransformationStream
-
startApplying
public CompletableFuture<Void> startApplying(String transformationId, Long sequence)
Description copied from interface:EventTransformationServiceRequests to AxonServer to apply the transformation with the specified identifier.- Specified by:
startApplyingin interfaceEventTransformationService- Parameters:
transformationId- the identifier of the transformation to be appliedsequence- the expected last sequence of the transformation, used to check that no change request has been lost- Returns:
- a
CompletableFuturethat completes when the request has been received by Axon Server.
-
cancel
public CompletableFuture<Void> cancel(String transformationId)
Description copied from interface:EventTransformationServiceRequests to AxonServer to cancel the transformation with the specified identifier.- Specified by:
cancelin interfaceEventTransformationService- Parameters:
transformationId- the identifier of the transformation to be cancelled- Returns:
- a
CompletableFuturethat completes when the request has been received by Axon Server.
-
startCompacting
public CompletableFuture<Void> startCompacting()
Description copied from interface:EventTransformationServiceRequests to AxonServer to compact the event store. In other words, the request to delete all obsoleted version of the events from the event store.- Specified by:
startCompactingin interfaceEventTransformationService- Returns:
- a
CompletableFuturethat completes when the request has been received by Axon Server.
-
-