Package com.atlassian.bamboo.grpc
Class CrossNodesEventsReceiverService
- java.lang.Object
-
- com.atlassian.bamboo.grpc.CrossNodesEventsServiceGrpc.CrossNodesEventsServiceImplBase
-
- com.atlassian.bamboo.grpc.CrossNodesEventsReceiverService
-
- All Implemented Interfaces:
CrossNodesEventsServiceGrpc.AsyncService
,io.grpc.BindableService
@Internal public class CrossNodesEventsReceiverService extends CrossNodesEventsServiceGrpc.CrossNodesEventsServiceImplBase
This class is responsible for receiving and handling event based gRPC requests from other nodes in the cluster. Event based requests are the type of request that does not require a specific response from the receiver. These are created in order to inform the receiver about some action that happened on the publisher side and that should the receiving node be aware of.- Since:
- 9.5
-
-
Constructor Summary
Constructors Constructor Description CrossNodesEventsReceiverService(ImmutablePlanCacheService immutablePlanCacheService, CachedRepositoryDefinitionManager cachedRepositoryDefinitionManager, PluginClusterAwareService pluginClusterAwareService, DeadLetterQueue deadLetterQueue, GrpcBackedCacheManager grpcBackedCacheManager, org.springframework.security.core.session.SessionRegistry sessionRegistry, BambooUserManager bambooUserManager, ClusterAwareLifecycleManager clusterAwareLifecycleManager, FileBasedPersister fileBasedPersister, com.atlassian.event.api.EventPublisher eventPublisher)
-
Method Summary
-
Methods inherited from class com.atlassian.bamboo.grpc.CrossNodesEventsServiceGrpc.CrossNodesEventsServiceImplBase
bindService
-
-
-
-
Constructor Detail
-
CrossNodesEventsReceiverService
public CrossNodesEventsReceiverService(ImmutablePlanCacheService immutablePlanCacheService, CachedRepositoryDefinitionManager cachedRepositoryDefinitionManager, PluginClusterAwareService pluginClusterAwareService, DeadLetterQueue deadLetterQueue, GrpcBackedCacheManager grpcBackedCacheManager, org.springframework.security.core.session.SessionRegistry sessionRegistry, BambooUserManager bambooUserManager, ClusterAwareLifecycleManager clusterAwareLifecycleManager, FileBasedPersister fileBasedPersister, com.atlassian.event.api.EventPublisher eventPublisher)
-
-
Method Detail
-
invalidatePlanCache
public void invalidatePlanCache(CrossNodesCommunication.InvalidatePlanCacheRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
Description copied from interface:CrossNodesEventsServiceGrpc.AsyncService
Plan cache related events
-
hidePlan
public void hidePlan(CrossNodesCommunication.HidePlanRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
-
hideStage
public void hideStage(CrossNodesCommunication.HideStageRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
-
invalidateBuildNumbersRange
public void invalidateBuildNumbersRange(CrossNodesCommunication.InvalidateBuildNumbersRangeRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
-
invalidateLatestResultSummary
public void invalidateLatestResultSummary(CrossNodesCommunication.InvalidateLatestResultSummaryRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
-
invalidateAllLatestResultSummaries
public void invalidateAllLatestResultSummaries(CrossNodesCommunication.Metadata request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
-
invalidateSpecsStateForPlan
public void invalidateSpecsStateForPlan(CrossNodesCommunication.InvalidateSpecsStateForPlanRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
-
invalidateRepositoryCache
public void invalidateRepositoryCache(CrossNodesCommunication.InvalidateRepositoryCacheRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
Description copied from interface:CrossNodesEventsServiceGrpc.AsyncService
Repository cache related events
-
installPlugin
public void installPlugin(CrossNodesCommunication.InstallPluginRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
Description copied from interface:CrossNodesEventsServiceGrpc.AsyncService
Plugins management related events
-
uninstallPlugin
public void uninstallPlugin(CrossNodesCommunication.UninstallPluginRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
-
enablePlugin
public void enablePlugin(CrossNodesCommunication.EnablePluginRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
-
disablePlugin
public void disablePlugin(CrossNodesCommunication.DisablePluginRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
-
upgradePlugin
public void upgradePlugin(CrossNodesCommunication.UpgradePluginRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
-
propagateAtlassianCachePut
public void propagateAtlassianCachePut(CrossNodesCommunication.AtlassianCachePutRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
Description copied from interface:CrossNodesEventsServiceGrpc.AsyncService
Atlassian cache related events
-
propagateAtlassianCachePutIfAbsent
public void propagateAtlassianCachePutIfAbsent(CrossNodesCommunication.AtlassianCachePutIfAbsentRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
-
propagateAtlassianCacheRemoveByKey
public void propagateAtlassianCacheRemoveByKey(CrossNodesCommunication.AtlassianCacheRemoveByKeyRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
-
propagateAtlassianCacheRemoveByKeyAndValue
public void propagateAtlassianCacheRemoveByKeyAndValue(CrossNodesCommunication.AtlassianCacheRemoveByKeyAndValueRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
-
propagateAtlassianCacheRemoveAll
public void propagateAtlassianCacheRemoveAll(CrossNodesCommunication.AtlassianCacheRemoveAllRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
-
propagateAtlassianCacheReplace
public void propagateAtlassianCacheReplace(CrossNodesCommunication.AtlassianCacheReplaceRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
-
propagateAtlassianCacheBulk
public void propagateAtlassianCacheBulk(CrossNodesCommunication.AtlassianCacheBulkRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
-
propagateAtlassianCachedReferenceReset
public void propagateAtlassianCachedReferenceReset(CrossNodesCommunication.AtlassianCachedReferenceResetRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
-
invalidateUserSessions
public void invalidateUserSessions(CrossNodesCommunication.InvalidateUserSessionsRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
Description copied from interface:CrossNodesEventsServiceGrpc.AsyncService
User sessions related events
-
refreshClusterLifecycleState
public void refreshClusterLifecycleState(CrossNodesCommunication.RefreshClusterLifecycleStateRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
Description copied from interface:CrossNodesEventsServiceGrpc.AsyncService
Server lifecycle related events
-
refreshAdministrationConfiguration
public void refreshAdministrationConfiguration(CrossNodesCommunication.RefreshAdministrationConfigurationRequest request, io.grpc.stub.StreamObserver<CrossNodesCommunication.CommonResponse> responseObserver)
Description copied from interface:CrossNodesEventsServiceGrpc.AsyncService
Administration configuration related events
-
reduceResultsToStatus
@VisibleForTesting protected static CrossNodesCommunication.ResultStatus.Status reduceResultsToStatus(List<Pair<Long,Long>> input)
- Returns:
- The full execution status based on the results of the partial executions. The execution error on the remote side is handled by the dead letter queue. In this gRPC implementation, if the transport layer fails we end up with the `onError`. However, if anything related to business logic fails, we always finish the request successfully with the 'onCompleted'. The 'real' execution status is evaluated with the function below and returned as a payload.
-
-