transactd 3.0.0-x86-mswin32-100 → 3.1.0-x86-mswin32-100

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 67f8a84256a3ffc4114ed1af3db447c0d562708f
4
- data.tar.gz: 6bddf802000f968a6df0e6cad4977d1def1d94c2
3
+ metadata.gz: f4c734af1505593cbcb0ae5bd29b39f9cf8f43a0
4
+ data.tar.gz: 44495611def4f4b3ef3733c48d30cf77b1e0f424
5
5
  SHA512:
6
- metadata.gz: fb21f6e1c49c1ce6f3204efac720810ee04bb768ec3064113c7fae864f6d137180d643f9e5e8e614c815a208fe81aab49388ebc95520c988aad0222c2735d8c5
7
- data.tar.gz: 3323709b33bed8267122319b4cc7ff14611674ac09797791f7994d438d756f203d80517ad9e64b53b71cc1f2567c6857b9bc75d7938cedb7e77e01571a59a358
6
+ metadata.gz: d0c23d5b68233bd73be52d7af638c1a5dc9cae4137c9e267c53dd94451c7c0718cc854c20fa0d9cf8b9a1f038f959b48167ccc957b166a090307d020c8800eef
7
+ data.tar.gz: dd574553c439b058ec29444c87f7416e6cc4c9ffe0f776cf3a9e25d86e889a39cff686a4b82b22781047c6f69b3e8569fe998a4c60d71f83cb8e080ac9fe89f4
data/bin/2.0/transactd.so CHANGED
Binary file
data/bin/2.1/transactd.so CHANGED
Binary file
data/bin/2.2/transactd.so CHANGED
Binary file
Binary file
Binary file
@@ -125,8 +125,8 @@ def Read(db, tb, start, endid, shapshot)
125
125
  for i in start..(endid - 1) do
126
126
  tb.setFV(FN_ID, i)
127
127
  tb.seek()
128
- if ((tb.stat() != 0) || (tb.getFVlng(FN_ID) != i))
129
- puts("GetEqual Error stat() = #{tb.stat().to_s} Value #{i.to_s} = #{tb.getFVlng(FN_ID).to_s}")
128
+ if ((tb.stat() != 0) || (tb.getFVint(FN_ID) != i))
129
+ puts("GetEqual Error stat() = #{tb.stat().to_s} Value #{i.to_s} = #{tb.getFVint(FN_ID).to_s}")
130
130
  ret = false
131
131
  break
132
132
  end
@@ -151,8 +151,8 @@ def Reads(db, tb, start, endid, unit, shapshot)
151
151
  while (en != endid)
152
152
  en = st + unit
153
153
  for i in st..(en - 1) do
154
- if (tb.getFVlng(FN_ID) != i)
155
- puts("findNext Error stat() = #{tb.stat().to_s} Value #{i.to_s} = #{tb.getFVlng(FN_ID).to_s}")
154
+ if (tb.getFVint(FN_ID) != i)
155
+ puts("findNext Error stat() = #{tb.stat().to_s} Value #{i.to_s} = #{tb.getFVint(FN_ID).to_s}")
156
156
  ret = false
157
157
  break
158
158
  end
@@ -220,7 +220,7 @@ def createTestDataBase(db, uri)
220
220
  fd = dbdef.insertField(td.id, 1)
221
221
  fd.setName('name')
222
222
  fd.type = Transactd::Ft_myvarchar
223
- fd.len = 100
223
+ fd.setLenByCharnum(20)
224
224
  dbdef.updateTableDef(td.id)
225
225
 
226
226
  kd = dbdef.insertKey(td.id, 0)
@@ -295,9 +295,9 @@ def main(argv)
295
295
  if (!db.open(uri, Transactd::TYPE_SCHEMA_BDF, Transactd::TD_OPEN_NORMAL, '', ''))
296
296
  puts("open table erorr No:#{db.stat().to_s}")
297
297
  else
298
- tb = openTable(db, 'users', Transactd::TD_OPEN_NORMAL)
298
+ tb = openTable(db, 'user', Transactd::TD_OPEN_NORMAL)
299
299
  if tb == nil
300
- puts "can not open table 'users'"
300
+ puts "can not open table 'user'"
301
301
  db.close()
302
302
  return
303
303
  end
@@ -1489,6 +1489,14 @@ def testConflict()
1489
1489
  db.close()
1490
1490
  end
1491
1491
 
1492
+ def isMySQL5_7(db)
1493
+ vv = Transactd::BtrVersions.new()
1494
+ db.getBtrVersion(vv)
1495
+ return (db.stat() == 0) &&
1496
+ ((vv.version(1).majorVersion == 5) &&
1497
+ (vv.version(1).minorVersion == 7))
1498
+ end
1499
+
1492
1500
  def testExclusive()
1493
1501
  # db mode exclusive
1494
1502
  db = Transactd::Database.new()
@@ -1507,6 +1515,10 @@ def testExclusive()
1507
1515
  db2.open(URL, Transactd::TYPE_SCHEMA_BDF)
1508
1516
  # database open error. Check database::stat()
1509
1517
  expect(db2.stat()).to eq Transactd::STATUS_CANNOT_LOCK_TABLE
