Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
bc3c7fe
Converted global class variables to global variables to avoid warnings
Jun 13, 2013
1d8945c
Created branch t_speedup_serilizer from master
Jun 14, 2013
f095e76
Created branch add_protocol_transfer_layer from t_speedup_serilizer
Jun 14, 2013
72207fc
added read support to layered protocol
Jun 19, 2013
822f2b1
Created branch t_rewrite_memorybuffer_transport from add_protocol_tra…
Jun 19, 2013
8821d9b
made all internal functions and variables static in the old memory bu…
Jun 19, 2013
45e8e62
added fast memory buffer
Jun 19, 2013
85ba032
rewrote memory buffer transport
Jun 20, 2013
8c7738b
Created branch t_modify_serilizer from t_rewrite_memorybuffer_transport
Jun 20, 2013
bb49b5e
added optional transportfactory parameter to Serializer and Deseriali…
Jun 20, 2013
a1e3436
fixed a few bugs with read_into_buffer, and added tests for them
Jun 20, 2013
f1145e5
added
Jun 20, 2013
221840c
Added factories for the protocols
Jun 20, 2013
9d035f9
Merge branch 't_rewrite_memorybuffer_transport' into t_speedup_serilizer
Jun 20, 2013
15eb765
added a few things to gitignore
Jun 20, 2013
8d0e71d
added tests for layered protocol
Jun 20, 2013
c16752b
added tests for fast memory buffer
Jun 20, 2013
5b29da4
Build was failing because the bash invocation was not expanding the t…
Jun 20, 2013
2a42838
exchanged transport.read to transport.read_into_buffer which should b…
Jun 20, 2013
3969a4d
fixed segfault bug due to dereferencing a native C int as a ruby int
Jun 20, 2013
8a07d6a
changed C ptr -> Ruby num conversion method
Jun 20, 2013
c566918
removed double buffering
Jun 20, 2013
f8705cb
cleaning up
Jun 20, 2013
de80db8
Created branch t_monkeypatch_thrift_module from t_speedup_serilizer
axos88 Jun 20, 2013
e97bbab
added fastcall calling method, and shortcircuited ruby funcall overwh…
Jun 21, 2013
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,15 @@ gen-*
.sonar
.DS_Store

.bin
.bundle
.ruby-version
Gemfile*
conf*
dobuild.sh
doconfig.sh
vendor

/Makefile
/Makefile.in
/contrib/.vagrant/
Expand Down
2 changes: 1 addition & 1 deletion lib/rb/Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ end

desc 'Install the thrift gem'
task :install => [:gem] do
unless sh 'gem', 'install', 'thrift-*.gem'
unless sh 'gem install thrift-*.gem'
$stderr.puts "Failed to install thrift gem"
break
end
Expand Down
7 changes: 7 additions & 0 deletions lib/rb/ext/compact_protocol.c
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@
#include <macros.h>
#include <bytes.h>

//#define LOG_FUNC() printf("Compact %s\n", __FUNCTION__);
#define LOG_FUNC()

#define LAST_ID(obj) FIX2INT(rb_ary_pop(rb_ivar_get(obj, last_field_id)))
#define SET_LAST_ID(obj, val) rb_ary_push(rb_ivar_get(obj, last_field_id), val)

Expand Down Expand Up @@ -174,16 +177,19 @@ VALUE rb_thrift_compact_proto_write_message_end(VALUE self) {
}

VALUE rb_thrift_compact_proto_write_struct_begin(VALUE self, VALUE name) {
LOG_FUNC();
rb_ary_push(rb_ivar_get(self, last_field_id), INT2FIX(0));
return Qnil;
}

VALUE rb_thrift_compact_proto_write_struct_end(VALUE self) {
LOG_FUNC();
rb_ary_pop(rb_ivar_get(self, last_field_id));
return Qnil;
}

VALUE rb_thrift_compact_proto_write_field_end(VALUE self) {
LOG_FUNC();
return Qnil;
}

Expand All @@ -210,6 +216,7 @@ VALUE rb_thrift_compact_proto_write_message_begin(VALUE self, VALUE name, VALUE
}

VALUE rb_thrift_compact_proto_write_field_begin(VALUE self, VALUE name, VALUE type, VALUE id) {
LOG_FUNC();
if (FIX2INT(type) == TTYPE_BOOL) {
// we want to possibly include the value, so we'll wait.
rb_ivar_set(self, boolean_field_id, rb_ary_new3(2, type, id));
Expand Down
Loading