diff options
author | Jun Kuriyama <kuriyama@FreeBSD.org> | 2004-06-25 05:38:30 +0000 |
---|---|---|
committer | Jun Kuriyama <kuriyama@FreeBSD.org> | 2004-06-25 05:38:30 +0000 |
commit | fd7debda486f84c0277ea4fb2849f1949e8fcb54 (patch) | |
tree | c6b2bc2982c4960aa7f54aa00cc73051fb0fbbd3 /databases | |
parent | 12fde0958c861344bdf37ab5b51ab91467ebddf1 (diff) | |
download | ports-fd7debda486f84c0277ea4fb2849f1949e8fcb54.tar.gz ports-fd7debda486f84c0277ea4fb2849f1949e8fcb54.zip |
Upgrade to 1.0.7 stable release.
Notes
Notes:
svn path=/head/; revision=112195
Diffstat (limited to 'databases')
-rw-r--r-- | databases/pgcluster/Makefile | 8 | ||||
-rw-r--r-- | databases/pgcluster/distinfo | 8 | ||||
-rw-r--r-- | databases/pgcluster/files/patch-pgrp:recovery.c | 39 | ||||
-rw-r--r-- | databases/pgcluster/files/patch-pgrp:replicate.c | 120 | ||||
-rw-r--r-- | databases/pgcluster/files/patch-pool_connection_pool.c | 12 |
5 files changed, 95 insertions, 92 deletions
diff --git a/databases/pgcluster/Makefile b/databases/pgcluster/Makefile index b56b458dab31..bc1613dd4628 100644 --- a/databases/pgcluster/Makefile +++ b/databases/pgcluster/Makefile @@ -5,15 +5,15 @@ # $FreeBSD$ PORTNAME= pgcluster -PORTVERSION= 1.0.6c.a14 +PORTVERSION= 1.0.7 CATEGORIES= databases MASTER_SITES= ${MASTER_SITE_PGSQL} -MASTER_SITE_SUBDIR= v${BASEPGSQL} +MASTER_SITE_SUBDIR= source/v${BASEPGSQL} DISTNAME= postgresql-base-${BASEPGSQL} DIST_SUBDIR= postgresql PATCH_SITES= http://dist.bsdlab.org/ -PATCHFILES= pgcluster-${PORTVERSION}-patch.tar.gz +PATCHFILES= pgcluster-${PORTVERSION}-patch.bz2 PATCH_DIST_STRIP= -p0 MAINTAINER= kuriyama@FreeBSD.org @@ -37,7 +37,7 @@ INSTALL_TARGET= install INSTALL_TARGET= install-strip .endif -BASEPGSQL= 7.3.4 +BASEPGSQL= 7.3.6 .if defined(WITHOUT_PGCLUSTER_REPLICATION) PGRP= "@comment " .endif diff --git a/databases/pgcluster/distinfo b/databases/pgcluster/distinfo index 53729c292d1c..237c3cc2bcb2 100644 --- a/databases/pgcluster/distinfo +++ b/databases/pgcluster/distinfo @@ -1,4 +1,4 @@ -MD5 (postgresql/postgresql-base-7.3.4.tar.gz) = 2b8600cc0f0c2d80271b533c394c886b -SIZE (postgresql/postgresql-base-7.3.4.tar.gz) = 7137288 -MD5 (postgresql/pgcluster-1.0.6c.a14-patch.tar.gz) = e4edd9b86f43a51929e826804830efd5 -SIZE (postgresql/pgcluster-1.0.6c.a14-patch.tar.gz) = 207961 +MD5 (postgresql/postgresql-base-7.3.6.tar.gz) = 6d35055a09fdb86cbbb6f4e556e038ef +SIZE (postgresql/postgresql-base-7.3.6.tar.gz) = 7147448 +MD5 (postgresql/pgcluster-1.0.7-patch.bz2) = 2ac6a0be0c9c0b5c2066896c8f19a7ea +SIZE (postgresql/pgcluster-1.0.7-patch.bz2) = 135242 diff --git a/databases/pgcluster/files/patch-pgrp:recovery.c b/databases/pgcluster/files/patch-pgrp:recovery.c index 834b279235d8..ad2b2865d29f 100644 --- a/databases/pgcluster/files/patch-pgrp:recovery.c +++ b/databases/pgcluster/files/patch-pgrp:recovery.c @@ -1,5 +1,5 @@ ---- src/pgcluster/pgrp/recovery.c 16 Apr 2004 10:17:45 -0000 1.1.1.4 -+++ src/pgcluster/pgrp/recovery.c 16 Apr 2004 10:21:06 -0000 1.5 +--- src/pgcluster/pgrp/recovery.c.orig Thu Jun 24 22:08:25 2004 ++++ src/pgcluster/pgrp/recovery.c Thu Jun 24 22:08:25 2004 @@ -121,7 +121,7 @@ int packet_size = 0; @@ -86,7 +86,7 @@ PGRset_recovery_packet_no(packet, RECOVERY_ERROR_CONNECTION); status = send_packet(Target, packet); reset_recovery_prepare(); -@@ -387,14 +387,14 @@ +@@ -387,18 +387,18 @@ Master->sock = -1; Master->port = master->port; Master->recoveryPort = master->recoveryPort; @@ -102,17 +102,13 @@ + show_error("connection error , master may be down"); PGRset_host_status(master,DB_TBL_ERROR); goto retry_connect_master ; - /* -@@ -405,7 +405,7 @@ - return loop_end; - */ } - + /* * start prepare of recovery * set recovery status to "prepare start" -@@ -415,10 +415,10 @@ +@@ -408,10 +408,10 @@ /* * wait answer from master server */ @@ -125,7 +121,7 @@ if (ntohs(packet->packet_no) == RECOVERY_PGDATA_ANS) { /* -@@ -461,7 +461,7 @@ +@@ -454,7 +454,7 @@ status = PGRwait_transaction_count_clear(); if (status != STATUS_OK) { @@ -134,7 +130,7 @@ PGRset_recovery_packet_no(packet, RECOVERY_ERROR_CONNECTION); status = send_packet(Target,packet); status = send_packet(Master,packet); -@@ -479,7 +479,7 @@ +@@ -472,7 +472,7 @@ /* * connection error , master may be down */ @@ -143,7 +139,7 @@ PGRset_recovery_packet_no(packet, RECOVERY_ERROR_CONNECTION); status = send_packet(Target,packet); status = send_packet(Master,packet); -@@ -508,7 +508,7 @@ +@@ -501,7 +501,7 @@ } else { @@ -152,7 +148,7 @@ PGRset_recovery_packet_no(packet, RECOVERY_ERROR_CONNECTION); status = send_packet(Target,packet); status = send_packet(Master,packet); -@@ -538,23 +538,23 @@ +@@ -531,23 +531,23 @@ if (master == (RecoveryTbl *)NULL) { @@ -181,7 +177,7 @@ return STATUS_ERROR; } } -@@ -621,7 +621,7 @@ +@@ -617,7 +617,7 @@ { free(msg_header); } @@ -190,7 +186,7 @@ return status; } -@@ -642,7 +642,7 @@ +@@ -638,7 +638,7 @@ set_function("pgrecovery_loop"); count = 0; @@ -199,7 +195,7 @@ while ((status = PGR_Create_Acception(fd,&sock,"",Recovery_Port_Number)) != STATUS_OK) { show_error("PGR_Create_Acception failed"); -@@ -682,7 +682,7 @@ +@@ -678,7 +678,7 @@ continue; } @@ -208,7 +204,7 @@ switch (ntohs(packet.packet_no)) { -@@ -739,7 +739,7 @@ +@@ -736,7 +736,7 @@ status = send_packet(&Target,&packet); } /* @@ -217,7 +213,7 @@ */ finish_recovery(); loop_end = true; -@@ -752,7 +752,7 @@ +@@ -749,7 +749,7 @@ memset((char *)&MasterPacketData,0,sizeof(RecoveryPacket)); break; case RECOVERY_ERROR_ANS : @@ -226,12 +222,3 @@ status = PGRsend_queue(&Master,NULL); memset(&packet,0,sizeof(RecoveryPacket)); PGRset_recovery_packet_no(&packet, RECOVERY_ERROR_ANS); -@@ -807,7 +807,7 @@ - */ - FD_ZERO(&rmask); - FD_SET(fd,&rmask); -- show_debug("wait recovery\n"); -+ show_debug("wait recovery"); - rtn = select(fd+1, &rmask, (fd_set *)NULL, (fd_set *)NULL, &timeout); - if (rtn && FD_ISSET(fd, &rmask)) - { diff --git a/databases/pgcluster/files/patch-pgrp:replicate.c b/databases/pgcluster/files/patch-pgrp:replicate.c index acf3bfe47797..8d3c0ae82abb 100644 --- a/databases/pgcluster/files/patch-pgrp:replicate.c +++ b/databases/pgcluster/files/patch-pgrp:replicate.c @@ -1,15 +1,6 @@ ---- src/pgcluster/pgrp/replicate.c 9 May 2004 11:21:36 -0000 1.1.1.10 -+++ src/pgcluster/pgrp/replicate.c 9 May 2004 11:51:34 -0000 1.6 -@@ -150,7 +150,7 @@ - ptr = Dbserver_Tbl_Begin; - while (ptr != NULL) - { -- show_debug("search host(%d):port(%d):db(%s)",ptr->hostIP,ptr->port,ptr->dbName); -+ show_debug("search host(%08x):port(%d):db(%s)",ptr->hostIP,ptr->port,ptr->dbName); - if ((ptr->useFlag == DB_TBL_USE) && - (ptr->hostIP == host) && - (ptr->port == host_ptr->port) && -@@ -380,6 +380,7 @@ +--- src/pgcluster/pgrp/replicate.c.orig Thu Jun 24 22:12:48 2004 ++++ src/pgcluster/pgrp/replicate.c Thu Jun 24 22:20:38 2004 +@@ -237,6 +237,7 @@ show_error("insertTransactionTbl failed"); return (TransactionTbl *)NULL; } @@ -17,7 +8,7 @@ return ptr; } -@@ -568,8 +569,10 @@ +@@ -386,8 +387,10 @@ set_function("PGRadd_HostTbl"); ptr = PGRget_HostTbl(conf_data->hostName, conf_data->port); @@ -28,7 +19,7 @@ PGRset_host_status(ptr,useFlag); return ptr; } -@@ -593,6 +596,7 @@ +@@ -411,6 +414,7 @@ { (ptr + 1) -> useFlag = DB_TBL_END; } @@ -36,20 +27,13 @@ ptr->hostNum = cnt; memcpy(ptr->hostName,conf_data->hostName,sizeof(ptr->hostName)); ptr->port = conf_data->port; -@@ -611,19 +615,22 @@ +@@ -429,14 +433,17 @@ set_function("PGRget_master"); host_tbl = Host_Tbl_Begin; + show_debug("start get_master loop"); while(host_tbl->useFlag != DB_TBL_END) { -- show_debug("name %s flg %d port %d recoveryPort %d ", -+ show_debug(" %s:%d flg %d recoveryPort %d", - host_tbl->hostName, -- host_tbl->useFlag, - host_tbl->port, -+ host_tbl->useFlag, - host_tbl->recoveryPort); if (host_tbl->useFlag == DB_TBL_USE) { + show_debug("found master"); @@ -61,7 +45,7 @@ return (HostTbl *)NULL; } -@@ -638,6 +645,9 @@ +@@ -451,6 +458,9 @@ PGRsem_lock(SemID,SEM_NUM_OF_RECOVERY); if (Recovery_Status_Inf != (RecoveryStatusInf *)NULL) { @@ -71,16 +55,7 @@ Recovery_Status_Inf->recovery_status = status; } PGRsem_unlock(SemID,SEM_NUM_OF_RECOVERY); -@@ -786,7 +796,7 @@ - { - if (Recovery_Status_Inf->useFlag != DB_TBL_FREE) - { -- show_debug("check recovered host %d",Recovery_Status_Inf->useFlag); -+ show_debug("check recovered host (useFlag=%d)",Recovery_Status_Inf->useFlag); - ptr = PGRadd_HostTbl((HostTbl *)&(Recovery_Status_Inf->target_host),Recovery_Status_Inf->useFlag); - if (ptr == (HostTbl *) NULL) - { -@@ -817,6 +827,8 @@ +@@ -629,6 +639,8 @@ if (target != (HostTbl*)NULL) { memcpy((HostTbl *)&(Recovery_Status_Inf->target_host),target,sizeof(HostTbl)); @@ -89,7 +64,7 @@ PGRset_host_status(target,useFlag); } -@@ -1032,6 +1044,7 @@ +@@ -845,6 +857,7 @@ { return STATUS_ERROR; } @@ -97,24 +72,15 @@ if (host_ptr->useFlag != status) { host_ptr->useFlag = status; -@@ -1257,6 +1270,7 @@ - show_debug("send_replicate_packet_to_server query=%s",query); +@@ -1028,6 +1041,7 @@ } + conn = transaction_tbl->conn; + set_function("PGRsend_replicate_packet_to_server"); if (conn == NULL) { show_error("[%d@%s] may be down",host_ptr->port,host_ptr->hostName); -@@ -1332,7 +1346,7 @@ - - if (res == NULL) - { -- show_error("PQexec error "); -+ show_error("PQexec error"); - if ( header->cmdSts != CMD_STS_NOTICE ) - { - PGRset_host_status(host_ptr,DB_TBL_ERROR); -@@ -1532,6 +1546,7 @@ +@@ -1268,6 +1282,7 @@ len = strlen(hostName); ptr = Host_Tbl_Begin; @@ -122,3 +88,65 @@ if (len > sizeof(ptr->hostName)) { len = sizeof(ptr->hostName); +@@ -1709,7 +1724,7 @@ + gettimeofday(&tv,NULL); + header->tv.tv_sec = htonl(tv.tv_sec); + header->tv.tv_usec = htonl(tv.tv_usec); +- show_debug("query :: %s\n",query); ++ show_debug("query :: %s",query); + + /* save header for logging */ + if (is_need_sync_time(header) == true) +@@ -1965,18 +1980,18 @@ + /* set function name */ + set_function("PGRreplicate_packet_send"); + +- show_debug("cmdSts=%c\n",header->cmdSts); +- show_debug("cmdType=%c\n",header->cmdType); +- show_debug("port=%d\n",ntohs(header->port)); +- show_debug("pid=%d\n",ntohs(header->pid)); +- show_debug("except_host=%s\n",header->except_host); +- show_debug("from_host=%s\n",header->from_host); +- show_debug("dbName=%s\n",header->dbName); +- show_debug("userName=%s\n",header->userName); +- show_debug("recieve sec=%u\n",ntohl(header->tv.tv_sec)); +- show_debug("recieve usec=%u\n",ntohl(header->tv.tv_usec)); +- show_debug("query_size=%d\n",ntohl(header->query_size)); +- show_debug("query=%s\n",query); ++ show_debug("cmdSts=%c",header->cmdSts); ++ show_debug("cmdType=%c",header->cmdType); ++ show_debug("port=%d",ntohs(header->port)); ++ show_debug("pid=%d",ntohs(header->pid)); ++ show_debug("except_host=%s",header->except_host); ++ show_debug("from_host=%s",header->from_host); ++ show_debug("dbName=%s",header->dbName); ++ show_debug("userName=%s",header->userName); ++ show_debug("recieve sec=%u",ntohl(header->tv.tv_sec)); ++ show_debug("recieve usec=%u",ntohl(header->tv.tv_usec)); ++ show_debug("query_size=%d",ntohl(header->query_size)); ++ show_debug("query=%s",query); + + /* + * loop while registrated cluster DB exist +@@ -2004,7 +2019,7 @@ + */ + if (is_master_in_recovery(ptr->hostName, ptr->port) == true) + { +- show_debug("%s skipped\n",ptr->hostName); ++ show_debug("%s skipped",ptr->hostName); + ptr ++; + continue; + } +@@ -2228,10 +2243,10 @@ + set_function("PGRreplicate_packet_send_each_server"); + + host = ptr->hostName; +- show_debug("except:%d@%s host:%d@%s\n", ++ show_debug("except:%d@%s host:%d@%s", + ntohs(header->port),header->except_host, + ptr->port,ptr->hostName); +- show_debug("send replicate to:%s\n",host); ++ show_debug("send replicate to:%s",host); + /* + * send query to cluster DB + */ diff --git a/databases/pgcluster/files/patch-pool_connection_pool.c b/databases/pgcluster/files/patch-pool_connection_pool.c deleted file mode 100644 index 61d999e438b0..000000000000 --- a/databases/pgcluster/files/patch-pool_connection_pool.c +++ /dev/null @@ -1,12 +0,0 @@ ---- src/pgcluster/pglb/pool_connection_pool.c 9 May 2004 11:21:36 -0000 1.1.1.4 -+++ src/pgcluster/pglb/pool_connection_pool.c 13 May 2004 13:57:23 -0000 1.5 -@@ -24,6 +24,9 @@ - */ - #include "config.h" - -+#ifdef HAVE_SYS_TYPES_H -+#include <sys/types.h> -+#endif - #include <sys/socket.h> - #include <sys/un.h> - #ifdef HAVE_NETINET_TCP_H |