1518
+ dd = db.dbDef()
1519
+ td = dd.tableDefs(1)
1520
+ dd.updateTableDef(1)
1521
+ expect(dd.stat()).to eq 0
1510
1522
  tb.close()
1511
1523
  db.close()
1512
1524
  db2.close()
@@ -1519,15 +1531,24 @@ def testExclusive()
1519
1531
  tb = db.openTable(TABLENAME, Transactd::TD_OPEN_READONLY_EXCLUSIVE)
1520
1532
  expect(db.stat()).to eq 0
1521
1533
 
1534
+ # read mysql version
1535
+ mySQL5_7 = isMySQL5_7(db)
1536
+
1522
1537
  # Read only open
1523
1538
  db2.open(URL, Transactd::TYPE_SCHEMA_BDF)
1524
1539
  expect(db2.stat()).to eq 0
1525
1540
  db2.close()
1526
1541
 
1527
1542
  # Normal open
1543
+ # Since MySQL 5.7 : D_OPEN_READONLY_EXCLUSIVE + TD_OPEN_NORMAL is fail,
1544
+ # It's correct.
1528
1545
  db2.connect(URL_DB, true)
1529
1546
  db2.open(URL, Transactd::TYPE_SCHEMA_BDF, Transactd::TD_OPEN_NORMAL)
1530
- expect(db2.stat()).to eq 0
1547
+ if (mySQL5_7)
1548
+ expect(db2.stat()).to eq Transactd::STATUS_CANNOT_LOCK_TABLE
1549
+ else
1550
+ expect(db2.stat()).to eq 0
1551
+ end
1531
1552
  db2.close()
1532
1553
 
1533
1554
  # Write Exclusive open
@@ -111,9 +111,10 @@ INSERT_SEB_TABLE_SQL = <<'EOS'
111
111
  EOS
112
112
 
113
113
  def dropDatabase(db)
114
- db.open(URL)
115
- expect(db.stat()).to eq 0
116
- db.drop()
114
+ #db.open(URL)
115
+ #expect(db.stat()).to eq 0
116
+ #db.drop()
117
+ db.drop(URL)
117
118
  expect(db.stat()).to eq 0
118
119
  end
119
120
 
@@ -143,6 +144,16 @@ def isMySQL5_5(db)
143
144
  (5 == server_ver.minorVersion)
144
145
  end
145
146
 
147
+ def isMariaDBWithGtid(db)
148
+ vv = Transactd::BtrVersions.new()
149
+ db.getBtrVersion(vv)
150
+ server_ver = vv.version(1)
151
+ return (db.stat() == 0) &&
152
+ (10 == server_ver.majorVersion) &&
153
+ (server_ver.type == Transactd::MYSQL_TYPE_MARIA)
154
+ end
155
+
156
+
146
157
  def isLegacyTimeFormat(db)
147
158
  vv = Transactd::BtrVersions.new()
148
159
  db.getBtrVersion(vv)
@@ -745,4 +756,19 @@ describe Transactd, 'V3Features' do
745
756
  ats.release()
746
757
  db.close()
747
758
  end
759
+ it 'snapshot' do
760
+ db = Transactd::Database.new()
761
+ openDatabase(db)
762
+ bpos = db.beginSnapshot(Transactd::CONSISTENT_READ_WITH_BINLOG_POS)
763
+ if (isMariaDBWithGtid(db))
764
+ expect(bpos.type).to eq Transactd::REPL_POSTYPE_MARIA_GTID
765
+ else
766
+ expect(bpos.type).to eq Transactd::REPL_POSTYPE_POS
767
+ end
768
+ expect(bpos.pos).not_to eq 0
769
+ expect(bpos.filename).not_to eq ""
770
+ print "\nbinlog pos = ", bpos.filename, ":", bpos.pos, "\n"
771
+ db.endSnapshot();
772
+ db.close()
773
+ end
748
774
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: transactd
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.0
4
+ version: 3.1.0
5
5
  platform: x86-mswin32-100
6
6
  authors:
7
7
  - BizStation Corp.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-12-25 00:00:00.000000000 Z
11
+ date: 2016-03-09 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Transactd client for ruby gem
14
14
  email: transactd@bizstation.jp
@@ -17,13 +17,13 @@ extensions:
17
17
  - build/tdclrb/bldgem/extconf.rb
18
18
  extra_rdoc_files: []
19
19
  files:
20
- - bin/1.9/transactd.so
21
20
  - bin/2.0/transactd.so
22
21
  - bin/2.1/transactd.so
23
22
  - bin/2.2/transactd.so
23
+ - bin/2.3/transactd.so
24
24
  - build/tdclrb/bldgem/extconf.rb
25
- - bin/common/tdclcpp_vc100_32mr_3_0.dll
26
- - bin/common/tdclc_32_3_0.dll
25
+ - bin/common/tdclcpp_vc100_32mr_3_1.dll
26
+ - bin/common/tdclc_32_3_1.dll
27
27
  - build/tdclrb/gem/detect.rb
28
28
  - build/tdclrb/gem/helper.rb
29
29
  - build/tdclrb/gem/INSTALLLOG.win32
data/bin/1.9/transactd.so DELETED
Binary file
Binary file
Binary file