[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2018-03-07 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 @JacopoMangiavacchi Server side already works using something like Perfect or Zewo, I already have separate server adapters for them https://github.com/apocolipse/TPerfectHTTPServer

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2017-11-01 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 @nsuke hah good catch, bad habits from other languages ;) Fixed ---

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2017-10-30 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 @nsuke requested cleanup completed ---

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2017-06-07 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 Also, to anyone using this, I'm making a pretty decent sized change right now to how `TEnums` work with Swift Enums. Backstory is that Swift enums are overly opinionated and don't work well

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2017-06-07 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 Its just a proposal so far, i don't think it'll be implemented for Swift 3 (but i havent been keeping close track, correct me if i'm wrong) It'll make more sense to do once Swift4 drops and SPM

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2017-06-05 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 @gotev feel free to contribute anything that was mentioned there. Its otherwise code complete (and likely better supported than the already merged Swift2 and Cocoa/Obj-C generators), I

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2017-03-25 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 @jeking3 no, any docs on whats needed for that? I can add it in. The old Cocoa+Swift generator was lacking here as well. (As is the Obj-C Cocoa generator) --- If your project is set up

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2017-02-28 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 Update 2/28/2017: Old Swift generator and new merged into one, Old generator under `cocoa` option, `promise_kit` option only available for old generator as well. I don't have any

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2016-12-21 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 @nsuke I've removed the attribution, will keep it in my personal Lib repo thats used strictly for SPM integration. Fixed the error codes you mentioned above. I'll go ahead and merge

[GitHub] thrift pull request #1084: THRIFT-3773 Swift 3 Native Library

2016-11-13 Thread apocolipse
Github user apocolipse commented on a diff in the pull request: https://github.com/apache/thrift/pull/1084#discussion_r87716435 --- Diff: lib/swift/README.md --- @@ -0,0 +1,217 @@ +Thrift Swift Library += + +License +--- +Licensed

[GitHub] thrift pull request #1084: THRIFT-3773 Swift 3 Native Library

2016-11-13 Thread apocolipse
Github user apocolipse commented on a diff in the pull request: https://github.com/apache/thrift/pull/1084#discussion_r87716418 --- Diff: lib/swift/Sources/LinuxHelper.swift --- @@ -0,0 +1,34 @@ +// +// LinuxHelper.swift +// Thrift +// +// Created

[GitHub] thrift pull request #1084: THRIFT-3773 Swift 3 Native Library

2016-11-13 Thread apocolipse
Github user apocolipse commented on a diff in the pull request: https://github.com/apache/thrift/pull/1084#discussion_r87716408 --- Diff: compiler/cpp/src/thrift/generate/t_swift_3_generator.cc --- @@ -0,0 +1,2553 @@ +/* --- End diff -- While I don't disagree, I

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2016-11-12 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 Update: I've modified the generated Async clients to use a new `TAsyncResult` parameter for callbacks rather than Optional Return/Error tuples. Short version of why is that those

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2016-10-28 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 I've created 2 separate HTTP Servers using external libraries and made them available to play with https://github.com/apocolipse/TZewoHTTPServer and https://github.com/apocolipse

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2016-10-25 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 @fumoboy007 so for clients you should be doing something like this: ```swift let factory = THTTPSessionTransport.Factory(url: serviceURL) let client = HermesAsyncClient

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2016-10-24 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 @fumoboy007 There is `TAsyncClient` in TClient.swift as well as `TAsyncTransport/Factory` in TTransport.swift, and the generator will generate async clients properly (`--gen swift_3

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2016-10-24 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 @fumoboy007 @ChristopherRogers Have you all found any other outstanding issues that need addressing? @nsuke @kdubb What final steps do we need to do to get this into the official

[GitHub] thrift pull request #1084: THRIFT-3773 Swift 3 Native Library

2016-10-10 Thread apocolipse
Github user apocolipse commented on a diff in the pull request: https://github.com/apache/thrift/pull/1084#discussion_r82631304 --- Diff: compiler/cpp/src/thrift/generate/t_swift_3_generator.cc --- @@ -0,0 +1,2458 @@ +/* + * Licensed to the Apache Software Foundation (ASF

[GitHub] thrift pull request #1084: THRIFT-3773 Swift 3 Native Library

2016-09-24 Thread apocolipse
Github user apocolipse commented on a diff in the pull request: https://github.com/apache/thrift/pull/1084#discussion_r80368318 --- Diff: compiler/cpp/src/generate/t_swift_3_generator.cc --- @@ -0,0 +1,2458 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under

[GitHub] thrift pull request #1084: THRIFT-3773 Swift 3 Native Library

2016-09-24 Thread apocolipse
Github user apocolipse commented on a diff in the pull request: https://github.com/apache/thrift/pull/1084#discussion_r80368238 --- Diff: lib/swift/Sources/TMultiplexedProtocol.swift --- @@ -0,0 +1,47 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one

[GitHub] thrift pull request #1084: THRIFT-3773 Swift 3 Native Library

2016-09-24 Thread apocolipse
Github user apocolipse commented on a diff in the pull request: https://github.com/apache/thrift/pull/1084#discussion_r80365498 --- Diff: compiler/cpp/src/generate/t_swift_3_generator.cc --- @@ -0,0 +1,2458 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under

[GitHub] thrift pull request #1084: THRIFT-3773 Swift 3 Native Library

2016-09-13 Thread apocolipse
Github user apocolipse commented on a diff in the pull request: https://github.com/apache/thrift/pull/1084#discussion_r78584053 --- Diff: lib/swift/Sources/TApplicationError.swift --- @@ -0,0 +1,157 @@ +/* +* Licensed to the Apache Software Foundation (ASF) under one

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2016-09-12 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 @ChristopherRogers @fumoboy007 I implemented union support with enums, here's an example of generated code: ``` union TestUnion { 1: i32 data, 2: string message, 3: bool

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2016-09-12 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 @nsuke I considered that when starting out, however the differences between Swift 2 and 3 are pretty dramatic that makes shared code minimal (i.e. everything in this library is Value typed

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2016-09-11 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 That'll require generation of both read and write serialization code (which I try to abstract much of to the library), but its doable I suppose. --- If your project is set up for it, you can

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2016-09-11 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 @ChristopherRogers Something like this? ``` union AUnion { 1: string result, 2: CustomException error } ``` ```swift enum AUnion { case result(val: String

[GitHub] thrift pull request #1084: THRIFT-3773 Swift 3 Native Library

2016-09-11 Thread apocolipse
Github user apocolipse commented on a diff in the pull request: https://github.com/apache/thrift/pull/1084#discussion_r78313057 --- Diff: lib/swift/Sources/LinuxHelper.swift --- @@ -0,0 +1,42 @@ +// +// LinuxHelper.swift +// Thrift +// +// Created

[GitHub] thrift issue #1084: THRIFT-3773 Swift 3 Native Library

2016-09-11 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1084 @fumoboy007 thanks, thought i had the overflow ones in there, will add them back in :) --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub

[GitHub] thrift pull request #1084: THRIFT-3773 Swift 3 Native Library

2016-09-09 Thread apocolipse
GitHub user apocolipse opened a pull request: https://github.com/apache/thrift/pull/1084 THRIFT-3773 Swift 3 Native Library Here is my implementation of the Thrift library for Swift 3.0, pure swift. There is no Objective-C requirement here. For implementation and design

[GitHub] thrift issue #1002: THRIFT-3812 Add option to prefix namespace Swift type na...

2016-06-21 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1002 Yeah I think that would be the most appropriate way, making sure that people that use it /want/ to use it and/or know that its not a Swift convention. SPM integration should come with Swift

[GitHub] thrift issue #1002: THRIFT-3812 Add option to prefix namespace Swift type na...

2016-06-19 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1002 So for Cocoapods/Carthage, you're also using Frameworks (startup time is negligible). I'd almost recommend manually handling separate Podspec's to keep things Module scope namespaced

[GitHub] thrift issue #1002: THRIFT-3812 Add option to prefix namespace Swift type na...

2016-06-17 Thread apocolipse
Github user apocolipse commented on the issue: https://github.com/apache/thrift/pull/1002 In my opinion this is very Un-Swifty. Namespace prefixes are an Objective-C Cocoa convention, Swift tries to get away from this convention (in fact with Swift 3.0, NS prefixes on many