Use SciDB from Lua
Tutorial on calling C functions from Lua Here
Tutorial on libcurl Here
- Lua & lua development libraries
sudo apt-get install lua5.2 liblua5.2-dev
- A symbolic link at /usr/include/lua pointing pointing to /usr/include/lua5.x. For example:
ln -s /usr/include/lua5.2 /usr/include/lua
- The file
/usr/include/curl/types.h
must be present. Otherwise, create it with the following content:/* not used */
- A SciDB database running the shim web service.
gcc -Wall -shared -fPIC -o shimclient.so -I/usr/include/lua shimc.c -lcurl -I.
- Create a text file called
conf.exe
. This text file must contain 4 lines:- URL of the public shim interface
- URL of the dic shim interface
- Username
- Password
http://mySciDB:8080
https://mySciDB:8083
scidb
mySecretPassword
- Make sure the following arrays do not exist on the datatbase:
iquery -aq "remove(winners)"
iquery -aq "remove(winnersFlat)"
iquery -aq "remove(event_index)"
- Run the following command to execute the tests:
lua shimc.lua