mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-04-06 15:00:40 +08:00
BugFix and selection in the test-suite of the bdb2 backend-specific
slapd server timing via a new slapd command line option '-t'.
This commit is contained in:
parent
2cf83d84ee
commit
548942edbe
@ -34,11 +34,11 @@ bdb2_back_abandon(
|
||||
struct timeval time1;
|
||||
int ret;
|
||||
|
||||
bdb2i_start_timing( be->be_private, &time1 );
|
||||
bdb2i_start_timing( be->bd_info, &time1 );
|
||||
|
||||
ret = bdb2i_back_abandon_internal( be, conn, op, msgid );
|
||||
|
||||
bdb2i_stop_timing( be->be_private, time1, "ABND", conn, op );
|
||||
bdb2i_stop_timing( be->bd_info, time1, "ABND", conn, op );
|
||||
|
||||
return( ret );
|
||||
}
|
||||
|
@ -239,7 +239,7 @@ bdb2_back_add(
|
||||
struct timeval time1;
|
||||
int ret;
|
||||
|
||||
bdb2i_start_timing( be->be_private, &time1 );
|
||||
bdb2i_start_timing( be->bd_info, &time1 );
|
||||
|
||||
if ( bdb2i_enter_backend_w( get_dbenv( be ), &lock ) != 0 ) {
|
||||
|
||||
@ -260,7 +260,7 @@ bdb2_back_add(
|
||||
|
||||
ret = bdb2i_back_add_internal( be, conn, op, e );
|
||||
(void) bdb2i_leave_backend( get_dbenv( be ), lock );
|
||||
bdb2i_stop_timing( be->be_private, time1, "ADD", conn, op );
|
||||
bdb2i_stop_timing( be->bd_info, time1, "ADD", conn, op );
|
||||
|
||||
return( ret );
|
||||
}
|
||||
|
@ -231,7 +231,7 @@ bdb2_back_bind(
|
||||
struct timeval time1;
|
||||
int ret;
|
||||
|
||||
bdb2i_start_timing( be->be_private, &time1 );
|
||||
bdb2i_start_timing( be->bd_info, &time1 );
|
||||
|
||||
if ( bdb2i_enter_backend_r( get_dbenv( be ), &lock ) != 0 ) {
|
||||
|
||||
@ -244,7 +244,7 @@ bdb2_back_bind(
|
||||
|
||||
(void) bdb2i_leave_backend( get_dbenv( be ), lock );
|
||||
|
||||
bdb2i_stop_timing( be->be_private, time1, "BIND", conn, op );
|
||||
bdb2i_stop_timing( be->bd_info, time1, "BIND", conn, op );
|
||||
|
||||
return( ret );
|
||||
}
|
||||
|
@ -32,11 +32,11 @@ bdb2_back_db_close( BackendDB *be )
|
||||
struct timeval time1;
|
||||
int ret;
|
||||
|
||||
bdb2i_start_timing( be->be_private, &time1 );
|
||||
bdb2i_start_timing( be->bd_info, &time1 );
|
||||
|
||||
ret = bdb2i_back_db_close_internal( be );
|
||||
|
||||
bdb2i_stop_timing( be->be_private, time1, "CLOSE", NULL, NULL );
|
||||
bdb2i_stop_timing( be->bd_info, time1, "CLOSE", NULL, NULL );
|
||||
|
||||
return( ret );
|
||||
}
|
||||
|
@ -76,7 +76,7 @@ bdb2_back_compare(
|
||||
struct timeval time1;
|
||||
int ret;
|
||||
|
||||
bdb2i_start_timing( be->be_private, &time1 );
|
||||
bdb2i_start_timing( be->bd_info, &time1 );
|
||||
|
||||
if ( bdb2i_enter_backend_r( get_dbenv( be ), &lock ) != 0 ) {
|
||||
|
||||
@ -87,7 +87,7 @@ bdb2_back_compare(
|
||||
|
||||
ret = bdb2i_back_compare_internal( be, conn, op, dn, ava );
|
||||
(void) bdb2i_leave_backend( get_dbenv( be ), lock );
|
||||
bdb2i_stop_timing( be->be_private, time1, "CMP", conn, op );
|
||||
bdb2i_stop_timing( be->bd_info, time1, "CMP", conn, op );
|
||||
|
||||
return( ret );
|
||||
}
|
||||
|
@ -189,11 +189,11 @@ bdb2_back_db_config(
|
||||
struct timeval time1;
|
||||
int ret;
|
||||
|
||||
bdb2i_start_timing( be->be_private, &time1 );
|
||||
bdb2i_start_timing( be->bd_info, &time1 );
|
||||
|
||||
ret = bdb2i_back_db_config_internal( be, fname, lineno, argc, argv );
|
||||
|
||||
bdb2i_stop_timing( be->be_private, time1, "DB-CONFIG", NULL, NULL );
|
||||
bdb2i_stop_timing( be->bd_info, time1, "DB-CONFIG", NULL, NULL );
|
||||
|
||||
return( ret );
|
||||
}
|
||||
|
@ -163,7 +163,7 @@ bdb2_back_delete(
|
||||
struct timeval time1;
|
||||
int ret;
|
||||
|
||||
bdb2i_start_timing( be->be_private, &time1 );
|
||||
bdb2i_start_timing( be->bd_info, &time1 );
|
||||
|
||||
if ( bdb2i_enter_backend_w( get_dbenv( be ), &lock ) != 0 ) {
|
||||
|
||||
@ -174,7 +174,7 @@ bdb2_back_delete(
|
||||
|
||||
ret = bdb2i_back_delete_internal( be, conn, op, dn );
|
||||
(void) bdb2i_leave_backend( get_dbenv( be ), lock );
|
||||
bdb2i_stop_timing( be->be_private, time1, "DEL", conn, op );
|
||||
bdb2i_stop_timing( be->bd_info, time1, "DEL", conn, op );
|
||||
|
||||
return( ret );
|
||||
}
|
||||
|
@ -139,7 +139,7 @@ bdb2_back_group(
|
||||
struct timeval time1;
|
||||
int ret;
|
||||
|
||||
bdb2i_start_timing( be->be_private, &time1 );
|
||||
bdb2i_start_timing( be->bd_info, &time1 );
|
||||
|
||||
if ( bdb2i_enter_backend_r( get_dbenv( be ), &lock ) != 0 ) {
|
||||
|
||||
@ -151,7 +151,7 @@ bdb2_back_group(
|
||||
objectclassValue, groupattrName );
|
||||
|
||||
(void) bdb2i_leave_backend( get_dbenv( be ), lock );
|
||||
bdb2i_stop_timing( be->be_private, time1, "GRP", NULL, NULL );
|
||||
bdb2i_stop_timing( be->bd_info, time1, "GRP", NULL, NULL );
|
||||
|
||||
return( ret );
|
||||
}
|
||||
|
@ -198,10 +198,10 @@ bdb2_back_db_init(
|
||||
struct timeval time1;
|
||||
int ret;
|
||||
|
||||
bdb2i_start_timing( be->be_private, &time1 );
|
||||
bdb2i_start_timing( be->bd_info, &time1 );
|
||||
|
||||
ret = bdb2i_back_db_init_internal( be );
|
||||
bdb2i_stop_timing( be->be_private, time1, "DB-INIT", NULL, NULL );
|
||||
bdb2i_stop_timing( be->bd_info, time1, "DB-INIT", NULL, NULL );
|
||||
|
||||
return( ret );
|
||||
}
|
||||
|
@ -129,7 +129,7 @@ bdb2_back_modify(
|
||||
struct timeval time1;
|
||||
int ret;
|
||||
|
||||
bdb2i_start_timing( be->be_private, &time1 );
|
||||
bdb2i_start_timing( be->bd_info, &time1 );
|
||||
|
||||
if ( bdb2i_enter_backend_w( get_dbenv( be ), &lock ) != 0 ) {
|
||||
|
||||
@ -150,7 +150,7 @@ bdb2_back_modify(
|
||||
|
||||
ret = bdb2i_back_modify_internal( be, conn, op, dn, modlist );
|
||||
(void) bdb2i_leave_backend( get_dbenv( be ), lock );
|
||||
bdb2i_stop_timing( be->be_private, time1, "MOD", conn, op );
|
||||
bdb2i_stop_timing( be->bd_info, time1, "MOD", conn, op );
|
||||
|
||||
return( ret );
|
||||
}
|
||||
|
@ -206,7 +206,7 @@ bdb2_back_modrdn(
|
||||
struct timeval time1;
|
||||
int ret;
|
||||
|
||||
bdb2i_start_timing( be->be_private, &time1 );
|
||||
bdb2i_start_timing( be->bd_info, &time1 );
|
||||
|
||||
if ( bdb2i_enter_backend_w( get_dbenv( be ), &lock ) != 0 ) {
|
||||
|
||||
@ -219,7 +219,7 @@ bdb2_back_modrdn(
|
||||
newrdn, deleteoldrdn );
|
||||
|
||||
(void) bdb2i_leave_backend( get_dbenv( be ), lock );
|
||||
bdb2i_stop_timing( be->be_private, time1, "MODRDN", conn, op );
|
||||
bdb2i_stop_timing( be->bd_info, time1, "MODRDN", conn, op );
|
||||
|
||||
return( ret );
|
||||
}
|
||||
|
@ -335,7 +335,7 @@ bdb2_back_search(
|
||||
struct timeval time1;
|
||||
int ret;
|
||||
|
||||
bdb2i_start_timing( be->be_private, &time1 );
|
||||
bdb2i_start_timing( be->bd_info, &time1 );
|
||||
|
||||
if ( bdb2i_enter_backend_r( get_dbenv( be ), &lock ) != 0 ) {
|
||||
|
||||
@ -348,7 +348,7 @@ bdb2_back_search(
|
||||
slimit, tlimit, filter, filterstr, attrs, attrsonly );
|
||||
|
||||
(void) bdb2i_leave_backend( get_dbenv( be ), lock );
|
||||
bdb2i_stop_timing( be->be_private, time1, "SRCH", conn, op );
|
||||
bdb2i_stop_timing( be->bd_info, time1, "SRCH", conn, op );
|
||||
|
||||
return( ret );
|
||||
}
|
||||
|
@ -191,10 +191,10 @@ bdb2_back_db_startup(
|
||||
struct timeval time1;
|
||||
int ret;
|
||||
|
||||
bdb2i_start_timing( be->be_private, &time1 );
|
||||
bdb2i_start_timing( be->bd_info, &time1 );
|
||||
|
||||
ret = bdb2i_back_db_startup_internal( be );
|
||||
bdb2i_stop_timing( be->be_private, time1, "DB-START", NULL, NULL );
|
||||
bdb2i_stop_timing( be->bd_info, time1, "DB-START", NULL, NULL );
|
||||
|
||||
return( ret );
|
||||
}
|
||||
@ -208,10 +208,10 @@ bdb2_back_db_shutdown(
|
||||
struct timeval time1;
|
||||
int ret;
|
||||
|
||||
bdb2i_start_timing( be->be_private, &time1 );
|
||||
bdb2i_start_timing( be->bd_info, &time1 );
|
||||
|
||||
ret = bdb2i_back_db_shutdown_internal( be );
|
||||
bdb2i_stop_timing( be->be_private, time1, "DB-SHUTDOWN", NULL, NULL );
|
||||
bdb2i_stop_timing( be->bd_info, time1, "DB-SHUTDOWN", NULL, NULL );
|
||||
|
||||
return( ret );
|
||||
}
|
||||
|
@ -29,10 +29,10 @@ bdb2_back_unbind(
|
||||
struct timeval time1;
|
||||
int ret;
|
||||
|
||||
bdb2i_start_timing( be->be_private, &time1 );
|
||||
bdb2i_start_timing( be->bd_info, &time1 );
|
||||
|
||||
ret = bdb2i_back_unbind_internal( be, conn, op );
|
||||
bdb2i_stop_timing( be->be_private, time1, "UNBIND", conn, op );
|
||||
bdb2i_stop_timing( be->bd_info, time1, "UNBIND", conn, op );
|
||||
|
||||
return( ret );
|
||||
}
|
||||
|
@ -17,6 +17,7 @@ if test "$BACKEND" = "bdb2" ; then
|
||||
ACLCONF=$DATADIR/slapd-bdb2-acl.conf
|
||||
MASTERCONF=$DATADIR/slapd-bdb2-repl-master.conf
|
||||
SLAVECONF=$DATADIR/slapd-bdb2-repl-slave.conf
|
||||
TIMING="-t"
|
||||
else
|
||||
LDIF2LDBM=../servers/slapd/tools/ldif2ldbm
|
||||
CONF=$DATADIR/slapd-master.conf
|
||||
|
@ -28,7 +28,7 @@ if [ $RC != 0 ]; then
|
||||
fi
|
||||
|
||||
echo "Starting slapd on TCP/IP port $PORT..."
|
||||
$SLAPD -f $CONF -p $PORT -d $LVL > $MASTERLOG 2>&1 &
|
||||
$SLAPD -f $CONF -p $PORT -d $LVL $TIMING > $MASTERLOG 2>&1 &
|
||||
PID=$!
|
||||
|
||||
echo "Using ldapsearch to retrieve all the entries..."
|
||||
|
@ -28,7 +28,7 @@ if [ $RC != 0 ]; then
|
||||
fi
|
||||
|
||||
echo "Starting slapd on TCP/IP port $PORT..."
|
||||
$SLAPD -f $CONF -p $PORT -d $LVL > $MASTERLOG 2>&1 &
|
||||
$SLAPD -f $CONF -p $PORT -d $LVL $TIMING > $MASTERLOG 2>&1 &
|
||||
PID=$!
|
||||
|
||||
echo "Using ldapsearch to retrieve all the entries..."
|
||||
|
@ -16,7 +16,7 @@ echo "Cleaning up in $DBDIR..."
|
||||
rm -f $DBDIR/[!C]*
|
||||
|
||||
echo "Starting slapd on TCP/IP port $PORT..."
|
||||
$SLAPD -f $CONF -p $PORT -d $LVL > $MASTERLOG 2>&1 &
|
||||
$SLAPD -f $CONF -p $PORT -d $LVL $TIMING > $MASTERLOG 2>&1 &
|
||||
PID=$!
|
||||
|
||||
echo "Using ldapsearch to check that slapd is running..."
|
||||
|
@ -24,7 +24,7 @@ if [ $RC != 0 ]; then
|
||||
fi
|
||||
|
||||
echo "Starting slapd on TCP/IP port $PORT..."
|
||||
$SLAPD -f $CONF -p $PORT -d $LVL > $MASTERLOG 2>&1 &
|
||||
$SLAPD -f $CONF -p $PORT -d $LVL $TIMING > $MASTERLOG 2>&1 &
|
||||
PID=$!
|
||||
|
||||
echo "Testing slapd searching..."
|
||||
|
@ -24,7 +24,7 @@ if [ $RC != 0 ]; then
|
||||
fi
|
||||
|
||||
echo "Starting slapd on TCP/IP port $PORT..."
|
||||
$SLAPD -f $CONF -p $PORT -d $LVL > $MASTERLOG 2>&1 &
|
||||
$SLAPD -f $CONF -p $PORT -d $LVL $TIMING > $MASTERLOG 2>&1 &
|
||||
PID=$!
|
||||
|
||||
echo "Testing slapd modify operations..."
|
||||
|
@ -24,7 +24,7 @@ if [ $RC != 0 ]; then
|
||||
fi
|
||||
|
||||
echo "Starting slapd on TCP/IP port $PORT..."
|
||||
$SLAPD -f $ACLCONF -p $PORT -d $LVL > $MASTERLOG 2>&1 &
|
||||
$SLAPD -f $ACLCONF -p $PORT -d $LVL $TIMING > $MASTERLOG 2>&1 &
|
||||
PID=$!
|
||||
|
||||
echo "Testing slapd access control..."
|
||||
|
@ -33,11 +33,11 @@ echo "Cleaning up in $REPLDIR..."
|
||||
rm -f $REPLDIR/[!C]*
|
||||
|
||||
echo "Starting master slapd on TCP/IP port $PORT..."
|
||||
$SLAPD -f $MASTERCONF -p $PORT -d $LVL > $MASTERLOG 2>&1 &
|
||||
$SLAPD -f $MASTERCONF -p $PORT -d $LVL $TIMING > $MASTERLOG 2>&1 &
|
||||
PID=$!
|
||||
|
||||
echo "Starting slave slapd on TCP/IP port $SLAVEPORT..."
|
||||
$SLAPD -f $SLAVECONF -p $SLAVEPORT -d $LVL > $SLAVELOG 2>&1 &
|
||||
$SLAPD -f $SLAVECONF -p $SLAVEPORT -d $LVL $TIMING > $SLAVELOG 2>&1 &
|
||||
SLAVEPID=$!
|
||||
|
||||
echo "Using ldapsearch to check that master slapd is running..."
|
||||
|
Loading…
x
Reference in New Issue
Block a user