-
Notifications
You must be signed in to change notification settings - Fork 93
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Modularize the Arkouda build process #978
Conversation
Adding a few additional comments: Backbone modulesThe approach taken in this initial prototype for determining which modules were considered "backbone" modules (modules that are included by default in every build) was moving all modules that were Adding a function to the client sideIn the case where a user would like to add their own module with this modular approach, the challenge still remains of how they would make those functions accessible on the client side. One approach that was talked about (thanks for the suggestions Kyle/Elliot) was to have a script to call the new server function like this:
And then import that script in their python environment to add the command to the client. |
@mhmerrill : This is Ben's draft of modularizing Arkouda using a separate configuration file and Python script as you requested when he demo'd it the other week. We'll be curious for your feedback when you get the chance to take a look at this. |
@bmcdonald3 @bradcray @Bears-R-Us/arkouda-core-dev i've finally got a chance to glance at this and I am happy with it so far. I do have several ideas I think we should discuss.
|
wow, great minds think alike I just went back and read the description about including client side code ;-) |
bf5dcfc
to
685320f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this looks good. The only thing I think should be done is moving Parquet support into the optional configuration since it is arguably the most optional module we have ;)
EDIT: With Ben's explanation for why Parquet needs to remain in, I'm good with this.
Closing as I have opened #1017 instead |
This draft PR is a prototype of an approach to modularizing the Arkouda build process aimed at promoting design discussion for next steps in this effort.
Summary
The approach taken in this prototype was adding a
map
that maps from command strings to first class functions and removed the majority of commands from the mainselect cmd
statement so that they would not be required with every Arkouda build. AServerModules.cfg
configuration file was added that takes the name of modules to include in the build, one per line, and generatesimport
statements for those modules and adds their messaging functions to the command map only when in the configuration file to avoid compiling files that are not desired in a given Arkouda build.Using the configuration file
Running
make
on this branch compiles Arkouda just like today with all modules included, and that is because theServerModules.cfg
file has all of the module names included by default. To build Arkouda without a module, all that is needed to do is comment out the module that you would like to exclude from that file and rerunmake
.Additionally, in the case where a user has multiple configuration files, for example, the user can specify which configuration file will be used to generate the
import
statements by setting the environment variableARKOUDA_CONFIG_FILE
Adding a module/converting an existing module
Assuming a module is already created that has its messaging functions, all that the user would need to do to add that module into a build is
(1) add a
registerMe()
(name up for discussion...) function in their file adding each function to the command map that looks like this:(2) add the module name to the
ServerModules.cfg
file(3) add a client-side function to handle the call