Class: Core::Models::Monitoring::Service

Inherits:
Object
  • Object
show all
Includes:
Concerns::Activable, Concerns::Diagnosticable, Concerns::Premiumable, Mongoid::Document, Mongoid::Timestamps
Defined in:
lib/core/models/monitoring/service.rb

Overview

A service is the representation of one of the applications composing the API.

Author:

Instance Attribute Summary collapse

Instance Attribute Details

#creator ⇒ Core::Models::Account

Returns the creator of this service.

Returns:



22
# File 'lib/core/models/monitoring/service.rb', line 22

belongs_to :creator, class_name: 'Core::Models::Account', optional: true, inverse_of: :services

#key ⇒ String

Returns the name of the service, used as a namespace on the Kubernetes side.

Returns:

  • (String) —

    the name of the service, used as a namespace on the Kubernetes side.



15
# File 'lib/core/models/monitoring/service.rb', line 15

field :key, type: String

#path ⇒ String

Returns the path the service will be mapped on in the API. This will be used in the Ingress.

Returns:

  • (String) —

    the path the service will be mapped on in the API. This will be used in the Ingress.



18
# File 'lib/core/models/monitoring/service.rb', line 18

field :path, type: String, default: '/'

#routes ⇒ Array<Core::Models::Monitoring::Route>

Returns the routes associated to this service, accessible from the gateway.

Returns:



25
# File 'lib/core/models/monitoring/service.rb', line 25

has_many :routes, class_name: 'Core::Models::Monitoring::Route', inverse_of: :service