Christopher Browne cbbrowne at ca.afilias.info
Thu Apr 10 09:25:14 PDT 2008
kevin kempter <kevin at kevinkempterllc.com> writes:
> I may have already asked this, but I couldn't find it in the archives
> ad zi want to be sure.
>
> Can SLONY replicate postGIS / spatial data ?

It should, as long as they use data types that can be manipulated via
INSERT/UPDATE/DELETE/COPY, and don't *require* further function usage
to access their data.

One of the base regression tests has, as examples, a whole series of
the data types supported by PostgreSQL:

create table table4 (
  id serial primary key,
  numcol numeric(12,4), -- 1.23
  realcol real,     -- (1.23)
  ptcol point,      -- (1,2)
  pathcol path,     -- ((1,1),(2,2),(3,3),(4,4))
  polycol polygon,  -- ((1,1),(2,2),(3,3),(4,4))
  circcol circle,   -- <(1,2>,3>
  ipcol inet,       -- "192.168.1.1"
  maccol macaddr,   -- "04:05:06:07:08:09"
  bitcol bit varying(20)  -- X'123' 
);

Those all work fine :-).

I'd definitely suggest running some tests on it before depending on
it, but I'd certainly expect it to work.

There is of course the extra "system management challenge" of needing
to manage deployment of code both for PostGIS and Slony-I, and to make
sure PostgreSQL is built suitably for both.

The requirements for both are fairly similar; they both need for all
PostgreSQL installations to include server header files ("make
install-all-headers").

Slony-I requires on some platforms (notably AIX, Solaris) that libpq
be compiled to be threadsafe (e.g. - PostgreSQL is configured with the
option --enable-thread-safety), which PostGIS doesn't seem to be
concerned about.  That might force you to rebuild PostgreSQL.

So there are some "small challenges" to be careful about; none of them
seem particularly insurmountable.  Good luck!  :-)
-- 
(format nil "~S@~S" "cbbrowne" "acm.org")
http://www3.sympatico.ca/cbbrowne/linuxxian.html
Rules of the Evil Overlord #79. "If my doomsday device happens to come
with  a reverse switch, as  soon as  it has  been employed  it will be
melted    down and  made  into   limited-edition commemorative coins."
<http://www.eviloverlord.com/>


More information about the Slony1-general mailing list