forked from rdkcentral/rdkservices
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request rdkcentral#4940 from rdkcentral/RDK-45037-grpc
RDK-45037 : Secure Storage Thunder Plugin
- Loading branch information
Showing
17 changed files
with
1,321 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
name: L0-PersistentStore-grpc | ||
|
||
on: | ||
push: | ||
paths: | ||
- PersistentStore/grpc/** | ||
pull_request: | ||
paths: | ||
- PersistentStore/grpc/** | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
path: ${{github.repository}} | ||
|
||
- name: Install valgrind, coverage, cmake, protoc, grpc_cpp_plugin, grpc | ||
run: | | ||
sudo apt update | ||
sudo apt install -y valgrind lcov cmake protobuf-compiler protobuf-compiler-grpc libgrpc++-dev | ||
- name: Build Thunder | ||
working-directory: ${{github.workspace}} | ||
run: sh +x ${GITHUB_REPOSITORY}/.github/workflows/BuildThunder.sh | ||
|
||
- name: Build | ||
working-directory: ${{github.workspace}} | ||
run: | | ||
cmake -S ${GITHUB_REPOSITORY}/PersistentStore/grpc/l0test -B build/grpcl0test -DCMAKE_INSTALL_PREFIX="install/usr" -DCMAKE_CXX_FLAGS="--coverage -Wall -Werror" | ||
cmake --build build/grpcl0test --target install | ||
- name: Run | ||
working-directory: ${{github.workspace}} | ||
run: PATH=${PWD}/install/usr/bin:${PATH} LD_LIBRARY_PATH=${PWD}/install/usr/lib:${LD_LIBRARY_PATH} valgrind --tool=memcheck --log-file=valgrind_log --leak-check=yes --show-reachable=yes --track-fds=yes --fair-sched=try grpcl0test | ||
|
||
- name: Generate coverage | ||
working-directory: ${{github.workspace}} | ||
run: | | ||
lcov -c -o coverage.info -d build/grpcl0test | ||
genhtml -o coverage coverage.info | ||
- name: Upload artifacts | ||
if: ${{ !env.ACT }} | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: artifacts | ||
path: | | ||
coverage/ | ||
valgrind_log | ||
if-no-files-found: warn |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
name: L2-PersistentStore-grpc | ||
|
||
on: | ||
push: | ||
paths: | ||
- PersistentStore/grpc/** | ||
pull_request: | ||
paths: | ||
- PersistentStore/grpc/** | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
path: ${{github.repository}} | ||
|
||
- name: Install cmake, protoc, grpc_cpp_plugin, grpc | ||
run: | | ||
sudo apt update | ||
sudo apt install -y cmake protobuf-compiler protobuf-compiler-grpc libgrpc++-dev | ||
- name: Build | ||
working-directory: ${{github.workspace}} | ||
run: | | ||
cmake -S ${GITHUB_REPOSITORY}/PersistentStore/grpc/l2test -B build/grpcl2test -DCMAKE_INSTALL_PREFIX="install/usr" -DCMAKE_CXX_FLAGS="-Wall -Werror" | ||
cmake --build build/grpcl2test --target install |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ configuration = JSON() | |
|
||
rootobject = JSON() | ||
rootobject.add("mode", "@PLUGIN_PERSISTENTSTORE_MODE@") | ||
rootobject.add("locator", "lib@[email protected]") | ||
configuration.add("root", rootobject) | ||
|
||
configuration.add("uri", "@PLUGIN_PERSISTENTSTORE_URI@") | ||
|
@@ -15,3 +16,4 @@ configuration.add("key", "@PLUGIN_PERSISTENTSTORE_KEY@") | |
configuration.add("maxsize", "@PLUGIN_PERSISTENTSTORE_MAXSIZE@") | ||
configuration.add("maxvalue", "@PLUGIN_PERSISTENTSTORE_MAXVALUE@") | ||
configuration.add("limit", "@PLUGIN_PERSISTENTSTORE_LIMIT@") | ||
configuration.add("tokencommand", "@PLUGIN_PERSISTENTSTORE_TOKEN_COMMAND@") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,24 @@ | ||
set (autostart true) | ||
set (preconditions Platform) | ||
set (callsign "org.rdk.PersistentStore") | ||
set(autostart true) | ||
set(preconditions Platform) | ||
set(callsign "org.rdk.PersistentStore") | ||
|
||
if(PLUGIN_PERSISTENTSTORE_STARTUPORDER) | ||
set (startuporder ${PLUGIN_PERSISTENTSTORE_STARTUPORDER}) | ||
endif() | ||
|
||
map() | ||
kv(mode ${PLUGIN_PERSISTENTSTORE_MODE}) | ||
end() | ||
ans(rootobject) | ||
|
||
map() | ||
key(root) | ||
map() | ||
kv(mode ${PLUGIN_PERSISTENTSTORE_MODE}) | ||
kv(locator lib${PLUGIN_IMPLEMENTATION}.so) | ||
end() | ||
kv(uri ${PLUGIN_PERSISTENTSTORE_URI}) | ||
kv(path ${PLUGIN_PERSISTENTSTORE_PATH}) | ||
kv(legacypath ${PLUGIN_PERSISTENTSTORE_LEGACYPATH}) | ||
kv(key ${PLUGIN_PERSISTENTSTORE_KEY}) | ||
kv(maxsize ${PLUGIN_PERSISTENTSTORE_MAXSIZE}) | ||
kv(maxvalue ${PLUGIN_PERSISTENTSTORE_MAXVALUE}) | ||
kv(limit ${PLUGIN_PERSISTENTSTORE_LIMIT}) | ||
kv(tokencommand ${PLUGIN_PERSISTENTSTORE_TOKEN_COMMAND}) | ||
end() | ||
ans(configuration) | ||
|
||
map_append(${configuration} root ${rootobject}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
#include "Store2.h" | ||
|
||
namespace WPEFramework { | ||
namespace Plugin { | ||
class GrpcStore2 : public Grpc::Store2 {}; | ||
SERVICE_REGISTRATION(GrpcStore2, 1, 0); | ||
} // namespace Plugin | ||
} // namespace WPEFramework |
Oops, something went wrong.