[Bug 16794] $wgSharedDB PostgreSQL support

2013-09-04 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

Andre Klapper aklap...@wikimedia.org changed:

   What|Removed |Added

Version|1.17.0  |1.17.x

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are on the CC list for the bug.
___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2012-06-30 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

Luca Fulchir t...@codepedia.eu changed:

   What|Removed |Added

  Attachment #10808|0   |1
is obsolete||

--- Comment #31 from Luca Fulchir t...@codepedia.eu 2012-06-30 12:43:57 UTC 
---
Created attachment 10809
  -- https://bugzilla.wikimedia.org/attachment.cgi?id=10809
PostgreSql $wgSharedDb support - wiki 1.20

You're right, I didn't understand the purpose of realTableName.

Corrected, now realTableName does the quoting/schema handling, tableName is
untouched.

I also cleand up a little bit the patch, tested with multiple
installation/shared tables/phpunit

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2012-06-29 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

Luca Fulchir t...@codepedia.eu changed:

   What|Removed |Added

   Attachment #9959|0   |1
is obsolete||

--- Comment #27 from Luca Fulchir t...@codepedia.eu 2012-06-29 17:57:04 UTC 
---
Created attachment 10807
  -- https://bugzilla.wikimedia.org/attachment.cgi?id=10807
PostgreSql $wgSharedDb support - wiki 1.20

Patch updated to work against latest git (29/06).

