Skip to content

Commit c77229e

Browse files
committed
[C++] add new paozhu
1 parent 4dfb9e0 commit c77229e

File tree

4 files changed

+118
-0
lines changed

4 files changed

+118
-0
lines changed

frameworks/C++/paozhu/README.md

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
# paozhu Benchmarking Test
2+
3+
This is the [Paozhu](https://github.com/hggq/paozhu)
4+
5+
### Test Type Implementation Source Code
6+
7+
* [Benchmark code](controller/src/techempower.cpp)
8+
* [ORM config](conf/orm.conf)
9+
* [Server config](conf/server.conf)
10+
11+
## Test URLs
12+
### JSON
13+
14+
http://localhost:8888/json
15+
16+
### PLAINTEXT
17+
18+
http://localhost:8888/plaintext
19+
20+
21+
### Single Database Query
22+
23+
http://localhost:8888/db
24+
25+
### Fortune
26+
27+
http://localhost:8888/fortunes
28+
29+
### Multiple Database Queries
30+
31+
http://localhost:8888/queries?queries=10
32+
33+
### Database Updates
34+
35+
http://localhost:8888/updates?queries=10
36+
37+
### Cache
38+
http://localhost:8888/cached-queries?count=20
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
{
2+
"framework": "paozhu",
3+
"tests": [
4+
{
5+
"default": {
6+
"json_url": "/json",
7+
"plaintext_url": "/plaintext",
8+
"db_url": "/db",
9+
"fortune_url": "/fortunes",
10+
"query_url": "/queries?queries=",
11+
"update_url": "/updates?queries=",
12+
"cached_query_url": "/cached-queries?count=",
13+
"port": 8888,
14+
"approach": "Realistic",
15+
"classification": "Fullstack",
16+
"database": "MySQL",
17+
"framework": "paozhu",
18+
"language": "C++",
19+
"flavor": "None",
20+
"orm": "Micro",
21+
"platform": "None",
22+
"webserver": "None",
23+
"os": "Linux",
24+
"database_os": "Linux",
25+
"display_name": "paozhu",
26+
"notes": "",
27+
"versus": "None"
28+
}
29+
}
30+
]
31+
}

frameworks/C++/paozhu/config.toml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
[framework]
2+
name = "paozhu"
3+
authors = ["Huang ziquan <huanguuq@163.com>"]
4+
github = "https://github.com/hggq/paozhu"
5+
6+
[main]
7+
urls.plaintext = "/plaintext"
8+
urls.json = "/json"
9+
urls.db = "/db"
10+
urls.query = "/queries?queries="
11+
urls.update = "/updates?queries="
12+
urls.fortune = "/fortunes"
13+
urls.cached_query = "/cached-queries?count="
14+
approach = "Realistic"
15+
classification = "Fullstack"
16+
database = "MySQL"
17+
database_os = "Linux"
18+
os = "Linux"
19+
orm = "Micro"
20+
platform = "None"
21+
webserver = "None"
22+
versus = "None"
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
FROM ubuntu:22.04
2+
RUN apt-get update -yqq && apt-get install -yqq software-properties-common wget unzip cmake git
3+
RUN apt-get install -yqq gcc g++ openssl libssl-dev zlib1g-dev build-essential
4+
5+
RUN sudo apt install brotli
6+
RUN sudo apt-get install mysql-server
7+
RUN sudo apt-get install mysql-common
8+
RUN sudo apt-get install mysql-client
9+
RUN sudo apt-get install libmysqlclient-dev
10+
11+
RUN locale-gen en_US.UTF-8
12+
ENV LANG en_US.UTF-8
13+
ENV LANGUAGE en_US:en
14+
ENV LC_ALL en_US.UTF-8
15+
16+
WORKDIR /
17+
18+
RUN wget https://github.com/hggq/paozhu/releases/download/v1.5.6/benchmark.zip
19+
RUN unzip benchmark.zip
20+
RUN mv ./benchmark/* ./
21+
22+
RUN cmake . -B build -DCMAKE_BUILD_TYPE=Release
23+
RUN cmake --build build
24+
25+
EXPOSE 8888
26+
WORKDIR ./
27+
CMD ./bin/paozhu

0 commit comments

Comments
 (0)