fl-thrift 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (83) hide show
  1. data/CHANGELOG +4 -0
  2. data/Manifest +81 -0
  3. data/README +43 -0
  4. data/Rakefile +102 -0
  5. data/benchmark/Benchmark.thrift +24 -0
  6. data/benchmark/benchmark.rb +271 -0
  7. data/benchmark/client.rb +74 -0
  8. data/benchmark/server.rb +82 -0
  9. data/benchmark/thin_server.rb +44 -0
  10. data/ext/binary_protocol_accelerated.c +474 -0
  11. data/ext/binary_protocol_accelerated.h +20 -0
  12. data/ext/compact_protocol.c +665 -0
  13. data/ext/compact_protocol.h +20 -0
  14. data/ext/constants.h +95 -0
  15. data/ext/extconf.rb +26 -0
  16. data/ext/macros.h +41 -0
  17. data/ext/memory_buffer.c +76 -0
  18. data/ext/memory_buffer.h +20 -0
  19. data/ext/protocol.c +185 -0
  20. data/ext/protocol.h +20 -0
  21. data/ext/struct.c +606 -0
  22. data/ext/struct.h +67 -0
  23. data/ext/thrift_native.c +194 -0
  24. data/lib/thrift.rb +59 -0
  25. data/lib/thrift/client.rb +62 -0
  26. data/lib/thrift/core_ext.rb +23 -0
  27. data/lib/thrift/core_ext/fixnum.rb +29 -0
  28. data/lib/thrift/exceptions.rb +82 -0
  29. data/lib/thrift/processor.rb +57 -0
  30. data/lib/thrift/protocol/base_protocol.rb +290 -0
  31. data/lib/thrift/protocol/binary_protocol.rb +225 -0
  32. data/lib/thrift/protocol/binary_protocol_accelerated.rb +35 -0
  33. data/lib/thrift/protocol/compact_protocol.rb +422 -0
  34. data/lib/thrift/serializer/deserializer.rb +33 -0
  35. data/lib/thrift/serializer/serializer.rb +34 -0
  36. data/lib/thrift/server/base_server.rb +31 -0
  37. data/lib/thrift/server/mongrel_http_server.rb +58 -0
  38. data/lib/thrift/server/nonblocking_server.rb +296 -0
  39. data/lib/thrift/server/simple_server.rb +43 -0
  40. data/lib/thrift/server/thread_pool_server.rb +75 -0
  41. data/lib/thrift/server/threaded_server.rb +47 -0
  42. data/lib/thrift/struct.rb +298 -0
  43. data/lib/thrift/thrift_native.rb +24 -0
  44. data/lib/thrift/transport/base_server_transport.rb +37 -0
  45. data/lib/thrift/transport/base_transport.rb +70 -0
  46. data/lib/thrift/transport/buffered_transport.rb +77 -0
  47. data/lib/thrift/transport/framed_transport.rb +90 -0
  48. data/lib/thrift/transport/http_client_transport.rb +45 -0
  49. data/lib/thrift/transport/io_stream_transport.rb +39 -0
  50. data/lib/thrift/transport/memory_buffer_transport.rb +96 -0
  51. data/lib/thrift/transport/server_socket.rb +63 -0
  52. data/lib/thrift/transport/socket.rb +136 -0
  53. data/lib/thrift/transport/unix_server_socket.rb +60 -0
  54. data/lib/thrift/transport/unix_socket.rb +40 -0
  55. data/lib/thrift/types.rb +101 -0
  56. data/script/proto_benchmark.rb +121 -0
  57. data/script/read_struct.rb +43 -0
  58. data/script/write_struct.rb +30 -0
  59. data/setup.rb +1585 -0
  60. data/spec/ThriftSpec.thrift +84 -0
  61. data/spec/base_protocol_spec.rb +160 -0
  62. data/spec/base_transport_spec.rb +351 -0
  63. data/spec/binary_protocol_accelerated_spec.rb +41 -0
  64. data/spec/binary_protocol_spec.rb +63 -0
  65. data/spec/binary_protocol_spec_shared.rb +375 -0
  66. data/spec/client_spec.rb +100 -0
  67. data/spec/compact_protocol_spec.rb +117 -0
  68. data/spec/exception_spec.rb +142 -0
  69. data/spec/http_client_spec.rb +49 -0
  70. data/spec/mongrel_http_server_spec.rb +117 -0
  71. data/spec/nonblocking_server_spec.rb +265 -0
  72. data/spec/processor_spec.rb +83 -0
  73. data/spec/serializer_spec.rb +69 -0
  74. data/spec/server_socket_spec.rb +80 -0
  75. data/spec/server_spec.rb +160 -0
  76. data/spec/socket_spec.rb +61 -0
  77. data/spec/socket_spec_shared.rb +104 -0
  78. data/spec/spec_helper.rb +60 -0
  79. data/spec/struct_spec.rb +252 -0
  80. data/spec/types_spec.rb +116 -0
  81. data/spec/unix_socket_spec.rb +108 -0
  82. data/thrift.gemspec +32 -0
  83. metadata +202 -0
