pgpool2.git / summary / log / commit / refs

commit    3804ec8ce6204e41ae8005384c11cd366c5f7a90
Author:   Tatsuo Ishii <ishii at sraoss.co.jp>
Date:     Wed Nov 17 06:57:38 2010 +0000

    Fix insert_lock().
    Comment for this function was not correct. It did not issue BEGIN.
    per_node_statement was not called for nodes other than master.


pool_process_query.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pool_process_query.c b/pool_process_query.c index b57c031f0..846ddc534 100644 --- a/pool_process_query.c +++ b/pool_process_query.c @@ -2713,8 +2713,7 @@ int need_insert_lock(POOL_CONNECTION_POOL *backend, char *query, Node *node) } /* - * If a transaction has not already started, start a new one. - * issue LOCK TABLE IN SHARE ROW EXCLUSIVE MODE if lock_kind == 1. + * Issue LOCK TABLE IN SHARE ROW EXCLUSIVE MODE if lock_kind == 1. * Issue row lock if lock_kind == 2. */ POOL_STATUS insert_lock(POOL_CONNECTION *frontend, POOL_CONNECTION_POOL *backend, char *query, InsertStmt *node, int lock_kind) @@ -2837,6 +2836,8 @@ POOL_STATUS insert_lock(POOL_CONNECTION *frontend, POOL_CONNECTION_POOL *backend MASTER_CONNECTION(backend)->pid, MASTER_CONNECTION(backend)->key, 0); else { + per_node_statement_log(backend, i, qbuf); + if (lock_kind == 1) { status = do_command(frontend, CONNECTION(backend, i), qbuf, PROTO_MAJOR_V3, [parent: 8b9e92cb1e9c]