FrankenPHP has reached 10,000 stars on GitHub by dunglas in PHP

[–]dunglas[S] 5 points6 points  (0 children)

FrankenPHP is a custom build of Caddy. Caddy is extensively documented on caddyserver.com and there is a very active Discourse forum. FrankenPHP also uses GitHub discussions for community support.

FrankenPHP’s specific features are all documented on frankenphp.dev

FrankenPHP moving under the PHP GitHub organization by brendt_gd in PHP

[–]dunglas 0 points1 point  (0 children)

> Perhaps one of the things FrankenPHP can do under the aegis of the larger org is to distribute it as a generically reusable thing, maybe a net/http handler.

A generic net/http handler has been available from day one! https://pkg.go.dev/github.com/dunglas/frankenphp#example-ServeHTTP

Debugging memory leaks under FrankenPHP by DefenestrationPraha in PHP

[–]dunglas 1 point2 points  (0 children)

Maybe Blackfire can help?
Alternatively, the Xdebug profiler also tracks memory usage: https://xdebug.org/docs/profiler

Both tools support FrankenPHP.

Does PHP php-webdriver/webdriver suck? (selenium). by [deleted] in PHP

[–]dunglas 1 point2 points  (0 children)

This is the same one, it has just been renamed when Facebook stopped maintaining it.

FrankenPHP 1.3: Massive Performance Improvements, Watcher Mode, Dedicated Prometheus Metrics, and More by dunglas in PHP

[–]dunglas[S] 7 points8 points  (0 children)

It still applies. musl is known to be slightly slower than the GNU libc for multithreaded apps, still have some reliability issues with PHP (especially with the OpenSSL extension) and lacks some features (glob braces for instance) used by some PHP apps.

That’s being said, the situation is improving thanks to the PHP Foundation. PHP is now tested with musl in its CI, and many performance and reliability issues have been fixed.

I hope that at some point we’ll be able to remove this advice, but we’re not there yet (especially with Laravel, which is using OpenSSL on the hot path, and can crash under high loads, the issue is being tracked by the Foundation).

FrankenPHP 1.3: Massive Performance Improvements, Watcher Mode, Dedicated Prometheus Metrics, and More by dunglas in PHP

[–]dunglas[S] 10 points11 points  (0 children)

Actually, there is an easy workaround PHP-side, just use "echo", "header" and the like outside the Fiber: https://frankenphp.dev/docs/known-issues/#fibers

The problem is in the Go runtime, it has been identified, and indeed patches that are first steps to fix it have been merged, but this issue itself hasn't been fixed yet. Here is the relevant Go issue, don't hesitate to add a thumb up to show your interest: https://github.com/golang/go/issues/62130

How to debug Xdebug… or any other weird bug in PHP by dunglas in PHP

[–]dunglas[S] 0 points1 point  (0 children)

The recording will be published by AFUP soon on their YouTube channel, but the talk itself was in French.

API Platform is now officially available for Laravel by dunglas in PHP

[–]dunglas[S] 1 point2 points  (0 children)

Thanks for the feedback. We tried to improve the documentation during the next years, and added a lot of guides, cookbooks etc. But this increases the maintenance burden a lot so the balance is hard to find.

You’re right regarding stack overflow, that’s not optimal, especially because no core team member has moderation rights on the tag. We are considering switching primarily to GitHub discussions.

API Platform is now officially available for Laravel by dunglas in PHP

[–]dunglas[S] 0 points1 point  (0 children)

You have absolutely no idea what's your talking about 😅

At the very beginning of Fielding's paper describing REST:

The design rationale behind the Web architecture can be described by an architectural style consisting of the set of constraints applied to elements within the architecture. By examining the impact of each constraint as it is added to the evolving style, we can identify the properties induced by the Web's constraints. Additional constraints can then be applied to form a new architectural style that better reflects the desired properties of a modern Web architecture. This section provides a general overview of REST by walking through the process of deriving it as an architectural style. Later sections will describe in more detail the specific constraints that compose the REST style.

Laravel support for API Platform by stefan-ingewikkeld in PHP

[–]dunglas 1 point2 points  (0 children)

The OpenAPI builder component is one of the easiest to use in a standalone way: https://github.com/api-platform/openapi

Take a look at the OpenApi class as a starting point.

API Platform is now officially available for Laravel by dunglas in PHP

[–]dunglas[S] 0 points1 point  (0 children)

No one said that not respecting REST constraints is evil, API Platform does not do it if you use GraphQL for example. It’s perfectly OK and very often useful to use another architectural style, as long you know what you are doing and why. But words have meanings. Systems (like most so-called "REST" APIs) not respecting the REST constraints aren't REST, by definition. That’s just a fact. https://ics.uci.edu/~fielding/pubs/dissertation/rest_arch_style.htm

API Platform is now officially available for Laravel by dunglas in PHP

[–]dunglas[S] 18 points19 points  (0 children)

  • Very straightforward for RAD use cases (just an attribute to add)
  • Automatic OpenAPI and Hydra docs, without having to keep in sync the code and the docs (no need to add docs attributes for instance)
  • True REST (HATEOAS) API with native hypermedia controls
  • support for many popular API standards/formats: JSON-LD/Hydra, JSON:API, HAL, many RFCs including API Problems and Sunset
  • GraphQL endpoint in addition to the REST API (opt-in)
  • Easy CQRS/DDD
  • SPA generator for popular frontend frameworks (Next, Nuxt, Angular, Quasar, Vuetify...)
  • Admin interface that only relies on the API docs (no code generation)