Module: GClouder::Resources::PubSub::Topics::Remote

Defined in:
lib/gclouder/resources/pubsub/topics.rb

Class Method Summary collapse

Class Method Details

.instancesObject



74
75
76
77
78
# File 'lib/gclouder/resources/pubsub/topics.rb', line 74

def self.instances
  Resources::Remote.instances(
    path: %w(beta pubsub topics)
  )
end

.listObject



70
71
72
# File 'lib/gclouder/resources/pubsub/topics.rb', line 70

def self.list
  { "global" => instances.fetch("global", []).map { |topic| { "name" => topic["name"].split("/").last } } }.delete_if { |_k, v| v.empty? }
end