⌚ OpenOpeningstijden main server application
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

event_sourcery.rb 597B

12345678910111213141516171819
  1. # frozen_string_literal: true
  2. require_relative './environment.rb'
  3. ##
  4. # Configure the event sourcery databases.
  5. # This assumes they already exist!
  6. EventSourcery::Postgres.configure do |config|
  7. database = Sequel.connect(Hours.config.database_url)
  8. Sequel.extension :pg_hstore
  9. Sequel.extension :pg_hstore_ops
  10. # NOTE: Often we choose to split our events and projections into separate
  11. # databases. For the purposes of this example we'll use one.
  12. config.event_store_database = database
  13. config.projections_database = database
  14. config.projections_database.extension :postgis_georuby
  15. end