Sha256: e53db8f93795b4a44d7eca65ca9918112881a3ef9fc182169dd2c2d38c88bf81

Contents?: true

Size: 1.06 KB

Versions: 6

Compression:

Stored size: 1.06 KB

Contents

require 'sinatra'
require 'rack/robustness'
require 'finitio'
require 'logger'
require 'path'
# Provides a reusable backend framework for backend components written
# in ruby.
#
# The framework installs conventions regarding:
#
# - The exposition of web service APIs (Framework::Api, on top of Sinatra)
# - Operations (Framework::Operation)
# - Error handling (Framework::Errors) and their handling in web APIs
#   (based on Rack::Robustness)
# - General code support (Framework::Support modules & classes).
#
# Please refer to the documentation of those main abstractions for details.
#
module Startback

  # Simply checks that a path exists of raise an error
  def self._!(path)
    Path(path).tap do |p|
      raise "Missing #{p.basename}." unless p.exists?
    end
  end

  require_relative 'startback/ext'
  require_relative 'startback/errors'
  require_relative 'startback/support'
  require_relative 'startback/context'
  require_relative 'startback/operation'

  # Logger instance to use for the application
  LOGGER = ::Startback::Support::Logger.new

end # module Startback

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
startback-0.4.5 lib/startback.rb
startback-0.4.4 lib/startback.rb
startback-0.4.3 lib/startback.rb
startback-0.4.2 lib/startback.rb
startback-0.4.1 lib/startback.rb
startback-0.4.0 lib/startback.rb