{"id":17442880,"url":"https://github.com/chertov/tntgrpc","last_synced_at":"2025-07-12T16:33:41.249Z","repository":{"id":41413005,"uuid":"130070249","full_name":"chertov/tntgrpc","owner":"chertov","description":"Tarantool GRPC service","archived":false,"fork":false,"pushed_at":"2018-04-18T15:18:17.000Z","size":159,"stargazers_count":9,"open_issues_count":4,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-07-05T16:29:31.641Z","etag":null,"topics":["grpc","lua","protobuf","tarantool"],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/chertov.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-04-18T13:54:54.000Z","updated_at":"2021-02-17T13:53:15.000Z","dependencies_parsed_at":"2022-09-21T08:11:42.060Z","dependency_job_id":null,"html_url":"https://github.com/chertov/tntgrpc","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/chertov/tntgrpc","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chertov%2Ftntgrpc","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chertov%2Ftntgrpc/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chertov%2Ftntgrpc/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chertov%2Ftntgrpc/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/chertov","download_url":"https://codeload.github.com/chertov/tntgrpc/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chertov%2Ftntgrpc/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265023805,"owners_count":23699582,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["grpc","lua","protobuf","tarantool"],"created_at":"2024-10-17T16:40:42.154Z","updated_at":"2025-07-12T16:33:40.969Z","avatar_url":"https://github.com/chertov.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"TNTGRPC is a tool for creating grpc C++ library for Tarantool application server. This example explains how to use GRPC generator for Tarantool application server.\n\nFirst, we need to build tntgrpc image.\n```sh\ngit clone https://github.com/jonywtf/tntgrpc.git\ncd ./tntgrpc\n./build.sh\n\ncd ./example\n```\n\n## Start tarantool GRPC server\n\nRemove grpc library 'mytntgrpclib.so' and docker container if exists.\n```sh\nrm -rf mytntgrpclib.so; docker rm mytarantool\n```\n\nOn the step we are trying to generate mytntgrpclib.so from helloworld.proto file.\nWe need only *.proto files to generate native library 'mytntgrpclib.so'.\nWe can use docker container from 'tntgrpc' image for this.\nWe can specify library name ('mytntgrpclib' in this example).\nAlso we must share two folders with proto files and output path for the container.\n'/proto' path is a directory where grpc tool takes proto files (helloworld.proto)\n'/output' path is a directory where grpc tool saves tarantool native library (mytntgrpclib.so)\n```sh\ndocker run -it \\\n    -v $(pwd):/proto \\  # our proto files is here\n    -v $(pwd):/output \\ # output files\n    tntgrpc \\\n    --name=mytntgrpclib helloworld.proto\n```\nOk, now we have 'mytntgrpclib.so' and we can use it for GRPC service inside Tarantool.\nWe need share port 3301 for tarantool and 50051 for grpc,\nalso we must share current folder for tarantool because lua code (app.lua) and grpc lib (mytntgrpclib.so) are here.\nOn this step we don't need *.proto files anymore. Only lua code and native library are required.\nIf you need you can use it in different way of course.\n```sh\ndocker run --name mytarantool -it \\\n    -p3301:3301 -p50051:50051 \\\n    -v $(pwd):/opt/tarantool \\\n    tarantool/tarantool:2 \\\n    tarantool /opt/tarantool/app.lua\n```\n\nAll the steps in ```./run_server.sh```\n\n## Start GRPC client\n\nWe should build GRPC client for Tarantool GRPC service.\nLet's build it with Docker. It's supereasy!\n\nWe have Dockerfile with build tools, grpc and golang compilers. Let's build it.\n```sh\ndocker build -t tnt_grpc_client_builder \\\n    -f ./client/Dockerfile ./\n```\nLet's start 'tnt_grpc_client_builder' container.\nWe need to share *.proto files and Goland source code for it.\nWe will get clients for Mac, Linux and Windows in 'bin' directory after the work is done.\n```sh\ndocker run -it \\\n    -v $(pwd)/:/proto/ \\ # our proto files is here\n    -v $(pwd)/client/:/client_src/ \\ # client source code\n    -v $(pwd)/:/hostoutput \\     # output path for binary files\n    tnt_grpc_client_builder\n```\n\nNow we can start the client for your platform.\n```sh\n./client/bin/client_mac\n```\n\nall the steps in ```./run_client.sh```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchertov%2Ftntgrpc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fchertov%2Ftntgrpc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchertov%2Ftntgrpc/lists"}