[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-04-07 Thread Allen George (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15961059#comment-15961059
 ] 

Allen George commented on THRIFT-2945:
--

And [~prz] - totally thought that you'd gone AWOL. Glad to hear that isn't the 
case :)

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-04-07 Thread Allen George (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15961053#comment-15961053
 ] 

Allen George commented on THRIFT-2945:
--

Good to hear! Was just pinged today on the status of your old patch.

And, yup, I've started attacking the pieces individually. For example, even 
auto-deriving {{Hash}} brought some small issues to light.

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-04-07 Thread Tony Przygienda (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15961031#comment-15961031
 ] 

Tony Przygienda commented on THRIFT-2945:
-

didn't forget about it.Had to get the company to approve releasing the stuff 
into the wild and will get to it in next couple weeks ...

See hash made it in already ... 

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-02-22 Thread Allen George (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15878212#comment-15878212
 ] 

Allen George commented on THRIFT-2945:
--

Done. I've separated it into 4 issues for which PRs can be generated:

THRIFT-4098: namespace support
THRIFT-4099: auto-derive {{Hash}}
THRIFT-4100: {{TSerializable}} trait
THRIFT-4101: enum extensibility

cc [~prz]

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-02-20 Thread Jens Geyer (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15875528#comment-15875528
 ] 

Jens Geyer commented on THRIFT-2945:


Hi [~allengeorge] and [~prz], 

could you open a new ticket for the new issue please?

Thanks!


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-02-20 Thread Tony Przygienda (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15874943#comment-15874943
 ] 

Tony Przygienda commented on THRIFT-2945:
-

OK, we're in agreement., I'll get to it & come back when done. Busy right now 
upstreaming couple other things. Give me couple days ... 

I'll make an example for the enum macro once I'm @ it. Problem is that match 
clauses cannot be generated by macros in Rust  so you have to provide a macro 
already implementing the match clause calling a callback function/macro given, 
especially in case of unions ... 

--- tony 

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-02-19 Thread Allen George (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15873735#comment-15873735
 ] 

Allen George commented on THRIFT-2945:
--

[~prz] Can you explain your enum macro above? I'm not 100% sure I see your 
use-case, and I'd like to understand what I'm missing, and whether this is the 
best option to achieve your goals (maybe it is! but, I can't comment because I 
feel like I'm missing something)

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-02-19 Thread Allen George (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15873729#comment-15873729
 ] 

Allen George commented on THRIFT-2945:
--

[~prz] First off - I'm sorry for the delay in replying.

a) Yes. Please name the trait {{TSerializable}}.
b) Yes. That makes sense.
c) Thank you - please extend the test with the example outlined above. This 
should verify that compiling without a namespace "just works".
d) Ah. I didn't consider range-walking. No problem - it's not an issue to add 
hash, but keep the containers as {{BTree..}}.
e) Thank you.

Yes - that sounds like a plan.

As for f) I'm currently experimenting with different approaches to structuring 
the transport to support multi-threaded servers. It won't affect your work, but 
I hope things may become cleaner in the long run.

Thank you for looking into this!

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-02-16 Thread Tony Przygienda (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15869482#comment-15869482
 ] 

Tony Przygienda commented on THRIFT-2945:
-

OK, rephrased in other points what I read

a) we agree the trait is called serializable then 
b) I will check the README and extend it with namespace example and make sure 
everything conforms. I will add a simple example of custom trait (this default 
thingy) 
c) will look @ the service inheritance test
d) We add Hash. Having said that: I discourage you from moving bask to HashSet. 
BTreeSet/Map can we range-walked which can be a very serious asset. 
e) I will look @ the format issue & fix `rust_safe_case`
f) Understood your reasoning about the Rc Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-02-15 Thread Allen George (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15867851#comment-15867851
 ] 

Allen George commented on THRIFT-2945:
--

