Software /
code /
prosody
Comparison
plugins/mod_proxy65.lua @ 3604:3e89f0509967
prosody: Removed all references to componentmanager from Prosody, except the main componentmanager file.
author | Waqas Hussain <waqas20@gmail.com> |
---|---|
date | Wed, 10 Nov 2010 20:59:16 +0500 |
parent | 3559:0708d42ef0d4 |
child | 3607:e1259b6d7560 |
comparison
equal
deleted
inserted
replaced
3603:fdc671381411 | 3604:3e89f0509967 |
---|---|
14 error("proxy65 should be loaded as a component, please see http://prosody.im/doc/components", 0); | 14 error("proxy65 should be loaded as a component, please see http://prosody.im/doc/components", 0); |
15 end | 15 end |
16 | 16 |
17 local jid_split, jid_join, jid_compare = require "util.jid".split, require "util.jid".join, require "util.jid".compare; | 17 local jid_split, jid_join, jid_compare = require "util.jid".split, require "util.jid".join, require "util.jid".compare; |
18 local st = require "util.stanza"; | 18 local st = require "util.stanza"; |
19 local componentmanager = require "core.componentmanager"; | |
20 local config_get = require "core.configmanager".get; | 19 local config_get = require "core.configmanager".get; |
21 local connlisteners = require "net.connlisteners"; | 20 local connlisteners = require "net.connlisteners"; |
22 local sha1 = require "util.hashes".sha1; | 21 local sha1 = require "util.hashes".sha1; |
23 local server = require "net.server"; | 22 local server = require "net.server"; |
24 | 23 |
183 reply.tags[1].attr.sid = sid; | 182 reply.tags[1].attr.sid = sid; |
184 return reply; | 183 return reply; |
185 end | 184 end |
186 | 185 |
187 module.unload = function() | 186 module.unload = function() |
188 componentmanager.deregister_component(host); | |
189 connlisteners.deregister(module.host .. ':proxy65'); | 187 connlisteners.deregister(module.host .. ':proxy65'); |
190 end | 188 end |
191 | 189 |
192 local function set_activation(stanza) | 190 local function set_activation(stanza) |
193 local from, to, sid, reply = nil; | 191 local from, to, sid, reply = nil; |
258 module:log("error", "mod_proxy65: Could not establish a connection listener. Check your configuration please."); | 256 module:log("error", "mod_proxy65: Could not establish a connection listener. Check your configuration please."); |
259 module:log("error", "Possibly two proxy65 components are configured to share the same port."); | 257 module:log("error", "Possibly two proxy65 components are configured to share the same port."); |
260 end | 258 end |
261 | 259 |
262 connlisteners.start(module.host .. ':proxy65'); | 260 connlisteners.start(module.host .. ':proxy65'); |
263 component = componentmanager.register_component(host, function() end); |