The document discusses change and how it begins with awareness. It talks about using testing to improve code and catch defects early. It describes using a service container and dependency injection to allow flexible configuration and extension of classes. It then discusses creating a custom user manager and discriminator to allow a FOSUserBundle to support multiple user classes. Finally, it proposes a bundle called NmnMultiUserBundle to implement this solution and mentions some books related to testing and code quality.
Context oriented architecture - Put the boundary in the right placeLeonardo Proietti
The slides of the talk I gave at PHPDay Italy 2016.
Last year the hype was on SOA, today is on the Microservices Architecture, what about tomorrow? No one knows. Whatever it is the architecture you want to use, we probably agree that the strategic goal of a tech team is to support a company business, creating customer value. How can we model our software and create an architecture to achieve that? What we are trying to do at Lendinvest, is using Domain Driven Design to drive the design of our architecture.
The slides of my talk at PUGRoma.
Here, a complete sample code
https://github.com/leopro/trip-planner
Presentation is also here: http://t.co/5EK56yYBmQ
Context oriented architecture - Put the boundary in the right placeLeonardo Proietti
The slides of the talk I gave at PHPDay Italy 2016.
Last year the hype was on SOA, today is on the Microservices Architecture, what about tomorrow? No one knows. Whatever it is the architecture you want to use, we probably agree that the strategic goal of a tech team is to support a company business, creating customer value. How can we model our software and create an architecture to achieve that? What we are trying to do at Lendinvest, is using Domain Driven Design to drive the design of our architecture.
The slides of my talk at PUGRoma.
Here, a complete sample code
https://github.com/leopro/trip-planner
Presentation is also here: http://t.co/5EK56yYBmQ
In this knolx we are going to learn about what, where and how for environment variables in angular and at the end we will go through the demo to have a more clearer picture of angular environment variables.
Feedback loops between tooling and cultureChris Winters
Discussion of how tools technologists create impact culture, and how culture impacts those tools. Not really a standalone presentation but hopefully useful.
Presented at jDD Krakow Oct 2017
Developers love to complain about their legacy systems, but if you have a legacy system, it means you have a working, successful system which deliver real value to business, and this is definitely a good thing.
The quest for global design principles (SymfonyLive Berlin 2015)Matthias Noback
If you’re a programmer you make design decisions every second. You need to think, and often think hard, about everything. Luckily there are many useful design principles and patterns that you can apply. But some of them merely expose code smells. Others only help you design your classes. And some are applicable to packages only. Wouldn’t it be nice to have some more general, always useful, invariably applicable, foundational design principles? In this talk we’ll look at software from many different perspectives, and while we’re zooming in and out, we’ll discover some of the deeper principles that form the basis of proper object-oriented design. After attending this talk you will be able to make better design decisions by reflecting on the stream of messages that is flowing from object to object, and from application to application.
The quest for global design principles - PHP Benelux 2016Matthias Noback
If you’re a programmer you make design decisions every second. Statements, functions, classes, packages, applications, even entire systems: you need to think, and often think hard, about everything. Luckily there are many useful design principles, patterns and best practices that you can apply. But some of them merely expose code smells. Others only help you design your classes. And some are applicable to packages only. Wouldn’t it be nice to have some more general, always useful, invariably applicable, foundational design principles?
In this talk we’ll look at software from many different perspectives, and while we’re zooming in and out, we’ll discover some of the deeper principles that lie beneath proper object-oriented design. They are the foundation of many of the well-known design patterns and they may even serve as an explanation for code smells.
Building Large Scale Javascript ApplicationAnis Ahmad
In recent years a number of libraries for building large JavaScript applications has appeared. As we no longer need to battle DOM differences between browsers we can finally focus on building highly interactive front-end applications instead. But before we can do a good job with these new libraries we need unlearn our previous DOM-centric approach and need to be aware of good practices and patterns of developing modern javascript app.
It will start with jQuery based old style practices and try to discuss on how can we approach to a modular, decoupled, scalable application architecture. This slide was prepared in very short time for technical session series of Digital World 2014 (http://www.digitalworld.org.bd/technical-session). The event video is here - https://www.youtube.com/watch?v=Gpw7l27MUUc (slide was not properly covered in video).
It has taken inspiration, ideas (, even some contents) from the following sources -
* http://addyosmani.com/largescalejavascript/
* http://addyosmani.com/resources/essentialjsdesignpatterns/book/
* https://www.youtube.com/watch?v=vXjVFPosQHw
* https://www.youtube.com/watch?v=qWr7x9wk6_c
* https://speakerdeck.com/kimjoar/patterns-of-large-scale-javascript-applications-1
Transforming Novices into Skilled Accessibility Testers - CSUN 2016Mark Stimson
Kaiser Permanente shares a proven method of transforming novice QA Testers into skilled screen reader testers. Anyone needing a fully accessible PowerPoint or PDF version, please send me a LinkedIn message.
Presentation I gave at the Houston TechFest Sept 2009. This presentation goes over Extension Methods, Lambdas, Expression Trees, and Fluent Interfaces. I also show examples from popular frameworks using these techniques.
In this knolx we are going to learn about what, where and how for environment variables in angular and at the end we will go through the demo to have a more clearer picture of angular environment variables.
Feedback loops between tooling and cultureChris Winters
Discussion of how tools technologists create impact culture, and how culture impacts those tools. Not really a standalone presentation but hopefully useful.
Presented at jDD Krakow Oct 2017
Developers love to complain about their legacy systems, but if you have a legacy system, it means you have a working, successful system which deliver real value to business, and this is definitely a good thing.
The quest for global design principles (SymfonyLive Berlin 2015)Matthias Noback
If you’re a programmer you make design decisions every second. You need to think, and often think hard, about everything. Luckily there are many useful design principles and patterns that you can apply. But some of them merely expose code smells. Others only help you design your classes. And some are applicable to packages only. Wouldn’t it be nice to have some more general, always useful, invariably applicable, foundational design principles? In this talk we’ll look at software from many different perspectives, and while we’re zooming in and out, we’ll discover some of the deeper principles that form the basis of proper object-oriented design. After attending this talk you will be able to make better design decisions by reflecting on the stream of messages that is flowing from object to object, and from application to application.
The quest for global design principles - PHP Benelux 2016Matthias Noback
If you’re a programmer you make design decisions every second. Statements, functions, classes, packages, applications, even entire systems: you need to think, and often think hard, about everything. Luckily there are many useful design principles, patterns and best practices that you can apply. But some of them merely expose code smells. Others only help you design your classes. And some are applicable to packages only. Wouldn’t it be nice to have some more general, always useful, invariably applicable, foundational design principles?
In this talk we’ll look at software from many different perspectives, and while we’re zooming in and out, we’ll discover some of the deeper principles that lie beneath proper object-oriented design. They are the foundation of many of the well-known design patterns and they may even serve as an explanation for code smells.
Building Large Scale Javascript ApplicationAnis Ahmad
In recent years a number of libraries for building large JavaScript applications has appeared. As we no longer need to battle DOM differences between browsers we can finally focus on building highly interactive front-end applications instead. But before we can do a good job with these new libraries we need unlearn our previous DOM-centric approach and need to be aware of good practices and patterns of developing modern javascript app.
It will start with jQuery based old style practices and try to discuss on how can we approach to a modular, decoupled, scalable application architecture. This slide was prepared in very short time for technical session series of Digital World 2014 (http://www.digitalworld.org.bd/technical-session). The event video is here - https://www.youtube.com/watch?v=Gpw7l27MUUc (slide was not properly covered in video).
It has taken inspiration, ideas (, even some contents) from the following sources -
* http://addyosmani.com/largescalejavascript/
* http://addyosmani.com/resources/essentialjsdesignpatterns/book/
* https://www.youtube.com/watch?v=vXjVFPosQHw
* https://www.youtube.com/watch?v=qWr7x9wk6_c
* https://speakerdeck.com/kimjoar/patterns-of-large-scale-javascript-applications-1
Transforming Novices into Skilled Accessibility Testers - CSUN 2016Mark Stimson
Kaiser Permanente shares a proven method of transforming novice QA Testers into skilled screen reader testers. Anyone needing a fully accessible PowerPoint or PDF version, please send me a LinkedIn message.
Presentation I gave at the Houston TechFest Sept 2009. This presentation goes over Extension Methods, Lambdas, Expression Trees, and Fluent Interfaces. I also show examples from popular frameworks using these techniques.
This presentation, created by Syed Faiz ul Hassan, explores the profound influence of media on public perception and behavior. It delves into the evolution of media from oral traditions to modern digital and social media platforms. Key topics include the role of media in information propagation, socialization, crisis awareness, globalization, and education. The presentation also examines media influence through agenda setting, propaganda, and manipulative techniques used by advertisers and marketers. Furthermore, it highlights the impact of surveillance enabled by media technologies on personal behavior and preferences. Through this comprehensive overview, the presentation aims to shed light on how media shapes collective consciousness and public opinion.
Collapsing Narratives: Exploring Non-Linearity • a micro report by Rosie WellsRosie Wells
Insight: In a landscape where traditional narrative structures are giving way to fragmented and non-linear forms of storytelling, there lies immense potential for creativity and exploration.
'Collapsing Narratives: Exploring Non-Linearity' is a micro report from Rosie Wells.
Rosie Wells is an Arts & Cultural Strategist uniquely positioned at the intersection of grassroots and mainstream storytelling.
Their work is focused on developing meaningful and lasting connections that can drive social change.
Please download this presentation to enjoy the hyperlinks!
1. Change begins with awareness
Appetite comes with testing
“It's a dangerous business, Frodo, going out
your door. You step onto the road, and if you
don't keep your feet, there's no knowing
where you might be swept off to.”
J.R.R. Tolkien, The Lord of the Rings
10. Change begins with awareness
And...
“Supporting multiple user classes is not easy at all. It would
make the bundle code far more complex as we would
basically need to change all places interacting with the user
to be able to handle all user classes. I don't really want to
go this way (it will also make it more likely to introduce
bugs).”
...a delusion
11. Change begins with awareness
But...
In Symfony2, all core classes use the service container,
so it is easy to extend, configure and use any object
...a hope
12. Change begins with awareness
Service Container
Dependency Injection Container
use AcmeHelloBundleMailer;
$mailer = new Mailer('sendmail');
$mailer->send('info@netmeans.net', ... );
13. Change begins with awareness
Service Container
Dependency Injection Container
class Mailer
{
private $mailerType;
public function __construct($mailerType)
{
$this->mailerType = $mailerType
}
public function send($to, ...)
{
...
}
}
services:
my_mailer:
class: AcmeHelloBundleMailer
arguments: [sendmail]
14. Change begins with awareness
Service Container
Dependency Injection Container
class HelloController extends Controller
{
public function sendEmailAction()
{
$mailer = $this->get('my_mailer');
$mailer->send('info@netmeans.net', ... );
}
}
15. Change begins with awareness
FOSUserBundle
fos_user:
db_driver: orm
firewall_name: main
user_class: AcmeUserBundleEntityUser
16. Change begins with awareness
FOSUserBundle
fos_user:
db_driver: orm
firewall_name: main
user_class: AcmeUserBundleEntityUser
service:
user_manager: custom_user_manager
17. Change begins with awareness
So ...
...a solution
We have to create our custom
UserManager that accepts in the
constructor an object that have the
responsibility to discriminate user
types
18. Change begins with awareness
First of all: test
We start writing some functional
tests to check correct integration
of FOSUserBundle
19. Change begins with awareness
Custom UserManager
Class UserManager extends FOSUserBundleEntityUserManager
{
protected $userDiscriminator;
public function __construct(..., UserDiscriminator $userDiscriminator)
public function getClass()
{
return $this->userDiscriminator->getClass();
}
}
20. Change begins with awareness
UserDiscriminator
public function getClass()
{
return 'Acme/UserBundle/Entity/UserOne';
}
21. Change begins with awareness
From here it's all smooth
With little iterations, we improve
UserManager and UserDiscriminator
with unit and functional tests,
passing from a dirty code to a more
elegant one
24. Change begins with awareness
NmnMultiUserBundle
Ok, it is an hack :)
A lazy way to use for free most of the
functionality of FOSUserBundle ...
... but it is ready to be improved by
anyone.
26. Change begins with awareness
Some Books
I know this sounds strident and unilateral, but given the record I don't
think the surgeons should have to defend hand-washing, and I don't
think programmers should have to defend TDD
The Clean Coder
A code of Conduct for Professional Programmers
Martin, Robert C.
27. Some Books
In software development, “perfect” is a verb, not an adjective
Extreme Programming Explained
Embrace Change
Beck, Kent
Change begins with awareness
In XP, testing is as important as programming
28. Change begins with awareness
Some Books
Building testable applications is Hard
The Grumpy Programmer's Guide To Building
Testable Applications in PHP
Hartjes, Chris
The reason for investing in automated testing is obvious: any bugs you
catch before your application makes it into production cost less in terms
of resources (money, developer time) to fix than fixing it into production