Works also with phpunit tests (before it didn't apply the table prefix)

I hope it will be included in 1.20...

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2012-06-29 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

--- Comment #28 from Marcin Cieślak marcin.cies...@gmail.com 2012-06-29 
18:19:34 UTC ---
Thanks for the patch! 

Unfortunately, I cannot install mediawiki with this patch:


[29-Jun-2012 18:15:15 UTC] PHP Fatal error:  Call to undefined method
DatabasePo
stgres::realTableName() in
/usr/home/saper/public_html/pg/w/includes/db/Database
Postgres.php on line 1233

I think we should re-think what realTableName and tableName should be...
realTableName is needed in some places where we know it's PostgreSQL

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.
___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2012-06-29 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

Luca Fulchir t...@codepedia.eu changed:

   What|Removed |Added

  Attachment #10807|0   |1
is obsolete||

--- Comment #29 from Luca Fulchir t...@codepedia.eu 2012-06-29 20:36:12 UTC 
---
Created attachment 10808
  -- https://bugzilla.wikimedia.org/attachment.cgi?id=10808
PostgreSql $wgSharedDb support - wiki 1.20

*Really* sorry, forgot to change one instance of realTableName() into
tableName() my bad... altrough the phpunit test passed...

a quick grep -r tells me there are no other realTableName(),and I tested this
with raw installation and phpunit.

realTableName is not needed anymore. The distinction was created (I think)
since tablename() didn't do proper escaping/quoting on all cases.

Now tableName() handles every escaping/quoting/schema/prefix you should need,
Much of it is done by mimicking Database-tableName(), which was called before
by realTableName()

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2012-06-29 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

--- Comment #30 from Marcin Cieślak marcin.cies...@gmail.com 2012-06-29 
21:42:17 UTC ---
Luca, can you check

https://gerrit.wikimedia.org/r/#/c/3323/
(or
https://gerrit.wikimedia.org/r/gitweb?p=mediawiki%2Fcore.git;a=commit;h=556c5cf464b9103b04b247ed7dd7ee3051e9aef6)

I believe need real table names for the updater... we shouldn't cheat with
renaming user and text tables to the PostgreSQL-aware parts of code...

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.
___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2012-03-09 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

Marcin Cieślak marcin.cies...@gmail.com changed:

   What|Removed |Added

 CC||marcin.cies...@gmail.com

--- Comment #25 from Marcin Cieślak marcin.cies...@gmail.com 2012-03-09 
11:49:01 UTC ---
You have a comment that worries me a bit (it's not your fault though):

# Lets test for any bits of text that should never show up in a table 
# name. Basically anything like JOIN or ON which are actually part of
# SQL queries, but may end up inside of the table value to combine 
# sql. Such as how the API is doing.  

# Note that we use a whitespace test rather than a \b test to avoid
# any remote case where a word like on may be inside of a table name
# surrounded by symbols which may be considered word breaks

and then you resort to a regex to catch them:

'/(^|\s)(DISTINCT|JOIN|ON|AS)(\s|$)/i'

Could you comment a bit more on this? (Probably in a separate bug
that blocks this one)?

It's some time since I looked at the API code but I understand that
our current SQL query infrastructure is not sufficient for all API
needs...

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.
___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2012-03-09 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

--- Comment #26 from Daniel Friesen mediawiki-b...@nadir-seen-fire.com 
2012-03-10 00:22:09 UTC ---
That's part of the MySQL code. It dates back to when I implemented shared
prefix and shared tables. After implementing it I got bug reports on it
breaking and found out that various bits of code had awfully being passing full
joins into the list of tables because we didn't have a join syntax back then. I
had to add that junk into tableName in order for it to work.

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2012-02-08 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

Sumana Harihareswara suma...@panix.com changed:

   What|Removed |Added

 CC||suma...@panix.com

--- Comment #24 from Sumana Harihareswara suma...@panix.com 2012-02-08 
19:22:15 UTC ---
Luca, if you need any help running PHPUnit, or want to improve your patch to
the point where it can be committed, we can help you in the IRC channel:
https://www.mediawiki.org/wiki/MediaWiki_on_IRC  Thanks!

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2012-02-06 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

Luca Fulchir t...@codepedia.eu changed:

   What|Removed |Added

   Attachment #9606|0   |1
is obsolete||
   Attachment #9765|0   |1
is obsolete||

--- Comment #23 from Luca Fulchir t...@codepedia.eu 2012-02-06 13:50:39 UTC 
---
Created attachment 9959
  -- https://bugzilla.wikimedia.org/attachment.cgi?id=9959
PostgreSql wgshareddb support - trunk

the patch has been reverted, but I didn't hear any negative comments, so this
update is to keep it here for anyone who needs it or wants to work on it

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-12-28 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

--- Comment #22 from Luca Fulchir t...@codepedia.eu 2011-12-28 16:01:19 UTC 
---
tested, seems ok.
since it doesn't force the main schema phpunit is now back to using temporary
tables.

If you run phpunit with $wgshareddb set it still gives you the shared table
instead of the temporary.
The tableName() for mysql seems to force the database if it's a shared table,
so even for mysql phpunit + $wgshareddb gives you the shared table... which
means it should now work as intended ( I hope :p)

I haven't tested it with mysql, trough, just looked at the code.

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-12-27 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

Luca Fulchir t...@codepedia.eu changed:

   What|Removed |Added

   Attachment #8818|0   |1
is obsolete||

--- Comment #19 from Luca Fulchir t...@codepedia.eu 2011-12-27 16:02:15 UTC 
---
Created attachment 9765
  -- https://bugzilla.wikimedia.org/attachment.cgi?id=9765
trunk patch to fix temporary tables

this patch (trunk) should put the schema name in front of the table only if the
requested table is a shared table.
Otherwise you get only the quoted table name.

This should fix the temporary tables problem. (test, please?)
Since the temp tables are per-connection sharing the same db should not pose
any problem.

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-12-27 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

Mark A. Hershberger m...@everybody.org changed:

   What|Removed |Added

   Keywords|need-review |reviewed
 Status|RESOLVED|REOPENED
 Resolution|FIXED   |

--- Comment #18 from Mark A. Hershberger m...@everybody.org 2011-12-27 
13:53:42 UTC ---
Luca, OverlordQ made this comment on that code:

  In Postgres temporary tables are put in to their own special schema,
   explicitly prefixing all table names with mediawiki's default schema breaks
   any usage of temporary tables.

  Either this needs reverted, or have to do some ugly hacks to the testing
   framework.

Could you look at what changes need to be made, either here or in the testing
framework, to make temporary tables work properly?

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-12-27 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

--- Comment #20 from Mark A. Hershberger m...@everybody.org 2011-12-27 
17:13:02 UTC ---
You should be able to test using phpunit.  Have you tried that yet?

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-12-27 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

--- Comment #21 from Luca Fulchir t...@codepedia.eu 2011-12-27 18:57:53 UTC 
---
I have a couple of problems with phpunit now... i'll test it tomorrow.

right now i only tested install and basic functionality with wgshareddb,

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-12-13 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

Mark A. Hershberger m...@everybody.org changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||m...@everybody.org
 Resolution||FIXED

--- Comment #17 from Mark A. Hershberger m...@everybody.org 2011-12-13 
15:07:11 UTC ---
r106025

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-12-04 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

Luca Fulchir t...@codepedia.eu changed:

   What|Removed |Added

   Attachment #9575|0   |1
is obsolete||

--- Comment #16 from Luca Fulchir t...@codepedia.eu 2011-12-04 14:12:20 UTC 
---
Created attachment 9606
  -- https://bugzilla.wikimedia.org/attachment.cgi?id=9606
PostgreSQL wgSharedDB with schemas

The patch was breaking update.php since it was still calling the parent in some
cases.

fixed it, update.php works, multiple wiki seems to work.

testing is appreciated (patch only for trunk)

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-11-30 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

--- Comment #15 from Luca Fulchir t...@codepedia.eu 2011-11-30 09:00:00 UTC 
---
Created attachment 9575
  -- https://bugzilla.wikimedia.org/attachment.cgi?id=9575
PostgreSQL wgSharedDB with schemas

This patch (only for trunk) is totally different from the other ones: instead
of having multiple connections to a single database, we use postgresql schemas.

we use $wgSharedDB as it was an other schema name.

tested with new wikis installations.
didn't test with update.php as right now in trunk it's broken even without my
patch :p

should work trough...

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-07-23 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

Luca Fulchir t...@codepedia.eu changed:

   What|Removed |Added

   Attachment #8562|0   |1
is obsolete||
   Attachment #8599|0   |1
is obsolete||
   Attachment #8738|0   |1
is obsolete||

--- Comment #14 from Luca Fulchir t...@codepedia.eu 2011-07-23 10:01:39 UTC 
---
Created attachment 8818
  -- https://bugzilla.wikimedia.org/attachment.cgi?id=8818
PostgreSql $wgSharedDB support - mwiki 1.17.0

Updated patch: doesn't break update.php anymore.
Again, it works for me, but testing is appreciated.

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-07-23 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

Luca Fulchir t...@codepedia.eu changed:

   What|Removed |Added

Version|1.16.5  |1.17.0

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-07-04 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

Luca Fulchir t...@codepedia.eu changed:

   What|Removed |Added

   Attachment #8598|0   |1
is obsolete||

--- Comment #11 from Luca Fulchir t...@codepedia.eu 2011-07-04 08:20:09 UTC 
---
Created attachment 8738
  -- https://bugzilla.wikimedia.org/attachment.cgi?id=8738
PostgreSQL - $wgSharedDB - mediawiki 1.17.0

Updated to patch smoothly to mediawiki 1.17.0

still working for me, i'm waiting for comments... :p

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-07-04 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

--- Comment #12 from OverlordQ overlo...@gmail.com 2011-07-04 09:27:38 UTC ---
Doesn't apply to trunk and unless it was significantly different then was was
tried last time[1], it will likely be broken as well.

1 - http://www.mediawiki.org/wiki/Special:Code/MediaWiki/89393#code-comments

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-07-04 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

--- Comment #13 from Luca Fulchir t...@codepedia.eu 2011-07-04 11:57:33 UTC 
---
(In reply to comment #12)
 Doesn't apply to trunk and unless it was significantly different then was was
 tried last time[1], it will likely be broken as well.
 
 1 - http://www.mediawiki.org/wiki/Special:Code/MediaWiki/89393#code-comments
sorry, didn't see it. i'll post back when i'll resolve it

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-05-29 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

--- Comment #9 from Luca Fulchir t...@codepedia.eu 2011-05-29 15:00:33 UTC ---
Created attachment 8598
  -- https://bugzilla.wikimedia.org/attachment.cgi?id=8598
PostgreSQL - $wgSharedDB - mediawiki 1.17.0beta1

Added patch to make this work with mediawiki 1.17.0beta1 
I just ported it from 1.16.5 patch, not really tested, don't have time now, but
it is just a copy-paste of the 1.16.5 patch in the right places...

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-05-29 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

--- Comment #10 from Luca Fulchir t...@codepedia.eu 2011-05-29 15:02:13 UTC 
---
Created attachment 8599
  -- https://bugzilla.wikimedia.org/attachment.cgi?id=8599
PostgreSQL - $wgsharedDB - mediawiki trunk

Added patch to make this work with mediawiki trunk (29/05/11) 
I just ported it from 1.16.5 patch, not really tested, don't have time now, but
it is just a copy-paste of the 1.16.5 patch in the right places... shouldn't
break anything.

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-05-29 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

Luca Fulchir t...@codepedia.eu changed:

   What|Removed |Added

Version|1.14.x  |1.16.5

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-05-21 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

p858snake p858sn...@gmail.com changed:

   What|Removed |Added

   Keywords||need-review
 CC||p858sn...@gmail.com

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-05-21 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

Reedy s...@reedyboy.net changed:

   What|Removed |Added

   Attachment #5624|0   |1
is obsolete||

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-05-20 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

--- Comment #7 from Luca Fulchir t...@codepedia.eu 2011-05-20 17:04:30 UTC ---
Created attachment 8562
  -- https://bugzilla.wikimedia.org/attachment.cgi?id=8562
PostgreSQL sharedDB with second connection

This patch should allow you to use the $wgSharedDB normally, as you would with
mysql. Basically this patch creates a second connection with the shared
database and when a query is made, we check on which connection we should send
it.

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2011-05-20 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794

Luca Fulchir t...@codepedia.eu changed:

   What|Removed |Added

 CC||t...@codepedia.eu

--- Comment #8 from Luca Fulchir t...@codepedia.eu 2011-05-20 17:12:52 UTC ---
Forgot to say:
The patch is in a it works for me state, I'm actually using it with a wiki
family...
More testing is appreciated, since it's the first time I write anything for
mediawiki (or php in general, but it took only 2 hours to write it, it's not
that complicated)

Apply as usual, on the main mediawiki dir:

patch -p0  PostgreSQL.patch

This patch was written for the latest mediawiki ( 1.16.5 ), so it might NOT
work with previous version. It should not be difficoult to port it to older
version trough...

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2009-02-06 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794


Greg Sabino Mullane g...@turnstep.com changed:

   What|Removed |Added

 CC||g...@turnstep.com




--- Comment #5 from Greg Sabino Mullane g...@turnstep.com  2009-02-06 
15:18:36 UTC ---
I don't have time to dig into this much, but if it's just the user table being
shared, couldn't you simply change the line in DatabasePostgres.php to
something like this:

if ($wgSharedDB) {
  return $wgSharedDB.mwuser;
}
return 'mwuser';

You'd also have to ensure that the FKs are in the right place too, of course,
which means modifying tables.sql slightly for a new install, or recreating the
FK constraints on an existing database.

Hmm...all in all, sounds like some search_path munging might be easier overall.


-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2009-01-27 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794


lar...@towncommons.com changed:

   What|Removed |Added

 CC||lar...@towncommons.com




--- Comment #4 from lar...@towncommons.com  2009-01-28 05:25:52 UTC ---
So...what I'm hearing is that, if you want to have a wiki farm with a shared
user table right now, you have to go with MySQL.  *sigh*  This seems like the
kind of thing that ought to be explicitly mentioned in the shared-user-table
doco.


-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2008-12-25 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794





--- Comment #1 from Brad Jorsch b-jor...@northwestern.edu  2008-12-26 
02:20:13 UTC ---
Created an attachment (id=5624)
 -- (https://bugzilla.wikimedia.org/attachment.cgi?id=5624)
Completely untested patch

It has always struck me that MySQL's databases are about equivalent to PG's
schemas, so theoretically it should work. I wonder if this copy-paste from
Database.php is enough to make it work?


-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2008-12-25 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794





--- Comment #2 from Brent G overlo...@gmail.com  2008-12-26 02:48:27 UTC ---
I came up with something similar and this is what's wrong:

1) Wont work as-is, takes $wgSharedTables into account after the PG'ification
of table names. Should be moved to after the horrible  mess.
2) Once moved, yes logging in works, reading pages works. Editing . . . is
another matter. It doesn't take into account schema's so it inserts into
$table, which depending on the search_path might not be valid.


-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l


[Bug 16794] $wgSharedDB PostgreSQL support

2008-12-25 Thread bugzilla-daemon
https://bugzilla.wikimedia.org/show_bug.cgi?id=16794





--- Comment #3 from Brent G overlo...@gmail.com  2008-12-26 03:13:18 UTC ---
Ok, Ignore #2. Think I figured out why the editing is snafu.

say we have 2 wikis, awesomewiki  poolwiki with matching schemas.

Poolwiki has the shared usertable so $wgSharedDB = 'poolwiki';

User logs into awesomewiki. The search path gets set to awesomewiki, public. 
Currently, it checks for $wgSharedDB, see's that user table is shared, and
plops down the poolwiki schema before the queries. The lookup works since the
schema is explicit.  Next said logged in user goes to submit an edit.  MW goes
to insert a row into the revisions table with the user data.  There is a
foreign key constraint on rev_user to the mwuser table.  However since we're
sharing the poolwiki mwuser table  the searchpath is (awesomewiki, public),
it tries to lookup user in awesomewiki.mwuser which is empty and fails the
foreign key constraint.

So I'm stumped on what 'Best Practices' would say on how to move on from here.


-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug.
You are on the CC list for the bug.

___
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l