Further testing and other exercises

In our examples, we tried to submit some valid and invalid data to see how the service performs and if we are able to handle the errors properly. We didn't, however, test every possible scenario.

As an extra exercise, I suggest that you attempt the following tasks:

  • Testing each of the functions in the Ruby client with both valid and invalid arguments
  • Testing border cases and different combinations of valid and invalid parameters
  • Writing automatic unit tests for the methods implemented in the server
  • Experimenting with different transports, protocols, and servers
  • Adding client and server code as a module to bigger applications, for example, written in some framework
  • Running performance tests and comparing response times ...

Get Learning Apache Thrift now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.