Thank you for your interest in contributing to our Reverse Proxy project! We welcome contributions of all kinds, including bug reports, feature suggestions, documentation improvements, and code submissions.
If you find a bug, please create an issue with the following information:
- Clear description of the problem
- Steps to reproduce the issue
- Expected behavior
- Actual behavior
- Environment details (OS, compiler version, etc.)
- Relevant logs or screenshots
We welcome feature suggestions! Please:
- Check if there's already a similar feature request
- Clearly describe the use case and value of the feature
- Provide implementation suggestions if possible
- C++17 compatible compiler (GCC 7+, or MSVC 2019+)
- CMake 3.12+
- Boost libraries (System, Thread)
# Install dependencies
sudo apt update
sudo apt install -y g++ make cmake libboost-system-dev libboost-thread-dev
# Optional: Development tools
sudo apt install -y cppcheck astyle gdb- Install Visual Studio 2019 or later with C++ support.
- Install CMake, cppcheck, and astyle. It’s recommended to use Scoop for installation.
- Install Boost libraries.
# Create build directory
mkdir build && cd build
# Configure with CMake
cmake ..
# Build the project
cmake --build .
# For Release builds
cmake --build . --config ReleaseWe use the following tools to maintain code quality:
This project provides an .astylerc configuration (Google style variant) for the AStyle formatter. To automatically refactor C/C++ code using the project's style rules, run:
astyle --options=.astylerc $(find src include -type f -regex '.*\.\(c\|cpp\|h\|hpp\)$')run_cppcheck() {
local target_file=$1
echo "Checking $target_file..."
cppcheck \
--enable=all \
--inconclusive \
--std=c++17 \
--library=std.cfg \
--library=posix.cfg \
-I include \
--suppress=missingIncludeSystem \
--quiet \
--error-exitcode=1 \
"$target_file" include/*.hpp
}
run_cppcheck "src/echo_server.cpp"
run_cppcheck "src/proxy_server.cpp"
run_cppcheck "src/expose.cpp"- Use snake_case for variables and functions
- Use PascalCase for classes and structs
- Use UPPER_CASE for constants
- Include header guards in all header files
- Prefer
constandconstexprwhere applicable - Use smart pointers instead of raw pointers
#ifndef PROJECT_CLASS_NAME_H
#define PROJECT_CLASS_NAME_H
#include <boost/asio.hpp>
#include <memory>
#include <string>
class ExampleClass {
public:
explicit ExampleClass(std::string name);
void perform_action();
const std::string& get_name() const { return name_; }
private:
void helper_method_();
std::string name_;
boost::asio::io_context io_context_;
};
#endif // PROJECT_CLASS_NAME_Hreverse-proxy/
├── .githooks/ # Git hooks
├── src/ # Source code
├── include/ # Public headers
├── docs/ # Documentation
└── cmake/ # CMake modules
Before opening a PR, make sure your commit messages follow our conventions and general best practices.
We follow the Conventional Commits format for clarity and consistency. A commit message should start with a short, descriptive title, followed by an optional body that explains the change in more detail.
<prefix>: <short summary>
[optional body]
| Prefix | Usage |
|---|---|
feat: |
New user-facing features or changes |
fix: |
Bug fixes |
refact: |
Code refactoring or cleanup without changing behavior |
chore: |
Maintenance tasks, documentation, CI updates, etc. |
-
Title: Use imperative mood (e.g., “add”, “fix”, “update”).
-
Body:
- Use present tense and complete sentences with explicit subjects (e.g., “This commit adds…”).
- Focus on what and why, not how.
- Keep the title under 50 characters if possible.
- Separate the title and body with a blank line.
chore: update README.md
This commit adds more related works and improves section formatting.feat: add proxy server example
This commit implements a minimal TCP proxy for demonstration purposes.- Update
README.mdfor user-facing changes (feat:) - Add comments for complex algorithms
- At least one maintainer must approve.
- Address review feedback if requested.
- The PR will be merged after approval.