I updated the `CONTRIBUTING.md` documentation to fix the outdated name
for the benchmarking plugin. The instructions now reference the
`benchmark` plugin instead of the previously outdated
`package-benchmark` plugin, and associated links and descriptions have
been updated accordingly. Previously these were leading to `404 Not
Found` errors.
No code changes were made in this PR.
Fixes: #510
---------
Co-authored-by: Vladimir Kukushkin <kukushechkin@mac.com>
Unify repos layout across the ecosystem:
1. Remove `CONTRIBUTORS.md` and mentions of it.
2. Remove `CODE_OF_CONDUCT.md` and mentions of it.
3. From `CONTRIBUTING.md` remove "Writing a Patch" and "Commit Message
Template" sections.
4. Remove `.mailmap` and mentions of it.
5. Remove `dev/git.commit.template` and mentions of it.
6. Remove `SECURITY.md`, if it is referenced somewhere, change it to
reference to the org security file
"https://github.com/apple/swift-log?tab=security-ov-file".
7. Remove copyright header from `Package.swift` and version-specific
package manifests.
8. Add SPI shields to the `README.md`.
9. Add "How to contribute your work" section in `CONTRIBUTING.md`.
10. Add "Add Automated release process" section in `CONTRIBUTING.md`.
Integrate swift-temporal-sdk's reusable auto-release workflow for
automated semantic versioning releases. Update CONTRIBUTING.md with a
link to the workflow documentation.
### Motivation
- Automate the release process using semantic versioning labels,
reducing manual overhead and ensuring consistent versioning across
releases.
### Modifications
- Add .github/workflows/auto-release.yml that uses swift-temporal-sdk's
reusable workflow
- Update CONTRIBUTING.md with automated release process documentation
linking to swift-temporal-sdk's workflow README
### Result
- When PRs are merged with semver labels (semver/patch, semver/minor),
the workflow automatically creates GitHub releases. Major releases
require manual creation.
### Test Plan
- Workflow will be validated after merge by labeling PRs with semver
labels and verifying that releases are created automatically.
Add simple benchmarks measuring instructions count and allocations when
logging with various log levels.
### Motivation:
Establish the baseline and have automated checks before approaching
performance improvements.
### Modifications:
- Dependency on https://github.com/ordo-one/package-benchmark added
- A new `Benchmarks` sub-package is added
- CI workflows now run benchmarks
### Result:
- CI workflows are running benchmarks on Linux and macOS
- Thresholds are recorded and verified only on macOS
An example of a benchmark failing with a **better** results than
expected:
https://github.com/apple/swift-log/actions/runs/19540944353/job/55950355442
An example of a benchmark failing with a **worse** results than
expected:
https://github.com/apple/swift-log/actions/runs/19569105729/job/56038101552
Migrating `swift-log` from XCTest to Swift Testing
### Motivation
Swift Testing is a modern alternative to XCTest. Swift Server Ecosystem
packages should serve as reference implementations for modern Swift
features and best practices.
### Modifications
- 1-to-1 migration of test suites, tests, and assertions to Swift
Testing syntax with XCTest import removed
- XCTest references removed from documentation
- `.trace` log level added to relevant tests
- `GlobalLoggerTest` suite serialized to handle global `LoggingSystem`
access (XCTest runs tests serially by default; Swift Testing runs in
parallel, so serializing this suite avoids requiring `swift test
--no-parallel` across all CI and development environments)
### Result
Successfully executes 52 tests with `swift test --disable-xctest`.