mentorenwahl/backend/src/backend/worker.cr
Dominic Grimm 50379148bc
Some checks failed
continuous-integration/drone/push Build is failing
Update codebase
2022-10-31 09:47:26 +01:00

47 lines
1.6 KiB
Crystal

# Mentorenwahl: A fullstack application for assigning mentors to students based on their whishes.
# Copyright (C) 2022 Dominic Grimm
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
require "mosquito"
require "./worker/*"
module Backend
# Worker module
module Worker
# # :inherit:
# module Mosquito::Serializers::Granite
# # :inherit:
# macro serialize_granite_model(klass)
# {% method_suffix = klass.resolve.stringify.underscore.gsub(/::/, "__").id %}
# # Serializes {{ klaas.id }} to redis manageable data
# def serialize_{{ method_suffix }}(model : {{ klass.id }}) : String
# model.id.to_s
# end
# # Deserializes {{ klaas.id }} from redis manageable data
# def deserialize_{{ method_suffix }}(raw : String) : {{ klass.id }}
# {{ klass.id }}.find!(raw.to_i)
# end
# end
# end
Mosquito.configure do |settings|
settings.redis_url = Backend.config.redis.url
end
end
end