red-arrow-flight 8.0.0 → 10.0.0

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
  SHA256:
3
- metadata.gz: e4f74cb77414d9aba8ed94f69182e8913f76d3a21364876602a2df0b2e10a957
4
- data.tar.gz: f41a565dec97caa4e8d7ee662e8cf3cc270b4eadd6d1700413f23055238663c7
3
+ metadata.gz: 2851747d0b1a512c9adf53924c329d1506f49aa9164ed8757e0a35d0d6c6cf76
4
+ data.tar.gz: fa12f7b4d02db860c5f114ef46ffe52e1365cfcd2d09e7cea486529911b9baa6
5
5
  SHA512:
6
- metadata.gz: 76ca294325958e2857c2ec7f5d56a933efea4009262b684458fa9d5a19a127e9982c1b82211c9c327be982992a0194a2a2210eb4fe8291e6161c50d288a65244
7
- data.tar.gz: ab0cab1756b7184a307e33eda5cd893ae36ee3cced162b297c89f2e29c7139ad6bc586e04424d570be55baf0de47ababb447d128b37d46e8f0a40c167d7cd401
6
+ metadata.gz: c7e0bbe4b64966a42038fa733c30ad94aa20ccdc9ca014807eef1834ed6b483fae55daa16c6dd772c4ba09cdd00a8764a8b8ee0c3ae469df23008a4e63ea3e6e
7
+ data.tar.gz: b9509c9abc3da1a46e437dde2a467c5b86bde8479796958fb53ac237e5274f6e65f8c315aa3270cd8295272c8f193c04683cfad326994908b393dcc9e5e29506
data/README.md CHANGED
@@ -21,19 +21,19 @@
21
21
 
22
22
  Red Arrow Flight is the Ruby bindings of Apache Arrow Flight. Red Arrow Flight is based on GObject Introspection.
23
23
 
