You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by wu...@apache.org on 2023/03/11 01:53:29 UTC
[skywalking-php] branch master updated: Update documents. (#56)
This is an automated email from the ASF dual-hosted git repository.
wusheng pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/skywalking-php.git
The following commit(s) were added to refs/heads/master by this push:
new 733d4f3 Update documents. (#56)
733d4f3 is described below
commit 733d4f3fb6d9e8e24b54f07382c0854b43690a78
Author: jmjoy <jm...@apache.org>
AuthorDate: Sat Mar 11 09:53:23 2023 +0800
Update documents. (#56)
---
docs/en/configuration/ini-settings.md | 21 +++++
docs/en/contribution/release-agent.md | 6 +-
docs/en/setup/service-agent/php-agent/README.md | 93 ++++++++++++----------
.../service-agent/php-agent/Supported-list.md | 4 +-
docs/menu.yml | 10 ++-
5 files changed, 83 insertions(+), 51 deletions(-)
diff --git a/docs/en/configuration/ini-settings.md b/docs/en/configuration/ini-settings.md
new file mode 100644
index 0000000..9106753
--- /dev/null
+++ b/docs/en/configuration/ini-settings.md
@@ -0,0 +1,21 @@
+# INI Settings
+
+This is the configuration list supported in `php.ini`.
+
+| Configuration Item | Description | Default Value |
+| ------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ | ------------------------- |
+| skywalking_agent.enable | Enable skywalking_agent extension or not. | Off |
+| skywalking_agent.log_file | Log file path. | /tmp/skywalking-agent.log |
+| skywalking_agent.log_level | Log level: one of `OFF`, `TRACE`, `DEBUG`, `INFO`, `WARN`, `ERROR`. | INFO |
+| skywalking_agent.runtime_dir | Skywalking agent runtime directory. | /tmp/skywalking-agent |
+| skywalking_agent.server_addr | Address of skywalking oap server. | 127.0.0.1:11800 |
+| skywalking_agent.service_name | Application service name. | hello-skywalking |
+| skywalking_agent.skywalking_version | Skywalking version, 8 or 9. | 8 |
+| skywalking_agent.authentication | Skywalking authentication token, let it empty if the backend isn't enabled. | |
+| skywalking_agent.worker_threads | Skywalking worker threads, 0 will auto set as the cpu core size. | 0 |
+| skywalking_agent.enable_tls | Wether to enable tls for gPRC, default is false. | Off |
+| skywalking_agent.ssl_trusted_ca_path | The gRPC SSL trusted ca file. | |
+| skywalking_agent.ssl_key_path | The private key file. Enable mTLS when `ssl_key_path` and `ssl_cert_chain_path` exist. | |
+| skywalking_agent.ssl_cert_chain_path | The certificate file. Enable mTLS when `ssl_key_path` and `ssl_cert_chain_path` exist. | |
+| skywalking_agent.heartbeat_period | Agent heartbeat report period. Unit, second. | 30 |
+| skywalking_agent.properties_report_period_factor | The agent sends the instance properties to the backend every heartbeat_period * properties_report_period_factor seconds. | 10 |
diff --git a/docs/en/contribution/release-agent.md b/docs/en/contribution/release-agent.md
index 9c75371..b291799 100644
--- a/docs/en/contribution/release-agent.md
+++ b/docs/en/contribution/release-agent.md
@@ -48,9 +48,9 @@ your package.
> export RELEASE_VERSION=x.y.z
## The package should be signed by your Apache committer mail.
-> gpg --armor --detach-sig skywalking_agent-{$RELEASE_VERSION}.tgz
+> gpg --armor --detach-sig skywalking_agent-$RELEASE_VERSION.tgz
-> shasum -a 512 skywalking_agent-{$RELEASE_VERSION}.tgz > skywalking_agent-{$RELEASE_VERSION}.tgz.sha512
+> shasum -a 512 skywalking_agent-$RELEASE_VERSION.tgz > skywalking_agent-$RELEASE_VERSION.tgz.sha512
```
After these, the source tar with its signed asc and sha512 are ready.
@@ -66,7 +66,7 @@ After these, the source tar with its signed asc and sha512 are ready.
Call a vote in `dev@skywalking.apache.org`
```
-Mail title: [VOTE] Release Apache SkyWalking version PHP x.y.z
+Mail title: [VOTE] Release Apache SkyWalking PHP version x.y.z
Mail content:
Hi All,
diff --git a/docs/en/setup/service-agent/php-agent/README.md b/docs/en/setup/service-agent/php-agent/README.md
index adc0a7e..3a824cc 100644
--- a/docs/en/setup/service-agent/php-agent/README.md
+++ b/docs/en/setup/service-agent/php-agent/README.md
@@ -13,34 +13,66 @@
- Make
- Protoc
-For Debian-base OS:
+## Install dependencies
+
+### For Debian-base OS
```shell
-sudo apt install gcc make llvm-dev libclang-dev clang protobuf-compiler
+sudo apt install gcc make llvm-13-dev libclang-13-dev protobuf-c-compiler
```
-### Install Rust globally
-
-*Refer to <https://forge.rust-lang.org/infra/other-installation-methods.html#standalone-installers>.*
-
-For linux x86_64 user:
+### For Alpine Linux
```shell
-wget https://static.rust-lang.org/dist/rust-1.65.0-x86_64-unknown-linux-gnu.tar.gz
-tar zxvf rust-1.65.0-x86_64-unknown-linux-gnu.tar.gz
-cd rust-1.65.0-x86_64-unknown-linux-gnu
-./install.sh
+apk add gcc make musl-dev llvm15-dev clang15-dev protobuf-c-compiler
```
+## Install Rust globally
+
+The officially recommended way to install Rust is via [`rustup`](https://www.rust-lang.org/tools/install).
+
+But because the source code toolchain is override by `rust-toolchain.toml`,
+so if you don't need multi version Rust, we recommend to install Rust by these
+way:
+
+1. Install through OS package manager (The Rust version in the source must be >= 1.65).
+
+2. Through [standalone installers](https://forge.rust-lang.org/infra/other-installation-methods.html#standalone-installers).
+
+ For linux x86_64 user:
+
+ ```shell
+ wget https://static.rust-lang.org/dist/rust-1.65.0-x86_64-unknown-linux-gnu.tar.gz
+ tar zxvf rust-1.65.0-x86_64-unknown-linux-gnu.tar.gz
+ cd rust-1.65.0-x86_64-unknown-linux-gnu
+ ./install.sh
+ ```
+
+3. Through `rustup` but set `default-toolchain` to none.
+
+ ```shell
+ curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- --default-toolchain none
+ ```
+
## Install
+> If you compile `skywalking_agent` in Alpine Linux, you have to disable `crt-static`, otherwise
+> the problem will be throw: "the libclang shared library at /usr/lib/libclang.so.15.0.7 could not
+> be opened: Dynamic loading not supported".
+>
+> You can disable `crt-static` by environment variable:
+>
+> ```shell
+> export RUSTFLAGS="-C target-feature=-crt-static"
+> ```
+
### Install from pecl.net
```shell script
pecl install skywalking_agent
```
-### install from the source codes
+### Install from the source codes
```shell script
git clone --recursive https://github.com/apache/skywalking-php.git
@@ -52,7 +84,9 @@ make
make install
```
-## Configure php.ini
+## Configure
+
+Configure skywalking agent in your `php.ini`.
```ini
[skywalking_agent]
@@ -72,35 +106,6 @@ skywalking_agent.server_addr = 127.0.0.1:11800
; Application service name.
skywalking_agent.service_name = hello-skywalking
-
-; Skywalking version.
-skywalking_agent.skywalking_version = 8
-
-; Skywalking authentication token, let it empty if the backend isn't enabled.
-; skywalking_agent.authentication =
-
-; Skywalking worker threads, 0 will auto set as the cpu core size, default is 0.
-; skywalking_agent.worker_threads = 3
-
-; Skywalking agent runtime directory, default is /tmp/skywalking-agent.
-; skywalking_agent.runtime_dir = /tmp/skywalking-agent
-
-; Wether to enable tls for gPRC, default is false.
-; skywalking_agent.enable_tls = Off
-
-; The gRPC SSL trusted ca file.
-; skywalking_agent.ssl_trusted_ca_path =
-
-; The private key file. Enable mTLS when ssl_key_path and ssl_cert_chain_path exist.
-; skywalking_agent.ssl_key_path =
-
-; The certificate file. Enable mTLS when ssl_key_path and ssl_cert_chain_path exist.
-; skywalking_agent.ssl_cert_chain_path =
-
-; Agent heartbeat report period. Unit, second. Default is 30.
-; skywalking_agent.heartbeat_period = 30
-
-; The agent sends the instance properties to the backend every
-; heartbeat_period * properties_report_period_factor seconds. Default is 10.
-; skywalking_agent.properties_report_period_factor = 10
```
+
+Refer to the Configuration section for more configuration items.
diff --git a/docs/en/setup/service-agent/php-agent/Supported-list.md b/docs/en/setup/service-agent/php-agent/Supported-list.md
index 4e11b15..58ea590 100644
--- a/docs/en/setup/service-agent/php-agent/Supported-list.md
+++ b/docs/en/setup/service-agent/php-agent/Supported-list.md
@@ -7,7 +7,7 @@ The following plugins provide the distributed tracing capability.
* PHP-FPM
* CLI under [Swoole](https://www.swoole.com/)
-## Support PHP extension
+## Supported PHP extension
* [cURL](https://www.php.net/manual/en/book.curl.php#book.curl)
* [PDO](https://www.php.net/manual/en/book.pdo.php)
@@ -15,6 +15,6 @@ The following plugins provide the distributed tracing capability.
* [Memcached](https://www.php.net/manual/en/book.memcached.php)
* [phpredis](https://github.com/phpredis/phpredis)
-## Support PHP library
+## Supported PHP library
* [predis](https://github.com/predis/predis)
diff --git a/docs/menu.yml b/docs/menu.yml
index 94a5ba4..63878fc 100644
--- a/docs/menu.yml
+++ b/docs/menu.yml
@@ -14,12 +14,18 @@
# limitations under the License.
catalog:
- - name: "PHP Agent Setup"
- path: "/en/setup/service-agent/php-agent/readme"
+ - name: "Get Started"
+ catalog:
+ - name: "PHP Agent Setup"
+ path: "/en/setup/service-agent/php-agent/readme"
- name: "Plugins"
catalog:
- name: "Supported SAPI, extension and library"
path: "/en/setup/service-agent/php-agent/Supported-list"
+ - name: "Configuration"
+ catalog:
+ - name: "INI Settings"
+ path: "/en/configuration/ini-settings"
- name: "Contribution"
catalog:
- name: "Compiling Guidance"