summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorAdam- <Adam-@5417fbe8-f217-4b02-8779-1006273d7864>2010-02-28 17:33:31 +0000
committerAdam- <Adam-@5417fbe8-f217-4b02-8779-1006273d7864>2010-02-28 17:33:31 +0000
commit3f80e1cad02735f692a5a300ee3b200a21f330aa (patch)
treed7bcd3c5d1cfd54c725f4c9a0eb7984632b6be67 /docs
parent393b5ab26e952f427f40a8ed6d10acfdf6ead96c (diff)
Added in support for live updating MySQL databases and the ability to execute commands to Anope through MySQL. Currently database support only applies to NickServ, ChanServ and BotServ but will be expanded soon.
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@2798 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'docs')
-rw-r--r--docs/MYSQL25
-rw-r--r--docs/NEWS3
2 files changed, 25 insertions, 3 deletions
diff --git a/docs/MYSQL b/docs/MYSQL
index 6bd71a9b9..42d9c928b 100644
--- a/docs/MYSQL
+++ b/docs/MYSQL
@@ -1,6 +1,29 @@
Anope MySQL Support
-------------------
-MySQL Support was removed in 1.9.0 until it can be better implemented moving forward.
+MySQL support was readded in version 1.9.2 In the form of three modules.
+db_mysql_read - Allows you to load your databases from MySQL.
+ Note: At the time of writing, MySQL did not support full databases (no support for OperServ, MemoServ, and HostServ)
+ which means using this is limited. I recommend using db_plain with db_mysql_write and db_mysql_execute
+db_mysql_write - Allows live updating of SQL tables whenever something is executed in Anope.
+db_mysql_execute - Allows executing of Anope commands via SQL.
+
+To execute commands via SQL, you must insert the command into the anope_commands table, an example is as follows:
+
+INSERT INTO `anope_commands` (nick, service, command) VALUES('Adam', 'NickServ', 'REGISTER qwerty Adam@anope.org');
+
+By default, every 60 seconds Anope checks this table for commands to execute. When Anope sees a new command to execute, it checks the following.
+
+If the nick given is -SQLUser, then the command gets executed by a special fake user within Anope called -SQLUser. -SQLUser has every permission and command available, there are no permission checks at all for this user, it can do anything.
+
+If the nick is not -SQLUser, it checks to see if it is a registered nick. If it is, it sees if there are any users online using the NickCore of that nick.
+ If there is a user online with that core the command gets executed as if that user executed it, and the reply goes to that user.
+ If there isn't a user online with the core, it creates a fake user as the nick given to it, and gives to it the permissions the user would have if they were online and identified.
+If the nick is not registered, it checks to see if there is a user currently on that nick. If there is, it executes the command as that user, and the reply goes to that user.
+ If the nick is not registered and no one is using the nick, it creates a fake user of the nick given to it, and gives it regular nonidentified user access.
+
+Currently there is no way to check to see if a command was executed successfully within Anope from SQL (even if there was, the possibly update delay would be a problem).
+
+IMPORTANT: When using db_mysql_write when you already have a database, you need to do an initial import of the data to SQL (as db_mysql_write only updates it when it is changed, it never actually mass-dumps all of your data into SQL). To do this, start Anope and execute /OperServ SQLSYNC.
diff --git a/docs/NEWS b/docs/NEWS
index fb5fe3ff9..1010816cf 100644
--- a/docs/NEWS
+++ b/docs/NEWS
@@ -1,8 +1,7 @@
Highlighted News in Anope 1.9
=============================
-* Removed MySQL Support (pending better implementation)
+* Added in live updating SQL and the ability to execute commands through SQL
* Re-designed configuration file
* Code refresh / rewrite into C++
-