24
- [Apache Arrow Flight](https://arrow.apache.org/) is one of Apache Arrow components to read and write semantic flights stored in different locations and formats.
24
+ [Apache Arrow Flight](https://arrow.apache.org/docs/format/Flight.html) is one of Apache Arrow components to read and write semantic flights stored in different locations and formats.
25
25
 
26
26
  [GObject Introspection](https://wiki.gnome.org/action/show/Projects/GObjectIntrospection) is a middleware for language bindings of C library. GObject Introspection can generate language bindings automatically at runtime.
27
27
 
28
- Red Arrow Flight uses [Apache Arrow Flight GLib](https://github.com/apache/arrow/tree/master/c_glib) and [gobject-introspection gem](https://rubygems.org/gems/gobject-introspection) to generate Ruby bindings of Apache Arrow Flight.
28
+ Red Arrow Flight uses [Apache Arrow Flight GLib](https://github.com/apache/arrow/tree/master/c_glib/arrow-flight-glib) and [gobject-introspection gem](https://rubygems.org/gems/gobject-introspection) to generate Ruby bindings of Apache Arrow Flight.
29
29
 
30
- Apache Arrow Flight GLib is a C wrapper for [Apache Arrow Flight C++](https://github.com/apache/arrow/tree/master/cpp). GObject Introspection can't use Apache Arrow Flight C++ directly. Apache Arrow Flight GLib is a bridge between Apache Arrow Flight C++ and GObject Introspection.
30
+ Apache Arrow Flight GLib is a C wrapper for [Apache Arrow Flight C++](https://github.com/apache/arrow/tree/master/cpp/src/arrow/flight). GObject Introspection can't use Apache Arrow Flight C++ directly. Apache Arrow Flight GLib is a bridge between Apache Arrow Flight C++ and GObject Introspection.
31
31
 
32
32
  gobject-introspection gem is a Ruby bindings of GObject Introspection. Red Arrow Flight uses GObject Introspection via gobject-introspection gem.
33
33
 
34
34
  ## Install
35
35
 
36
- Install Apache Arrow Flight GLib before install Red Arrow Flight. Install Apache Arrow GLib before install Red Arrow. See [Apache Arrow install document](https://arrow.apache.org/install/) for details.
36
+ Install Apache Arrow Flight GLib before install Red Arrow Flight. See [Apache Arrow install document](https://arrow.apache.org/install/) for details.
37
37
 
38
38
  Install Red Arrow Flight after you install Apache Arrow Flight GLib:
39
39
 
@@ -38,8 +38,9 @@ namespace :dependency do
38
38
  ArrowFlight::Version::MAJOR,
39
39
  ArrowFlight::Version::MINOR,
40
40
  ArrowFlight::Version::MICRO)
41
- unless NativePackageInstaller.install(:debian => "libarrow-flight-glib-dev",
42
- :redhat => "arrow-flight-glib-devel")
41
+ unless NativePackageInstaller.install(debian: "libarrow-flight-glib-dev",
42
+ fedora: "libarrow-flight-glib-devel",
43
+ redhat: "arrow-flight-glib-devel")
43
44
  exit(false)
44
45
  end
45
46
  end
@@ -31,5 +31,23 @@ module ArrowFlight
31
31
  end
32
32
  end
33
33
  end
34
+
35
+ def headers=(headers)
36
+ clear_headers
37
+ headers.each do |name, value|
38
+ add_header(name, value)
39
+ end
40
+ end
41
+
42
+ def each_header
43
+ return to_enum(__method__) unless block_given?
44
+ foreach_header do |key, value|
45
+ yield(key, value)
46
+ end
47
+ end
48
+
49
+ def headers
50
+ each_header.to_a
51
+ end
34
52
  end
35
53
  end
@@ -21,7 +21,7 @@ module ArrowFlight
21
21
  # @api private
22
22
  def try_convert(value)
23
23
  case value
24
- when String
24
+ when String, GLib::Bytes
25
25
  new(value)
26
26
  else
27
27
  nil
@@ -16,7 +16,7 @@
16
16
  # under the License.
17
17
 
18
18
  module ArrowFlight
19
- VERSION = "8.0.0"
19
+ VERSION = "10.0.0"
20
20
 
21
21
  module Version
22
22
  numbers, TAG = VERSION.split("-")
@@ -0,0 +1,53 @@
1
+ # Licensed to the Apache Software Foundation (ASF) under one
2
+ # or more contributor license agreements. See the NOTICE file
3
+ # distributed with this work for additional information
4
+ # regarding copyright ownership. The ASF licenses this file
5
+ # to you under the Apache License, Version 2.0 (the
6
+ # "License"); you may not use this file except in compliance
7
+ # with the License. You may obtain a copy of the License at
8
+ #
9
+ # http://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing,
12
+ # software distributed under the License is distributed on an
13
+ # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14
+ # KIND, either express or implied. See the License for the
15
+ # specific language governing permissions and limitations
16
+ # under the License.
17
+
18
+ class TestCallOptions < Test::Unit::TestCase
19
+ sub_test_case(".try_convert") do
20
+ def test_headers
21
+ options = ArrowFlight::CallOptions.try_convert(headers: {"a" => "b"})
22
+ assert_equal([["a", "b"]],
23
+ options.headers)
24
+ end
25
+ end
26
+
27
+ def setup
28
+ @options = ArrowFlight::CallOptions.new
29
+ end
30
+
31
+ def test_add_header
32
+ @options.add_header("name1", "value1")
33
+ @options.add_header("name2", "value2")
34
+ assert_equal([
35
+ ["name1", "value1"],
36
+ ["name2", "value2"],
37
+ ],
38
+ @options.headers)
39
+ end
40
+
41
+ def test_set_headers
42
+ @options.add_header("name1", "value1")
43
+ @options.headers = {
44
+ "name2" => "value2",
45
+ "name3" => "value3",
46
+ }
47
+ assert_equal([
48
+ ["name2", "value2"],
49
+ ["name3", "value3"],
50
+ ],
51
+ @options.headers)
52
+ end
53
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: red-arrow-flight
3
3
  version: !ruby/object:Gem::Version
4
- version: 8.0.0
4
+ version: 10.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Apache Arrow Developers
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-05-07 00:00:00.000000000 Z
11
+ date: 2022-11-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: red-arrow
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - '='
18
18
  - !ruby/object:Gem::Version
19
- version: 8.0.0
19
+ version: 10.0.0
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - '='
25
25
  - !ruby/object:Gem::Version
26
- version: 8.0.0
26
+ version: 10.0.0
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: bundler
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -94,6 +94,7 @@ files:
94
94
  - test/helper/info-generator.rb
95
95
  - test/helper/server.rb
96
96
  - test/run-test.rb
97
+ - test/test-call-options.rb
97
98
  - test/test-client.rb
98
99
  - test/test-location.rb
99
100
  - test/test-ticket.rb
@@ -101,7 +102,7 @@ homepage: https://arrow.apache.org/
101
102
  licenses:
102
103
  - Apache-2.0
103
104
  metadata: {}
104
- post_install_message:
105
+ post_install_message:
105
106
  rdoc_options: []
106
107
  require_paths:
107
108
  - lib
@@ -116,8 +117,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
116
117
  - !ruby/object:Gem::Version
117
118
  version: '0'
118
119
  requirements: []
119
- rubygems_version: 3.4.0.dev
120
- signing_key:
120
+ rubygems_version: 3.3.15
121
+ signing_key:
121
122
  specification_version: 4
122
123
  summary: Red Arrow Flight is the Ruby bindings of Apache Arrow Flight
123
124
  test_files:
@@ -125,6 +126,7 @@ test_files:
125
126
  - test/helper/server.rb
126
127
  - test/helper.rb
127
128
  - test/run-test.rb
129
+ - test/test-call-options.rb
128
130
  - test/test-client.rb
129
131
  - test/test-location.rb
130
132
  - test/test-ticket.rb