Hi Preston,
I’m sorry, I didn’t reply to this message earlier.
First I'd like to day that I agree that this will be a nice addition
and that I think that the appoach is fine. These are just 2 thoughts on
possible alternatives:
- Looking at the names of the boxes it seems that the more traditional
approach would be to have vxquery-xtest and vxquery-cli talk to the
vxquery-server that uses vxquery-rest to expose the functionality and
vxquery-core to provide the functionality.
I do understand that vxquery-cli is differnt from than a tradtitonal
CLI/shell, but I'm wondering if it should be. Maybe keeping it
simpler could simplify the code structure as well.
Thoughts about that?
- Also, I'm wondering if we should call the new API module vxquery-http
instead of vxquery-rest (as it's not really a RESTful API).
Thoughts around this?
Cheers,
Till
On 26 Jul 2017, at 13:21, Preston Carman wrote:
Erandi's work on adding a RESTful HTTP API will be a nice improvement
for VXQuery. As we look at adding this code, I thought it would be
good to clarify where this code should live and what is in the new
maven project. Our current project hierarchy is shown in this diagram
[1]. To keep minimize our code paths for executing a query, I suggest
all queries be process through the RESTful HTTP API. For this to
happen, both XTest and the CLI would need to be update to used the new
REST API. In addition these projects would depend on the REST project.
The REST project would be responsible for compiling and executing the
query. [2] shows the new hierarchy.
To help conslidate code for creating a local cluster, the REST project
will also include a class to start and stop a local cluster (similar
to AsterixHyracksIntegrationUtil in AsterixDB). The XTest project has
a local cluster for testing and the CLI has uses a local cluster when
no cluster ip address was provided. These will now need to used the
REST local cluster class and pass queries to the REST API for
processing.
The VXQuery Server project will operate similar the current method.
Only now it will include a REST port and start the REST API with the
Cluster Controller.
I think this is a good direction, what are your thoughts?
[1]
https://docs.google.com/drawings/d/1XaVm97hO6L2cWRJfqVimXiC_RyPFw-gw9spw-8Lof5U/edit?usp=sharing
[2]
https://docs.google.com/drawings/d/16xyO3TW_9sqSAkFNcnlC4WzN4B3JBzYarQreQ_X438M/edit?usp=sharing