Class: Gitlab::GitalyClient::PraefectInfoService

Inherits:
Object
  • Object
show all
Defined in:
lib/gitlab/gitaly_client/praefect_info_service.rb

Instance Method Summary collapse

Constructor Details

#initialize(repository) ⇒ PraefectInfoService

Returns a new instance of PraefectInfoService.


6
7
8
9
10
# File 'lib/gitlab/gitaly_client/praefect_info_service.rb', line 6

def initialize(repository)
  @repository = repository
  @gitaly_repo = repository.gitaly_repository
  @storage = repository.storage
end

Instance Method Details

#replicasObject


12
13
14
15
16
# File 'lib/gitlab/gitaly_client/praefect_info_service.rb', line 12

def replicas
  request = Gitaly::RepositoryReplicasRequest.new(repository: @gitaly_repo)

  GitalyClient.call(@storage, :praefect_info_service, :repository_replicas, request, timeout: GitalyClient.fast_timeout)
end