Newer
Older
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
## Installation
### Dependencies
#### hiredis
Either install from package manager or
> git clone https://github.com/redis/hiredis.git
> cd hiredis
> mkdir build && cd build
> cmake .. -DCMAKE_INSTALL_PREFIX=/usr/local/hiredis
> make -j9 && sudo make install
#### redis-plus-plus
> git clone https://github.com/sewenew/redis-plus-plus
> cd redis-plus-plus
> mkdir build && cd build
If redis has been manually installed in /usr/local/hiredis, then execute
> cmake .. -DCMAKE_INSTALL_PREFIX=/opt/redis-plus-plus -DCMAKE_PREFIX_PATH=/opt/hiredis -DHIREDIS_HEADER=/opt/redis-plus-plus/include
otherwise the options -DCMAKE_PREFIX_PATH and HIREDIS_HEADER is not necessary.
We experienced that CMAKE_PREFIX_PATH is not enough to let redis plus plus include hiredis files
correctly, and we need to add also -DHIREDIS_HEADER.
> make -j9
> sudo make install
### service Installation
Assuming the paths mentioned above were used to install hiredis and redis-plus-plus:
> git clone https://gitlab.elettra.eu/puma/server/ca-tango-db-cache-mgr
Adjust PKG_CONFIG_PATH according to the caserver-lib, hiredis, redis-plus-plus, cumbia-libs
installation paths. For example:
> export PKG_CONFIG_PATH=/opt/caserver-lib/lib/pkgconfig:/opt/hiredis/lib/pkgconfig:/opt/redis-plus-plus/lib/pkgconfig:$PKG_CONFIG_PATH
*nlohmann-json* dependency is also required. You can place a copy in the *subprojects* directory if the
package is not installed system-wide
### request syntax
> curl -v http://woody.elettra.eu:9296 -d $'{"srcs":[{"src":"test/device/1/double_scalar"}]}'