Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
74f17e4c
Commit
74f17e4c
authored
20 years ago
by
joreland@mysql.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix changed interface to HugoOperations
parent
9497ee2f
Branches unavailable
Tags unavailable
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
13 deletions
+13
-13
ndb/test/ndbapi/testRestartGci.cpp
ndb/test/ndbapi/testRestartGci.cpp
+2
-2
ndb/test/ndbapi/testTimeout.cpp
ndb/test/ndbapi/testTimeout.cpp
+11
-11
No files found.
ndb/test/ndbapi/testRestartGci.cpp
View file @
74f17e4c
...
@@ -63,7 +63,7 @@ int runInsertRememberGci(NDBT_Context* ctx, NDBT_Step* step){
...
@@ -63,7 +63,7 @@ int runInsertRememberGci(NDBT_Context* ctx, NDBT_Step* step){
result
=
NDBT_FAILED
;
result
=
NDBT_FAILED
;
break
;
break
;
}
}
CHECK
(
hugoOps
.
pkReadRecord
(
pNdb
,
i
,
false
)
==
0
);
CHECK
(
hugoOps
.
pkReadRecord
(
pNdb
,
i
)
==
0
);
if
(
hugoOps
.
execute_Commit
(
pNdb
)
!=
0
){
if
(
hugoOps
.
execute_Commit
(
pNdb
)
!=
0
){
ndbout
<<
"Did not find record in DB "
<<
i
<<
endl
;
ndbout
<<
"Did not find record in DB "
<<
i
<<
endl
;
result
=
NDBT_FAILED
;
result
=
NDBT_FAILED
;
...
@@ -146,7 +146,7 @@ int runVerifyInserts(NDBT_Context* ctx, NDBT_Step* step){
...
@@ -146,7 +146,7 @@ int runVerifyInserts(NDBT_Context* ctx, NDBT_Step* step){
// gci as in the vector
// gci as in the vector
for
(
unsigned
i
=
0
;
i
<
savedRecords
.
size
();
i
++
){
for
(
unsigned
i
=
0
;
i
<
savedRecords
.
size
();
i
++
){
CHECK
(
hugoOps
.
startTransaction
(
pNdb
)
==
0
);
CHECK
(
hugoOps
.
startTransaction
(
pNdb
)
==
0
);
CHECK
(
hugoOps
.
pkReadRecord
(
pNdb
,
i
,
false
)
==
0
);
CHECK
(
hugoOps
.
pkReadRecord
(
pNdb
,
i
)
==
0
);
if
(
hugoOps
.
execute_Commit
(
pNdb
)
!=
0
){
if
(
hugoOps
.
execute_Commit
(
pNdb
)
!=
0
){
// Record was not found in db'
// Record was not found in db'
...
...
This diff is collapsed.
Click to expand it.
ndb/test/ndbapi/testTimeout.cpp
View file @
74f17e4c
...
@@ -108,7 +108,7 @@ int runTimeoutTrans(NDBT_Context* ctx, NDBT_Step* step){
...
@@ -108,7 +108,7 @@ int runTimeoutTrans(NDBT_Context* ctx, NDBT_Step* step){
do
{
do
{
// Commit transaction
// Commit transaction
CHECK
(
hugoOps
.
startTransaction
(
pNdb
)
==
0
);
CHECK
(
hugoOps
.
startTransaction
(
pNdb
)
==
0
);
CHECK
(
hugoOps
.
pkReadRecord
(
pNdb
,
stepNo
,
true
)
==
0
);
CHECK
(
hugoOps
.
pkReadRecord
(
pNdb
,
stepNo
)
==
0
);
CHECK
(
hugoOps
.
execute_NoCommit
(
pNdb
)
==
0
);
CHECK
(
hugoOps
.
execute_NoCommit
(
pNdb
)
==
0
);
int
sleep
=
minSleep
+
myRandom48
(
maxSleep
-
minSleep
);
int
sleep
=
minSleep
+
myRandom48
(
maxSleep
-
minSleep
);
...
@@ -162,25 +162,25 @@ int runTimeoutTrans2(NDBT_Context* ctx, NDBT_Step* step){
...
@@ -162,25 +162,25 @@ int runTimeoutTrans2(NDBT_Context* ctx, NDBT_Step* step){
case
0
:
case
0
:
break
;
break
;
case
1
:
case
1
:
if
(
hugoOps
.
pkReadRecord
(
pNdb
,
stepNo
,
true
)
!=
0
){
if
(
hugoOps
.
pkReadRecord
(
pNdb
,
stepNo
)
!=
0
){
g_err
<<
stepNo
<<
": Fail"
<<
__LINE__
<<
endl
;
g_err
<<
stepNo
<<
": Fail"
<<
__LINE__
<<
endl
;
result
=
NDBT_FAILED
;
break
;
result
=
NDBT_FAILED
;
break
;
}
}
break
;
break
;
case
2
:
case
2
:
if
(
hugoOps
.
pkUpdateRecord
(
pNdb
,
stepNo
,
true
)
!=
0
){
if
(
hugoOps
.
pkUpdateRecord
(
pNdb
,
stepNo
)
!=
0
){
g_err
<<
stepNo
<<
": Fail"
<<
__LINE__
<<
endl
;
g_err
<<
stepNo
<<
": Fail"
<<
__LINE__
<<
endl
;
result
=
NDBT_FAILED
;
break
;
result
=
NDBT_FAILED
;
break
;
}
}
break
;
break
;
case
3
:
case
3
:
if
(
hugoOps
.
pkDeleteRecord
(
pNdb
,
stepNo
,
true
)
!=
0
){
if
(
hugoOps
.
pkDeleteRecord
(
pNdb
,
stepNo
)
!=
0
){
g_err
<<
stepNo
<<
": Fail"
<<
__LINE__
<<
endl
;
g_err
<<
stepNo
<<
": Fail"
<<
__LINE__
<<
endl
;
result
=
NDBT_FAILED
;
break
;
result
=
NDBT_FAILED
;
break
;
}
}
break
;
break
;
case
4
:
case
4
:
if
(
hugoOps
.
pkInsertRecord
(
pNdb
,
stepNo
+
records
+
l
,
true
)
!=
0
){
if
(
hugoOps
.
pkInsertRecord
(
pNdb
,
stepNo
+
records
+
l
)
!=
0
){
g_err
<<
stepNo
<<
": Fail"
<<
__LINE__
<<
endl
;
g_err
<<
stepNo
<<
": Fail"
<<
__LINE__
<<
endl
;
result
=
NDBT_FAILED
;
break
;
result
=
NDBT_FAILED
;
break
;
}
}
...
@@ -204,25 +204,25 @@ int runTimeoutTrans2(NDBT_Context* ctx, NDBT_Step* step){
...
@@ -204,25 +204,25 @@ int runTimeoutTrans2(NDBT_Context* ctx, NDBT_Step* step){
case
0
:
case
0
:
break
;
break
;
case
1
:
case
1
:
if
(
hugoOps
.
pkReadRecord
(
pNdb
,
stepNo
,
true
)
!=
0
){
if
(
hugoOps
.
pkReadRecord
(
pNdb
,
stepNo
)
!=
0
){
g_err
<<
stepNo
<<
": Fail"
<<
__LINE__
<<
endl
;
g_err
<<
stepNo
<<
": Fail"
<<
__LINE__
<<
endl
;
result
=
NDBT_FAILED
;
break
;
result
=
NDBT_FAILED
;
break
;
}
}
break
;
break
;
case
2
:
case
2
:
if
(
hugoOps
.
pkUpdateRecord
(
pNdb
,
stepNo
,
true
)
!=
0
){
if
(
hugoOps
.
pkUpdateRecord
(
pNdb
,
stepNo
)
!=
0
){
g_err
<<
stepNo
<<
": Fail"
<<
__LINE__
<<
endl
;
g_err
<<
stepNo
<<
": Fail"
<<
__LINE__
<<
endl
;
result
=
NDBT_FAILED
;
break
;
result
=
NDBT_FAILED
;
break
;
}
}
break
;
break
;
case
3
:
case
3
:
if
(
hugoOps
.
pkDeleteRecord
(
pNdb
,
stepNo
,
true
)
!=
0
){
if
(
hugoOps
.
pkDeleteRecord
(
pNdb
,
stepNo
)
!=
0
){
g_err
<<
stepNo
<<
": Fail"
<<
__LINE__
<<
endl
;
g_err
<<
stepNo
<<
": Fail"
<<
__LINE__
<<
endl
;
result
=
NDBT_FAILED
;
break
;
result
=
NDBT_FAILED
;
break
;
}
}
break
;
break
;
case
4
:
case
4
:
if
(
hugoOps
.
pkInsertRecord
(
pNdb
,
stepNo
+
2
*
records
+
l
,
true
)
!=
0
){
if
(
hugoOps
.
pkInsertRecord
(
pNdb
,
stepNo
+
2
*
records
+
l
)
!=
0
){
g_err
<<
stepNo
<<
": Fail"
<<
__LINE__
<<
endl
;
g_err
<<
stepNo
<<
": Fail"
<<
__LINE__
<<
endl
;
result
=
NDBT_FAILED
;
break
;
result
=
NDBT_FAILED
;
break
;
}
}
...
@@ -263,7 +263,7 @@ int runDontTimeoutTrans(NDBT_Context* ctx, NDBT_Step* step){
...
@@ -263,7 +263,7 @@ int runDontTimeoutTrans(NDBT_Context* ctx, NDBT_Step* step){
do
{
do
{
// Commit transaction
// Commit transaction
CHECK
(
hugoOps
.
startTransaction
(
pNdb
)
==
0
);
CHECK
(
hugoOps
.
startTransaction
(
pNdb
)
==
0
);
CHECK
(
hugoOps
.
pkReadRecord
(
pNdb
,
stepNo
,
true
)
==
0
);
CHECK
(
hugoOps
.
pkReadRecord
(
pNdb
,
stepNo
)
==
0
);
CHECK
(
hugoOps
.
execute_NoCommit
(
pNdb
)
==
0
);
CHECK
(
hugoOps
.
execute_NoCommit
(
pNdb
)
==
0
);
int
sleep
=
myRandom48
(
maxSleep
);
int
sleep
=
myRandom48
(
maxSleep
);
...
@@ -299,7 +299,7 @@ int runBuddyTransNoTimeout(NDBT_Context* ctx, NDBT_Step* step){
...
@@ -299,7 +299,7 @@ int runBuddyTransNoTimeout(NDBT_Context* ctx, NDBT_Step* step){
// Start an insert trans
// Start an insert trans
CHECK
(
hugoOps
.
startTransaction
(
pNdb
)
==
0
);
CHECK
(
hugoOps
.
startTransaction
(
pNdb
)
==
0
);
int
recordNo
=
records
+
(
stepNo
*
loops
)
+
l
;
int
recordNo
=
records
+
(
stepNo
*
loops
)
+
l
;
CHECK
(
hugoOps
.
pkInsertRecord
(
pNdb
,
recordNo
,
true
)
==
0
);
CHECK
(
hugoOps
.
pkInsertRecord
(
pNdb
,
recordNo
)
==
0
);
CHECK
(
hugoOps
.
execute_NoCommit
(
pNdb
)
==
0
);
CHECK
(
hugoOps
.
execute_NoCommit
(
pNdb
)
==
0
);
for
(
int
i
=
0
;
i
<
3
;
i
++
){
for
(
int
i
=
0
;
i
<
3
;
i
++
){
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment