move IP/FP updaters to web namespace

This commit is contained in:
byte[] 2020-05-07 22:03:10 -04:00
parent 0506334046
commit 1168ba86f6
4 changed files with 11 additions and 11 deletions

View file

@ -17,16 +17,16 @@ defmodule Philomena.Application do
Philomena.Servers.UserLinkUpdater,
Philomena.Servers.PicartoChannelUpdater,
Philomena.Servers.PiczelChannelUpdater,
Philomena.Servers.UserFingerprintUpdater,
Philomena.Servers.UserIpUpdater,
Philomena.Servers.Config,
{Pow.Store.Backend.MnesiaCache, extra_db_nodes: Node.list()},
{Redix, name: :redix, host: Application.get_env(:philomena, :redis_host)},
{Phoenix.PubSub, [name: Philomena.PubSub, adapter: Phoenix.PubSub.PG2]},
# Start the endpoint when the application starts
PhilomenaWeb.Endpoint,
PhilomenaWeb.StatsUpdater,
PhilomenaWeb.UserFingerprintUpdater,
PhilomenaWeb.UserIpUpdater,
PhilomenaWeb.Endpoint,
# Connection drainer for SIGTERM
{RanchConnectionDrainer, ranch_ref: PhilomenaWeb.Endpoint.HTTP, shutdown: 30_000}

View file

@ -3,8 +3,8 @@ defmodule PhilomenaWeb.ReloadUserPlug do
alias Pow.Plug
alias Philomena.Users
alias Philomena.Servers.UserIpUpdater
alias Philomena.Servers.UserFingerprintUpdater
alias PhilomenaWeb.UserIpUpdater
alias PhilomenaWeb.UserFingerprintUpdater
def init(opts), do: opts

View file

@ -1,12 +1,12 @@
defmodule Philomena.Servers.UserFingerprintUpdater do
defmodule PhilomenaWeb.UserFingerprintUpdater do
alias Philomena.UserFingerprints.UserFingerprint
alias Philomena.Repo
import Ecto.Query
def child_spec([]) do
%{
id: Philomena.Servers.UserFingerprintUpdater,
start: {Philomena.Servers.UserFingerprintUpdater, :start_link, [[]]}
id: PhilomenaWeb.UserFingerprintUpdater,
start: {PhilomenaWeb.UserFingerprintUpdater, :start_link, [[]]}
}
end

View file

@ -1,12 +1,12 @@
defmodule Philomena.Servers.UserIpUpdater do
defmodule PhilomenaWeb.UserIpUpdater do
alias Philomena.UserIps.UserIp
alias Philomena.Repo
import Ecto.Query
def child_spec([]) do
%{
id: Philomena.Servers.UserIpUpdater,
start: {Philomena.Servers.UserIpUpdater, :start_link, [[]]}
id: PhilomenaWeb.UserIpUpdater,
start: {PhilomenaWeb.UserIpUpdater, :start_link, [[]]}
}
end