I'm sorry - I don't have any idea about XCode :( I use both CLion and Visual 
Studio Code for C++ work.

I'm unsatisfied with the entire {{Rc>>}} business as well; it 
was easily the most frustrating thing in working with Rust: how semantics that 
are easy to express in many other languages become extremely convoluted in 
Rust. I posted many questions on the various Rust forums about better solutions 
given the problem constraints, but didn't receive any better options.

Here are the problem constraints:

# You must be able to choose any combination of io-channel, transport, protocol 
at runtime. See the 
[cross-test|https://github.com/apache/thrift/blob/master/test/rs/src/bin/test_client.rs#L71]
 for a concrete example.
# A single *IO channel* (i.e. tcp socket, unix socket, memory) may be _shared 
by both_ the input transport and the output transport. Alternatively, each 
transport may have its own IO channel.
# A single *transport* may be _shared by both_ the input protocol and the 
output protocol. Alternatively, each protocol may have its own transport.
# I want to write test code that _preserves the type_ of the wrapped IO-channel 
or transport.

* The most maintainable way to achieve *1* is write code like:
{noformat}
let channel = create_io_channel(&channel_type, ...);
let transport = create_transport(&transport_type, &mut channel);
let input_protocol = create_input_protocol(&input_protocol_type, 
transport.clone());
let output_protocol = create_output_protocol(&output_protocol_type, 
transport.clone());
{noformat}
Unfortunately this means that channel and transport have to be trait-boxed 
because you don't know the exact type coming out of the {{create_io_channel}} 
and {{create_transport}} constructor functions.
* The sharing requirements of *2* and *3* require that types are wrapped in a 
{{Rc>}}.
* Boxing the types returned by the {{create_io_channel}} and 
{{create_transport}} constructor functions mean that you lose type information 
and can't downcast to the concrete type because boxed pointers are different 
from struct pointers. This requires the annoying {{TPassThruTransport}} that 
takes the underlying type using generics and can be boxed and shared etc. etc.

If you can propose a cleaner solution that meets all the criteria that'd be 
great!

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-02-15 Thread Allen George (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15867808#comment-15867808
 ] 

Allen George commented on THRIFT-2945:
--

Extracting {{write_from...}} and {{read_from...}}: Ok. Your points make sense. 
Please name the new trait {{TSerializable}} then.

Doubles: Hmm, so you ran everything outlined in the 
[README|https://github.com/apache/thrift/blob/master/lib/rs/README.md]? A 
minimal test type would be:

{noformat}
struct SomeStruct {
  1: double bare_double
  2: map mapped_doubles
  3: set set_of_doubles
}
{noformat}

Ah. Looks like it was an oversight on my part (I think?) I notice that there is 
a {{Hash}} implementation for ordered float. This is ideal because I can 
replace the {{BTree...}} versions of maps and sets with hashes if they work. 
That said, I only want to do that if it's an "all or nothing" move; I want to 
avoid flags in code generation.

Namespaces: Can you confirm that all the steps in the README work? I would also 
update the service inheritance 
[test|https://github.com/apache/thrift/tree/master/lib/rs/test] to ensure that 
two identically named types can be referred to properly. For example:

{noformat}
Base_One.thrift: Define a struct "Foo"
Ultimate.thrift: Define another struct "Foo"; create a service call that uses 
Base_One.Foo and Ultimate.Foo
{noformat}

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-02-13 Thread Tony Przygienda (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15865263#comment-15865263
 ] 

Tony Przygienda commented on THRIFT-2945:
-

for 5. I finally found the PassThru solution to mask a richer implementation of 
the transport. I guess it works but it surely ain't easy to figure out ... 

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-02-13 Thread Tony Przygienda (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15865159#comment-15865159
 ] 

Tony Przygienda commented on THRIFT-2945:
-

1. OK, I named it serializable since that's what the functions do. TThriftType 
may imply many other things ... I have already my own traits called TThriftXXX 
... Observe that Rust lives off traits, it's very common to add them to structs 
... 
2. worked all fine with all the tests so please give me a min test you think 
may break on the hash. Otherwise maybe a knob under rust code generation ... 
3. well, a method values() is a runtime thing which won't help. A simple 
example of trivial defaults one can generate under https://is.gd/bvkaey
   You can only generate it via macros, nothing else. And people do NOT have to 
use the macros, they just compile away ... I find it extremely helpful for my 
work here, the special enum treatement is necessary due to Rust macro 
restrictions ... 
4. concrete example is that I have a module and within it the mod models where 
I want my thrift files to. I just run a small makefile in the models directory 

> all: encoding.rs routingtable.rs common.rs
> *.rs: common.rs Makefile
> %.rs: %.thrift
>   $(THRIFT_COMPILER) -I $(CURDIR)/common --gen rs --out $(CURDIR) $<

this needs  namespace * models on top so all the imports are correctly 
generated, otherwise the assumption is that models are in the top which is 
unscalable. Works a charm 

OK, will fix the `rust_safe_case` ... 

Formatting is the XCode setup, don't know where to twiddle it ... :-/  Any 
idea? Otherwise need surf web ... 

5. The implementation of the transport/protocol is now very convoluted. The 
TTransport embedded in Rc Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-02-13 Thread Allen George (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15864893#comment-15864893
 ] 

Allen George commented on THRIFT-2945:
--

[~prz] - let me try to address these points individually.

# "Split the {{read_from_in_protocol}} and {{write_to_out_protocol}} as a 
trait." This seems like a great idea. Perhaps it could be named {{TThriftType}} 
to keep with the existing naming convention? I suggest submitting this as a PR 
since it would be small and self-contained.
# "Auto-derive hash on generated types." Are you sure this works with types 
that contain {{OrderedFloat}}? Thrift doubles (represented in Rust by floats, 
not fixed-point integers) are the reason why I had to use {{BTreeMap}} and 
{{BTreeSet}}, and was unable to auto-derive {{Hash}}. Perhaps I overlooked 
something?
# Could you clarify why you need to change the enum and union code-generation? 
From what I understand, your main requirement was getting a list of all defined 
enum variants and associated values. Since we know the full list of variants 
ahead from the thrift file we could simply add a {{values()}} method that 
returns the information you need. Also note that I specifically opted *not* to 
use generate macros since it adds another level of indirection that anybody 
debugging thrift auto-gen code would have to reason about: they'd have to 
understand how the thrift gets turned into a macro, the macro definition, and 
then the final rust output.
# Finally, while I understand that you want to use the Thrift {{namespace}} 
directive. Could you give me a concrete example of what you expect the output 
to be? Would it be output to different directories, or would you output it to 
the same directory and then rely on a manual step afterwards to move it to the 
appropriate Rust module. (PS. Your patch has a bug: you forgot to 
{{rust_safe_case}} the module name, and it will break on thrift modules that 
already have underscores in them)

Another points: I looked at your branch, and noticed that your formatting is 
inconsistent with the existing code (the existing code uses 2-space tabs).

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-02-12 Thread Tony Przygienda (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15863010#comment-15863010
 ] 

Tony Przygienda commented on THRIFT-2945:
-

understood, I'm commenting purely in Rust context here and Rust code 
generation. I didn't touch the Thrift compiler meta code, it's golden, in fact 
great code very easy to get one's head around ... 

As well, I implemented additionally on the branch macro generation for 
struct/union/enum which will convienently allow the application to derive 
further traits via e.g. Rust macros, example 

macro_rules! ENUM_MEMBERS_OPERATION { () => 
  {
ADD = 1,
SUBTRACT = 2,
MULTIPLY = 3,
DIVIDE = 4,
  }
}
///You can define enums, which are just 32 bit integers. Values are optional
///and start at 1 if not supplied, C style again.
#[derive(Copy, Clone, Debug, Eq, Ord, PartialEq, PartialOrd, Hash)]
pub enum Operation {
  ADD = 1,
  SUBTRACT = 2,
  MULTIPLY = 3,
  DIVIDE = 4,
}

will allow via ENUM_MEMBERS_OPERATION!() invocation to obtain the list of all 
names of enum members with values (analogous struct,enum) and write according 
macros of it ... Extremely useful for traits, since then one can just macroize 
traits out per each Thrift type in case the specific fields/types/values are 
needed ... Mind-bendingly powerful ... 

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-02-12 Thread Jens Geyer (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15863002#comment-15863002
 ] 

Jens Geyer commented on THRIFT-2945:


http://thrift.apache.org/docs/idl
{{[6]  NamespaceScope  ::=  '*' | 'cpp' | 'java' | 'py' | 'perl' | 'rb' | 
'cocoa' | 'csharp'}}

The * in namespace decls is already supported for a while now.

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-02-12 Thread Tony Przygienda (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15862911#comment-15862911
 ] 

Tony Przygienda commented on THRIFT-2945:
-

fantastic work albeit it compltely ruined all my previous work & I need 
refactor now ;-) I pulled a branch since I suggest multiple changes to this 
work:

a) the namespace support could be significatnly better by allowing on top of 
the thrift file 

namespace * thriftmodule

that allows to put the thrift schemas into a submodule of a crate and use it 
that way which is very convenienent if you want to implement e.g. custom traits 
for the generated types ... I have the patch on 

https://github.com/przygienda/thrift-rust-thrift-include-and-custom-trait-support

already. It's not trivial since the namespace + get_program are interacting up 
to point things need be

::namespace::thriftmodule::type 

all works on the branch 

b)  suggest auto-derive Hash on the types for convienence 

c) will pull out the read_from_in_protocol and write_to_out_protocol as a trait 
implementation. Before there was a ThriftTyped which allowed to write generics 
for generated trait types. We need that again ;-) 

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-26 Thread Allen George (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15839705#comment-15839705
 ] 

Allen George commented on THRIFT-2945:
--

[~anatolikus], [~jensg] - thank you for the kind words, it's really appreciated!

I've definitely not completed work on this :) My top three priorities are:

* Multi-threaded synchronous client
* Multi-threaded synchronous server
* JSON protocol

Before I make these changes there are some internal house-keeping things I've 
to do, like adding macros to make it easier to write protocol and transport 
tests.

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-25 Thread Jens Geyer (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15838941#comment-15838941
 ] 

Jens Geyer commented on THRIFT-2945:


Hi [~anatolikus],

