Posts Tagged ‘PHPForumParis2022’
[PHPForumParis2022] Internet and Geopolitics – Stéphane Bortzmeyer
Stéphane Bortzmeyer, a seasoned expert in Internet infrastructure, delivered a thought-provoking presentation at PHP Forum Paris 2022, exploring the intricate relationship between the Internet and geopolitics. Dedicated to Mahsa Amini, whose tragic death sparked a revolt in Iran, Stéphane’s talk illuminated how global politics shape the Internet’s architecture and accessibility. With a focus on real-world examples, he challenged developers to consider the geopolitical implications of their work, particularly in the context of PHP-driven applications that rely on global connectivity.
The Myth of the Cloud
Stéphane began by debunking the term “cloud,” criticizing it as a marketing ploy that obscures the Internet’s physical and political realities. Far from being a borderless entity, the Internet is deeply tied to national jurisdictions, data centers, and political decisions. He highlighted how regimes, such as Iran’s, manipulate Internet access to suppress dissent, using censorship and throttling to control information flow. For PHP developers, this underscores the importance of designing applications that account for such restrictions, ensuring accessibility and resilience in diverse geopolitical contexts.
Global Connectivity Challenges
Delving into connectivity, Stéphane explained how historical and economic factors create disparities in Internet access. He cited Colombia, where local content is often hosted abroad due to limited domestic infrastructure, creating a self-reinforcing cycle of dependency on foreign connections. This phenomenon, driven by business interests rather than technical necessity, affects latency and accessibility for PHP applications. Stéphane urged developers to advocate for local interconnection and consider hosting strategies that prioritize user experience in underserved regions.
The Role of Regulation and Advocacy
Addressing regulatory responses, Stéphane contrasted Bolivia’s legal mandates for local interconnection with Europe’s reliance on user and government pressure. He emphasized that developers can influence these dynamics by supporting open Internet standards and advocating for equitable access. For PHP developers, this means building applications that are adaptable to varying network conditions and contributing to discussions on infrastructure policies. Stéphane’s insights highlighted the developer’s role in fostering a more inclusive and resilient Internet.
Empowering Developers to Act
Concluding, Stéphane called on developers to engage with the geopolitical aspects of their work, from choosing hosting providers to supporting open standards. By understanding the Internet’s physical and political constraints, PHP developers can create applications that better serve global audiences. His dedication to Mahsa Amini served as a poignant reminder of the stakes involved, inspiring attendees to approach their craft with a broader perspective on its societal impact.
Links:
[PHPForumParis2022] Once Upon a Time… Web Browsers – Noël Macé and Pierre Tibulle
Noël Macé and Pierre Tibulle, passionate advocates for web standards, delivered a captivating narrative at PHP Forum Paris 2022, tracing the evolution of web browsers from their inception to the present day. Their talk, structured as a historical journey, began with Tim Berners-Lee’s pioneering work at CERN in 1980 and explored the technological and ethical shifts that shaped the modern web. Noël and Pierre’s engaging delivery, enriched with anecdotes, offered developers a deeper understanding of browsers’ impact on PHP development and user privacy.
The Birth of the Web
Noël and Pierre opened with Tim Berners-Lee’s creation of the first browser interface at CERN, designed to manage particle accelerators with a simple 24-line, 64-character display. This foundational work laid the groundwork for the World Wide Web, introduced in 1991. They described the rapid evolution of early browsers like Mosaic and Netscape, which introduced graphical interfaces, transforming the web into a user-friendly platform and setting the stage for PHP’s role in dynamic web applications.
Browser Wars and Standardization
The presenters chronicled the intense browser wars of the 1990s, where Netscape and Internet Explorer competed for dominance, often at the cost of compatibility. They highlighted the formation of the W3C and its role in standardizing web technologies, ensuring cross-browser consistency. Noël and Pierre emphasized how these standards, driven by open collaboration, enabled PHP developers to build reliable, cross-platform applications, underscoring the importance of adhering to W3C guidelines in modern development.
Privacy and Ethical Considerations
Shifting to contemporary challenges, Noël and Pierre addressed the growing importance of user privacy. They recommended tools like Privacy Badger and Firefox to mitigate tracking, noting issues like GitHub’s editor requiring data collection for basic functionality. By advocating for active engagement with the W3C’s open discussions on GitHub, they encouraged developers to influence web standards, ensuring browsers align with ethical values and support privacy-focused PHP applications.
Shaping the Future of the Web
Concluding, Noël and Pierre inspired developers to contribute to the web’s evolution by participating in W3C discussions and reporting issues to platforms like GitHub. Their call to action emphasized the developer’s role in advocating for a user-respecting web. By blending historical context with practical advice, they provided PHP developers with a roadmap to navigate browser-related challenges, fostering a more inclusive and ethical digital landscape.
Links:
[PHPForumParis2022] BFF: Our Best Friend Forever for Frontend Applications? – Valentin Claras
Valentin Claras, a seasoned team leader at Bedrock, delivered a compelling session at PHP Forum Paris 2022, exploring the Backend for Frontend (BFF) pattern as a solution for managing complex frontend applications. With over a decade of development experience, Valentin shared insights from his work at Bedrock, formerly MC6, illustrating how BFF streamlines frontend-backend interactions. His presentation, dense with practical examples, highlighted the pattern’s potential to enhance performance and maintainability in PHP-driven projects.
Understanding the BFF Pattern
Valentin introduced the BFF pattern as a specialized backend layer tailored to specific frontend needs, acting as a “glue” between diverse APIs and client applications. Drawing from Bedrock’s streaming platform, he explained how BFF aggregates data from multiple backend services, simplifying frontend development. By reducing the complexity of direct API calls, BFF enables faster iteration and better user experiences, particularly for applications with varied frontend requirements like web and mobile interfaces.
Optimizing Performance with Asynchronous Processing
Addressing performance concerns, Valentin detailed Bedrock’s use of the Tornado engine to handle asynchronous API calls within the BFF layer. He explained how parallelizing 10 to 20 API requests ensures reasonable response times, even under heavy loads. Valentin referenced prior talks by colleague Benoit Viguier, emphasizing the importance of non-sequential processing to maintain efficiency. This approach, he argued, mitigates the risk of performance bottlenecks, making BFF a viable solution for high-traffic applications.
Maintaining Clear Boundaries
Valentin emphasized the importance of keeping BFF’s responsibilities minimal to avoid it becoming a monolithic service. At Bedrock, the BFF focuses solely on data aggregation and transformation, leaving business logic to dedicated services. This clear separation ensures maintainability and scalability, preventing the BFF from absorbing unrelated responsibilities. Valentin’s insights, grounded in real-world challenges, offered a blueprint for developers aiming to implement BFF effectively in their PHP projects.
Fostering Collaborative Development
Concluding, Valentin highlighted BFF’s role in fostering collaboration between frontend and backend teams. By providing a unified interface, BFF reduces miscommunication and aligns development efforts. He encouraged developers to adopt BFF incrementally, leveraging its flexibility to enhance project workflows. Valentin’s practical approach inspired attendees to explore BFF as a tool for building robust, frontend-friendly PHP applications, drawing from Bedrock’s successful implementation.
Links:
[PHPForumParis2022] Exploring DDD and Functional Programming Practices – Benjamin Rambaud
Benjamin Rambaud, an accomplished PHP engineer at ekino, delivered an engaging presentation at PHP Forum Paris 2022, inviting developers to explore Domain-Driven Design (DDD) and functional programming to enhance their craft. With a nod to the collaborative spirit of the event, Benjamin adopted a market-like metaphor, encouraging attendees to “pick and choose” principles from DDD and functional programming to enrich their PHP projects. His talk, informed by his role as a co-organizer of AFUP Bordeaux, offered practical insights into improving code quality and project communication, drawing from established methodologies while urging developers to adapt them thoughtfully.
Foundations of Domain-Driven Design
Benjamin opened by demystifying DDD, a methodology focused on modeling complex business domains with precision. He emphasized the Ubiquitous Language, a shared vocabulary that aligns developers, stakeholders, and domain experts, fostering clearer communication. By prioritizing domain logic over technical details, DDD isolates business rules, making code more maintainable and expressive. Benjamin illustrated this with examples from his work at ekino, showing how DDD’s strategic patterns, like bounded contexts, help developers encapsulate business logic effectively, reducing framework dependency.
Leveraging Functional Programming
Shifting to functional programming, Benjamin highlighted its synergy with PHP’s multi-paradigm nature. He introduced concepts like pure functions, immutability, and value objects, which enhance testability and predictability. By integrating these principles, developers can create robust, error-resistant codebases. Benjamin drew from his experience with Drupal, demonstrating how functional programming complements DDD by isolating domain logic from framework-specific code, allowing for greater flexibility and maintainability in PHP projects.
Practical Implementation and Hexagonal Architecture
Delving into practical applications, Benjamin advocated for hexagonal architecture as a cornerstone of DDD in PHP. This approach uses ports and adapters to decouple business logic from external systems, enabling seamless integration with frameworks like Symfony. He cautioned against rigid adherence to frameworks, referencing resources like Mathias Verraes’ blog for deeper insights into DDD patterns. Benjamin’s practical advice, grounded in real-world examples, encouraged developers to experiment with repositories and interfaces tailored to their project’s needs, fostering adaptable and resilient code.
Balancing Frameworks and Principles
Concluding, Benjamin urged developers to understand their frameworks deeply while embracing external paradigms to avoid being constrained by default configurations. He emphasized that DDD and functional programming are not rigid doctrines but flexible tools to be adapted contextually. By encouraging exploration of languages like Elixir or OCaml, Benjamin inspired attendees to broaden their perspectives, enhancing their ability to craft high-quality, business-aligned PHP applications through thoughtful experimentation.
Links:
[PHPForumParis2022] FrankenPHP: Diving into PHP’s Interpreter, Virtual Machines, and More – Kévin Dunglas
Kévin Dunglas, a seasoned developer at Les-Tilleuls.coop and creator of API Platform, presented an innovative exploration of FrankenPHP at PHP Forum Paris 2022. Blending PHP with Go, Kévin introduced a groundbreaking server solution that pushes PHP’s boundaries. His talk delved into the technical intricacies of integrating Go’s threading model with PHP’s interpreter, offering a glimpse into a future where PHP applications achieve unprecedented performance and flexibility.
Introducing FrankenPHP
Kévin opened with the origins of FrankenPHP, a project born from his passion for both PHP and Go. Inspired by Les-Tilleuls’ developer Loris Sorio, who designed its logo, FrankenPHP aims to combine PHP’s ease of use with Go’s performance capabilities. Kévin explained how it leverages Go’s threading to overcome PHP-FPM’s limitations, enabling features like concurrent request handling. This fusion, he argued, unlocks new possibilities for PHP applications, particularly in high-performance scenarios.
Overcoming Technical Challenges
Delving into the technical core, Kévin described the complexities of integrating PHP’s Zend Thread Safe (ZTS) mode with Go’s threading model. He highlighted challenges like signal conflicts and the lack of OPcache support, which required custom modifications to PHP’s source code. By isolating PHP processes within Go threads, Kévin’s team achieved stable communication, though he noted the solution remains experimental. His transparency about these hurdles provided valuable insights for developers exploring similar integrations.
Performance and Future Directions
Kévin showcased FrankenPHP’s performance potential, demonstrating how enabling OPcache by modifying PHP’s SAPI list significantly reduced compilation overhead. He outlined future goals, including support for Laravel Octane and Symfony’s CLI, while acknowledging Windows compatibility challenges. Kévin’s call for community contributions to refine FrankenPHP underscored its open-source ethos, inviting developers to explore its code and report issues to enhance its stability.
Community Engagement and Collaboration
Concluding, Kévin emphasized the collaborative spirit driving FrankenPHP’s development. He encouraged developers to contribute via GitHub, highlighting the project’s experimental nature and potential for growth. By sharing Les-Tilleuls’ vision, Kévin inspired attendees to experiment with FrankenPHP, fostering a community-driven effort to redefine PHP’s role in modern web development.
Links:
[PHPForumParis2022] What a Complete Production Crash Taught Us – Jean-François Lépine
Jean-François Lépine, a quality-focused developer at Alineaforce, shared a gripping account at PHP Forum Paris 2022 of a production crash that reshaped his team’s approach to software development. With a background in tools like PHP Metrics, Jean-François offered a candid reflection on the lessons learned from a critical incident two years prior. His presentation emphasized proactive strategies for preventing future failures, blending technical insights with a focus on team culture and process improvement.
Anatomy of a Production Crash
Jean-François began by recounting the harrowing incident that brought their production environment to a halt. Without dwelling on the chaos, he focused on the root causes, such as inadequate monitoring and untested assumptions. By analyzing the failure’s impact, Jean-François highlighted the importance of identifying vulnerabilities early. His narrative underscored how such crises expose gaps in processes, prompting his team to rethink their approach to reliability and resilience.
Building Robust Processes
Drawing from the aftermath, Jean-François detailed the processes his team implemented to prevent recurrence. These included automated monitoring, rigorous incident tracking, and mandatory documentation for every merge request. He emphasized the creation of secondary tickets to address root causes, ensuring issues are resolved systematically. Jean-François noted that while some practices, like immediate alerting, remain a work in progress, others, such as incident resolution protocols, have become ingrained team habits.
Fostering a Culture of Accountability
Jean-François stressed the role of team culture in sustaining these changes. He described how Alineaforce adopted measurable goals, such as increasing documentation coverage to 12% of merge requests, with plans to improve further. By fostering accountability and encouraging proactive communication, the team transformed painful lessons into a framework for continuous improvement. Jean-François’s insights inspired developers to prioritize resilience and collaboration in their workflows.
Links:
[PHPForumParis2022] Drupal, I’ll Tell You Everything! – Marine Gandy
Marine Gandy, a dynamic Drupal advocate, delivered an energetic and entertaining presentation at PHP Forum Paris 2022, unveiling the upcoming Drupal 10 release. Adopting a playful “newsroom” format, Marine shared exclusive insights from her “undercover” investigation within the Drupal community. Her talk blended humor, technical depth, and community spirit, offering a comprehensive look at Drupal 10’s advancements and its evolving ecosystem, captivating both newcomers and seasoned developers.
Drupal 10’s New Features
Marine kicked off with a lively overview of Drupal 10, set for release on December 14, 2022. She highlighted its enhanced support for modern PHP versions and improved compatibility with diverse environments. Marine explained how Drupal 10 builds on its predecessor, introducing streamlined tools and modules to enhance developer productivity. Her animated delivery, complete with sound effects and lighthearted jabs, kept the audience engaged while conveying the technical significance of these updates.
Simplifying Installation and Updates
Focusing on usability, Marine discussed Drupal 10’s efforts to simplify installation and updates, particularly through restructured module handling. She addressed the shift away from traditional distributions, noting that while modules like Drupal Commerce remain integral, their installation process is evolving to be more modular and flexible. Marine emphasized that these changes aim to reduce maintenance overhead, allowing developers to customize setups without relying on rigid distributions, thus enhancing long-term maintainability.
Engaging the Drupal Community
Marine concluded by rallying the Drupal community to embrace Drupal 10’s advancements and contribute to its growth. She encouraged developers to explore the updated ecosystem and provide feedback to refine its features. Her infectious enthusiasm and call for inclusivity, including support for diverse contributors, resonated with attendees, inspiring them to engage with Drupal’s vibrant open-source community and drive its future development.
Links:
[PHPForumParis2022] A Rusty PHP Extension – Pierre Tondereau
Pierre Tondereau, a developer with a passion for exploring new technologies, captivated attendees at PHP Forum Paris 2022 with his engaging exploration of creating PHP extensions using Rust. Drawing from his personal journey of discovering Rust in 2021, Pierre shared a compelling narrative about leveraging this modern language to enhance PHP’s capabilities. His presentation, rooted in a practical experiment, highlighted Rust’s potential to improve security and streamline development, offering a fresh perspective on extending PHP’s functionality.
Why Rust for PHP Extensions?
Pierre began by introducing Rust, a language developed by Mozilla in 2015 to refactor their HTML rendering engine, prioritizing performance and memory safety. Unlike traditional PHP extensions written in C, which demand meticulous memory management to avoid security vulnerabilities, Rust offers robust safety guarantees. Pierre explained how Rust’s design eliminates common issues like null pointer dereferences, making it an appealing choice for PHP developers unfamiliar with C’s complexities. He emphasized that his goal was not to rewrite PHP’s virtual machine but to create a secure, efficient extension using the ext-php-rs crate.
Building and Distributing Extensions
Delving into the technical process, Pierre outlined how the ext-php-rs crate simplifies PHP extension development by abstracting the Zend API. He demonstrated wrapping Rust APIs for PHP userland, using tools like cargo-php to streamline building and installation. Pierre highlighted the crate’s comprehensive coverage, which handled his use case effectively, though he encouraged community feedback to expand its capabilities. By automating distribution, Rust enables developers to integrate extensions seamlessly, enhancing PHP’s ecosystem with minimal friction.
Security and Future Potential
Concluding, Pierre underscored Rust’s security benefits, citing its ability to prevent memory-related vulnerabilities that plague C-based extensions, such as those impacting Google Chrome. He referenced Microsoft’s 2019 shift toward prioritizing security over performance, reinforcing Rust’s relevance. Pierre invited developers to explore his GitHub repository and contribute to ext-php-rs, fostering a collaborative push toward safer, more reliable PHP extensions. His talk inspired attendees to consider Rust as a viable tool for modernizing PHP development.
Links:
[PHPForumParis2022] Code Review: We Didn’t Come to Suffer! – Anne-Laure de Boissieu
Anne-Laure de Boissieu, a backend developer at Bedrock, delivered a heartfelt presentation at PHP Forum Paris 2022 on transforming code reviews into positive, constructive experiences. As a member of the Duchess France network and an organizer of the Mixit conference, Anne-Laure shared personal anecdotes and practical strategies to make code reviews less daunting and more collaborative, drawing from her experience at Bedrock and her passion for community engagement.
Reframing Code Reviews as Collaboration
Anne-Laure began by addressing the emotional challenges of code reviews, recounting instances where feedback felt personal or discouraging. She argued that code reviews should be a collaborative process, not a source of suffering. By adopting a constructive mindset, developers can focus on improving code quality rather than defending their work. Anne-Laure emphasized the importance of clear communication, citing her own experiences at Bedrock, where supportive feedback helped her grow as a developer.
Best Practices for Effective Reviews
Drawing from Bedrock’s workflow, Anne-Laure shared actionable best practices for code reviews. She advocated for assigning a “buddy” to new developers for initial reviews, conducting verbal feedback sessions to reduce misunderstandings, and addressing complex feedback in person. Referencing Amélie’s talk on onboarding, she highlighted small tasks, like adding a name to a list, to familiarize newcomers with workflows. These practices, Anne-Laure argued, create a supportive environment that fosters learning and aligns with team standards.
Building a Positive Review Culture
Anne-Laure emphasized that human interactions are key to successful code reviews. She cautioned against piling up written comments, which can escalate tensions, and encouraged direct discussions to resolve issues. By sharing her journey from feeling hurt by feedback to valuing constructive critiques, Anne-Laure inspired developers to approach reviews with empathy and openness. Her insights underscored the role of team dynamics in creating a culture where reviews enhance collaboration and professional growth.
Links:
[PHPForumParis2022] Testing Through OpenAPI, or How to Validate Your Documentation – Stéphane Hulard
Stéphane Hulard, CTO at Chstudio, delivered a compelling session at PHP Forum Paris 2022 on using OpenAPI to validate API documentation. With four years of experience maintaining a PHP-based project, Stéphane shared a practical approach to ensuring documentation aligns with implementation. His talk emphasized the synergy between testing and documentation, offering developers a workflow to enhance collaboration and maintainability in API-driven projects.
The Role of OpenAPI in Documentation
Stéphane introduced OpenAPI as a standardized format for describing APIs, enabling both human-readable documentation and automated testing. He explained how OpenAPI specifications serve as a contract between backend and frontend teams, ensuring consistency. By documenting a single API endpoint, developers can validate its behavior through automated tests, creating a virtuous cycle of reliable documentation and robust code. Stéphane emphasized starting small, documenting one endpoint at a time to build momentum.
Implementing Documentation-Driven Testing
Delving into technical details, Stéphane demonstrated how to integrate OpenAPI with PHP projects, using tools to generate and validate API requests. He shared code examples from Chstudio’s workflow, illustrating how tests derived from OpenAPI specs catch discrepancies early. This approach, akin to Test-Driven Development (TDD), ensures that documentation remains accurate as the codebase evolves. Stéphane highlighted the importance of enriching test suites with edge cases to uncover potential bugs, enhancing overall API reliability.
Enhancing Collaboration Across Teams
Stéphane underscored OpenAPI’s role in fostering collaboration between backend and frontend developers. By defining API contracts upfront, teams can make informed design decisions, reducing miscommunication. He described Chstudio’s experience with a monolithic repository, where OpenAPI facilitated smoother interactions despite the absence of microservices. Stéphane’s approach, which he termed Documentation-Driven Design (DDD), aligns development and documentation efforts, ensuring both are prioritized from the project’s outset.
Encouraging Community Contributions
Concluding, Stéphane invited developers to contribute to open-source OpenAPI tools, emphasizing their accessibility for PHP projects. He encouraged attendees to adopt incremental documentation practices, noting that even partial coverage yields significant benefits. By sharing Chstudio’s workflow, Stéphane inspired developers to integrate OpenAPI into their projects, fostering a culture of disciplined documentation and testing.