PHP Developers Network

A community of PHP developers offering assistance, advice, discussion, and friendship.
 
Loading
It is currently Tue Jun 25, 2019 5:59 pm

All times are UTC - 5 hours




Post new topic Reply to topic  [ 7 posts ] 
Author Message
PostPosted: Wed Feb 10, 2016 1:07 pm 
Offline
Forum Newbie

Joined: Wed Feb 10, 2016 12:57 pm
Posts: 3
I recently ran across a situation where someone has written their own framework of PHP from the ground up rather than using an available framework. At least that's the claim. From a business perspective, the argument is that the software created with a completely custom PHP can be resold commercially in a licensing scheme that is more defensible and protectable in terms of IP than with GPL.

I'm unsure of whether building PHP from the ground up makes good business sense or if it is overkill. From a development perspective, it seems superfluous, especially with a competing requirement to quickly get a stable, feature-rich product to market. Writing your own PHP from the ground up seems to be a reinvention of the wheel in that sense.

What is the general consensus on this practice, if any? Is it fairly common?


Top
 Profile  
 
PostPosted: Wed Feb 10, 2016 1:39 pm 
Offline
Moderator
User avatar

Joined: Tue Nov 09, 2010 3:39 pm
Posts: 6425
Location: Montreal, Canada
webidextrous wrote:
From a business perspective, the argument is that the software created with a completely custom PHP can be resold commercially in a licensing scheme that is more defensible and protectable in terms of IP than with GPL.

Who is going to pay for a PHP framework?

There are a number of great PHP frameworks out there already. They're well tested, well documented, peer reviewed (by virtue of being open source), and have large communities supporting them. You'll get little if any of that with a custom job. It will also likely kill your time to market. Building your own framework as a tool for learning is about the only legitimate use case I can think of, and that's certainly not the foundation you'd want for your shiny new app.

_________________
Supported PHP versions No longer supported versions


Top
 Profile  
 
PostPosted: Wed Feb 10, 2016 2:17 pm 
Offline
Forum Newbie

Joined: Wed Feb 10, 2016 12:57 pm
Posts: 3
Thanks, Celauran. That was my initial assessment as well, but I wanted to make sure I wasn't assuming anything via my own bias.


Top
 Profile  
 
PostPosted: Wed Feb 10, 2016 3:49 pm 
Offline
Spammer :|
User avatar

Joined: Wed Oct 15, 2008 2:35 am
Posts: 6617
Location: WA, USA
As a proponent of custom frameworks (when circumstances allow),

- You don't get bloat. I tried using Zend Framework at a previous job and there was so much bloat it took seconds to load a static page. I made a custom router that handled everything in milliseconds. And it only took a couple hours.
- You get a tailor-made solution. All the code is geared towards your business and every line matters. There are no classes floating around not doing anything.
- If you want to trim out code from a framework that you're not using, good luck. It's often highly coupled.

Now that's not saying it's always good to use a custom framework. If your developers don't know what they're doing then any framework they write (not to mention the rest of the codebase) will probably be terrible. If you want to hire as many developers as possible then a known framework will get you more people more easily with a shorter ramp-up period. If you don't care about efficient code and just want something quick and easy so you can move onto the "fun" business stuff then you'd want as much pre-written stuff as possible.

PS: I love writing low-level stuff like frameworks. I would much rather do that than, really, anything else.


Top
 Profile  
 
PostPosted: Wed Feb 10, 2016 3:59 pm 
Offline
Forum Newbie

Joined: Wed Feb 10, 2016 12:57 pm
Posts: 3
Thanks, requinix, for that perspective. My first computer programming exercise was with writing Assembler, then Basic, then progressively higher-level languages and frameworks. I gravitated toward the "fun business stuff" due to the amount of cool things I could do, and more quickly, with pre-built frameworks. Low-level just wasn't my cup of tea and it's still a struggle for me to understand the allure of it. But I appreciate that others enjoy it and are able to do it for the rest of us. :)


Top
 Profile  
 
PostPosted: Wed Feb 10, 2016 4:05 pm 
Offline
Spammer :|
User avatar

Joined: Wed Oct 15, 2008 2:35 am
Posts: 6617
Location: WA, USA
"Low-level", at least when I use the term, varies on context. It's relative. Dealing with assembly code forces you to write a lot of boilerplate code (eg, interacting with the console or opening files) that you'll never want to do again. C isn't much higher up from there and has many of the same problems.
With PHP it means more like making a router, or autoloading classes, or logging, that you take for granted once it's written. It generally always follows a certain form, and doing it repeatedly from one project to the next can get boring.


Top
 Profile  
 
PostPosted: Wed Feb 10, 2016 5:14 pm 
Offline
Site Administrator
User avatar

Joined: Wed Aug 25, 2004 7:54 pm
Posts: 13590
Location: New York, NY, US
While I think writing a custom framework can be appropriate for:

1. Certain types of application that require atypical program flow (i.e., not a normal router).

2. When you want to invest in your own programmings skills by implementing some core libraries.

However, that said there are a couple of very good reasons not to build a custom framework:

1. Security and stability require extensive knowledge and testing to achieve. Popular frameworks have lots of eyeballs on the code and lots of users testing the code. Custom frameworks can have severe unknown security and stability problems.

2. The time you spend building something 98% identical to one of the current, popular, high quality frameworks, is time you are not spending on developing your application(s). For an employee, building a custom framework is almost always wasting the company's money.

_________________
(#10850)


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 

All times are UTC - 5 hours


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group