tiny_tds 2.1.0.pre2-x86-mingw32 → 2.1.0.pre3-x86-mingw32

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: a8ab6753959f2f2c7b2ad23a83df0ce13b99a095
4
- data.tar.gz: f9563f999bed18c08f00b8303d8bbbe3f70324c1
3
+ metadata.gz: '08eae6e3200b5f32608163ec4387e72d60bb1fa7'
4
+ data.tar.gz: 148f42c5ea47d801eb9af226cf9f6f6e8a6911b8
5
5
  SHA512:
6
- metadata.gz: 51e973625c491bc1f5c12e7dacc60756a13cf988893157d162922f0f88faa5ccff4d6df295e37147124135d1c5925d9dacb257f68fe5ea51205212f7004e9ff2
7
- data.tar.gz: 001c4a7ee542f88b5bbca7303bd2b9a31073ac943015fa043195f051ff9f2390ce3438158d577ec9d167d52ddec64724a455d8ab4ba20309897fa2b7641390b0
6
+ metadata.gz: 58d25bea67f36bcd79785fd71e78637addb01572462d3bfbcdb6200c736d93556bfbc182743057d15e3da163ddf85c4c74d7d48b927b2a2197ade281b4d9ddd8
7
+ data.tar.gz: 253484eadc75693a73c08c861424dc358204139f9bd4e425695007bb736aa9dc47bfc2d2d9c2be2fe5f7a7d0335dc00d0ecb4d935c1c8c453596a7ab6a1be60e
data/CHANGELOG.md CHANGED
@@ -3,6 +3,7 @@
3
3
  * Support RubyInstaller2 for Windows. Fixes #365.
4
4
  * Support the FREETDS_DIR environment variable. Fixes #371.
5
5
  * Rename binstubs to tsql-ttds and defncopy-ttds
6
+ * Support separate timeout values per connection Fixes #348.
6
7
 
7
8
 
8
9
  ## 2.0.0
data/README.md CHANGED
@@ -117,7 +117,7 @@ Creating a new client takes a hash of options. For valid iconv encoding options,
117
117
  * :appname - Short string seen in SQL Servers process/activity window.
118
118
  * :tds_version - TDS version. Defaults to "7.3".
119
119
  * :login_timeout - Seconds to wait for login. Default to 60 seconds.
120
- * :timeout - Seconds to wait for a response to a SQL command. Default 5 seconds.
120
+ * :timeout - Seconds to wait for a response to a SQL command. Default 5 seconds. Prior to 1.0rc5, FreeTDS was unable to set the timeout on a per-client basis, permitting only a global timeout value. This means that if you're using an older version, the timeout values for all clients will be overwritten each time you instantiate a new `TinyTds::Client` object. If you are using 1.0rc5 or later, all clients will have an independent timeout setting as you'd expect.
121
121
  * :encoding - Any valid iconv value like CP1251 or ISO-8859-1. Default UTF-8.
122
122
  * :azure - Pass true to signal that you are connecting to azure.
123
123
  * :contained - Pass true to signal that you are connecting with a contained database user.
@@ -482,5 +482,3 @@ My name is Ken Collins and I currently maintain the SQL Server adapter for Activ
482
482
  ## License
483
483
 
484
484
  TinyTDS is Copyright (c) 2010-2015 Ken Collins, <ken@metaskills.net> and Will Bond (Veracross LLC) <wbond@breuer.com>. It is distributed under the MIT license. Windows binaries contain pre-compiled versions of FreeTDS <http://www.freetds.org/> which is licensed under the GNU LGPL license at <http://www.gnu.org/licenses/lgpl-2.0.html>
485
-
486
-
data/VERSION CHANGED
@@ -1 +1 @@
1
- 2.1.0.pre2
1
+ 2.1.0.pre3
@@ -326,8 +326,6 @@ static VALUE rb_tinytds_connect(VALUE self, VALUE opts) {
326
326
  dbsetlapp(cwrap->login, StringValueCStr(app));
327
327
  if (!NIL_P(ltimeout))
328
328
  dbsetlogintime(NUM2INT(ltimeout));
329
- if (!NIL_P(timeout))
330
- dbsettime(NUM2INT(timeout));
331
329
  if (!NIL_P(charset))
332
330
  DBSETLCHARSET(cwrap->login, StringValueCStr(charset));
333
331
  if (!NIL_P(database)) {
@@ -354,12 +352,18 @@ static VALUE rb_tinytds_connect(VALUE self, VALUE opts) {
354
352
  #endif
355
353
  cwrap->client = dbopen(cwrap->login, StringValueCStr(dataserver));
356
354
  if (cwrap->client) {
357
- VALUE transposed_encoding;
355
+ VALUE transposed_encoding, timeout_string;
358
356
 
359
357
  cwrap->closed = 0;
360
358
  cwrap->charset = charset;
361
359
  if (!NIL_P(version))
362
360
  dbsetversion(NUM2INT(version));
361
+ if (!NIL_P(timeout)) {
362
+ timeout_string = rb_sprintf("%"PRIsVALUE"", timeout);
363
+ if (dbsetopt(cwrap->client, DBSETTIME, StringValueCStr(timeout_string), 0) == FAIL) {
364
+ dbsettime(NUM2INT(timeout));
365
+ }
366
+ }
363
367
  dbsetuserdata(cwrap->client, (BYTE*)cwrap->userdata);
364
368
  cwrap->userdata->closed = 0;
365
369
  if (!NIL_P(database) && (azure != Qtrue)) {
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tiny_tds
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.0.pre2
4
+ version: 2.1.0.pre3
5
5
  platform: x86-mingw32
6
6
  authors:
7
7
  - Ken Collins
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2017-09-04 00:00:00.000000000 Z
13
+ date: 2017-09-06 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: mini_portile2