amazonica
amazonica copied to clipboard
Docstrings?
This library is great, and the example coverage seems pretty extensive on a whole (considering how much there is to the api). However, it's not exhaustive. As soon as I'm interested in behavior details, options or even a simple function signature of something not in the README examples, we're left with the Java docs. I understand this has been a messive undertaking, and that the code is somewhat auto-generated using reflection on the Java API, and that this might make the task tricky. But especially when tinkering around at the REPL this just makes it harder get a handle on the library, which is unfortunate.
Yes, it's a tradeoff. The public api functions are 100% generated by reflecting on the Java SDK. This lets us cover pretty much all of the AWS api far far easier than we could if we manually wrote a client, and likewise allows the client to effortlessly stay up to date with a fast moving api. Unfortunately this comes at the expense of some performance cost of reflection and the frequent necessity to keep the javadocs open in a browser rather than simply calling doc
in the repl. Docstrings could probably be added without too much effort by inspecting some form of the json specs AWS publishes elsewhere [1] at require time, but at least for me, that effort is more painful than consulting the javadocs. YMMV and pull requests welcome :)
[1] https://github.com/aws/aws-sdk-go/tree/master/apis
Would it be less painful to just provive the :arglists
metadata for these functions?
The information necessary for this is already in the reflection data, no need to parse json or anything external.
I'm trying to use amazonica for SWF, and the Readme's section on this namespace is very succint. So it would be super helpful to just know what arguments I need to call the functions. In fact, most of the time that would be enough for me.
Agreed. Same here.
On Fri, Mar 4, 2016, 6:41 AM Artur Malabarba [email protected] wrote:
Would it be less painful to just provive the :arglists metadata for these functions? The information necessary for this is already in the reflection data, no need to parse json or anything external.
I'm trying to use this amazonica for SWF, and the Readme's section on this namespace is very succint. So it would be super helpful to just know what arguments I need to call the functions. In fact, most of the time that would be enough for me.
— Reply to this email directly or view it on GitHub https://github.com/mcohen01/amazonica/issues/170#issuecomment-192305567.
Chris
Sent via mobile
FWIW, this could be done by referencing the JSON models at compile time. (Not easy, because edge cases, but still.)