[
https://issues.apache.org/jira/browse/THRIFT-921?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12915638#action_12915638
]
Jun Ma commented on THRIFT-921:
-------------------------------
What I'm thinking about is to generate a faked implementation of the skeleton
function. For example,
int32_t add(const int32_t num1, const int32_t num2)
{
return 1 // or any random number or some number read from a configuration file
}
Especially in case the returned value is a complex object, only thrift know the
structure of the returned object. The value is, thrift help to create a
skeleton of returned object with random or faked data filled.
The language does not matter.
> Can thrift generate stub server for specified thrift interface
> --------------------------------------------------------------
>
> Key: THRIFT-921
> URL: https://issues.apache.org/jira/browse/THRIFT-921
> Project: Thrift
> Issue Type: Improvement
> Reporter: Jun Ma
>
> I think it's likely that the one who write a RPC server using thrift would
> like to write a test server which will simply return a fake response object.
> I think thrift have the ability to support this, when generating thrift
> definition files, generate a stub server for test purpose. Language does not
> matter for this stub server.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.