Class: RazorRisk::Cassini::Applications::Microservices::RESTful::UserProfiles::UserProfilesApp

Inherits:
SecuredMicroservice
  • Object
show all
Includes:
Cassini::Applications::RESTFramework::RouteVerbDispatch, Cassini::Mixin::RazorResponseValidator, Pantheios, RouteVerbAdaptors::UserProfiles
Defined in:
lib/razor_risk/cassini/applications/microservices/restful/user_profiles/app.rb

Overview

Sinatra Application for the UserProfiles Microservice.

Constant Summary collapse

FULL_DESIGNATION =

########################################################## Constants

'UserProfiles'
SHORT_DESIGNATION =
'user_profiles'
SERVICE_TYPE =
:microservice
PROGRAM_FEATURES =
{
    has_web_server:         true,
    has_host_and_port:      true,
    has_razor_connectivity: true,
    authentication:         true,
    copyright_year:         2019,
}
SUPPORTED_ROUTES =
[
]
HTTP_ACCEPTS =
%w{
    text/html
    application/json
    application/xml
    text/xml
    text/csv
    text/plain
    text/tab-separated-values
    text/tsv
}

Class Method Summary collapse

Class Method Details

.on_init_service(options) ⇒ Object

########################################################## methods

Raises:

  • (ArgumentError)


84
85
86
87
88
89
90
91
92
93
94
95
96
# File 'lib/razor_risk/cassini/applications/microservices/restful/user_profiles/app.rb', line 84

def self.on_init_service options

    trace ParamNames[ :options ], options

    raise ArgumentError.new(
        'missing keyword: razor_requester'
    ) unless options.has_key? :razor_requester

    request_options = options[:request_options]

    set :razor_requester, options[:razor_requester]
    set :request_options, request_options
end