@@ -0,0 +1,116 @@
1
+ #
2
+ # Licensed to the Apache Software Foundation (ASF) under one
3
+ # or more contributor license agreements. See the NOTICE file
4
+ # distributed with this work for additional information
5
+ # regarding copyright ownership. The ASF licenses this file
6
+ # to you under the Apache License, Version 2.0 (the
7
+ # "License"); you may not use this file except in compliance
8
+ # with the License. You may obtain a copy of the License at
9
+ #
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
+ #
12
+ # Unless required by applicable law or agreed to in writing,
13
+ # software distributed under the License is distributed on an
14
+ # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15
+ # KIND, either express or implied. See the License for the
16
+ # specific language governing permissions and limitations
17
+ # under the License.
18
+ #
19
+
20
+ require File.dirname(__FILE__) + '/spec_helper'
21
+
22
+ class ThriftTypesSpec < Spec::ExampleGroup
23
+ include Thrift
24
+
25
+ before(:each) do
26
+ Thrift.type_checking = true
27
+ end
28
+
29
+ after(:each) do
30
+ Thrift.type_checking = false
31
+ end
32
+
33
+ describe "Type checking" do
34
+ it "should return the proper name for each type" do
35
+ Thrift.type_name(Types::I16).should == "Types::I16"
36
+ Thrift.type_name(Types::VOID).should == "Types::VOID"
37
+ Thrift.type_name(Types::LIST).should == "Types::LIST"
38
+ Thrift.type_name(42).should be_nil
39
+ end
40
+
41
+ it "should check types properly" do
42
+ # lambda { Thrift.check_type(nil, Types::STOP) }.should raise_error(TypeError)
43
+ lambda { Thrift.check_type(3, {:type => Types::STOP}, :foo) }.should raise_error(TypeError)
44
+ lambda { Thrift.check_type(nil, {:type => Types::VOID}, :foo) }.should_not raise_error(TypeError)
45
+ lambda { Thrift.check_type(3, {:type => Types::VOID}, :foo) }.should raise_error(TypeError)
46
+ lambda { Thrift.check_type(true, {:type => Types::BOOL}, :foo) }.should_not raise_error(TypeError)
47
+ lambda { Thrift.check_type(3, {:type => Types::BOOL}, :foo) }.should raise_error(TypeError)
48
+ lambda { Thrift.check_type(42, {:type => Types::BYTE}, :foo) }.should_not raise_error(TypeError)
49
+ lambda { Thrift.check_type(42, {:type => Types::I16}, :foo) }.should_not raise_error(TypeError)
50
+ lambda { Thrift.check_type(42, {:type => Types::I32}, :foo) }.should_not raise_error(TypeError)
51
+ lambda { Thrift.check_type(42, {:type => Types::I64}, :foo) }.should_not raise_error(TypeError)
52
+ lambda { Thrift.check_type(3.14, {:type => Types::I32}, :foo) }.should raise_error(TypeError)
53
+ lambda { Thrift.check_type(3.14, {:type => Types::DOUBLE}, :foo) }.should_not raise_error(TypeError)
54
+ lambda { Thrift.check_type(3, {:type => Types::DOUBLE}, :foo) }.should raise_error(TypeError)
55
+ lambda { Thrift.check_type("3", {:type => Types::STRING}, :foo) }.should_not raise_error(TypeError)
56
+ lambda { Thrift.check_type(3, {:type => Types::STRING}, :foo) }.should raise_error(TypeError)
57
+ hello = SpecNamespace::Hello.new
58
+ lambda { Thrift.check_type(hello, {:type => Types::STRUCT, :class => SpecNamespace::Hello}, :foo) }.should_not raise_error(TypeError)
59
+ lambda { Thrift.check_type("foo", {:type => Types::STRUCT}, :foo) }.should raise_error(TypeError)
60
+ lambda { Thrift.check_type({:foo => 1}, {:type => Types::MAP}, :foo) }.should_not raise_error(TypeError)
61
+ lambda { Thrift.check_type([1], {:type => Types::MAP}, :foo) }.should raise_error(TypeError)
62
+ lambda { Thrift.check_type([1], {:type => Types::LIST}, :foo) }.should_not raise_error(TypeError)
63
+ lambda { Thrift.check_type({:foo => 1}, {:type => Types::LIST}, :foo) }.should raise_error(TypeError)
64
+ lambda { Thrift.check_type(Set.new([1,2]), {:type => Types::SET}, :foo) }.should_not raise_error(TypeError)
65
+ lambda { Thrift.check_type([1,2], {:type => Types::SET}, :foo) }.should raise_error(TypeError)
66
+ lambda { Thrift.check_type({:foo => true}, {:type => Types::SET}, :foo) }.should raise_error(TypeError)
67
+ end
68
+
69
+ it "should error out if nil is passed and skip_types is false" do
70
+ lambda { Thrift.check_type(nil, {:type => Types::BOOL}, :foo, false) }.should raise_error(TypeError)
71
+ lambda { Thrift.check_type(nil, {:type => Types::BYTE}, :foo, false) }.should raise_error(TypeError)
72
+ lambda { Thrift.check_type(nil, {:type => Types::I16}, :foo, false) }.should raise_error(TypeError)
73
+ lambda { Thrift.check_type(nil, {:type => Types::I32}, :foo, false) }.should raise_error(TypeError)
74
+ lambda { Thrift.check_type(nil, {:type => Types::I64}, :foo, false) }.should raise_error(TypeError)
75
+ lambda { Thrift.check_type(nil, {:type => Types::DOUBLE}, :foo, false) }.should raise_error(TypeError)
76
+ lambda { Thrift.check_type(nil, {:type => Types::STRING}, :foo, false) }.should raise_error(TypeError)
77
+ lambda { Thrift.check_type(nil, {:type => Types::STRUCT}, :foo, false) }.should raise_error(TypeError)
78
+ lambda { Thrift.check_type(nil, {:type => Types::LIST}, :foo, false) }.should raise_error(TypeError)
79
+ lambda { Thrift.check_type(nil, {:type => Types::SET}, :foo, false) }.should raise_error(TypeError)
80
+ lambda { Thrift.check_type(nil, {:type => Types::MAP}, :foo, false) }.should raise_error(TypeError)
81
+ end
82
+
83
+ it "should check element types on containers" do
84
+ field = {:type => Types::LIST, :element => {:type => Types::I32}}
85
+ lambda { Thrift.check_type([1, 2], field, :foo) }.should_not raise_error(TypeError)
86
+ lambda { Thrift.check_type([1, nil, 2], field, :foo) }.should raise_error(TypeError)
87
+ field = {:type => Types::MAP, :key => {:type => Types::I32}, :value => {:type => Types::STRING}}
88
+ lambda { Thrift.check_type({1 => "one", 2 => "two"}, field, :foo) }.should_not raise_error(TypeError)
89
+ lambda { Thrift.check_type({1 => "one", nil => "nil"}, field, :foo) }.should raise_error(TypeError)
90
+ lambda { Thrift.check_type({1 => nil, 2 => "two"}, field, :foo) }.should raise_error(TypeError)
91
+ field = {:type => Types::SET, :element => {:type => Types::I32}}
92
+ lambda { Thrift.check_type(Set.new([1, 2]), field, :foo) }.should_not raise_error(TypeError)
93
+ lambda { Thrift.check_type(Set.new([1, nil, 2]), field, :foo) }.should raise_error(TypeError)
94
+ lambda { Thrift.check_type(Set.new([1, 2.3, 2]), field, :foo) }.should raise_error(TypeError)
95
+
96
+ field = {:type => Types::STRUCT, :class => SpecNamespace::Hello}
97
+ lambda { Thrift.check_type(SpecNamespace::BoolStruct, field, :foo) }.should raise_error(TypeError)
98
+ end
99
+
100
+ it "should give the TypeError a readable message" do
101
+ msg = "Expected Types::STRING, received Fixnum for field foo"
102
+ lambda { Thrift.check_type(3, {:type => Types::STRING}, :foo) }.should raise_error(TypeError, msg)
103
+ msg = "Expected Types::STRING, received Fixnum for field foo.element"
104
+ field = {:type => Types::LIST, :element => {:type => Types::STRING}}
105
+ lambda { Thrift.check_type([3], field, :foo) }.should raise_error(TypeError, msg)
106
+ msg = "Expected Types::I32, received NilClass for field foo.element.key"
107
+ field = {:type => Types::LIST,
108
+ :element => {:type => Types::MAP,
109
+ :key => {:type => Types::I32},
110
+ :value => {:type => Types::I32}}}
111
+ lambda { Thrift.check_type([{nil => 3}], field, :foo) }.should raise_error(TypeError, msg)
112
+ msg = "Expected Types::I32, received NilClass for field foo.element.value"
113
+ lambda { Thrift.check_type([{1 => nil}], field, :foo) }.should raise_error(TypeError, msg)
114
+ end
115
+ end
116
+ end
@@ -0,0 +1,108 @@
1
+ #
2
+ # Licensed to the Apache Software Foundation (ASF) under one
3
+ # or more contributor license agreements. See the NOTICE file
4
+ # distributed with this work for additional information
5
+ # regarding copyright ownership. The ASF licenses this file
6
+ # to you under the Apache License, Version 2.0 (the
7
+ # "License"); you may not use this file except in compliance
8
+ # with the License. You may obtain a copy of the License at
9
+ #
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
+ #
12
+ # Unless required by applicable law or agreed to in writing,
13
+ # software distributed under the License is distributed on an
14
+ # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15
+ # KIND, either express or implied. See the License for the
16
+ # specific language governing permissions and limitations
17
+ # under the License.
18
+ #
19
+
20
+ require File.dirname(__FILE__) + '/spec_helper'
21
+ require File.dirname(__FILE__) + "/socket_spec_shared"
22
+
23
+ class ThriftUNIXSocketSpec < Spec::ExampleGroup
24
+ include Thrift
25
+
26
+ describe UNIXSocket do
27
+ before(:each) do
28
+ @path = '/tmp/thrift_spec_socket'
29
+ @socket = UNIXSocket.new(@path)
30
+ @handle = mock("Handle", :closed? => false)
31
+ @handle.stub!(:close)
32
+ ::UNIXSocket.stub!(:new).and_return(@handle)
33
+ end
34
+
35
+ it_should_behave_like "a socket"
36
+
37
+ it "should raise a TransportException when it cannot open a socket" do
38
+ ::UNIXSocket.should_receive(:new).and_raise(StandardError)
39
+ lambda { @socket.open }.should raise_error(Thrift::TransportException) { |e| e.type.should == Thrift::TransportException::NOT_OPEN }
40
+ end
41
+
42
+ it "should accept an optional timeout" do
43
+ ::UNIXSocket.stub!(:new)
44
+ UNIXSocket.new(@path, 5).timeout.should == 5
45
+ end
46
+ end
47
+
48
+ describe UNIXServerSocket do
49
+ before(:each) do
50
+ @path = '/tmp/thrift_spec_socket'
51
+ @socket = UNIXServerSocket.new(@path)
52
+ end
53
+
54
+ it "should create a handle when calling listen" do
55
+ UNIXServer.should_receive(:new).with(@path)
56
+ @socket.listen
57
+ end
58
+
59
+ it "should create a Thrift::UNIXSocket to wrap accepted sockets" do
60
+ handle = mock("UNIXServer")
61
+ UNIXServer.should_receive(:new).with(@path).and_return(handle)
62
+ @socket.listen
63
+ sock = mock("sock")
64
+ handle.should_receive(:accept).and_return(sock)
65
+ trans = mock("UNIXSocket")
66
+ UNIXSocket.should_receive(:new).and_return(trans)
67
+ trans.should_receive(:handle=).with(sock)
68
+ @socket.accept.should == trans
69
+ end
70
+
71
+ it "should close the handle when closed" do
72
+ handle = mock("UNIXServer", :closed? => false)
73
+ UNIXServer.should_receive(:new).with(@path).and_return(handle)
74
+ @socket.listen
75
+ handle.should_receive(:close)
76
+ File.stub!(:delete)
77
+ @socket.close
78
+ end
79
+
80
+ it "should delete the socket when closed" do
81
+ handle = mock("UNIXServer", :closed? => false)
82
+ UNIXServer.should_receive(:new).with(@path).and_return(handle)
83
+ @socket.listen
84
+ handle.stub!(:close)
85
+ File.should_receive(:delete).with(@path)
86
+ @socket.close
87
+ end
88
+
89
+ it "should return nil when accepting if there is no handle" do
90
+ @socket.accept.should be_nil
91
+ end
92
+
93
+ it "should return true for closed? when appropriate" do
94
+ handle = mock("UNIXServer", :closed? => false)
95
+ UNIXServer.stub!(:new).and_return(handle)
96
+ File.stub!(:delete)
97
+ @socket.listen
98
+ @socket.should_not be_closed
99
+ handle.stub!(:close)
100
+ @socket.close
101
+ @socket.should be_closed
102
+ @socket.listen
103
+ @socket.should_not be_closed
104
+ handle.stub!(:closed?).and_return(true)
105
+ @socket.should be_closed
106
+ end
107
+ end
108
+ end
@@ -0,0 +1,32 @@
1
+ # -*- encoding: utf-8 -*-
2
+
3
+ Gem::Specification.new do |s|
4
+ s.name = %q{fl-thrift}
5
+ s.version = "0.0.1"
6
+
7
+ s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
8
+ s.authors = ["Kevin Ballard, Kevin Clark, Mark Slee, Evan Weaver"]
9
+ s.cert_chain = ["/Users/eweaver/p/configuration/gem_certificates/evan_weaver-original-public_cert.pem"]
10
+ s.date = %q{2009-11-18}
11
+ s.description = %q{Ruby libraries for Thrift, with fixes.}
12
+ s.email = %q{}
13
+ s.extensions = ["ext/extconf.rb"]
14
+ s.extra_rdoc_files = ["CHANGELOG", "README", "ext/binary_protocol_accelerated.c", "ext/binary_protocol_accelerated.h", "ext/compact_protocol.c", "ext/compact_protocol.h", "ext/constants.h", "ext/extconf.rb", "ext/macros.h", "ext/memory_buffer.c", "ext/memory_buffer.h", "ext/protocol.c", "ext/protocol.h", "ext/struct.c", "ext/struct.h", "ext/thrift_native.c", "lib/thrift.rb", "lib/thrift/client.rb", "lib/thrift/core_ext.rb", "lib/thrift/exceptions.rb", "lib/thrift/processor.rb", "lib/thrift/struct.rb", "lib/thrift/thrift_native.rb", "lib/thrift/types.rb", "lib/thrift/core_ext/fixnum.rb", "lib/thrift/protocol/base_protocol.rb", "lib/thrift/protocol/binary_protocol.rb", "lib/thrift/protocol/binary_protocol_accelerated.rb", "lib/thrift/protocol/compact_protocol.rb", "lib/thrift/serializer/deserializer.rb", "lib/thrift/serializer/serializer.rb", "lib/thrift/server/base_server.rb", "lib/thrift/server/mongrel_http_server.rb", "lib/thrift/server/nonblocking_server.rb", "lib/thrift/server/simple_server.rb", "lib/thrift/server/thread_pool_server.rb", "lib/thrift/server/threaded_server.rb", "lib/thrift/transport/base_server_transport.rb", "lib/thrift/transport/base_transport.rb", "lib/thrift/transport/buffered_transport.rb", "lib/thrift/transport/framed_transport.rb", "lib/thrift/transport/http_client_transport.rb", "lib/thrift/transport/io_stream_transport.rb", "lib/thrift/transport/memory_buffer_transport.rb", "lib/thrift/transport/server_socket.rb", "lib/thrift/transport/socket.rb", "lib/thrift/transport/unix_server_socket.rb", "lib/thrift/transport/unix_socket.rb"]
15
+ s.files = ["CHANGELOG", "Manifest", "Rakefile", "README", "setup.rb", "benchmark/benchmark.rb", "benchmark/Benchmark.thrift", "benchmark/client.rb", "benchmark/server.rb", "benchmark/thin_server.rb", "ext/binary_protocol_accelerated.c", "ext/binary_protocol_accelerated.h", "ext/compact_protocol.c", "ext/compact_protocol.h", "ext/constants.h", "ext/extconf.rb", "ext/macros.h", "ext/memory_buffer.c", "ext/memory_buffer.h", "ext/protocol.c", "ext/protocol.h", "ext/struct.c", "ext/struct.h", "ext/thrift_native.c", "lib/thrift.rb", "lib/thrift/client.rb", "lib/thrift/core_ext.rb", "lib/thrift/exceptions.rb", "lib/thrift/processor.rb", "lib/thrift/struct.rb", "lib/thrift/thrift_native.rb", "lib/thrift/types.rb", "lib/thrift/core_ext/fixnum.rb", "lib/thrift/protocol/base_protocol.rb", "lib/thrift/protocol/binary_protocol.rb", "lib/thrift/protocol/binary_protocol_accelerated.rb", "lib/thrift/protocol/compact_protocol.rb", "lib/thrift/serializer/deserializer.rb", "lib/thrift/serializer/serializer.rb", "lib/thrift/server/base_server.rb", "lib/thrift/server/mongrel_http_server.rb", "lib/thrift/server/nonblocking_server.rb", "lib/thrift/server/simple_server.rb", "lib/thrift/server/thread_pool_server.rb", "lib/thrift/server/threaded_server.rb", "lib/thrift/transport/base_server_transport.rb", "lib/thrift/transport/base_transport.rb", "lib/thrift/transport/buffered_transport.rb", "lib/thrift/transport/framed_transport.rb", "lib/thrift/transport/http_client_transport.rb", "lib/thrift/transport/io_stream_transport.rb", "lib/thrift/transport/memory_buffer_transport.rb", "lib/thrift/transport/server_socket.rb", "lib/thrift/transport/socket.rb", "lib/thrift/transport/unix_server_socket.rb", "lib/thrift/transport/unix_socket.rb", "script/proto_benchmark.rb", "script/read_struct.rb", "script/write_struct.rb", "spec/base_protocol_spec.rb", "spec/base_transport_spec.rb", "spec/binary_protocol_accelerated_spec.rb", "spec/binary_protocol_spec.rb", "spec/binary_protocol_spec_shared.rb", "spec/client_spec.rb", "spec/compact_protocol_spec.rb", "spec/exception_spec.rb", "spec/http_client_spec.rb", "spec/mongrel_http_server_spec.rb", "spec/nonblocking_server_spec.rb", "spec/processor_spec.rb", "spec/serializer_spec.rb", "spec/server_socket_spec.rb", "spec/server_spec.rb", "spec/socket_spec.rb", "spec/socket_spec_shared.rb", "spec/spec_helper.rb", "spec/struct_spec.rb", "spec/ThriftSpec.thrift", "spec/types_spec.rb", "spec/unix_socket_spec.rb", "thrift.gemspec"]
16
+ s.homepage = %q{http://blog.evanweaver.com/files/doc/fauna/thrift/}
17
+ s.rdoc_options = ["--line-numbers", "--inline-source", "--title", "Thrift", "--main", "README"]
18
+ s.require_paths = ["lib", "ext"]
19
+ s.rubyforge_project = %q{fauna}
20
+ s.rubygems_version = %q{1.3.5}
21
+ s.summary = %q{Ruby libraries for Thrift, with fixes.}
22
+
23
+ if s.respond_to? :specification_version then
24
+ current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
25
+ s.specification_version = 3
26
+
27
+ if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
28
+ else
29
+ end
30
+ else
31
+ end
32
+ end
metadata ADDED
@@ -0,0 +1,202 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: fl-thrift
3
+ version: !ruby/object:Gem::Version
4
+ hash: 29
5
+ prerelease:
6
+ segments:
7
+ - 0
8
+ - 0
9
+ - 1
10
+ version: 0.0.1
11
+ platform: ruby
12
+ authors:
13
+ - Kevin Ballard, Kevin Clark, Mark Slee, Evan Weaver
14
+ autorequire:
15
+ bindir: bin
16
+ cert_chain:
17
+ - /Users/eweaver/p/configuration/gem_certificates/evan_weaver-original-public_cert.pem
18
+ date: 2009-11-18 00:00:00 -08:00
19
+ default_executable:
20
+ dependencies: []
21
+
22
+ description: Ruby libraries for Thrift, with fixes.
23
+ email: ""
24
+ executables: []
25
+
26
+ extensions:
27
+ - ext/extconf.rb
28
+ extra_rdoc_files:
29
+ - CHANGELOG
30
+ - README
31
+ - ext/binary_protocol_accelerated.c
32
+ - ext/binary_protocol_accelerated.h
33
+ - ext/compact_protocol.c
34
+ - ext/compact_protocol.h
35
+ - ext/constants.h
36
+ - ext/extconf.rb
37
+ - ext/macros.h
38
+ - ext/memory_buffer.c
39
+ - ext/memory_buffer.h
40
+ - ext/protocol.c
41
+ - ext/protocol.h
42
+ - ext/struct.c
43
+ - ext/struct.h
44
+ - ext/thrift_native.c
45
+ - lib/thrift.rb
46
+ - lib/thrift/client.rb
47
+ - lib/thrift/core_ext.rb
48
+ - lib/thrift/exceptions.rb
49
+ - lib/thrift/processor.rb
50
+ - lib/thrift/struct.rb
51
+ - lib/thrift/thrift_native.rb
52
+ - lib/thrift/types.rb
53
+ - lib/thrift/core_ext/fixnum.rb
54
+ - lib/thrift/protocol/base_protocol.rb
55
+ - lib/thrift/protocol/binary_protocol.rb
56
+ - lib/thrift/protocol/binary_protocol_accelerated.rb
57
+ - lib/thrift/protocol/compact_protocol.rb
58
+ - lib/thrift/serializer/deserializer.rb
59
+ - lib/thrift/serializer/serializer.rb
60
+ - lib/thrift/server/base_server.rb
61
+ - lib/thrift/server/mongrel_http_server.rb
62
+ - lib/thrift/server/nonblocking_server.rb
63
+ - lib/thrift/server/simple_server.rb
64
+ - lib/thrift/server/thread_pool_server.rb
65
+ - lib/thrift/server/threaded_server.rb
66
+ - lib/thrift/transport/base_server_transport.rb
67
+ - lib/thrift/transport/base_transport.rb
68
+ - lib/thrift/transport/buffered_transport.rb
69
+ - lib/thrift/transport/framed_transport.rb
70
+ - lib/thrift/transport/http_client_transport.rb
71
+ - lib/thrift/transport/io_stream_transport.rb
72
+ - lib/thrift/transport/memory_buffer_transport.rb
73
+ - lib/thrift/transport/server_socket.rb
74
+ - lib/thrift/transport/socket.rb
75
+ - lib/thrift/transport/unix_server_socket.rb
76
+ - lib/thrift/transport/unix_socket.rb
77
+ files:
78
+ - CHANGELOG
79
+ - Manifest
80
+ - Rakefile
81
+ - README
82
+ - setup.rb
83
+ - benchmark/benchmark.rb
84
+ - benchmark/Benchmark.thrift
85
+ - benchmark/client.rb
86
+ - benchmark/server.rb
87
+ - benchmark/thin_server.rb
88
+ - ext/binary_protocol_accelerated.c
89
+ - ext/binary_protocol_accelerated.h
90
+ - ext/compact_protocol.c
91
+ - ext/compact_protocol.h
92
+ - ext/constants.h
93
+ - ext/extconf.rb
94
+ - ext/macros.h
95
+ - ext/memory_buffer.c
96
+ - ext/memory_buffer.h
97
+ - ext/protocol.c
98
+ - ext/protocol.h
99
+ - ext/struct.c
100
+ - ext/struct.h
101
+ - ext/thrift_native.c
102
+ - lib/thrift.rb
103
+ - lib/thrift/client.rb
104
+ - lib/thrift/core_ext.rb
105
+ - lib/thrift/exceptions.rb
106
+ - lib/thrift/processor.rb
107
+ - lib/thrift/struct.rb
108
+ - lib/thrift/thrift_native.rb
109
+ - lib/thrift/types.rb
110
+ - lib/thrift/core_ext/fixnum.rb
111
+ - lib/thrift/protocol/base_protocol.rb
112
+ - lib/thrift/protocol/binary_protocol.rb
113
+ - lib/thrift/protocol/binary_protocol_accelerated.rb
114
+ - lib/thrift/protocol/compact_protocol.rb
115
+ - lib/thrift/serializer/deserializer.rb
116
+ - lib/thrift/serializer/serializer.rb
117
+ - lib/thrift/server/base_server.rb
118
+ - lib/thrift/server/mongrel_http_server.rb
119
+ - lib/thrift/server/nonblocking_server.rb
120
+ - lib/thrift/server/simple_server.rb
121
+ - lib/thrift/server/thread_pool_server.rb
122
+ - lib/thrift/server/threaded_server.rb
123
+ - lib/thrift/transport/base_server_transport.rb
124
+ - lib/thrift/transport/base_transport.rb
125
+ - lib/thrift/transport/buffered_transport.rb
126
+ - lib/thrift/transport/framed_transport.rb
127
+ - lib/thrift/transport/http_client_transport.rb
128
+ - lib/thrift/transport/io_stream_transport.rb
129
+ - lib/thrift/transport/memory_buffer_transport.rb
130
+ - lib/thrift/transport/server_socket.rb
131
+ - lib/thrift/transport/socket.rb
132
+ - lib/thrift/transport/unix_server_socket.rb
133
+ - lib/thrift/transport/unix_socket.rb
134
+ - script/proto_benchmark.rb
135
+ - script/read_struct.rb
136
+ - script/write_struct.rb
137
+ - spec/base_protocol_spec.rb
138
+ - spec/base_transport_spec.rb
139
+ - spec/binary_protocol_accelerated_spec.rb
140
+ - spec/binary_protocol_spec.rb
141
+ - spec/binary_protocol_spec_shared.rb
142
+ - spec/client_spec.rb
143
+ - spec/compact_protocol_spec.rb
144
+ - spec/exception_spec.rb
145
+ - spec/http_client_spec.rb
146
+ - spec/mongrel_http_server_spec.rb
147
+ - spec/nonblocking_server_spec.rb
148
+ - spec/processor_spec.rb
149
+ - spec/serializer_spec.rb
150
+ - spec/server_socket_spec.rb
151
+ - spec/server_spec.rb
152
+ - spec/socket_spec.rb
153
+ - spec/socket_spec_shared.rb
154
+ - spec/spec_helper.rb
155
+ - spec/struct_spec.rb
156
+ - spec/ThriftSpec.thrift
157
+ - spec/types_spec.rb
158
+ - spec/unix_socket_spec.rb
159
+ - thrift.gemspec
160
+ has_rdoc: true
161
+ homepage: http://blog.evanweaver.com/files/doc/fauna/thrift/
162
+ licenses: []
163
+
164
+ post_install_message:
165
+ rdoc_options:
166
+ - --line-numbers
167
+ - --inline-source
168
+ - --title
169
+ - Thrift
170
+ - --main
171
+ - README
172
+ require_paths:
173
+ - lib
174
+ - ext
175
+ required_ruby_version: !ruby/object:Gem::Requirement
176
+ none: false
177
+ requirements:
178
+ - - ">="
179
+ - !ruby/object:Gem::Version
180
+ hash: 3
181
+ segments:
182
+ - 0
183
+ version: "0"
184
+ required_rubygems_version: !ruby/object:Gem::Requirement
185
+ none: false
186
+ requirements:
187
+ - - ">="
188
+ - !ruby/object:Gem::Version
189
+ hash: 11
190
+ segments:
191
+ - 1
192
+ - 2
193
+ version: "1.2"
194
+ requirements: []
195
+
196
+ rubyforge_project: fauna
197
+ rubygems_version: 1.3.9.3
198
+ signing_key:
199
+ specification_version: 3
200
+ summary: Ruby libraries for Thrift, with fixes.
201
+ test_files: []
202
+