- Regarding the package stuff you should talk to [~jfarrell].
- Only [Apache Committers|https://www.apache.org/dev/committers.html] have 
write access to ASF repos, on a per-project basis (i.e. Thrift is a project), 
for  a number of reasons.
- Maintaining happens as before via Github and/or Patch files, reviews and 
finally commits. There is usually someone around that will take care of this. 

And since this is open source, everybody can 
[contribute|https://community.apache.org/contributors] by reviewing and testing 
patch proposals and giving useful feedback.

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-25 Thread Anatol Pomozov (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15838921#comment-15838921
 ] 

Anatol Pomozov commented on THRIFT-2945:


Also, when are you going to release a new version of Thrift? I know you just 
released 0.10.0 recently. Is there any hope that we will see 0.10.1 in the next 
few months?

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-25 Thread Anatol Pomozov (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15838919#comment-15838919
 ] 

Anatol Pomozov commented on THRIFT-2945:


Yay! It is great! And thank you Allen for your work!

Who owns access to language package manager account (in case of Rust - 
http://crates.io)? Who publishes `thrift` crate?
Is there a such thing as a Thrift language binding maintainer? Allen did a 
great work with Thrift. Is there an easy way for him to maintain his code? 
Anything like per-language commit access or something similar?

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Rust - Compiler, Rust - Library
>Reporter: Maksim Golov
>Assignee: Allen George
> Fix For: 0.11.0
>
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-25 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15838912#comment-15838912
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user asfgit closed the pull request at:

https://github.com/apache/thrift/pull/1147


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-25 Thread Allen George (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15838841#comment-15838841
 ] 

Allen George commented on THRIFT-2945:
--

Oh great! Yes - sorry about that. I had an initial PR that I abandoned; I 
squashed everything into a single commit and have simply been updating that. 
But, just to confirm, the latest hash I have is "b9b20fa0". Thank you for 
taking the time [~jensg] - and let me know if you've any questions or comments!

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-25 Thread Jens Geyer (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15838795#comment-15838795
 ] 

Jens Geyer commented on THRIFT-2945:


Ah, got it. The URL has changed, it's now thrift-2945-pr. I took the old one 
and hit the wall with tons of conflicts (not just one or two). 
Merge succeeded, looking into it ...

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-25 Thread Allen George (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15838737#comment-15838737
 ] 

Allen George commented on THRIFT-2945:
--

[~jensg] I have just updated the PR commit after rebasing on master right now 
(the latest commit I have locally is 6fe7fa Thrift-3892). As far as I can tell 
on Github there are no merge conflicts. Could you let me know if there are any 
issues? I'd be happy to help track them down and resolve them.

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-25 Thread Allen George (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15838729#comment-15838729
 ] 

Allen George commented on THRIFT-2945:
--

[~jensg] Also, could you tell me while file is causing issues?

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-25 Thread Allen George (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15838727#comment-15838727
 ] 

Allen George commented on THRIFT-2945:
--

[~jensg] I don't see a conflict in github. Let me pull upstream master again 
and rebase. Give me 5 mins.

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-25 Thread Jens Geyer (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15838683#comment-15838683
 ] 

Jens Geyer commented on THRIFT-2945:


I'm getting conflicts on merge?

> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-22 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15833757#comment-15833757
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
Yay! Build passed :) Any thoughts on whether this is OK to merge?


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-22 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15833725#comment-15833725
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
Fixed makefile errors with `make distdir`


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-22 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15833537#comment-15833537
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
More updates:

- Minor cleanups to Rust code generators
- Confirmed that all Rust code does not trigger any clippy lint warnings


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-22 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15833497#comment-15833497
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@anatol Code has been updated with the following changes:

- All usage of `try!` converted to `?`
- Fix all but two clippy lint warnings (I thought the existing code was 
clearer)


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-21 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15833249#comment-15833249
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@anatol Thanks for the clippy output! I'll look through all of the items 
and fix them. I'd no idea that `new()` without `Default` was considered a code 
smell. Interesting.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-21 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15833247#comment-15833247
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r97211560
  
--- Diff: lib/rs/src/errors.rs ---
@@ -0,0 +1,678 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+use std::convert::{From, Into};
+use std::error::Error as StdError;
+use std::fmt::{Debug, Display, Formatter};
+use std::{error, fmt, io, string};
+use try_from::TryFrom;
+
+use ::protocol::{TFieldIdentifier, TInputProtocol, TOutputProtocol, 
TStructIdentifier, TType};
+
+// FIXME: should all my error structs impl error::Error as well?
+// FIXME: should all fields in TransportError, ProtocolError and 
ApplicationError be optional?
+
+/// Thrift error type.
+///
+/// The error type defined here is used throughout this crate as well as in
+/// all Thrift-compiler-generated Rust code. It falls into one of four
+/// standard (i.e. defined by convention in Thrift implementations) 
categories.
+/// These are:
+///
+/// 1. **Transport errors**: errors encountered while writing byes to the 
I/O
+///channel. These include "connection closed", "bind errors", etc.
+/// 2. **Protocol errors**: errors encountered when processing a Thrift 
message
+///within the thrift library. These include "exceeding size limits",
+///"unsupported protocol versions", etc.
+/// 3. **Application errors**: errors encountered when 
Thrift-compiler-generated
+///'application' code encounters conditions that violate the spec. 
These
+///include "out-of-order messages", "missing required-field values", 
etc.
+///This category also functions as a catch-all: any error returned by
+///handler functions is automatically encoded as an `ApplicationError` 
and
+///returned to the caller.
+/// 4. **User errors**: exception structs defined within the Thrift IDL.
+///
+/// With the exception of `Error::User`, each error variant encapsulates a
+/// corresponding struct which encodes two required fields:
+///
+/// 1. kind: an enum indicating what kind of error was encountered
+/// 2. message: string with human-readable error information
+///
+/// These two fields are encoded and sent over the wire to the remote. 
`kind`
+/// is defined by convention while `message` is freeform. If none of the
+/// enumerated error kinds seem suitable use the catch-all `Unknown`.
+///
+/// # Examples
+///
+/// Creating a `TransportError` explicitly.
+///
+/// Conversions are defined from `thrift::TransportError`, 
`thrift::ProtocolError`
+/// and `thrift::ApplicationError` to the corresponding `thrift::Error` 
variant
+/// (see `err2` below).
+///
+/// ```
+/// use thrift;
+/// use thrift::{TransportError, TransportErrorKind};
+///
+/// let err0: thrift::Result<()> = Err(
+///   thrift::Error::Transport(
+/// TransportError {
+///   kind: TransportErrorKind::TimedOut,
+///   message: format!("connection to server timed out")
+/// }
+///   )
+/// );
+///
+/// let err1: thrift::Result<()> = Err(
+///   thrift::Error::Transport(
+/// TransportError::new(
+///   TransportErrorKind::TimedOut,
+///   format!("connection to server timed out")
+/// )
+///   )
+/// );
+///
+/// let err2: thrift::Result<()> = Err(
+///   thrift::Error::from(
+/// TransportError::new(
+///   TransportErrorKind::TimedOut,
+///   format!("connection to server timed out")
+/// )
+///   )
+/// );
+///
+/// ```
+///
+/// Creating an arbitrary error from a string
+///
+/// ```
+/// use thrift;
+/// use thrift::{ApplicationError, ApplicationErrorKind};
+///
+///

[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-21 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15833239#comment-15833239
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user anatol commented on the issue:

https://github.com/apache/thrift/pull/1147
  
FYI: run the code through `clippy` checker and [here is its 
output](http://pastebin.com/icvD3yNA)  Some of the warnings (but not all) look 
interesting.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-21 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15833237#comment-15833237
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user anatol commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r97211272
  
--- Diff: lib/rs/src/errors.rs ---
@@ -0,0 +1,678 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+use std::convert::{From, Into};
+use std::error::Error as StdError;
+use std::fmt::{Debug, Display, Formatter};
+use std::{error, fmt, io, string};
+use try_from::TryFrom;
+
+use ::protocol::{TFieldIdentifier, TInputProtocol, TOutputProtocol, 
TStructIdentifier, TType};
+
+// FIXME: should all my error structs impl error::Error as well?
+// FIXME: should all fields in TransportError, ProtocolError and 
ApplicationError be optional?
+
+/// Thrift error type.
+///
+/// The error type defined here is used throughout this crate as well as in
+/// all Thrift-compiler-generated Rust code. It falls into one of four
+/// standard (i.e. defined by convention in Thrift implementations) 
categories.
+/// These are:
+///
+/// 1. **Transport errors**: errors encountered while writing byes to the 
I/O
+///channel. These include "connection closed", "bind errors", etc.
+/// 2. **Protocol errors**: errors encountered when processing a Thrift 
message
+///within the thrift library. These include "exceeding size limits",
+///"unsupported protocol versions", etc.
+/// 3. **Application errors**: errors encountered when 
Thrift-compiler-generated
+///'application' code encounters conditions that violate the spec. 
These
+///include "out-of-order messages", "missing required-field values", 
etc.
+///This category also functions as a catch-all: any error returned by
+///handler functions is automatically encoded as an `ApplicationError` 
and
+///returned to the caller.
+/// 4. **User errors**: exception structs defined within the Thrift IDL.
+///
+/// With the exception of `Error::User`, each error variant encapsulates a
+/// corresponding struct which encodes two required fields:
+///
+/// 1. kind: an enum indicating what kind of error was encountered
+/// 2. message: string with human-readable error information
+///
+/// These two fields are encoded and sent over the wire to the remote. 
`kind`
+/// is defined by convention while `message` is freeform. If none of the
+/// enumerated error kinds seem suitable use the catch-all `Unknown`.
+///
+/// # Examples
+///
+/// Creating a `TransportError` explicitly.
+///
+/// Conversions are defined from `thrift::TransportError`, 
`thrift::ProtocolError`
+/// and `thrift::ApplicationError` to the corresponding `thrift::Error` 
variant
+/// (see `err2` below).
+///
+/// ```
+/// use thrift;
+/// use thrift::{TransportError, TransportErrorKind};
+///
+/// let err0: thrift::Result<()> = Err(
+///   thrift::Error::Transport(
+/// TransportError {
+///   kind: TransportErrorKind::TimedOut,
+///   message: format!("connection to server timed out")
+/// }
+///   )
+/// );
+///
+/// let err1: thrift::Result<()> = Err(
+///   thrift::Error::Transport(
+/// TransportError::new(
+///   TransportErrorKind::TimedOut,
+///   format!("connection to server timed out")
+/// )
+///   )
+/// );
+///
+/// let err2: thrift::Result<()> = Err(
+///   thrift::Error::from(
+/// TransportError::new(
+///   TransportErrorKind::TimedOut,
+///   format!("connection to server timed out")
+/// )
+///   )
+/// );
+///
+/// ```
+///
+/// Creating an arbitrary error from a string
+///
+/// ```
+/// use thrift;
+/// use thrift::{ApplicationError, ApplicationErrorKind};
+///
+/// let 

[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-21 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15833229#comment-15833229
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r97211074
  
--- Diff: lib/rs/src/errors.rs ---
@@ -0,0 +1,678 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+use std::convert::{From, Into};
+use std::error::Error as StdError;
+use std::fmt::{Debug, Display, Formatter};
+use std::{error, fmt, io, string};
+use try_from::TryFrom;
+
+use ::protocol::{TFieldIdentifier, TInputProtocol, TOutputProtocol, 
TStructIdentifier, TType};
+
+// FIXME: should all my error structs impl error::Error as well?
+// FIXME: should all fields in TransportError, ProtocolError and 
ApplicationError be optional?
+
+/// Thrift error type.
+///
+/// The error type defined here is used throughout this crate as well as in
+/// all Thrift-compiler-generated Rust code. It falls into one of four
+/// standard (i.e. defined by convention in Thrift implementations) 
categories.
+/// These are:
+///
+/// 1. **Transport errors**: errors encountered while writing byes to the 
I/O
+///channel. These include "connection closed", "bind errors", etc.
+/// 2. **Protocol errors**: errors encountered when processing a Thrift 
message
+///within the thrift library. These include "exceeding size limits",
+///"unsupported protocol versions", etc.
+/// 3. **Application errors**: errors encountered when 
Thrift-compiler-generated
+///'application' code encounters conditions that violate the spec. 
These
+///include "out-of-order messages", "missing required-field values", 
etc.
+///This category also functions as a catch-all: any error returned by
+///handler functions is automatically encoded as an `ApplicationError` 
and
+///returned to the caller.
+/// 4. **User errors**: exception structs defined within the Thrift IDL.
+///
+/// With the exception of `Error::User`, each error variant encapsulates a
+/// corresponding struct which encodes two required fields:
+///
+/// 1. kind: an enum indicating what kind of error was encountered
+/// 2. message: string with human-readable error information
+///
+/// These two fields are encoded and sent over the wire to the remote. 
`kind`
+/// is defined by convention while `message` is freeform. If none of the
+/// enumerated error kinds seem suitable use the catch-all `Unknown`.
+///
+/// # Examples
+///
+/// Creating a `TransportError` explicitly.
+///
+/// Conversions are defined from `thrift::TransportError`, 
`thrift::ProtocolError`
+/// and `thrift::ApplicationError` to the corresponding `thrift::Error` 
variant
+/// (see `err2` below).
+///
+/// ```
+/// use thrift;
+/// use thrift::{TransportError, TransportErrorKind};
+///
+/// let err0: thrift::Result<()> = Err(
+///   thrift::Error::Transport(
+/// TransportError {
+///   kind: TransportErrorKind::TimedOut,
+///   message: format!("connection to server timed out")
+/// }
+///   )
+/// );
+///
+/// let err1: thrift::Result<()> = Err(
+///   thrift::Error::Transport(
+/// TransportError::new(
+///   TransportErrorKind::TimedOut,
+///   format!("connection to server timed out")
+/// )
+///   )
+/// );
+///
+/// let err2: thrift::Result<()> = Err(
+///   thrift::Error::from(
+/// TransportError::new(
+///   TransportErrorKind::TimedOut,
+///   format!("connection to server timed out")
+/// )
+///   )
+/// );
+///
+/// ```
+///
+/// Creating an arbitrary error from a string
+///
+/// ```
+/// use thrift;
+/// use thrift::{ApplicationError, ApplicationErrorKind};
+///
+///

[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-21 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15833222#comment-15833222
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user anatol commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r97210978
  
--- Diff: lib/rs/src/errors.rs ---
@@ -0,0 +1,678 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+use std::convert::{From, Into};
+use std::error::Error as StdError;
+use std::fmt::{Debug, Display, Formatter};
+use std::{error, fmt, io, string};
+use try_from::TryFrom;
+
+use ::protocol::{TFieldIdentifier, TInputProtocol, TOutputProtocol, 
TStructIdentifier, TType};
+
+// FIXME: should all my error structs impl error::Error as well?
+// FIXME: should all fields in TransportError, ProtocolError and 
ApplicationError be optional?
+
+/// Thrift error type.
+///
+/// The error type defined here is used throughout this crate as well as in
+/// all Thrift-compiler-generated Rust code. It falls into one of four
+/// standard (i.e. defined by convention in Thrift implementations) 
categories.
+/// These are:
+///
+/// 1. **Transport errors**: errors encountered while writing byes to the 
I/O
+///channel. These include "connection closed", "bind errors", etc.
+/// 2. **Protocol errors**: errors encountered when processing a Thrift 
message
+///within the thrift library. These include "exceeding size limits",
+///"unsupported protocol versions", etc.
+/// 3. **Application errors**: errors encountered when 
Thrift-compiler-generated
+///'application' code encounters conditions that violate the spec. 
These
+///include "out-of-order messages", "missing required-field values", 
etc.
+///This category also functions as a catch-all: any error returned by
+///handler functions is automatically encoded as an `ApplicationError` 
and
+///returned to the caller.
+/// 4. **User errors**: exception structs defined within the Thrift IDL.
+///
+/// With the exception of `Error::User`, each error variant encapsulates a
+/// corresponding struct which encodes two required fields:
+///
+/// 1. kind: an enum indicating what kind of error was encountered
+/// 2. message: string with human-readable error information
+///
+/// These two fields are encoded and sent over the wire to the remote. 
`kind`
+/// is defined by convention while `message` is freeform. If none of the
+/// enumerated error kinds seem suitable use the catch-all `Unknown`.
+///
+/// # Examples
+///
+/// Creating a `TransportError` explicitly.
+///
+/// Conversions are defined from `thrift::TransportError`, 
`thrift::ProtocolError`
+/// and `thrift::ApplicationError` to the corresponding `thrift::Error` 
variant
+/// (see `err2` below).
+///
+/// ```
+/// use thrift;
+/// use thrift::{TransportError, TransportErrorKind};
+///
+/// let err0: thrift::Result<()> = Err(
+///   thrift::Error::Transport(
+/// TransportError {
+///   kind: TransportErrorKind::TimedOut,
+///   message: format!("connection to server timed out")
+/// }
+///   )
+/// );
+///
+/// let err1: thrift::Result<()> = Err(
+///   thrift::Error::Transport(
+/// TransportError::new(
+///   TransportErrorKind::TimedOut,
+///   format!("connection to server timed out")
+/// )
+///   )
+/// );
+///
+/// let err2: thrift::Result<()> = Err(
+///   thrift::Error::from(
+/// TransportError::new(
+///   TransportErrorKind::TimedOut,
+///   format!("connection to server timed out")
+/// )
+///   )
+/// );
+///
+/// ```
+///
+/// Creating an arbitrary error from a string
+///
+/// ```
+/// use thrift;
+/// use thrift::{ApplicationError, ApplicationErrorKind};
+///
+/// let 

[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-21 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15833221#comment-15833221
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r97210903
  
--- Diff: lib/rs/src/errors.rs ---
@@ -0,0 +1,678 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+use std::convert::{From, Into};
+use std::error::Error as StdError;
+use std::fmt::{Debug, Display, Formatter};
+use std::{error, fmt, io, string};
+use try_from::TryFrom;
+
+use ::protocol::{TFieldIdentifier, TInputProtocol, TOutputProtocol, 
TStructIdentifier, TType};
+
+// FIXME: should all my error structs impl error::Error as well?
+// FIXME: should all fields in TransportError, ProtocolError and 
ApplicationError be optional?
+
+/// Thrift error type.
+///
+/// The error type defined here is used throughout this crate as well as in
+/// all Thrift-compiler-generated Rust code. It falls into one of four
+/// standard (i.e. defined by convention in Thrift implementations) 
categories.
+/// These are:
+///
+/// 1. **Transport errors**: errors encountered while writing byes to the 
I/O
+///channel. These include "connection closed", "bind errors", etc.
+/// 2. **Protocol errors**: errors encountered when processing a Thrift 
message
+///within the thrift library. These include "exceeding size limits",
+///"unsupported protocol versions", etc.
+/// 3. **Application errors**: errors encountered when 
Thrift-compiler-generated
+///'application' code encounters conditions that violate the spec. 
These
+///include "out-of-order messages", "missing required-field values", 
etc.
+///This category also functions as a catch-all: any error returned by
+///handler functions is automatically encoded as an `ApplicationError` 
and
+///returned to the caller.
+/// 4. **User errors**: exception structs defined within the Thrift IDL.
+///
+/// With the exception of `Error::User`, each error variant encapsulates a
+/// corresponding struct which encodes two required fields:
+///
+/// 1. kind: an enum indicating what kind of error was encountered
+/// 2. message: string with human-readable error information
+///
+/// These two fields are encoded and sent over the wire to the remote. 
`kind`
+/// is defined by convention while `message` is freeform. If none of the
+/// enumerated error kinds seem suitable use the catch-all `Unknown`.
+///
+/// # Examples
+///
+/// Creating a `TransportError` explicitly.
+///
+/// Conversions are defined from `thrift::TransportError`, 
`thrift::ProtocolError`
+/// and `thrift::ApplicationError` to the corresponding `thrift::Error` 
variant
+/// (see `err2` below).
+///
+/// ```
+/// use thrift;
+/// use thrift::{TransportError, TransportErrorKind};
+///
+/// let err0: thrift::Result<()> = Err(
+///   thrift::Error::Transport(
+/// TransportError {
+///   kind: TransportErrorKind::TimedOut,
+///   message: format!("connection to server timed out")
+/// }
+///   )
+/// );
+///
+/// let err1: thrift::Result<()> = Err(
+///   thrift::Error::Transport(
+/// TransportError::new(
+///   TransportErrorKind::TimedOut,
+///   format!("connection to server timed out")
+/// )
+///   )
+/// );
+///
+/// let err2: thrift::Result<()> = Err(
+///   thrift::Error::from(
+/// TransportError::new(
+///   TransportErrorKind::TimedOut,
+///   format!("connection to server timed out")
+/// )
+///   )
+/// );
+///
+/// ```
+///
+/// Creating an arbitrary error from a string
+///
+/// ```
+/// use thrift;
+/// use thrift::{ApplicationError, ApplicationErrorKind};
+///
+///

[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-21 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15833220#comment-15833220
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user anatol commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r97210872
  
--- Diff: lib/rs/src/errors.rs ---
@@ -0,0 +1,678 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+use std::convert::{From, Into};
+use std::error::Error as StdError;
+use std::fmt::{Debug, Display, Formatter};
+use std::{error, fmt, io, string};
+use try_from::TryFrom;
+
+use ::protocol::{TFieldIdentifier, TInputProtocol, TOutputProtocol, 
TStructIdentifier, TType};
+
+// FIXME: should all my error structs impl error::Error as well?
+// FIXME: should all fields in TransportError, ProtocolError and 
ApplicationError be optional?
+
+/// Thrift error type.
+///
+/// The error type defined here is used throughout this crate as well as in
+/// all Thrift-compiler-generated Rust code. It falls into one of four
+/// standard (i.e. defined by convention in Thrift implementations) 
categories.
+/// These are:
+///
+/// 1. **Transport errors**: errors encountered while writing byes to the 
I/O
+///channel. These include "connection closed", "bind errors", etc.
+/// 2. **Protocol errors**: errors encountered when processing a Thrift 
message
+///within the thrift library. These include "exceeding size limits",
+///"unsupported protocol versions", etc.
+/// 3. **Application errors**: errors encountered when 
Thrift-compiler-generated
+///'application' code encounters conditions that violate the spec. 
These
+///include "out-of-order messages", "missing required-field values", 
etc.
+///This category also functions as a catch-all: any error returned by
+///handler functions is automatically encoded as an `ApplicationError` 
and
+///returned to the caller.
+/// 4. **User errors**: exception structs defined within the Thrift IDL.
+///
+/// With the exception of `Error::User`, each error variant encapsulates a
+/// corresponding struct which encodes two required fields:
+///
+/// 1. kind: an enum indicating what kind of error was encountered
+/// 2. message: string with human-readable error information
+///
+/// These two fields are encoded and sent over the wire to the remote. 
`kind`
+/// is defined by convention while `message` is freeform. If none of the
+/// enumerated error kinds seem suitable use the catch-all `Unknown`.
+///
+/// # Examples
+///
+/// Creating a `TransportError` explicitly.
+///
+/// Conversions are defined from `thrift::TransportError`, 
`thrift::ProtocolError`
+/// and `thrift::ApplicationError` to the corresponding `thrift::Error` 
variant
+/// (see `err2` below).
+///
+/// ```
+/// use thrift;
+/// use thrift::{TransportError, TransportErrorKind};
+///
+/// let err0: thrift::Result<()> = Err(
+///   thrift::Error::Transport(
+/// TransportError {
+///   kind: TransportErrorKind::TimedOut,
+///   message: format!("connection to server timed out")
+/// }
+///   )
+/// );
+///
+/// let err1: thrift::Result<()> = Err(
+///   thrift::Error::Transport(
+/// TransportError::new(
+///   TransportErrorKind::TimedOut,
+///   format!("connection to server timed out")
+/// )
+///   )
+/// );
+///
+/// let err2: thrift::Result<()> = Err(
+///   thrift::Error::from(
+/// TransportError::new(
+///   TransportErrorKind::TimedOut,
+///   format!("connection to server timed out")
+/// )
+///   )
+/// );
+///
+/// ```
+///
+/// Creating an arbitrary error from a string
+///
+/// ```
+/// use thrift;
+/// use thrift::{ApplicationError, ApplicationErrorKind};
+///
+/// let 

[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-21 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15833207#comment-15833207
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
Updated:

- Auto-generate constructors for all public structs
- Auto-generate `Default` impl for structs with all-optional fields
- Add constructors for protocol/transport factories
- Use constructors/defaults where appropriate in test/tutorial, etc.
- Fix `make clean` bugs in Rust makefiles
- Clean up some generator code


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-21 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15832996#comment-15832996
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
Any thoughts on this?


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-18 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15827975#comment-15827975
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
I've now added the tutorial.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-17 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15825973#comment-15825973
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@Jens-G Sorry to bother you, but all the Appveyor builds seem stalled. It 
appears to be holding up the Travis fix #1158 that was approved yesterday as 
well :/


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-15 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15823138#comment-15823138
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user Jens-G commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@all: Everyone happy with it?


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-14 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15823014#comment-15823014
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@anatol No worries! I was glad to do it :)


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-14 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15822993#comment-15822993
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user anatol commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@allengeorge Hi Allen, I was intended to send only `.gitignore` comments 
related to `erl`. The other two comments were create a long time ago and for 
some reason github decided to publish it this time. But you've already resolved 
it. Sorry for the confusion. And thanks one more time for your work.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-14 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15822990#comment-15822990
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@anatol My apologies for the earlier spam. FWIW, the latest version of the 
PR has the following:

- The "thrift" crate name (I do not use "rift" anywhere)
- I use the "_" suffix instead of the prefixes I used earlier

I am just about to submit another change that removes the ".erl" gitignores.

I would be very happy to be the thrift library maintainer for rust. There 
are additional server types I want to add, including one for Tokio when it 
stabilizes.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-14 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15822985#comment-15822985
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r96126534
  
--- Diff: compiler/cpp/src/thrift/generate/t_rs_generator.cc ---
@@ -2722,7 +2756,30 @@ string t_rs_generator::rust_namespace(t_service* 
tservice) {
 }
 
 string t_rs_generator::rust_struct_name(t_struct* tstruct) {
-  return rust_camel_case(tstruct->get_name());
+  string base_struct_name(rust_camel_case(tstruct->get_name()));
+  if (is_reserved(base_struct_name)) {
+return "Res" + base_struct_name;
+  } else {
+return base_struct_name;
+  }
+}
+
+string t_rs_generator::rust_field_name(t_field* tfield) {
+  string base_field_name(rust_snake_case(tfield->get_name()));
+  if (is_reserved(base_field_name)) {
+return "res_" + base_field_name;
--- End diff --

I agree. I've changed this as well - perhaps you were looking at an older 
version of the PR?


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-14 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15822987#comment-15822987
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r96126542
  
--- Diff: .gitignore ---
@@ -281,6 +293,7 @@ project.lock.json
 /test/log/
 /test/test.log
 /test/erl/.generated
+/test/erl/.rebar
--- End diff --

Will do so.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-14 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15822986#comment-15822986
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r96126537
  
--- Diff: .gitignore ---
@@ -206,6 +206,7 @@ project.lock.json
 /lib/delphi/test/typeregistry/*.local
 /lib/delphi/test/typeregistry/*.dcu
 /lib/erl/.generated
+/lib/erl/.rebar
--- End diff --

I'll remove this.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-14 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15822984#comment-15822984
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r96126529
  
--- Diff: lib/rs/Cargo.toml ---
@@ -0,0 +1,17 @@
+[package]
+name = "rift"
--- End diff --

@anatol I've previously changed this - perhaps you accidentally looked at 
an older version of the PR?


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-14 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15822944#comment-15822944
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
[puzzled] I removed the reserved prefix and added an underscore suffix as 
you requested. Perhaps I didn't commit that. Let me check. Sorry about that!
And, BTW - I would be very happy to maintain the Rust thrift library and 
cargo. I have additional changes I'd like to make, including a Tokio 
implementation.






On Sat, Jan 14, 2017 at 3:24 PM -0500, "Allen George" 
 wrote:










Sorry @anatol - I thought I'd changed the package name everywhere! I must 
have missed that. Let me fix it ASAP. Sorry!






On Sat, Jan 14, 2017 at 3:20 PM -0500, "Anatol Pomozov" 
 wrote:












This patch looks really good. Thank you @allengeorge for your work! Thrift 
team, is there anything left that prevents rust library from merging?


Is there a such status as 'thrift library maintainer'. It would be great if 
@allengeorge keep maintaining rust library and thrift cargo.



—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.


  
  

















> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-14 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15822943#comment-15822943
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
Sorry @anatol - I thought I'd changed the package name everywhere! I must 
have missed that. Let me fix it ASAP. Sorry!






On Sat, Jan 14, 2017 at 3:20 PM -0500, "Anatol Pomozov" 
 wrote:












This patch looks really good. Thank you @allengeorge for your work! Thrift 
team, is there anything left that prevents rust library from merging?


Is there a such status as 'thrift library maintainer'. It would be great if 
@allengeorge keep maintaining rust library and thrift cargo.



—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.


  
  












> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-14 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15822942#comment-15822942
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user anatol commented on the issue:

https://github.com/apache/thrift/pull/1147
  
This patch looks really good. Thank you @allengeorge for your work! Thrift 
team, is there anything left that prevents rust library from merging?

Is there a such status as 'thrift library maintainer'. It would be great if 
@allengeorge keep maintaining rust library and `thrift` cargo.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-14 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15822937#comment-15822937
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user anatol commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r94364636
  
--- Diff: lib/rs/Cargo.toml ---
@@ -0,0 +1,17 @@
+[package]
+name = "rift"
--- End diff --

I still think that `thrift` would be a better name for the official Thrift 
library implementation.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-14 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15822936#comment-15822936
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user anatol commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r94457731
  
--- Diff: compiler/cpp/src/thrift/generate/t_rs_generator.cc ---
@@ -2722,7 +2756,30 @@ string t_rs_generator::rust_namespace(t_service* 
tservice) {
 }
 
 string t_rs_generator::rust_struct_name(t_struct* tstruct) {
-  return rust_camel_case(tstruct->get_name());
+  string base_struct_name(rust_camel_case(tstruct->get_name()));
+  if (is_reserved(base_struct_name)) {
+return "Res" + base_struct_name;
+  } else {
+return base_struct_name;
+  }
+}
+
+string t_rs_generator::rust_field_name(t_field* tfield) {
+  string base_field_name(rust_snake_case(tfield->get_name()));
+  if (is_reserved(base_field_name)) {
+return "res_" + base_field_name;
--- End diff --

"res_" prefix some might be a little bit confusing. Maybe just add "_" 
prefix/suffix to the name? Compare field names: `res_type` and `type_`; 
`res_func` and `func_`.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-14 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15822938#comment-15822938
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user anatol commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r96123141
  
--- Diff: .gitignore ---
@@ -281,6 +293,7 @@ project.lock.json
 /test/log/
 /test/test.log
 /test/erl/.generated
+/test/erl/.rebar
--- End diff --

ditto


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-14 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15822935#comment-15822935
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user anatol commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r96123137
  
--- Diff: .gitignore ---
@@ -206,6 +206,7 @@ project.lock.json
 /lib/delphi/test/typeregistry/*.local
 /lib/delphi/test/typeregistry/*.dcu
 /lib/erl/.generated
+/lib/erl/.rebar
--- End diff --

it seems unrelated to the rust library


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-14 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15822876#comment-15822876
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
Hi guys - any comments on this PR? I think I've addressed all review 
comments.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-10 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15814870#comment-15814870
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@Jens-G Could you add `lib/rs/README.md` to the list of files for which a 
version has to be updated? I will also look and see if I can automate this 
somehow.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-10 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15814863#comment-15814863
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
I've now updated the PR with `TMultiplexedProcessor`, which was the last 
functional piece missing. I'm now fleshing out the remaining tests as well as 
documentation and examples.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-08 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15809415#comment-15809415
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@Jens-G Do you know why the Debian steps in Travis are failing with:

```
The command "docker run --net=host -e BUILD_LIBS="$BUILD_LIBS" $BUILD_ENV 
-v $(pwd):/thrift/src -it thrift-build:$DISTRO build/docker/scripts/$SCRIPT 
$BUILD_ARG" exited with 2.```


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-08 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15809413#comment-15809413
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
The only file that has to be changed is `lib/rs/Cargo.toml`. It's a simple 
INI-style file, and it has a `version` field in there. Note that Rust does not 
allow you to overwrite crates, so if someone accidentally releases a 1.0.0 onto 
https://crates.io the version is going to have to be bumped upwards.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-08 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15809377#comment-15809377
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user Jens-G commented on the issue:

https://github.com/apache/thrift/pull/1147
  
Master is (currently) always at 1.0.0, since we haven't released a 1.0 yet.

If you tell me all the relevant files, I can add it to 
https://thrift.apache.org/docs/committers/HowToVersion


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-08 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15809342#comment-15809342
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
As for crate ownership, I'm happy to publish (and thereby reserve 
`thrift`), and then transfer ownership to whoever will be in charge of pushing 
published crates.

The relevant documentation is here: 
http://doc.crates.io/crates-io.html#cargo-owner

Note: I've not done anything yet.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-08 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15809335#comment-15809335
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
OK. I believe I've addressed all outstanding comments.

@anatol:

* Reserved type names now have a `_` suffix. I've confirmed that this does 
not trip warnings for either snake-cased or camel-cased identifiers
* Ran `rustfmt` with default settings on the code
* Rebased onto master and squashed all the changes into a single commit

@Jens-G:

* Should the version of the client library be 1.0.0?


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-07 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15808364#comment-15808364
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user Jens-G commented on the issue:

https://github.com/apache/thrift/pull/1147
  
> Oh. Interesting. I forgot that Debian doesn't have a Rust package (yet) 
though it's being worked on IIRC.

There is no (suitable) Rust package for Suse either, only an older version. 
I finally managed [installing through the Rust web 
site](https://www.rust-lang.org/en-US/install.html), works like a charm & build 
went through.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-07 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15807903#comment-15807903
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@anatol Ran `rustfmt` with default settings. Humorously, it has a bug where 
it transforms `::{SomeTypeName}` to `{SomeTypeName}`.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-07 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15807844#comment-15807844
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user anatol commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@allengeorge as of your question about `thrift` crate. Someone from Thrift 
team should own access to it and deploy a new library version every time Thrift 
makes a release.

For example [thrift rubygem](https://rubygems.org/gems/thrift/) is owned by 
@jfarrell. @jfarrell maybe you have a suggestion who from Thrift team needs to 
make Rust library releases? Or maybe [crate.io](crate.io) can be co-owned with 
@allengeorge who will deploy new Rust library on behalf of Thrift team?


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-07 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15807811#comment-15807811
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@anatol I've made the changes. I'll try and rebase (it's a little tough 
because I merged from master in the middle of my work to pick up some build 
fixes)


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-07 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15807705#comment-15807705
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
OK. Will do.

@anatol Do you know if it's possible for someone on the thrift team to 
"reserve" the thrift crate on crates.io? I originally named the library `rift` 
because I didn't want to claim the name until it was decided that this code was 
reasonable.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-06 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15804897#comment-15804897
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user anatol commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@allengeorge thanks for this great work!! A few comment I had earlier that 
looks unresolved

- Name of the official crate should be `thrift`, not `rift`.
- Fields with reserved names should be renamed to `type_` rather than to 
`res_type`.


Also please squash all commits in `thrift-2945-pr` and rebase if needed.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-06 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15804404#comment-15804404
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
Oh. Interesting. I forgot that Debian doesn't have a Rust package (yet) 
though it's being worked on IIRC.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-06 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15804399#comment-15804399
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
I'm continuing to add tests and update documentation, and I think I've 
addressed all the initial comments on this PR. Any further thoughts?


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-04 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15798864#comment-15798864
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
Also, I think the Appveyor build breakage is unrelated?


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-04 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15798855#comment-15798855
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
With my latest commits (fix type reference that broke on another version of 
clang) and removing boost, it appears like the code compiles on all platforms. 
It's not clear to me why the debian builds are breaking though. Did I forget 
something?


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-04 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15798850#comment-15798850
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
Thanks @markerickson-wf - I also saw the commit improving "make clean".


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-04 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15798529#comment-15798529
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user markerickson-wf commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@allengeorge I just did `make clean` followed by `make precross` and I 
don't see any warnings.

The `pubspec.lock` files are in `.gitignore`, so you can safely delete 
those and try again.

`make clean` should remove all of the artifacts leftover from `pub get`, 
but if you want to make sure, you could do this from the root of the thrift 
repo:
```
find . -type f -name "pubspec.lock" | xargs rm
find . -type d -name ".pub" | xargs rm -r
find . -type d -name "packages" | xargs rm -r
find . -type f -name ".packages" | xargs rm
```

As far as the `version` in `pubspec.yaml`, that should be updated on the 
next release.  It looks like it's on the checklist here - 
https://thrift.apache.org/docs/committers/HowToVersion 


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-04 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15798207#comment-15798207
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@jsgf For structs it's more involved than it appears - perhaps because of 
the way I've chosen to represent them. Here are some factors that cause issues:

1. I represent `required` fields as bare types (i.e. no `Option` wrapper). 
This means that if the user doesn't specify them in the IDL const declaration 
then `rustc` will fail.
2. I'm not sure how to handle a case where a user specifies a single struct 
field in the IDL const declaration but ignores the others. I *could* 
conceivably use ".." but (see below)
3. I currently don't implement a `Defaults` trait for structs. Even if I 
did generate one, I'd only do it for structs with all optional or 
opt-in-req-out fields


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-04 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15798180#comment-15798180
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@markerickson-wf Thanks Mark. Here's the error I get when I run `make 
precross`:

```
Resolving dependencies...
The pubspec for thrift 0.10.0 from path has version 1.0.0-dev.
make[4]: *** [pub-get-client] Error 65
```

I see the `pubspec.yaml` in `lib/dart` is set to `1.0.0-dev`, but what's 
weird (to me) is that the `pubspec.yaml` in the `test/dart` directory only has 
a path dependency, not a version dependency. There must be a lock file with the 
specific version somewhere that I missed.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-04 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15798171#comment-15798171
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
What should the version number of the client library be? Looks like they're 
currently set to 1.0.0?


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-04 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15798168#comment-15798168
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r94576295
  
--- Diff: compiler/cpp/src/thrift/generate/t_rs_generator.cc ---
@@ -0,0 +1,2846 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+#include 
+#include 
+#include 
+#include 
--- End diff --

OK. I'll code up my own string replace.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-03 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15796638#comment-15796638
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user Jens-G commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r94510188
  
--- Diff: compiler/cpp/src/thrift/generate/t_rs_generator.cc ---
@@ -0,0 +1,2846 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+#include 
+#include 
+#include 
+#include 
--- End diff --

Oops! The Thrift compiler should not rely on boost being installed. We 
really need to remove that. Sorry.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-03 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15795320#comment-15795320
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user markerickson-wf commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@allengeorge re: "Dart: weird problem with pubspec requiring 1.0.0 instead 
of 1.0.0-dev" - I can help look into that if you give some more detail.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-03 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15794522#comment-15794522
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user Jens-G commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r94371350
  
--- Diff: test/ThriftTest.thrift ---
@@ -67,7 +67,7 @@ typedef i64 UserId
 struct Bonk
 {
   1: string message,
-  2: i32 type
+  2: i32 bonkType
 }
--- End diff --

It didn't. 


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-03 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15794514#comment-15794514
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user Jens-G commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r94370827
  
--- Diff: lib/rs/Cargo.toml ---
@@ -0,0 +1,17 @@
+[package]
+name = "rift"
+description = "Rust Thrift library"
+version = "0.5.1"
+license = "Apache-2.0"
+authors = ["Allen George "]
+readme = "README.md"
+documentation = "https://docs.rs/rift/";
+exclude = ["Makefile*"]
+keywords = ["thrift"]
+
--- End diff --

Yep, fine. We also have a template on the bottom of [that page over 
here]((http://thrift.apache.org/docs/committers/HowToVersion)). The `name` 
should probably not be "Rift" and `documentation` should point to 
http://thrift.apache.org. The `version` tag needs to be the same as for all 
other client libraries.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-02 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15793994#comment-15793994
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r94356759
  
--- Diff: lib/rs/Cargo.toml ---
@@ -0,0 +1,17 @@
+[package]
+name = "rift"
+description = "Rust Thrift library"
+version = "0.5.1"
+license = "Apache-2.0"
+authors = ["Allen George "]
+readme = "README.md"
+documentation = "https://docs.rs/rift/";
+exclude = ["Makefile*"]
+keywords = ["thrift"]
+
--- End diff --

I have changed it to "Apache Thrift Developers ". 
This is what other author tags read, so I assume that's OK.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-02 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15793909#comment-15793909
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r94354976
  
--- Diff: lib/rs/Cargo.toml ---
@@ -0,0 +1,17 @@
+[package]
+name = "rift"
+description = "Rust Thrift library"
+version = "0.5.1"
+license = "Apache-2.0"
+authors = ["Allen George "]
+readme = "README.md"
+documentation = "https://docs.rs/rift/";
+exclude = ["Makefile*"]
+keywords = ["thrift"]
+
--- End diff --

No problem.

1. Should the authors be "Thrift developers"?
2. Isn't the license OK?


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-02 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15793905#comment-15793905
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on the issue:

https://github.com/apache/thrift/pull/1147
  
@jsgf I opted not to do anything with Tokio because I'd like to see it 
settle down and get some solid real-world usage for a while before coding 
anything up with it. IMO, it would be great to get Rust into the hands of 
people (like me) who'd be OK with writing Rust clients against non-Rust servers.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-02 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15793901#comment-15793901
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r94354857
  
--- Diff: test/ThriftTest.thrift ---
@@ -67,7 +67,7 @@ typedef i64 UserId
 struct Bonk
 {
   1: string message,
-  2: i32 type
+  2: i32 bonkType
 }
--- End diff --

@Jens-G I'm sorry if my comment came across as rude. I'll change the code 
generator to prefix reserved names with an identifier.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-02 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15793555#comment-15793555
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user Jens-G commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r94347222
  
--- Diff: lib/rs/Cargo.toml ---
@@ -0,0 +1,17 @@
+[package]
+name = "rift"
+description = "Rust Thrift library"
+version = "0.5.1"
+license = "Apache-2.0"
+authors = ["Allen George "]
+readme = "README.md"
+documentation = "https://docs.rs/rift/";
+exclude = ["Makefile*"]
+keywords = ["thrift"]
+
--- End diff --

I was more referring to the legalese section. If its ASF code, then it 
should say ASF.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-02 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15793553#comment-15793553
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user jsgf commented on the issue:

https://github.com/apache/thrift/pull/1147
  
Awesome! The thing that I got stalled on was non-support for other 
protocols/framing, which meant it wasn't really useful for real use. The other 
blocker was support for async, which is pretty much a must-have for practical 
uses, and the Rust async story is in flux right now with Tokio, etc.

> Not implemented:
> - Struct/union constants: Honestly, this looks like it's "not possible" 
(tm)
> - Multiplexed processor

Have a look at [my repo](https://github.com/jsgf/thrift/tree/rust). I 
implemented these with `lazy_static`. I didn't find anything that couldn't be 
implemented; in general Rust and Thrift seem like a good match.

The main complexity I found was that you have to use `BTreeMap`/`BTreeSet` 
if you want to use maps/sets as keys for other maps/sets, but otherwise 
`HashMap`/`HashSet` are preferred.

The other tricky part was using `Result` to represent exceptions and 
handling some edge cases around void functions which are extended to throw 
extensions.

I'll review in detail.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-02 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15793552#comment-15793552
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user Jens-G commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r94347166
  
--- Diff: test/ThriftTest.thrift ---
@@ -67,7 +67,7 @@ typedef i64 UserId
 struct Bonk
 {
   1: string message,
-  2: i32 type
+  2: i32 bonkType
 }
--- End diff --

BTW, I just did a search for *.thrift files already using `type` across the 
Thrift repo. Besides ThriftTest.thrift itself, there are quite a few more. So 
if we put "type" into the global list, we will have to fix a whole lot of 
existing code.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-02 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15793544#comment-15793544
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user Jens-G commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r94346945
  
--- Diff: test/ThriftTest.thrift ---
@@ -67,7 +67,7 @@ typedef i64 UserId
 struct Bonk
 {
   1: string message,
-  2: i32 type
+  2: i32 bonkType
 }
--- End diff --

Well, first, it is a keyword in Delphi too. Next, you cannot safely assume 
that anyone offering a Thrift API will test all languages implemented today if 
they work with the curent names you use in your IDL. And you cannot look into 
the future and foresee what language Apple or Google or whoever else comes 
around next week which may use "bonkType" as a keyword. So we have to deal with 
it. One way to do it is like the C# generator does it (look for 
`csharp_keywords`). The only bad thing about it is that we still have no common 
mechanism that is used by all generators. Today all generators more or less 
implement it their own way. I still have it on my list and some day I'll start 
working on it and finally consolidate that stuff.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-02 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15793537#comment-15793537
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user Jens-G commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r94346784
  
--- Diff: test/ThriftTest.thrift ---
@@ -67,7 +67,7 @@ typedef i64 UserId
 struct Bonk
 {
   1: string message,
-  2: i32 type
+  2: i32 bonkType
 }
--- End diff --

Well, first, it is a keyword in Delphi too. Next, you cannot safely assume 
that anyone offering a Thrift API will test all languages implemented today if 
they work with the curent names you use in your IDL. And you cannot look into 
the future and foresee what language Apple or Google or whoever else comes 
around next week which may use "bonkType" as a keyword. So we have to deal with 
it.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-02 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15793532#comment-15793532
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user Jens-G commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r94346650
  
--- Diff: test/ThriftTest.thrift ---
@@ -67,7 +67,7 @@ typedef i64 UserId
 struct Bonk
 {
   1: string message,
-  2: i32 type
+  2: i32 bonkType
 }
--- End diff --

Well, it is a keyword in Delphi too. How did we do that? Magic? No.


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-02 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15793169#comment-15793169
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user anatol commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r94333540
  
--- Diff: test/ThriftTest.thrift ---
@@ -67,7 +67,7 @@ typedef i64 UserId
 struct Bonk
 {
   1: string message,
-  2: i32 type
+  2: i32 bonkType
 }
--- End diff --

@Jens-G "type" is a Rust keyword 
https://doc.rust-lang.org/grammar.html#keywords What is the best way to deal in 
such situation?


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-02 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15793123#comment-15793123
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r94331438
  
--- Diff: lib/rs/Cargo.toml ---
@@ -0,0 +1,17 @@
+[package]
+name = "rift"
+description = "Rust Thrift library"
+version = "0.5.1"
+license = "Apache-2.0"
+authors = ["Allen George "]
+readme = "README.md"
+documentation = "https://docs.rs/rift/";
+exclude = ["Makefile*"]
+keywords = ["thrift"]
+
--- End diff --

What should change? And what should I change it to?


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (THRIFT-2945) Implement support for Rust language

2017-01-02 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/THRIFT-2945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15793122#comment-15793122
 ] 

ASF GitHub Bot commented on THRIFT-2945:


Github user allengeorge commented on a diff in the pull request:

https://github.com/apache/thrift/pull/1147#discussion_r94331401
  
--- Diff: test/ThriftTest.thrift ---
@@ -67,7 +67,7 @@ typedef i64 UserId
 struct Bonk
 {
   1: string message,
-  2: i32 type
+  2: i32 bonkType
 }
--- End diff --

@Jens-G will do, but now the autogenerated rust code won't work :(


> Implement support for Rust language
> ---
>
> Key: THRIFT-2945
> URL: https://issues.apache.org/jira/browse/THRIFT-2945
> Project: Thrift
>  Issue Type: New Feature
>  Components: Wish List
>Reporter: Maksim Golov
>Assignee: Jeremy Fitzhardinge
>
> Work on implementing support for Rust is in progress: 
> https://github.com/maximg/thrift by Simon Génier and myself.
> It will probably take quite some time to complete. Please keep us updated if 
> there are changes related to our work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


  1   2   >