obs/esdk-obs-php
PHP SDK for Huawei Cloud OBS (Object Storage Service). Provides client APIs for buckets, objects, multipart uploads, ACLs, lifecycle rules, and signed URLs, making it easy to integrate scalable cloud storage into Laravel or plain PHP applications. Includes examples and configuration support.
Architecture fit. obs/esdk-obs-php is Huawei Cloud's official server-side OBS (Object Storage Service) SDK for PHP — a vendor transport client, not a Laravel package. It ships a low-level ObsClient with its own request/response and exception model; it does not register a service provider, publish config, expose a facade, or implement a League\Flysystem\FilesystemAdapter. In a Laravel app it therefore sits below the Storage facade: you either call it directly from a dedicated service class or wrap it in an adapter you own. It also bypasses Laravel's HTTP client entirely (no Guzzle/PSR-18), so middleware-based retries, logging, and tracing do not apply. Verdict: good as a transport, poor as a drop-in.
Integration feasibility. Composer-installable, Apache-2.0, ext-curl required. A one-week spike is realistic; the real cost is the adapter, credential handling (AK/SK vs. IAM STS temporary credentials with refresh), presigned-URL generation for private buckets, and a parity test suite. OBS offers an S3-compatible API, so pointing an existing S3 driver at an OBS endpoint is viable for the S3 subset — but ACL semantics, multipart behavior, error codes, and OBS-proprietary features (image processing, custom headers) diverge, so each capability must be validated, not assumed.
Technical risk. Low release cadence (last release 2024-10-09), 58 stars, 0 dependents — near-zero community signal. Practically this means: vendor ticket queue is your only bug escalation path; no StackOverflow safety net; hiring and knowledge transfer are entirely internal. Documentation and console are Chinese-first. There is no first-class retry/backoff, circuit breaking, or OpenTelemetry hook — you build and own that layer. The Composer packaging is thin relative to the historically zip-distributed SDK, so verify autoload shape and class collisions before committing.
Key questions.
Stack fit. Target Laravel 9/10/11 (Flysystem 3). Two viable paths: (a) a custom FilesystemAdapter implementing League\Flysystem\FilesystemAdapter and bound as a disk driver — recommended for anything beyond put/get/delete; (b) reuse the S3 driver against OBS's S3-compatible endpoint — fastest, but confines you to the S3 subset and hides OBS-specific capability.
Migration path. Keep the swap config-only by depending on a disk name / Storage contract, never on ObsClient directly.
Compatibility. Pin the SDK version explicitly. Verify PHP constraint against your runtime, confirm ext-curl, and check for class-name collisions with existing vendor code. Endpoints and regions differ per environment — keep them in config/filesystems.php, never hardcoded. Note the package carries no Laravel version constraint: it will not break your upgrade, but it also will not be tested against it, so your parity suite is the real compatibility gate.
Sequencing. Spike and credential/IAM proof (1 week) → adapter + parity tests + observability wrapper (1–2 sprints) → dual-write and backfill → per-environment cutover → runbook and ownership handoff. Do not start the backfill until the parity suite is green; storage migrations are one-way in practice.
Maintenance. Vendor-owned and slow-moving. You inherit the release cadence and must independently track PHP deprecations (the SDK will not warn you). Budget roughly 10–15% of one engineer for adapter upkeep, SDK bumps, and parity-suite maintenance; that is the hidden cost of a 58-star dependency.
Support. Official Huawei Cloud support plans plus Chinese-language docs. Community support is effectively nil — no dependents, minimal issue traffic. Escalation runs through the cloud ticket system, so the support contract is a procurement dependency, not an afterthought.
Scaling. OBS as a service scales; the SDK client is stateless and safe to reuse, so bind it as a singleton — instantiating ObsClient per request adds endpoint and credential setup overhead for no benefit. Large uploads need explicit multipart chunking and memory discipline; push them to queued jobs rather than the request cycle. Watch egress and request-count costs at volume, since the cost model differs from S3 in non-obvious ways.
Failure modes. The SDK throws its own exception hierarchy — map it to domain errors at the adapter boundary or vendor types leak into controllers. No built-in retry means transient 5xx and timeouts reach users unless you wrap them. Aborted multipart uploads leave orphaned parts that accrue cost silently — add a cleanup job. STS credential expiry needs refresh logic. Presigned URLs are sensitive to clock skew. There is no native Laravel logging or metrics, so instrument the wrapper yourself; otherwise OBS will be the one dependency with no traces in your dashboards.
Ramp-up. One to two sprints for a mid-level PHP developer to reach productivity, and the friction is Huawei Cloud's IAM/console model and Chinese-first docs — not the PHP API, which is conventional. Add a half-day of team onboarding on bucket policy, AK/SK vs. STS, and egress costs. Write the internal runbook early; you will not find one publicly.
How can I help you explore Laravel packages today?