Slashdot Mirror


Thinking about Rails? Think Again

wolfeon writes "In 2005, Derek Sivers of CD Baby wanted to scrap his site and perform a rewrite in Rails. He hired Jeremy Kemper, also known as bitsweat on Freenode, to help on the project. Two years later, through blood and sweat, the project was then canceled because of limitations of Rails. Rails just wasn't meant to do everything since it is very much "canned" project. Mr. Sivers has written an entry in the O'Reilly blog: 7 reasons I switched back to PHP."

482 comments

  1. Why rewrite existing systems? by MarkWatson · · Score: 1, Insightful

    What a waste of time. Evaluate and use new technology on new tasks.

    One of my main customers hired a good team in Vietnam who used PHP, CSS, HTML, and Javascript. I introduced them to Rails a year ago, and they were just about instantly productive.

    Deploying Rails can be a small hassle, but there are now lots of good options, including running on JRuby/Goldspike/Java app server.

    1. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 5, Interesting

      This reminds me of a similar incident I saw on Reddit a few months ago:

      Sometimes it's best to leave old software systems alone.
      http://pinderkent.blogsavy.com/archives/88

      Last night at the pub, a friend and colleague of mine was telling me of a recent experience he had at a company he was doing some IT work for. I think the lesson learned is a very important one, and thus I wish to share it. But first I'll describe the situation he encountered.

      In the mid-1990s, the company in question built their IT operations around systems from Sun. They wrote much of their in-house code using C++, and used Oracle for their database needs. On the front-end, they used PCs running a mix of Windows NT 3.51, FreeBSD 2.x, and even OS/2, depending on the department. While that is not a unique setup by any means, what is somewhat unique is that they essentially continued to use those same systems up until 2006.

      One of the main reasons why they didn't switch is because their software systems worked just fine, even if the UIs were somewhat archaic. Their software was mature and well-understood by the company's employees. They even got extremely lucky in the first place, as the developers who initially designed and implemented their software systems did so in a way that allowed for the systems to easily scale as the need arose over time.

      The hardware proved to be the main instigator of change. After a decade, many of the front-end PCs they were using started to exhibit a variety of physical problems. Some had been replaced earlier, but eventually it was decided to replace them all with newer systems. However, to the best of my friend's knowledge, the back-end Sun systems were working just fine.

      However, at the same time they decided to also replace the back-end systems. A variety of consultants were apparently called in to appraise the situation. For whatever reason, it was eventually decided that the new back-end systems would be built around Windows Server 2003 and SQL Server 2005. The new back-end software was to be built upon .NET, while Web-based client-side apps would be developed and used. My friend wasn't sure exactly when this effort started, but he believed it was in early 2006.

      By the end of 2006, the consultants and developers deemed the new system ready to go. Over the course of the December 2006 holidays, the new systems were rolled out. It turned out to be a pretty major disaster. The first problem they ran into was a complete lack of performance. As they moved into the first weeks of 2007, their back-end systems just wouldn't scale. As an emergency fix, they ended up throwing more hardware at the problem, which did ease the burden on the existing servers somewhat. But it was in no means a permanent solution.

      The front-end software systems proved to be an even bigger disaster. Many of the AJAX-based applications used Internet Explorer-specific functionality. But the IT managers of some of the front-end networks would not allow IE to be used, for security reasons. They only allowed for Firefox to be used. So the Web-based front-end software needed significant modifications right away, as well.

      What was perhaps the worst failure involved the in-house users and their productivity. Large portions of the old system were built around a curses-based UI. Although it apparently wasn't very pretty, it did allow for a great deal of user productivity. One of the main complaints about the new Web-based software was that the keyboard support was quite poor, requiring the user to select input fields using the mouse, and at times even having to scroll the page to input or manipulate certain data. With the earlier system, the nagivation could rapidly be performed using just the keyboard. Some of the more experienced users were apparently so efficient with the older system that their productivity was reduced to 25% of what it was before the switch.

      My friend and his colleagues were called in to try to

    2. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 2, Interesting

      last year we made a major rollout of an application that was a rewrite of an existing application with microsoft tools, and guess what, it was a success, it outperformed the previous application and now the old system is forgotten. Lessons learned. * Use HTML, CSS, and keyboard support (onfocus, onblur, etc). * Don't understimate old software, we basically rewrote the application from scratch but using the lessons learned in 10+ years of the legacy software, sometimes working with the original developers. * Performance IS a priority, using proper OO techniques, and proper database design, performance is not an issue, even in windows plattform, sometimes the performance problems come from sloppy programming. * Benchmark your software, and test since day 1. Rewrite software is sometimes a need, particulary when the software is not actively mantained, the mentality of "it just works" avoid to look at the real problems... the systems that not change die, even the 20+ year cobol systems will die. Your post is misleading, since the problems were due bad project management, cheap developers and not in the tools.

    3. Re:Why rewrite existing systems? by Slim+Backwater · · Score: 5, Funny

      I submit to you, my fellow slashdotters, the parent post for the most ironic post ever. Such a long, insightful post about how to do a successful software deployment, and then not clicking preview to realize that the formatting of your list is all screwed up. Only posting as an A/C saved you a year of personal shame.

    4. Re:Why rewrite existing systems? by man_of_mr_e · · Score: 5, Insightful

      I disagree with the vast majority of those points. The only two that I agree with is giving consideration to scalability and getting user feedback. The rest are illogical conclusions based on a failed project whos real failure was poorly specified requirements.

      Certainly, Web UI's are not appropriate for everything. They should really only be used if there is some overpowering need (like the ability to access the data from anywhere without having client apps installed). They also apparently gave zero thought to existing processes and staff skillsets.

      Avoiding AJAX or any other technology because you tried to use it for something it wasn't good at is patently stupid. There are good uses for the technologies. This just wasn't one of them.

    5. Re:Why rewrite existing systems? by devjj · · Score: 1

      Good points. It really just seems like this guy tried to use Rails to say he was using Rails. I don't see anything in the article that actually states why he chose Rails in the first place. Not having a specific reason for doing it any one way or the other, and then being surprised when it doesn't work the way you want? Sure.. that must be Rails' fault. Next time try choosing a language and/or framework based on cold, hard reasons, and not because it's what the cool kids are doing. Rails is designed such that you know the assumptions and opt to work with them. When you choose to use Rails and then choose to shrug off everything that goes with it, you're shooting yourself in the foot. Your Rails project failed because of bad reasoning. Rails had nothing to do with it.

    6. Re:Why rewrite existing systems? by DasAlbatross · · Score: 1

      Absolutely. This was just poorly designed, planned, and understood. These sorts of problems happen on new projects. What do you blame in that case?

    7. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0

      Why rewrite existing systems?

      - If you succeed, your website is better. More revenues.
      - If you fail, you post about your failure on Slashdot with a link to your website. More revenues.

      It's a "win-win" situation.

    8. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 1, Interesting

      The rest of those points look pretty valid to me. I don't know how you can disagree with them.

      * Use mature, well-tested, effective software (eg. Solaris, Oracle, FreeBSD).

      Why do you disagree with that point? It makes sense to me. Using proven technology, especially those ones that were listed, does help build a solid foundation for whatever software you're layering on top.

      * Avoid immature fad "technologies" like AJAX.

      It sounds like they were just building a CRUD app, like you find in most enterprises. When it comes to the presentation layer for such an app, Ajax should be more than suitable. Why do you say that Ajax shouldn't be used for those kind of CRUD apps?

      * Traditional applications offer more flexibility than Web-based applications.

      This makes sense. You do have far fewer restrictions when using non-web technologies. Using C++ with a toolkit like wxWidgets or GTK+ is a lot more flexible than HTML forms and JavaScript.

      * Sometimes a text-based interface is far more efficient than a GUI.

      I guess this can be true. It's probably why you don't see point-and-click UIs at most POS terminals. The focus there is on making as many transactions as possible, as quickly as possible. ie. Maximizing the efficiency. This is best done from a keyboard.

      * Maintain a reasonable level of heterogeneity, when it comes to software, hardware and vendors.

      Diversity like this is also sensible. It prevents the spread of malicious software, and can help contain security issues without risking the entire network. But you don't want too much of it, like the point suggests. It's all about balance.

    9. Re:Why rewrite existing systems? by qb001 · · Score: 2, Insightful

      I've got to agree. In two years he could have rewritten this in Fortran on MVS. This has nothing to do with techonology. Obviously he's not comfortable with Ruby - it not be the right language for him since it's full on OOP. Complaining about integration problems because two systems are written in different languages indicates that their systems are tightly coupled. As Homer Simposon would say "Doh!". Probably sticking with PHP in their shop is a good idea in their case and they would have gotten in over their heads with . The second rule of techonology problems is "No matter how it looks at first, it's always a people problem."

    10. Re:Why rewrite existing systems? by Slippy. · · Score: 3, Insightful

      The big problem with flavor-itis in large projects is the years of support after. Time tested solutions people!

      Once a company gets committed to a design decision made by an trendy-entranced developer, the sysadmins and users can get punished with years of suffering afterwards.

      The tools stop being updated, and none of the *good* developers want to care for the ugly, unique application once the shine comes off the tools. It's like being forced to wear a magic top hat made out of steel - because top hats and magic steel were the fads when the project started.

      A trustworthy, *experienced* design architect is important. Preferably someone who's been/seen the young-uns make the silly mistakes.

      --
      -- Life is good. Tastes like chicken.
    11. Re:Why rewrite existing systems? by betterunixthanunix · · Score: 5, Insightful
      I thoroughly agree with you on this one. Unfortunately, I stand alone when I ask a question like, "What has a GUI added to this system? Why wasn't a text-base solution sufficient?" People think I am some kind of lunatic if I propose a non-AJAX/Application Server/wiz-bang solution to a problem. I understand that sort of mentality from end-users, but from programmers?

      My advice is to analyze the needs of the system before designing it. Don't assume a GUI or AJAX front end is the best possible way to do things. My favorite example is the library system in my county: their computers are using a console system for check in/check out, card processing, etc. The beauty of it is that the bar code scanner they use behaves like a keyboard, so that each scan is just a series of a numeric keystrokes following by an end-of-line. It is simple, the 80 year old librarians have no problem using it, and it doesn't require any difficult to coordinate mouse movements (as anyone who has studied this knows, using the mouse requires a lot of brain activity than using the keyboard). The console very accurately maps the workflow; a GUI wouldn't add very much, other than sheer lines of code, and a web interface would actually slow down the people who need to use it.

      Sure, there are cases where a GUI or web interface is better than a console interface. But that is why an analysis is needed before any code is written. As your friend's situation demonstrates, a well design system can work for many years without any trouble.

      --
      Palm trees and 8
    12. Re:Why rewrite existing systems? by u38cg · · Score: 3, Insightful

      The biggest problem, as I see it, is that the people who make major strategic decisions on IT don't have a clue what they are talking about. It's happening in my company right now - a consultant is being paid vast amounts of money to essentially write an ERP from scratch, for a company that doesn't need anything more complex than a decent accounting package that can handle more than one operating site. The guy is being paid a monthly fee and has no written specification or brief. He has no deadline and no agreed feature set. On a regular basis he turns up and spouts off his latest idea, solving a problem we don't have. The bosses, who know their business but don't know technology, are completely clueless and are pretty much at the whim of this chancer.

      --
      [FUCK BETA]
    13. Re:Why rewrite existing systems? by man_of_mr_e · · Score: 1

      I don't necessarily disagree with the points, but the conclusions don't follow from the problem space. .NET is very mature technology, as is SQL Server. The choice of those technologies was not the problem (other than throwing away something that worked).

      AJAX is not particularly immature, though many frameworks are. AJAX has been around for almost 10 years (it just wasn't called AJAX then). And the choice of AJAX in this case was bad, not because of AJAX, but because the requirements didn't call for it.

      Traditional apps don't offer more flexibility than Web-based Apps *in every circumstance*. Again, it depends on the requirements. If you need an app that is useable from anywhere in the world, without installing software on the client machine, the traditional apps are significantly LESS flexible, for instance. That wasn't the case in this situation, so the choice of a web-based app was silly.

      The choice of Text based UI versus GUI is also silly. A well designed GUI app is just as usable via keyboard as a text one, it's just a different presentation framework.

    14. Re:Why rewrite existing systems? by Foofoobar · · Score: 1, Interesting
      Instantly productive like any framework will make them in any language. Ruby on Rails though has serious scalability issues that limits it in a production environment. This is why the RUBY website and RUBY ON RAILS website all use PHP on their frontend.

      If they no longer show it's because they have expose_php turned off but several of these sites still show. They have yet to resolve their scalability issues and this is a well known issue with RUBY and why no main website uses it in production; it's only for small blogs or news sites but nothing major.

      Even 43things in their switch had to use 2 as much hardware to scale RUBY and they still had to fall back on PHP to get it to scale. The move was a nightmare (though the president keeps saying it was 'smooth').

      --
      This is my sig. There are many like it but this one is mine.
    15. Re:Why rewrite existing systems? by B'Trey · · Score: 4, Insightful

      I don't see anything in the article that actually states why he chose Rails in the first place.

      Even worse, there's absolutely nothing there about why Rails didn't work. Exactly what was it that was so hard to do in Rails that was easy to do in PHP? The article provides nothing useful to anyone looking to build a web site. How do I know if PHP is superior to Rails for my particular application? There's little there to help. This is nothing but a senseless rant.

      --

      "The legitimate powers of government extend only to such acts as are injurious to others." Thomas Jefferson.

    16. Re:Why rewrite existing systems? by PopeRatzo · · Score: 3, Insightful

      Sometimes it's best to leave old software systems alone.
      If you can afford the time and effort, trying something new almost always produces some benefit.

      The only failed experiment is the one you don't try.

      Clearly, someone thought there would be a benefit to using Rails over PHP in this case. If they were wrong, they gained valuable insight into a) the abilities of their tools and b) the nature of their project.

      I never liked the old saying "if it's not broke, don't fix it". The quest for innovation is a beautiful thing.
      --
      You are welcome on my lawn.
    17. Re:Why rewrite existing systems? by Tim+Browse · · Score: 0, Flamebait

      You remind me of an idiot I had to work with once (I'm not saying you're an idiot, just that you remind me of one).

      Working on a fairly vanilla stock control app, we were arguing over whether to use mysql or the Zope database (the system was written in Zope - don't get me started). From my side, I favoured mysql as a known quantity, I had run tests/queries with data representing the accumulation of orders etc over number of years, and was happy it worked/performed well. The other guy just wanted to use Zope's DB because it was Zope, and had not done any tests at all (I was later to learn this was his MO).

      At one stage, having run out of arguments, he pronounced "But...Innovation is the key!"

      I'm fairly proud of the fact that I resisted the temptation to shout in his face "We're writing a fucking Stock Control system - get over yourself."

      Great days.

    18. Re:Why rewrite existing systems? by Rakishi · · Score: 3, Insightful
      BS, you're apparently incapable of understanding the real world.

      If you can afford the time and effort, trying something new almost always produces some benefit. And if you are omnipotent you can move mountains, in the real world (not whatever fantasy YOU live in) everything is a trade off against time and money. Nothing has infinite resources and apparently you think everything does.

      If they were wrong, they gained valuable insight into a) the abilities of their tools and b) the nature of their project. And it cost them likely millions of dollars, probably tens of millions if you add everything into it.
    19. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0

      http://ruby-lang.org/ : "This website is made with Ruby and powered by Radiant CMS."

      or were you talking about some other ruby website ? :'(

    20. Re:Why rewrite existing systems? by mosch · · Score: 3, Insightful

      You're just trolling.

      A PHP tag on a webserver doesn't mean that the site is powered by PHP. It means that whoever compiled apache loaded a PHP module for possible use in one of the virtual hosts. That Apache also has FastCGI installed, which is routinely used for serving rails applications.

      I know for a fact that several high-traffic websites use RoR extensively, but none of them are tech sites, so they don't go around advertising what is on the back-end.

      I shouldn't have taken time to respond to your obvious troll, but I felt forced to because some gullible moderators gave you points for spewing lies and idiocy. Typical slashdot fare, I know, but give it a break.

    21. Re:Why rewrite existing systems? by larry+bagina · · Score: 1

      Maybe he's not comfortable with Ruby, but presumably the RoR expert he hired (bitsweat aka Jeremy Kemper) was.

      Let's review:

      php rewrite: 2 months

      ruby on rails rewrite: 2 years (before being cancelled)

      The article was light on specific reasons ("twisting the deep inner guts of Rails to make it do things it was never intended to do", "our needs clashed with Rails' preferences"), but it's consistent with other RoR criticism.

      --
      Do you even lift?

      These aren't the 'roids you're looking for.

    22. Re:Why rewrite existing systems? by TheLink · · Score: 3, Insightful

      MySQL? I know a company that went MySQL4 for a lot of things (and then later MySQL5). Using MySQL is usually a bad idea (and it does bite them every now and then - though most of them don't even realize it - I suppose they think that sort of thing is normal, they switched to having email on Microsoft Exchange too, so go figure).

      They have should have gone postgresql as per my recommendation. Oh well.

      With MySQL at first sight you seem to have all these features and behaviours/performance. But when you get down to the technical details you find that many of the "great" features, behaviours and performance are mutually exclusive. Want transactions - go innodb. Want fast inserts, go myisam. Want better concurrent write performance go innodb (or deal with buggy myisam insert delayed vs concurrent_insert vs etc stuff). Want fast selects - go myisam. Want foreign keys to work - innodb. Don't want to lock yourself to MySQL tech that's owned by Oracle (who may not have the best interests of MySQL in mind...) go myisam.

      Or just use postgresql. The devs tend to do things right (except when the SQL specs are stupid, in which case they usually follow the stupid spec and do things "wrong").

      --
    23. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0

      I usually blame the requirements project manager, but really anyone except the programming team will work - except the customer. Regardless, it is almost never their fault unless they prevented the end users from being involved in the requirements and mock up phases.

      Any senior consultant/PM would know better than to allow what this team encountered. Not to name, names, but many of the BIG 6 consulting teams have been using very smart, but inexperienced delivery teams. Seems they aren't actually trying to provide value, just suck the customer dry.
      Occasionally, customers are the big problem. They demand unreasonable deliveries (time / functions / low cost), so the consulting teams can only lead them on and push more and more features into a huge release "coming next quarter". When next quarter comes, they should be fired, but that means the selection team has to take the fall. They don't want that, so another quarter is needed - they dig their own hole. Until, finally 6-9 months overdue, some garbage is released or the firm is fired and everyone goes back to what they did before.

      The last 9 years, I've worked hundreds of projects from adding a few disk drives to deploying 10 environments and over 100 servers for a single team. Only 1 was canceled after $500M was spent - mostly by 3 of the "BIG 6" consulting firms. Fortunately, for my part of that effort, only $10M was blown. I knew something was wrong when the developer count was 60 and I didn't think they'd need more than 3. Poor management of features, schedule and most importantly cost was the failure. Ok, so with 17 years of development experience I should have done something. I did tell anyone listening of the issue, but my role in this huge project was for infrastructure hardware,not software. Lots of folks were fired - not enough if you ask me. I've paid off the house and live debt free.

      The company has been purchased by another and I'm on my way out in 2 months. It was a nice ride. I'm looking for a new gig to help move the family into a larger house.

      Oh, how do you know you have a problem? How many titles include "Application Architect" and how many contain "Technical Architect" in them. If more than 1 of those per software package - RUN!

    24. Re:Why rewrite existing systems? by tacocat · · Score: 3, Informative

      Ruby is nice, Rails has some severe limitations on what it can do without major hacks.

      Examples:

      Business Model versus Business Rules

      There is a distinction between the Rules and the Model. Rules are those things that must be enforced against the data. Examples of this would be (in database terms) referential integrity, unique values for certain fields or combination of fields.

      Without this distinction you can easily run into rampant data duplication and your ability to determine what is actually going on becomes a major challenge. Rails fails on this enforcement of the rule because when you identify something as being unique according to Rails, it's managed by a Model declaration to check for uniqueness before making an UPDATE/INSERT SQL execution. Problem with this is you are assuming that you have only one active rails session at a time. If you don't, then it's trivial for two web sessions to insert the same username in the table, thereby fucking your database and your business. Without the database actually enforcing the data through database constraints, you cannot guarantee the results.

      Things get even more difficult/tricky when you have to ensure that combinations of fields remain unique or referential constraints are preserved.

      I'm know there is some way to do all of this in Rails, but it's counter productive and essentially a hack. For example -- I would have to create additional unique SQL constraints in the database migration files, in some cases, I have to write out the SQL directly -- bypassing that which is Rails. Then the Model would not only have to run the extraneous SQL statement to check for uniqueness, but also be modified to accomodate the error handling that is going to happen when you violate the database integrity. Again, this makes for a lot of non-Rails and non-elegant code.

      Don't get me wrong, Rails is nice but it is not really going to be a useful product for some major site that is going to just get crushed in transactions. Do you really think you can open the next MySpace and have it keep all the data properly synchronized? I know it's possible to get around the application rules of the Model, so I know it's also likely to muck up your data.

    25. Re:Why rewrite existing systems? by qb001 · · Score: 1

      I don't think this is technology question. If you look at well researched info like the Chaos report the majority of technology projects fails, regardless of the technology. To blame RoR (or PHP, Java, .NET, etc) for their problems is missing the point. There are a lot of bad smells here and it has little to do with technology.

      They have integration problems, fighting fires for existing systems (Hello???), and don't seem to have a clear technology selection approach. Of course, this particular shop will be more successful with PHP because they know it best and the demands of their business (business complexity, transactionality, infrastructure, etc) are will suited to this.

      I've seen plenty of blanket criticisms like "it's consistent with other RoR criticism" leveled against plenty of technologies for years. I have one ex-client whose business is currently in severe peril since their PHP infrastructure is crumbling. Does this mean PHP is bad? Hardly. Does this mean the vendor that is providing the technology has poor development, testing, and support practices. Probably.

      I've seen lots of PHP, Ruby, Python, Java, .NET, C++, Smalltalk, etc, etc, etc projects fail. What it means is that software development is difficult.

    26. Re:Why rewrite existing systems? by canuck57 · · Score: 1

      ...With the earlier system, the nagivation could rapidly be performed using just the keyboard. Some of the more experienced users were apparently so efficient with the older system that their productivity was reduced to 25% of what it was before the switch.

      Going thought the pains of this ourselves. Were those .NET people off base on server estimates, almost 3 times as many servers as was pessimistically predicted and the users are just p'ssed. DBA are in a snit rightfully so that the SQL queries are not efficient at all.

      Hopefully we can all learn from these lessons made obvious by this situation. Although given my years of experience, somehow I think that won't be the case.

      You are far more optimistic than I am. Few companies today "engineer" their software. It is more often a brute force programming effort without architectural and performance guide lines. Front end unstable web interfaces on old back end code because newer programmers don't understand pointers and curses.

      Poor quality programmers. Commodity is more important than quality. Sort of why I left 12 years of programming C/C++/DB as it was clear you were the underpaid grunt. Companies pay more for sales and hype than getting a real slick product that sells itself. Much of the complexity in todays apps is their own downfall.

    27. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 1, Insightful

      I find it hard to believe you wrote such a lengthy comment and completely missed the lesson.

      The #1 lesson is that they did not properly assess the requirements for the project. If Firefox was required and they coded to IE, they missed a requirement. If scalability failed, they missed that as a requirement. How about the basic question: which requirement indicated there had to be a rewrite? Almost every paragraph you wrote points to this being the real problem.

      People need to look at what happened much earlier in projects before blaming fads, AJAX, .NET, Microsoft for IE, C++, whatever. Blaming Ruby, or AJAX, or whatever, is the PHB response to a failed project. Competent programmers should know it's almost always bad requirements or not coding to the requirements.

    28. Re:Why rewrite existing systems? by Foofoobar · · Score: 1

      It means that page, is loading and parsing PHP and PHP tags. If that was NOT a PHP page, that would not work. Expose_php is within the PHP.ini and NOT the APACHE.conf therefore you are looking at a PHP page and NOT a RUBY page (which is why they leave out the file extension for the page). If you knew anything about Apache, you would know this.

      --
      This is my sig. There are many like it but this one is mine.
    29. Re:Why rewrite existing systems? by turbidostato · · Score: 5, Insightful

      I just can't understand how your input data makes you assume your conclussions. Except from the "why change a system already working just OK?" which I'm 100% with you, I extract very different ones from your provided data:

      "In the mid-1990s, the company in question built their IT operations [...] They wrote much of their in-house code"

      I read here: in the mid 90s the company built a tailor-made IT system engineered by their internal knowledgeable technical staff.

      "what is somewhat unique is that they essentially continued to use those same systems up until 200what is somewhat unique is that they essentially continued to use those same systems up until 2006."

      We know their staff was knowledgeable and that the system fitted well their needs from the simple fact that it managed to work about 15 years without major complains.

      "One of the main reasons why they didn't switch is because their software systems worked just fine"

      Exactly what I was saying.

      "They even got extremely lucky in the first place, as the developers who initially designed and implemented their software systems did so in a way that allowed for the systems to easily scale"

      Do you think that's "luckyness"? That properly scalable systems grow up "per chance"? No: it was properly designed, that's why the system scaled, not because "luck".

      An now, for the problems:

      "A variety of consultants were apparently called in"

      I read here: A variety of *external* resources that surely couldn't know the bussiness better than their old internal counterparts (things cannot be done much better than "OK", and that was the standard to beat), and that surely held their own agendas (like pushing the technologies they are knowledgeable about, instead the ones that best fitted, if only because the old "for a man with only a hammer every problem seems a nail", if not worse, "Certified Microsoft Gold Partner That Gains Money Every Time Microsoft Technologies Are Pushed Into A Client") were in place to design the new system.

      And this is the very and only problem: By the 90's they had knowdledgeable internal staff. By 2006 they went to external unfitted consultors. I bet there's an untold story here that includes those "so expensive" Solaris sysadmins and C++ developers that were fired by a "smart" manager looking for profit. All the particular problems you outlined are not problems but consecuencies of this. Of course the new web-based GUI could be Firefox-tested -if knowledgeable people were in charge. Of course the new web-based GUI could make use of proper keyboard-based navigation -if knowledgeable people were in charge. Of course that the proper ammount of iron could have been pushed on the backed (specially after 15-more years of stats and usage-patterns) -if knowledgeable people were in charge.

      No one of them are strictily speaking problems with AJAX, or Windows, or dot-net, or whatever the technology (while going from a perfectly working C++/Unix environment to an all-and-only-Microsoft is a very hard hint about management going nuts). All of them can be pointed out to a very common tendency on IT: fire the old knowledgeable technicians that put the means for the company to grow and stay there in first place and contract cheap minions and expensive external consultants as substitutes; then look as a very smart manager that saves the company some pennies; then the obvious "???" and finally the "wreak havoc" instead of "profit".

    30. Re:Why rewrite existing systems? by tom's+a-cold · · Score: 1

      * Use mature, well-tested, effective software (eg. Solaris, Oracle, FreeBSD).

      I dunno about that. Has anyone used a major upgrade of Oracle when it first comes out? I'd say that FreeBSD is the most carefully-tested of those three. But a well-tested release of Linux isn't that bad either. If you meant "stay off the bleeding edge," well, yeah, good idea. But don't assume those big vendors are always that rock-solid either.

      * Avoid immature fad "technologies" like AJAX.

      Some AJAX toolkits and implementations are better than others, but there's so much diversity in client-side async scripting that one could argue that there's really no such thing as AJAX anyway. It's a marketecture. The AJAX problems your project had were the consequence of poor requirements and short-sighted design choices: nobody thought about which browsers needed to be supported so the developers (who seem to have had an irrational MS-only bias) guessed wrong. I've implemented sites using Dojo, and have had no problems with it supporting both Firefox and IE-- though there were some interesting bugs on Safari, which we were not required to support, though some home users turned out to want it after all. More of a corner case than yours (three users in a population of several hundred), but I learned from that mistake.

      * Traditional applications offer more flexibility than Web-based applications.

      If by "traditional applications" you mean "fat clients," I have to disagree. There are some things fat clients allow that are hard with web apps, such as disconnected operations and tolerable performance with lousy connectivity. Before good client-side web UI toolkits came along, fat clients also gave richer interactions. But those gains were at the cost of nasty deployment problems, DLL hell (or the Java equivalent), sensitivity to OS version and patch level changes, and risk that locally-stored data on client boxes could be lost or corrupted in the event of system failure. Many of the limitations of web clients are really symptoms of poorly-thought-out UI design rather than endemic features of the browser interface.

      * Always give much consideration to back-end scalability.

      But never prematurely optimize. It seldom works and you end up constraining yourself because of scenarios that never arise. Scalability, capacity, and performance requirements are certainly things a design needs to address. Sounds like those were not articulated on your project, so the designers just threw it together. By the way, while it's quite possible to make dumb choices in .NET implementations that will kill performance, but I've also seen .NET-based systems that handle huge volumes well. I have lots of other reasons to dislike MS technologies, but it's not inevitable that your problems are directly attributable to the choice of .NET. More to incompetent architectural decisions.

      * Sometimes a text-based interface is far more efficient than a GUI.

      You betcha. Even if there's a GUI, point-and-click is not optimal for frequent, repetitive, time-critical tasks. People who sit in front of a screen all day live by keyboard shortcuts. They'll go carpal on you if they're forced to drag and drop thousands of times a day.

      * Get user feedback on software early and often.

      ABSOLUTELY. This goes back to the earlier point about requirement validity. Do UI prototypes. Do proofs of concept. Get the UI in front of the users early, and be prepared to redo it if it sucks. The fact that your development team didn't do that is another sign that they were ignorant and arrogant.

      * Maintain a reasonable level of heterogeneity, when it comes to software, hardware and vendors.

      If you mean that it's good to have a diverse environment, that ain't necessarily so. Supportability's better when you have less diversity. But what IS necessary is standards compliance when imple

      --
      Get your teeth into a small slice: the cake of liberty
    31. Re:Why rewrite existing systems? by crucini · · Score: 1

      They also apparently gave zero thought to existing processes and staff skillsets.

      This is standard in Enterprise software. Larry Ellison championed the idea that Enterprise software should be judged by strategic impact, not by how much the data entry people like or dislike it.

      As for process, Oracle's attitude is that nonstandard processes are a liability, not an asset. If your processes are incompatible with Oracle, change them.
    32. Re:Why rewrite existing systems? by Mad+Merlin · · Score: 1

      If you actually read the link in the GP's post, you'd find out that he's not trolling. The PHP easter eggs only work on PHP pages, not any page served by a server that supports PHP. For example, compare http://otc.dyndns.org/foo.html?=PHPE9568F36-D428-11d2-A769-00AA001ACF42 and http://otc.dyndns.org/?=PHPE9568F36-D428-11d2-A769-00AA001ACF42

    33. Re:Why rewrite existing systems? by makomk · · Score: 1

      As foofoobar has pointed out, the evidence he's pointing to has nothing to do with the "mod_php" tag that pops up in various places if you have mod_php installed. It's based on a hidden easter egg whereby if you pass a particular GET argument to a page served by a PHP script it displays the PHP logo. I've tested it, and it doesn't work on static content, so I presume it wouldn't work on RoR scripts either (and there's no reason why it should, since PHP shouldn't be touching requests served by them them).

    34. Re:Why rewrite existing systems? by Tim+Browse · · Score: 1

      Well, it was a small stock control system for a company that would have maybe 10-15 users. So awesome performance etc wasn't an requirement. It wasn't a website with thousands of users or anything. It just had to work and not be really slow (i.e. when we did the monthly report queries, I'd rather they took a few seconds than an hour). If I remember correctly, the Zope DB extensions didn't support the version of mySQL that allowed transactions (or some similar nonsense), so a lot of that wasn't an issue, even if we wanted it to be.

      My point was, it was a stock control system, for crying out loud. People have been writing them for many years. Let's not 'innovate' ourselves into a corner for the sake of it. Hence, I tested the known working system (mysql) with typical data for typical use cases, and it worked fine (I didn't even have to set up specific indices to get decent performance). The other guy just tried to convince me with rhetoric that his way was better.

      Not surprisingly, he lost the argument.

    35. Re:Why rewrite existing systems? by jadavis · · Score: 2, Informative

      Examples of this would be (in database terms) referential integrity, unique values for certain fields or combination of fields.

      I agree completely.

      More generally, ActiveRecord does not address any interdependence of the tuples or relations at all (except for a few very common cases where they have no alternative).

      ActiveRecord is essentially a persistence engine at its core, with it's own OODBMS-like API on top (that is not closed over any useful set of operations). It blindly assumes that objects are independent of eachother, and can be created, updated, or deleted without regard to the rest of the data. There are some special cases that are addressed, but they are far from complete. In general, ActiveRecord does not even know how to handle database errors, even though the SQLSTATE error codes are defined in the SQL standard. It doesn't expect errors aside from the few special cases.

      It has no regard at all for potential race conditions with another application accessing the same data. In fact, it assumes that it's the only application accessing the data, and the data therefore really has no meaning outside of the context of the ActiveRecord application.

      --
      Social scientists are inspired by theories; scientists are humbled by facts.
    36. Re:Why rewrite existing systems? by An+Onerous+Coward · · Score: 2, Insightful

      I was disappointed too.

      There were some rumblings about the incredible performance of the new PHP system, but no mention of how the Rails version was performing by comparison (it sounds like it never went live).

      The "integration" point seemed to be claiming that the only way for the transition to work was for Every Single Line of PHP to be removed from the system simultaneously, but it should be possible for different portions of the site to run in different languages.

      The "don't want what I don't need" point sounds sensible, until you decide to go adding arbitrary features. Then it's kind of nice to have some well-tested shortcuts that someone has spent a lot of time testing.

      I'm sure he could spend a lot of time and detail justifying the points he tried to make, but these brief descriptions seem nigh unto trollish, and are practically begging for pat answers like "What about connection.execute()?" which the author doubtless has already considered. I just want to know WHY connection.execute() wasn't working for him.

      --

      You want the truthiness? You can't handle the truthiness!

    37. Re:Why rewrite existing systems? by rdean400 · · Score: 1

      Rewriting an existing system only makes sense if either the benefits outweigh the costs, or there is a high level of risk to staying on the base system (i.e., the hardware or software is no longer supported).

      Other than that, most overhaul/modernization efforts should be focused on making the UI more accessible to end users and interoperable with other systems.

    38. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0

      You're the idiot - grandparent doesn't even mention curses...

    39. Re:Why rewrite existing systems? by Evets · · Score: 2, Insightful

      I think some of the other major lessons are as follows:

                      * Use mature, well-tested, effective software (eg. Solaris, Oracle, FreeBSD).
      Absolutely, and this should be a given but it isn't always.

                      * Avoid immature fad "technologies" like AJAX.
      There are plenty of people here who would defend AJAX and blame the developers for a poor implementation, but really the point to be made is that if you are going with something that is new to the environment your research needs to be thorough and you need a lot of usability testing.

                      * Traditional applications offer more flexibility than Web-based applications.
      Very true, but the benefit of a web application is easy deployment/easy updating and hopefully OS independence. Many companies are pushing for web based apps but they are ignoring the initial premises that led them down that road. If you are doing a web based app, there is no excuse for at the very least supporting Firefox. And you have to pay attention to screen readers / accessibility issues.

                      * Always give much consideration to back-end scalability.
      This is another common gotcha in corporate environments. I see more than my share of apps that are highly scalable, but the licensing costs associated with scaling are enormous. Just because an application supports a load balanced environment doesn't mean that you are going to get linear performance increases by throwing more hardware at it.

                      * Sometimes a text-based interface is far more efficient than a GUI.
      Sometimes? Always. Any application that requires a person to interact with it during their entire workday needs to be designed in such a way that you can use it without a mouse. It seems like such a simple task, but it is so frequently ignored. Sometimes a software solution isn't the best solution at all - everyone WANTS things in computers, but when the development project costs more than two years of temp monkeys pushing paper to get the job done, you should think long and hard about creating an internship program instead of throwing money at a software project.

                      * Get user feedback on software early and often.
      This one is often ignored because third party companies don't share their intermediary results and project managers cut out the end users because of historic cooperation problems coupled with agressive roll out timelines. End user communication should be in the hands of somebody dedicated to the task and project planning should account for user feedback delays. If you really have to move forward without the delays, the push should be for dedicated time from a group of end users instead of cutting them out of the loop all together.

                      * Maintain a reasonable level of heterogeneity, when it comes to software, hardware and vendors.
      I would argue that documentation is more important, and independence from vendors in order to perform maintenance and implement high level enhancements / bug fixes. As long as you have good in-house knowledge about how a system works and the decisions that went into laying out the requirements you should always be able to work with another vendor for a replacement system. It might be painful and expensive, but it is important to have the option.

    40. Re:Why rewrite existing systems? by Sciryl+Llort · · Score: 1

      # So every time you stumble never grumble.
      Next time you'll bumble even less!
      For up from the ashes, up from the ashes - grow the roses of success! /#

      But seriously, I'd hope to notice it's going pear-shaped in a bit less than two years.

    41. Re:Why rewrite existing systems? by Almahtar · · Score: 1
      You say you disagree with the majority of his points except the two you talked about. I'd like to discuss that...

      So you're telling me you disagree with

      Use mature, well-tested, effective software (eg. Solaris, Oracle, FreeBSD) ?

      No discussion necessary.
      Also, he didn't say "avoid ajax", he said

      "Avoid immature fad "technologies" like AJAX" He's making a generalization and using Ajax as one example. Also, he doesn't say to do so at all costs - he's saying "as a rule of thumb". I agree - new technologies are great and should be encouraged, but not trusted with the fate of your business(unless your business is new technology). I know he didn't phrase it that way, so I can see how you could disagree, but I think that's what he meant. Regardless, I think it's a reasonable rule.

      "Traditional applications offer more flexibility than Web-based applications" I can see how you would disagree with this - traditional apps and web apps offer different kinds of flexibility. To say one is "more flexible" than the other really depends on your needs.

      "Sometimes a text-based interface is far more efficient than a GUI." Why you would contest this is beyond me - to disagree with this point is to say 'no text based interface is ever more efficient than a gui'. Take, for example, a command line. If I know what I want, I can just type a word and I've got it - no need to open the "everything" menu, select the "category I want" sub menu, select the "particular program I want" submenu, select the "configuration options" option, check a check box, hit "ok". If your hands never have to leave the keyboard you can drive a computer much faster. By muscle memory, your hands can remember where the 'r' key, the 'q' key, etc are. If you have to click a button ("say, the OK button") that will be at a different place on different dialogs in different programs, and the programs can move around the screen based on where the windowing system wants to put them, muscle memory is useless to you. I can think of a few console programs that I'm glad just stayed as console programs.

      "Get user feedback on software early and often." This is a point you agreed with, but then you stated that the main problem with the project was "poorly specified requirements". I agree with you that this was a problem, but getting user feedback early and often really serves to regulate poor initial requirements.

      " Maintain a reasonable level of heterogeneity, when it comes to software, hardware and vendors." This one can be contested, I understand - but it should be noted there are cases either way. On one end, homogeneous technologies offer great integration. On the other, if you can meet all your needs with heterogeneous technologies and do so well, you maintain MUCH more flexibility and a much greater set of options. If you can get "cat" server and "dog" client to work well together, you know dang well you could switch to "dog" server or "cat" client and work just as well - so now they have to give you a better reason than "well... you're using a bunch of our other products, so you should use this one too." - they have to compete on merit. That leaves you with LOTS of options, and is a Good Thing(tm).
    42. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0

      > It's based on a hidden easter egg whereby if you pass a particular GET argument to a page served by a PHP script it displays the PHP logo.

      You can't be serious. Yay, yet another reason to dropkick PHP from any consideration in any project.

    43. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0

      Curses is actually a TUI, as it has no graphical elements; c.f. http://en.wikipedia.org/wiki/Text_user_interface
      Now what, motherfucker? ;-)

    44. Re:Why rewrite existing systems? by mosch · · Score: 1

      This url does not work. The parent claims it should.

      That said, even if RoR had a few PHP pages, that would not indicate that RoR is incapable of serving high loads... it might just mean that there is no legitimate reason for that page to be backed by rails (nothing particularly dynamic, etc.)

      Everyone on slashdot is an idiot, and you're proof of why. You not only defend a wholesale attack based on a single, pointless fact, but you do so even when that fact isn't true.

      Thanks for reminding me why this site is useless.

    45. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0
      Your experience and that of TFA are great experiences to learn from but, honestly, what does any of this have to do with Rails?

      The title 'Thinking about Rails? Think Again' seems to imply that there is some danger lurking out there, waiting to punish developers who choose Rails. To me, all of these experiences say that people didn't use "the right tool for the right job." Rails is certainly not for everyone and it won't solve everyone's problems.

      This sounds like yet another case of someone believing that some new technology is the 'Silver Bullet' that's come along to change the world and solve everyone's problems. It's just not going to happen.

      From TFA, if Rails isn't built to 'you tastes,' why in the world would you use it? Personally, I love Ruby and I love Rails and I use them when it makes sense to do so. I've even built console and GUI bases apps based on Rails. Why? Because Rails gives you a lot of out-of-the-box functionality, an active community, and an ever-growing set of plugins (same with Ruby, itself), that it often makes sense to use it for little web, console, and GUI apps, here and there.

      Again - use the right tool for the right job. @Work, I use .NET for everything on mostly Windows systems, and our primary app is ASP.NET. @Home, I code mostly in ruby (or .NET), all on linux systems. For clients, I do a lot of php because that's what they're already using, that's what their coders know, so it makes sense to use it. I've also used a good bit of ruby for web sites, without rails, but I usually find myself coming back to Rails, otherwise I end up recreating similar functionality anyway.

      Some direct responses to TFA ...

      #1 - "IS THERE ANYTHING RAILS/RUBY CAN DO THAT PHP CAN'T DO? ... (thinking)... NO."
    46. Re:Why rewrite existing systems? by remitaylor · · Score: 1

      *shakes head*

      Submit and Preview look *so* similar sometimes, ... don't they?

      Nevermind! As many, many, many others have pointed out ... the thoughts in TFA are pretty lame. If the whole company uses PHP, why did you use Ruby? If you like your own 'little self-made system,' why did you choose Rails? Is there anything Rails can do that PHP can't? Well ... yes, in a way. Rails is a framework and PHP is a language. A better question would be ... can Rails do anything that CakePHP (or another similar framework) can't? Or can ruby do anything that PHP can't? Well, the answer to both of those questions might be Yes but, if YAGNI (You Ain't Gonna Need It), then why bother?

    47. Re:Why rewrite existing systems? by Kjella · · Score: 1

      The guy is being paid a monthly fee and has no written specification or brief. He has no deadline and no agreed feature set.

      In other words, you have crap management. Ok, so the bosses are clueless about technology but you get that all the time from those doing the leg work on IT systems so I'll take that with a grain of salt. But unless they've put up some *business* goals, features, use cases and a timeline so they can ask completely non-technical questions on whether you're meeting the deliverables, they suck at management in general. If they haven't got a clue what they want, so that they won't say "Look it's great that you're solving a problem we don't have, but why are you working on this instead of delivery X that's two months overdue?" then they don't know how they'd like to manage their business. To me it sounds like a missing business case, not lack of technical understanding.

      --
      Live today, because you never know what tomorrow brings
    48. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0

      This is normal, u38cg, and is the natural way of things. When the leaders in a company stop listening to their own tech people, and start getting sold on ideas from outside consultants, the company begins its downward spiral which eventually ruins the company and makes room for new better-managed companies to take its place.

    49. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0

      > > "They even got extremely lucky in the first place, as the developers who
      > > initially designed and implemented their software systems did so in a way
      > > that allowed for the systems to easily scale"
      >
      > Do you think that's "luckyness"?

      I think the OP meant that the company got lucky in having good people to
      design and implement the first system.

    50. Re:Why rewrite existing systems? by lena_10326 · · Score: 1

      I don't think the web model works well for frequent data entry or data manipulation tasks. Before I finished college, I worked a few various jobs requiring data entry so I can appreciate how effortless a good curses or DOS application can be. That's because those applications were designed for maximum workflow efficiency from the start. Their focus was not glitzy design but boring data organization and being smart about filtering options to the context of the task.

      There's nothing wrong with glitzy design because it has a purpose when it's used properly. If your client base is composed of infrequent users, then good web design will naturally guide them to understand the data organization. But in terms of workflow, the glitz gets in the way. Consider that a web page might place a form in a tab that slides out when you mouse over. When you mouse out, it slides back to hide. This helps hide a complex feature from the overall design so users can understand what high level functions are available, such as edit my details or shop for product XYZ. That sort of feature would only hinder an experienced data entry worker who has years of experience with the business and the system. A data entry person will usually be more efficient when the data is presented in tabular grid (boring) with no IO pauses or animated transitions to get in the way.

      The other thing I'd consider is a curses application is like a desktop application when it comes to data access and session state. Converting a desktop application to an AJAX/web application is certainly not as straightforward as executive management would like to think. Even with pulling data down into the browser, there are still issues of managing delay and not having a direct connection to the database. For example, a CGI based application never knows if the user will be back or commit their changes, but a curses or desktop application generally maintains a continuous socket connection so it can perform more intricate operations such as lock a record while it's being manipulated by the user. Do that in a web form and you can end up in trouble.

      Desktop apps are usually more complex and difficult to build but can be worth it for complex DB interaction. An AJAX web application bears the complexity of a thick desktop client, but not the power. An AJAX app will always be a 3-tiered system at minimum. More tiers, more complexity. I think AJAX excels in data preview not data entry or manipulation.

      The managers and developers designing that new system simply never considered how the workflow of the user would be benefited. It sounded like they were only concerned about upgrading the technology, so they treated it more important than workflow and ended up changing the core design with the unintended side-effects of that technology. Had I been present in those meetings, my first questions would have been: what does it fix, why is it needed, and why would that be better?

      I'm not convinced an AJAX web app is futile in this case, but implementing one without understanding what makes a data entry worker efficient is just plain ignorance.

      --
      Camping on quad since 1996.
    51. Re:Why rewrite existing systems? by PopeRatzo · · Score: 1

      I'm not saying you're an idiot, just that you remind me of one


      Tim, take comfort knowing that industry runs on small-minded people who only care to see one step in front of them. It goes all the way to the top, too, in CEOs that only care about the quarterly stock price.

      You'll always have a job. You won't innovate, but you'll keep the machines running. I say this as a sincere compliment. We can't all be innovators. Some of us have to be drudges or who would keep the "vanilla stock control app(s)" running? Yours is an important niche.
      --
      You are welcome on my lawn.
    52. Re:Why rewrite existing systems? by History's+Coming+To · · Score: 1

      I work for a large national book company. Our multi-site database, tied in with the website, runs on a VERY old DOS system. All our machines at work run on 95 simply so they can properly handle the single most important piece of software we use.

      Know what? It works brilliantly. Yes, on personal preference I'd rather be using a LAMP based system, but to be honest I think that this particular application runs better under DOS than anything else I can think of. It's tried, proven and trusted.

      --
      Please consider this account deleted, I just can't be bothered with the spam anymore.
    53. Re:Why rewrite existing systems? by bit01 · · Score: 1

      The choice of Text based UI versus GUI is also silly. A well designed GUI app is just as usable via keyboard as a text one, it's just a different presentation framework.

      No, on the same hardware a GUI will be slower than text based. If throughput is needed that can be a problem. I've seen countless businesses switch from text based to GUI frameworks and experience drastic slowdowns as a result.

      Sometimes the problem can be fixed by throwing more hardware at it but often it's intrinsic to the GUI desktop paradigm; GUI's try to be all things to all people and that often means it's sub-optimal for special purpose, high throughput applications. e.g. One of the main reasons vi is still used despite it's bizarre command set is because it is still far faster than any of the GUI alternatives.

      ---

      Don't be a programmer-bureaucrat; someone who substitutes marketing buzzwords and software bloat for verifiable improvements.

    54. Re:Why rewrite existing systems? by Mad+Merlin · · Score: 1

      You make far too many assumptions.

      That that url doesn't work only shows that either expose_php is off, or that the page isn't powered by PHP. Allegedly it did work at the time of that blog posting, and given that every single other 37 Signals website is powered by PHP, it seems pretty plausible that rubyonrails.com also uses PHP. Regardless, I don't particularly care either way about that point.

      You attacked the original poster's method, saying that it would give false positives, which it clearly does not. I pointed out the flaw in your argument, and you assumed that that somehow meant that I agreed with the original poster, which I do not (I don't disagree either, however).

      I'm not defending anything, I'm merely pointing out the blatantly wrong.

    55. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0

      "...the people who make major strategic decisions on IT don't have a clue what they are talking about."

      I believe you left out a few words in the above quote:

      "...the people who make major strategic decisions on IT AT MY COMPANY don't have a clue what they are talking about."

      Or maybe you think ridiculous, sweeping generalizations help get your point across.

    56. Re:Why rewrite existing systems? by zullnero · · Score: 1

      From what I can see, you had problems with the old systems, so you are recommending that people keep their old systems, or bring in new hardware that runs software that isn't even still supported by the manufacturer?

      What the real problem looks like is that the company didn't define EXACTLY what they wanted to begin with. They brought in some consultants, who probably didn't have all the requirements they needed, and they probably implemented a cookie cutter solution because it seemed to meet requirements and they were probably just following Microsoft standards (many consultant firms that Microsoft partners are MCSEs and such, and that's just how they roll). The problem there seems entirely one of extremely bad communication, outdated design, a lack of up-to-date functional knowledge of the technologies being applied, and seriously lacking requirements.

    57. Re:Why rewrite existing systems? by TheLink · · Score: 2, Interesting

      Yeah, MySQL would have been a better choice than Zope.

      But, if the company grows and its database can't do it gracefully then there will be big problems. MySQL is like PHP, it will look ok when you're testing some small stuff, but when you really want to do things properly it gets really difficult (it might still be possible but its difficult and to use the technical term for it - very yucky/icky).

      For example: Say it's X years later, and after a few "problems" the company (now bigger) decides it does need to do live backups. So now you want consistent backups of a bigger database (say tens of gigs), and you need to do it without slowing the reporting, orders and deliveries etc too much (it's stockkeeping like you said).

      If you picked MyISAM, in a naive system then you'd need to lock _all_ tables otherwise the mysqldump won't be consistent. But locking all the tables blocks stuff...

      If you picked innodb, you don't have to lock all tables (yay!). But when stuff goes belly up, and you try to _restore_ from backups, you may find that the estimated time it takes to reload in X gigabytes of data into the innodb tables is more than "a few" days, which is not what you want to tell the boss or your customers (don't ask me how I know this - and it wasn't even _my_ problem). On a related note it seems that innodb has performance problems with concurrent inserts if you have autoincrement fields (weird but true).

      So one workaround is to use MyISAM, buy two or three machines. Live data = master, and nonlive reporting and backups on slaves. You can lock all the tables on a slave to make a consistent snapshot and not stop the master (basically you are badly reimplementing MVCC).

      The recommended option of course is don't use MySQL. Forgive my ranting, but the fewer MySQL systems out there, the lower chance of me one day inheriting yet another crappy MySQL system.

      Same goes for PHP too - braindead bad designs like magic_quotes, addslashes. Then there's peardb vs pdo vs mysql_escape vs mysql_real_escape vs mysql_definitely_real_escape_this_time_no_really. OK last one's a lame joke (for now?) but so's much of PHP.

      Sure mod me flamebait, but mysql_real_escape says it all...

      --
    58. Re:Why rewrite existing systems? by szobatudos · · Score: 1

      Back in 1998 I was working for a large German company. In their IT centre they had the motto: "never touch a working system". And they knew this for good reason: they had a mainframe that was doing its work since 1970. I guess it works still.

    59. Re:Why rewrite existing systems? by amorsen · · Score: 1

      No, on the same hardware a GUI will be slower than text based.

      If the hardware happens to support text mode. The Amiga could do a perfectly usable GUI with a 7MHz M68k, and the comparable Apples weren't that much slower. That doesn't mean I want to go back to those, or to text mode.

      --
      Finally! A year of moderation! Ready for 2019?
    60. Re:Why rewrite existing systems? by bit01 · · Score: 1

      ... The Amiga could do a perfectly usable GUI with a 7MHz M68k, ...

      Agreed. Modern GUI's are bloated beyond belief, often being slower than the Amiga GUI on 2+ orders of magnitude faster hardware.

      Unfortunately however that's what we're stuck with for now and that's why text mode, even simulated text mode like modern vi uses (avoiding slow window operations), may be a good choice for some applications.

      Some people have what I feel is a prejudice against text mode applications however if they're serious about it they should really give up text full stop. Nobody's going to do that right now as text is still the best tool we have for many problems and GUI decoration is simply not relevant. I can see one day in the future where there's no such thing as written text, it's all computer mediated video's, sound and graphics, but we're nowhere near there yet.

      ---

      Stop using tab characters in your code!

    61. Re:Why rewrite existing systems? by mcalwell · · Score: 1

      Avoid immature fad "technologies" like AJAX Ajax is no big deal, it just means that you can now use browser based apps to do the job that were only really practicable for GUI apps previously. You can make a monster out of AJAX, or just use it sparsely in conventional pages to do things like table updates.
    62. Re:Why rewrite existing systems? by bckrispi · · Score: 1

      In their IT centre they had the motto: "never touch a working system".
      Translated into German: Das computermachine ist nicht fuer gefingerpoken und mittengrabben...
      --
      Xenon, where's my money? -Borno
    63. Re:Why rewrite existing systems? by oliderid · · Score: 1

      It looked to me that the main problem was the database legacy. He pointed out difficulties with SQL queries and Rails.

      His legacy code wasn't Object oriented. Ruby is. Such a big conceptual change, Usually means that you have to redesign a database. I don't if he did it (i guess not).

      If Ruby needs dozens of queries to build common objects, you are in serious trouble with such a traffic.

      It pointed out his 7 reasons. I've got only one so far:
      The relative small number of hosting companies providing it per default. Not all projects require a dedicated web server, most only needs a virtual host.

      The Ruby availibility is way below other factors such as a phone number or personal email of one of their sysadmin, confidence, reliability, bandwidth or the fact that the hosting company must be located in my country (for any legal issue), etc.

    64. Re:Why rewrite existing systems? by aproposofwhat · · Score: 1
      You owe me a new keyboard - this one isn't very coffee proof :)

      --
      One swallow does not a fellatrix make
    65. Re:Why rewrite existing systems? by Matey-O · · Score: 1

      But what if the company is state government? I doubt we'll see a coup d'état anytime soon.

      --
      "Draco dormiens nunquam titillandus."
    66. Re:Why rewrite existing systems? by shenanigans · · Score: 1

      I think the OP meant that the company got lucky in having good people to design and implement the first system.

      I disagree - as he pointed out, getting and keeping good people is not "luck". And losing them was certainly not "bad luck", but bad management based on short-sighted thinking and lack of understanding of what is really valuable in your business (assuming the lay-offs is what happened, which seems likely.)

    67. Re:Why rewrite existing systems? by wolenczak · · Score: 1

      Virtualize the client computers with VMWare and forget about old hardware and non-existent device drivers, been there, done that. even OS/2 in experimental mode under VMWare works just fine for both client and server.

    68. Re:Why rewrite existing systems? by Richthofen80 · · Score: 1

      A ha! now you know why us kooky small-goverment libertarians are running around screaming all the time! When bad management is hired, you can fire them. When bad management is elected, you issue more bonds!

      --
      Reason, free market capitalism, and individualism
    69. Re:Why rewrite existing systems? by man_of_mr_e · · Score: 1

      I already responded to these further down the thread. Read what I wrote there.

    70. Re:Why rewrite existing systems? by man_of_mr_e · · Score: 1

      I can think of very few applications in which text-throughput is an issue. I mean, if the throughput is is slowed down that much, then the data is going by so fast the user can't read it anyways. Which tells me that the data doesn't really need to go to the screen at all.

      Take, for instance, a vt100 terminal connected to a mainframe that spews forth pages and pages of text. Most likely, that text doesn't need to be drawn to the screen, it could be dumped to a buffer and read (one screen at a time) or printed from that.

      Can you provide an example of a use that REQUIRES text throughput to the screen?

    71. Re:Why rewrite existing systems? by man_of_mr_e · · Score: 1

      I agree with you, but the problem comes down to assessing the benefits vs cost. Ask nearly any programmer who's stuck maintaining code he didn't write and he'll tell you that the maintenance costs of maintaining the old code will be too high, and a rewrite needs to occur to reduce maintenance costs. Of course, even if that happens successfully, the next programmer put on maintenance will say the same thing of the new code.

      It's often very difficult to migrate an application, piece by piece, to a new design. Look at Microsoft Office, for example.

    72. Re:Why rewrite existing systems? by chochos · · Score: 1

      I think Rails didn't work for him, mainly because it works very different from PHP and you need to do things differently. Plus, reason #5 is pretty much all you need to know... "it's built to my tastes" means "I'm used to code in PHP so it was easier for me to rewrite the whole thing in PHP again, using what I've learned over the years, instead of switching to a new language/framework".

      But the same thing applies to anything. He couldn't have ported it to Java with any of the numerous web frameworks out there, or to python or anything else, because he's a PHP programmer. And a Java developer would also probably end up rewriting his own app in Java again, with a different architecture, instead of switching to something else he's not familiar with.

    73. Re:Why rewrite existing systems? by CommandNotFound · · Score: 1

      If the hardware happens to support text mode. The Amiga could do a perfectly usable GUI with a 7MHz M68k...

      I'll disagree with you on this point, and it was one that annoyed me about my Amiga 2000 back in the day. Text scrolling was at the CLI was S-L-O-W compared to my Tandy 1000 (8088), even with FastFonts loaded. Other than that though, how I miss my old Ami...

    74. Re:Why rewrite existing systems? by jhantin · · Score: 1

      It's often very difficult to migrate an application, piece by piece, to a new design. Look at Microsoft Office, for example.

      Microsoft Office is a very atypical example though -- they're trying to maintain ~10 years of backward compatibility while moving the design forward. In any case, though, the usual cause I've found for difficulty changing the design of existing software is a combination of poor/insufficient/leaky abstraction and a crippling shortage of test resources.

      The poor abstraction is often caused by people who can manage to write COBOL or FORTRAN style code in whatever language you put in front of them. 5000 line methods chock full of if, switch, and such. One shop I've worked at had one such routine -- in Java no less -- consisting of if (customerID == foo-id) { do-foo-special-work; } else if (customerID == bar-id) { do-bar-special-work; } else ... on and on for pages.

      The lack of test resources is more of an organizational problem. When the pointy-haired boss dictates that there will be one tester per 12 programmers, and that that tester will be in another city if not on the opposite side of the planet, and you will not be given time to build a test framework... well... sorry, and thank you for playing.

      --
      ...when you're writing a game...tweak the difficulty of "Easy" to something [your mother] can cope with. -- onion2k
    75. Re:Why rewrite existing systems? by amorsen · · Score: 1

      I'll disagree with you on this point, and it was one that annoyed me about my Amiga 2000 back in the day. Text scrolling was at the CLI was S-L-O-W compared to my Tandy 1000 (8088), even with FastFonts loaded.

      That was a problem with the terminal though. CED could fill the screen at what seemed to me to be 60Hz.

      --
      Finally! A year of moderation! Ready for 2019?
    76. Re:Why rewrite existing systems? by man_of_mr_e · · Score: 1

      In my experience, software is almost *ALWAYS* late. Even when it's not. Typically, most companies cannibalize testing time for development time, extending the development time and shrinking testing time so they can meet the schedule (or something aproximating it).

      This is a result of many things, but the largest being that most shops are expected to give a firm estimate when they have the least amount of knowledge about what they're doing. This is because the users expect that when they say "it'll take 12 months" that it does, in fact, take 12 months.

      Look at Microsoft. They get royally roasted every time they slip their schedule. So much so that they were forced to ship Vista before it was ready in order to appease the public. And don't say "5 years wasn't enough?" because things changed after Vista development started, all the requirements changed, security became a huge priority, retraiing, redesigns, re-doing XP and Windows 2003, etc.. Vista, when they finally got to work on it in earnest only started in late 2004 after all that other stuff was done. What's worse is that this fixed schedule likely forced many design compromises to get it done on time, not just shipping before it was ready.

    77. Re:Why rewrite existing systems? by Mattintosh · · Score: 1

      newer programmers don't understand pointers and curses.

      While older programmers understand that they're the same thing.

      Example: "I'm gonna char* your mom in the int*!" "Oh yeah? Well your mom is a char*-ing void* with a int[] like a horse!"

    78. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0

      Fair enough really, anyone who does data entry are fucking semi-literate scum.

    79. Re:Why rewrite existing systems? by philam3nt · · Score: 1

      Yes, there is a giant gap between the knowledge of what CAN be done with IT, and what SHOULD be done. I, on the other hand, implemented a great web-based ERP (webERP) over the weekend because my company doesn't yet realize what they need, so it's not yet in the budget!

      I now have the reverse of your company: an ERP system that works great, but nobody knows they need yet! You should have your people call my people.

      Charles
      doublerebel.com

      --

      If I had a sig, this is where it would be.
    80. Re:Why rewrite existing systems? by DragonWriter · · Score: 1

      Even worse, there's absolutely nothing there about why Rails didn't work.


      Its not all that clear to me that Rails "didn't work", so much as:
      1) Rails wasn't necessary because PHP did work,
      2) Rails wasn't desirable because the priorities for the project were out of line with the strengths of rails (direct SQL was important to the author's approach, the author had hand-tailored code that did what was necessary and nothing else and wanted to keep it that way, and, perhaps most importantly,
      3) The whole idea of complete, all-at-once replacement was disruption that wasn't really desirable.

      The article provides nothing useful to anyone looking to build a web site.


      Since the problem wasn't with building a web site (the author says he's looking forward to using Rails on a fresh project), but with reimplementing an existing large production website with minimal disruption, that shouldn't be a big surprise.

      How do I know if PHP is superior to Rails for my particular application?


      Judging from TFA, if you have a large existing production application in PHP that does essentially what you want, its probably a better idea to clean it up bit-by-bit using ideas from Rails than to reimplement in Rails.

      For a new project? Well, TFA won't give you much of a clue on that, because that's not something the author has tried Rails for yet.

      This is nothing but a senseless rant.


      I don't think its a "senseless rant", I think it illustrates something that sometimes gets overlooked in the enthusiasm for the new, shiny thing out there: if you've got something that works, your often better off learning from other approaches and adapting them to improve your existing codebase than adopting something new and rebuilding from scratch. Now, the title of the Slashdot article, which suggests that this is somehow a reason not to use Rails in general, is senseless, but then having poorly-considered titles on Slashdot is hardly something new.
    81. Re:Why rewrite existing systems? by DragonWriter · · Score: 1

      For example -- I would have to create additional unique SQL constraints in the database migration files, in some cases, I have to write out the SQL directly -- bypassing that which is Rails.


      Writing out SQL directly is not "bypassing that which is Rails". AWDR makes this pretty clear; the intent of Rails is not to follow the "SQL is evil" mindset, but to abstract and make portable that part of the SQL that can productively be abstracted out and made portable. Now, there are applications that, given how much Rails does abstract, can do without much, if any, direct SQL with Rails (particularly if they avoid database-level constraints), but its not subverting Rails to use direct SQL where it is appropriate for an application.

      Then the Model would not only have to run the extraneous SQL statement to check for uniqueness, but also be modified to accomodate the error handling that is going to happen when you violate the database integrity.


      If the constraints are added as additional SQL to the migrations as either table constraints or database triggers, I don't think the model has to do anything. Rails built in error handling should fire an exception on a failed update or insert, which should generally happen and be handled in the controller, right? And if you are handcoding in MVC style without Rails, in any language, that's still going to be the case, right? Rails may not add much to this, but it doesn't seem to me that it really fights you in it, either.

      I agree, though, that the MySQLcentrism of, apparently, both the applications which spawned Rails and most of the Rails books and tutorials to date tend to give the impression that Rails is hostile to database-level integrity constraints, but I think as a practical matter Rails is more neutral to them (in that it doesn't abstract them into some portable form, but doesn't prevent you from using them). It seems more hostile to tables without simple integer primary keys...

    82. Re:Why rewrite existing systems? by aevans · · Score: 1

      That's a bug in slashdot. Why should anyone work around it?

    83. Re:Why rewrite existing systems? by Almahtar · · Score: 1

      I'll check out what you wrote. Thanks for letting me know so I could follow up.

    84. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0

      The only two that I agree with is giving

      "are giving".

      a failed project whos real failure

      "whose".

      Certainly, Web UI's are not

      "web UIs".

      Avoiding AJAX or any other technology because you tried to use it for something it wasn't good at is patently stupid.

      Using AJAX in any form is patently stupid, because any person who cares about security will have JavaScript disabled in his/her browser (because 90-95% of browser security issues involve scripting), and thus will not be able to use a site that relies on AJAX.

    85. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0

      GUI's try to be

      "GUIs".

      e.g. One of the main reasons

      "E.g., one".

      despite it's bizarre

      "its".

    86. Re:Why rewrite existing systems? by mosch · · Score: 1

      I'll respond using small words, so that your tiny little mind can understand.

      The parent claimed that RoR cannot be used on high-volume sites, and his only evidence was that PHP may be used in some portion of the stack of some sites. I was attacking this assertion by noting that the trick does not work (and expose_php does NOT affect this one. You're just wrong about that.)

      I also noted that even if there was some use of PHP, it would not be a condemnation of RoR's scalability anymore than the use of a shell script on a Unix box would be a condemnation of programming in C.

      So keep on thinking you're clever if you want, but you're not. You're missing the point, arguing the wrong issues, and despite all that you still manage to be factually incorrect.

      Fucking typical slashdot idiocy.

    87. Re:Why rewrite existing systems? by jcoleman · · Score: 1

      The time has come for you to either change your organization or change your organization. (credit to Scott Ambler)

    88. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0

      Oops. now astroturfer aevans forgets to post AC to support his above goof. See examples of his previous MS support here or here.

      To answer your question, open source coders have learned to check their work because they know other people see it. That's why we hit preview.

    89. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0

      No, it's not. To get the effect that the AC did, you have to actively changed the post type from Plain Old Text (the default for an AC) to HTML Formatted.

      * plaintext
      * lists
      * work
      * fine
      * if
      * you
      * choose
      * the
      * correct
      * format

      Slashdot saved the post as the AC posted it and the browser is properly handling multiple adjacent whitespace characters in the poster's HTML.

      The text is displaying exactly as it should given the criteria that the user selected and the data the user input. It is expected, normal behavior (in fact, it's a documented STANDARD behavior).

    90. Re:Why rewrite existing systems? by Mad+Merlin · · Score: 1

      I was attacking this assertion by noting that the trick does not work (and expose_php does NOT affect this one. You're just wrong about that.)

      Yes, and you're wrong. I just verified it with both PHP 5.2.2 and 4.4.6, and expose_php most definitely does affect the previously mentioned urls, in that with expose_php = Off, the easter eggs cannot be produced.

      So keep on thinking you're clever if you want, but you're not. You're missing the point, arguing the wrong issues, and despite all that you still manage to be factually incorrect.

      I'd tell you the same thing, but I'm guessing you'll continue not listening.

    91. Re:Why rewrite existing systems? by aevans · · Score: 1

      Actually, the only failed experiment is one you try that fails. If you don't try it, you didn't fail the experiment. It may pass or fail if you try it in the future, but you might have spent your time more wisely doing something else -- even possibly a different experiment where knowing the outcome is more valuable.

    92. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0

      That's pretty funny.

      You're defending the premise that RoR is not scalable, and that this is provable because some RoR sites might also use PHP for a portion of their infrastructure.

      As such, it doesn't really matter what I write. Your logic is so completely and totally deficient that it doesn't matter if I'm wrong about expose_php (which I'm not. I just checked my PHP installation, and I am correct.)

      DIAF!

    93. Re:Why rewrite existing systems? by Fulcrum+of+Evil · · Score: 1

      I work at a decent sized company. We have a number of internal sites running on linux for various things; the only one that routinely pisses me off is an Oracle App thing that requires IE for some godforsaken reason. Fuck Oracle. Fuck them right in their ear.

      --
      "We returned the General to El Salvador, or maybe Guatemala, it's difficult to tell from 10,000 feet"
    94. Re:Why rewrite existing systems? by Fulcrum+of+Evil · · Score: 1

      From the comments:

      I never said "the project was cancelled because of limitations of Rails" - more like I spent two years trying to make Rails do something it wasn't meant to do, then realized my old abandoned language (PHP, in my case) would do just fine if approached with my new Rails-gained wisdom.
      That's all.

      --
      "We returned the General to El Salvador, or maybe Guatemala, it's difficult to tell from 10,000 feet"
    95. Re:Why rewrite existing systems? by B'Trey · · Score: 1

      Please explain the difference in a "limitation of Rails" and "something Rails wasn't meant to do." If Rails wasn't meant to do task A, whatever A happens to be, how is it incorrect to say that doing A is a limitation of Rails?

      --

      "The legitimate powers of government extend only to such acts as are injurious to others." Thomas Jefferson.

    96. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0

      What I would have proposed in this situation, if the back end was working well, however they wanted a new UI front end, would be to write a new front end that worked with the existing back end, and kept the old back end. This way as well, the new web based UI would still be avialable, but also the existing text based interfaces would also be available. The web front end could have simply used the text based interface to feed the back end data, or accessed the existing databases directly. The users could then use whuich UI they felt was the best.

    97. Re:Why rewrite existing systems? by Anonymous Coward · · Score: 0

      Ah, the difference between a "blue sky" research mentality, and an "engineer for benefit" only mentality.

    98. Re:Why rewrite existing systems? by Fulcrum+of+Evil · · Score: 1

      Easy - rails has a particular way of doing things - if you try to accomplish a task some other way, it'll be harder and not work as well. The original poster as much as admitted that the limitation was in his skill as a developer, which was what I awas trying to convey with that post. Basically, Rails is just fine, but it's different that php.

      --
      "We returned the General to El Salvador, or maybe Guatemala, it's difficult to tell from 10,000 feet"
    99. Re:Why rewrite existing systems? by B'Trey · · Score: 1

      Really? You must have read a different article than I did. The one I read said that "I hired one of the best Rails programmers in the world..." and that they were trying to "...make [Rails] do things it was never intended to do." It likened the task to "..trying to turn a train into a boat..." and said it was "... do-able with a lot of glue. But it's damn hard..."

      That doesn't at all sound like an issue of coding skill or preference in method of coding. It sounds like the author is claiming a mismatch between the task and the tool being used to perform the task. Rails may very well not be intended to handle every contingency that a web designer may need. It may very well be that the particular tasks the author needed just happened to be tasks for which Rails was poorly suited. And if that's the case, it's not a significant knock on Rails. It just means that Rails isn't a great choice for some limited subset of web coding problems. But if that's the case and you're going to post about it on a blog, then the responsible course of action is to also post about exactly which tasks gave Rails problems and why PHP was better suited for those particular tasks. Such a blog, assuming it was accurate, would be an intelligent and informative post for those interested in the field. That isn't what we got.

      --

      "The legitimate powers of government extend only to such acts as are injurious to others." Thomas Jefferson.

    100. Re:Why rewrite existing systems? by Fulcrum+of+Evil · · Score: 1

      No, he's a musician turned coder. The fact that this is his first foray into anything that isn't php is just one of the reasons the project failed. Really, read the comments - it's clear that rails works just fine.

      --
      "We returned the General to El Salvador, or maybe Guatemala, it's difficult to tell from 10,000 feet"
    101. Re:Why rewrite existing systems? by tacocat · · Score: 1

      If the constraints are added as additional SQL to the migrations as either table constraints or database triggers, I don't think the model has to do anything. Rails built in error handling should fire an exception on a failed update or insert, which should generally happen and be handled in the controller, right? And if you are handcoding in MVC style without Rails, in any language, that's still going to be the case, right? Rails may not add much to this, but it doesn't seem to me that it really fights you in it, either.

      But it shouldn't handle the error as a failure.. It should know what to do and do the right thing. Here's an example, but assume we aren't doing a security login username thing:

      1. I want to add a username to my table (eg: list of all the email addresses that send me email) so I naturally do an INSERT using sequences
      2. If the INSERT fails on a duplicate key violation then I want to turn around and do a SELECT and pull the necessary ID information for that username.
      3. Return ID for that username.

      The simply return an error at step 1 citing, "You can't do this" is not the right thing to do. Perhaps in another story line, but not this one.

    102. Re:Why rewrite existing systems? by DragonWriter · · Score: 1

      I see your point, but it seems that the "right thing" to do isn't something a framework could simply "know", but something that would necessarily have to be part of the application-level error handling logic.

    103. Re:Why rewrite existing systems? by mosch · · Score: 1

      I'd tell you the same thing, but I'm guessing you'll continue not listening.

      I'm not like you. I listen when people have useful things to say.

      You're just some idiotic fuckwit troll who claims that RoR isn't scalable because sometimes people use PHP.

      The fact that there are high volume sites that do run RoR doesn't matter to you, because you're either a PHP fanboi, or a complete and total fucking retard.

      Either way, the world will be more honest once you're dead, you manipulative, lying shit.

  2. To me that's poor planning by RaigetheFury · · Score: 4, Interesting

    Every technology out there has it's benefits. It's the job of the person planning the project to explore all of these technologies before they choose one. If you read his article, he makes no comments as to why he chose Ruby on Rails. Was he following the hype?

    I've been involved in the decision making process to choose a technology for writing a site many times. Working for a University common questions we use in comparison to the technology is

    1) Development time
    2) Ability to integrate with LDAP or other existing technologies
    3) Support (server level)
    4) Documenation (For development)
    5) Budget
    6) Number of developers on the project

    Depending on those variables it usually winds up being either PHP or Cold Fusion. Ruby on Rails has never once been a consideration. Not because it isn't a good solution, but it's never once been the best for our needs.

    1. Re:To me that's poor planning by Chandon+Seldon · · Score: 1

      Depending on those variables it usually winds up being either PHP or Cold Fusion. Ruby on Rails has never once been a consideration.

      The only way that you could get to those results given those criteria would be that you have a bunch of PHP and Cold Fusion developers on staff who push those choices. They aren't leading contenders on Development Time, Budget, or # of Developers - and they're about equal to any of the other contenders on the other points.

      From what I've seen, the only real criteria that anyone ever uses in choosing a development environment is this: What are the developers used to. A runner up is "what has the manager seen hyped in trade publications" - but that never works out well.

      This is probably a reasonable result. In practice, the differences between development environments in terms of the 6 points mentioned by the parent are pretty small. You might get an order of magnitude difference in #1, #5, and #6 in Java vs. Ruby for example - but you'll never convince a Java developer of that (or they'll claim an order of magnitude performance difference that rarely matters in practice). Hell, even writing an LDAP client library from scratch in Common Lisp (for example) is probably far cheaper than trying to get a team of Lisp programmers to move to ASP.NET or whatever.

      --
      -- The act of censorship is always worse than whatever is being censored. Always.
  3. on rails by ch0ad · · Score: 1, Funny

    7 reasons I switched back to PHP after 2 years on Rails wtf is php? is it new or something?

    2 years on cocaine!? jesus fuck he can't have much of a nose left...
    1. Re:on rails by Anonymous Coward · · Score: 0

      dude, i think php has been around since like the 60s, even before coke. it's more hardcore than coke too, trip you out and fry your brain type shit.

      but yeah, this guy has serious problems. php to blow and now back to php... man, hard.core. (wtf is this doing on orielly though??? should be on erowid)

    2. Re:on rails by Gen.Anti · · Score: 1

      I think PHP is this tranquilizer for horses and when some guys were taking it then they would pull out their eyes and stuff

  4. thinking about something new? think again by yagu · · Score: 3, Insightful

    After twenty five years watching technology try to not suck, one note rings true from The Fine Article. The new girlfriend always seems better... at first. But over time you'll likely discover she too (as one might expect) has foibles, idiosyncrasies that annoy and sometimes downright frustrate.

    • Thinking about ditching assembler for PL/I? Think again.
    • Thinking about ditching C for Java? Think again.
    • Thinking about ditching Windows for Linux? Think again.
    • Thinking about ditching Cascade methodology for JAD? Think again.

    If you've found a solution to a problem, consider carefully wrapping some other technology around it just because. Unfortunately my experience was that usually new technology/approaches typically were just because, usually driven by management (not always, and I'm not blaming them).

    Had I known then what I know now I'd have fought harder for status quo on a lot of big projects.

  5. Planning is key. by djsmiley · · Score: 2, Insightful

    You dont choose a project for a language, but a language for a project.

    Heyho I didn't read the artical but if i've learnt anything (hahah like hell i have), then its planning is key. Plan your project and find a language that works, not the other way around.

    --
    - http://www.milkme.co.uk
    1. Re:Planning is key. by Anonymous Coward · · Score: 1, Insightful

      I often hear other managers go on and on about planning. I think they're full of shit.

      It makes little sense to sit down and think through an entire non-trivial project, especially when it involves a new technology that you and the developers know relatively little about. You'll surely run into technological roadblocks that there really isn't an effective way around, unless you throw out a lot of the code you've already written. So now you're not only rewriting your code, but you also wasted a long time planning that which you now cannot do.

      So the only solution is to be able to manage change effectively, and swiftly. Do a minimum amount of planning, and then get to work solving the problems that you will not have anticipated during your planning sessions.

    2. Re:Planning is key. by 2short · · Score: 1

      I hear that here regularly, and it sounds so wise. But I don't buy it...

      You choose and hire developers for a general problem domain; you and they choose a language they like that can handle that general problem domain well. Now choose projects from that general domain.

      If you're planning a project and debating between two languages of wildly different capabilites, you've probably already failed to choose the right developer. If you're debating between languages of fairly similar capabilities, you're wasting your time.

    3. Re:Planning is key. by Kjella · · Score: 1

      I hear what you're saying, at the same time I don't think programming languages should be like that, I think it's a shortcoming of the languages we've got. After all, you're writing a different application, not doing anything fundamentally different. I don't mean like theoretically Turing-complete similar, but to me it would be perfectly natural if you could program a mainframe, a desktop app, an OS kernel and a website using the same language, just using different modules and constructs. I see absolutely no reason that basic syntax and functions like importing other code, interfaces, assignment, comparison, branching, value passing or objects such as basic lists should be different from project to project. Computer langauges are still young and making many improvements which spawn off new languages going in different directions, but I think those will merge together into a few dominating ones given another 20-50 years.

      --
      Live today, because you never know what tomorrow brings
    4. Re:Planning is key. by Anonymous Coward · · Score: 0
      djsmiley: You dont choose a project for a language, but a language for a project.

      you: But I don't buy it ... you and they choose a language they like that can handle that general problem domain well.

      You just reiterated exactly what dgsmiley was saying.

    5. Re:Planning is key. by DragonWriter · · Score: 1

      You dont choose a project for a language, but a language for a project.


      If the higher level goal is implementing a particular project for some use, you do the latter. If the higher level goal is learning a particular language by implenting something realistically useful with it, you do the former.

      Having both goals at once (which is what seems to have produced the situation in TFA) and trying to satisfy them both without appropriately addressing either is a really bad idea.

  6. Languages are just tools by Monoman · · Score: 3, Insightful

    It is all about choosing the right tool for a job. Sometimes you use a new tool and you wind up feeling like you are trying to put in a screw with a hammer. Sure it will work but not the way you want.

    Sometimes you go back to the tool you know how to use best.

    --
    Keep the Classic Slashdot.
    1. Re:Languages are just tools by CRCulver · · Score: 2, Funny

      But if all my l337 friends are using a screwdriver to pound in a nail, doesn't that mean I'm obliged to follow them?

    2. Re:Languages are just tools by Jeff+DeMaagd · · Score: 4, Insightful

      The problem I have with the "languages are just tools" adage is that they are about the most complex tools one can use, I mean hammers and screwdrivers have nothing on them. What might undo a project might be because of an obscure limitation of the language that wasn't known at the time of designing the project.

      That said, I don't know much about Ruby or Rails, but I've heard that you have to follow the conventions or you're just making things hard. You can just not follow conventions, but it's just adding another pile of problems that defeat the point of using Rails.

    3. Re:Languages are just tools by e.colli · · Score: 1

      You can just not follow conventions, but it's just adding another pile of problems that defeat the point of using Rails.

      That is very true for any framework. A simple 'tool' like plain PHP or javascript don't impose these conventions.

    4. Re:Languages are just tools by mccoma · · Score: 1

      but they impose a belief system and set of idioms that probably shouldn't be ignored.

    5. Re:Languages are just tools by e.colli · · Score: 1

      I agree, but these are much more flexible and less restrictive than a framework.

    6. Re:Languages are just tools by mccoma · · Score: 1
      For the most part, I agree with that, but I guess it really is how different is the language. I would expect a lot of problems with people going from the C-based languages to something like Erlang or Haskell.

      On that note, I would expect going from custom PHP to Ruby and Rail to be two level new learning needed. If you try to write PHP in Ruby on Rails you will feel a lot of pain.

    7. Re:Languages are just tools by sporkmonger · · Score: 1

      Yeah, that's pretty accurate. I use Ruby on Rails, and have been doing so for the past 2 and a half years. It wouldn't be a problem if Rails's defaults were always what you really want. It really doesn't work out that way in practice. Now, don't get me wrong, Rails is great. I dare anyone to write the first 80% of a web app's code faster than I can in Rails. But once you start having to deal with all the hard issues like integrating with a financial system or getting things to scale, Rails starts to look like every other tool in the toolbox. If you're lucky enough to have a web application project where there really aren't any hard issues to deal with, Rails is fantastic and probably really is the best tool for the job. Once the going gets tough though, I think I'd rather be working with a more lightweight framework that doesn't make things difficult when you want to be a bit closer to the actual protocols.

    8. Re:Languages are just tools by Seraphim_72 · · Score: 1

      I mean hammers and screwdrivers have nothing on them.
      What that means is that you don't know shit about screws, or nails for that matter. Don't think because you can code that "easy" stuff like machine work is simple. Machinists make as much money as you do, and half the time they are programming computers.
      --
      Slashdot, where armchair scientists get shouted down and armchair theologians get modded up.
  7. Re:Linus is right by Anonymous Coward · · Score: 0

    Without Linus FOSS is tossed


    FOSS won't go away if Teh Lunis does, but Lunix certainly will.

    Now given how Lunix is the flagship FOSSie product, it may turn out that Teh Lunis leaving would be a huge blow to teh FOSSies, but it won't go away entirely.

    But either way... I don't see how this has anything to do with the topic.
  8. What an idiot by Anonymous Coward · · Score: 4, Insightful

    "All the cool kids were using Rails, so I decided if I wanted to be cool, I had to completely switch to Rails in one big jump!"

    1. Re:What an idiot by Anonymous Coward · · Score: 0

      The idea that the cutover to a new Rails platform for every system in the company had to be done as one monolithic change is pure lunacy, unless they completely redesigned their entire database schema. But if that is the case, that is not Rails' fault. A very shallow analysis of the root issues behind this failed project.

    2. Re:What an idiot by Anonymous Coward · · Score: 0

      Ah, just like ATT Yellowpages! Let's dump our existing site that WORKS for a shit website that lags like hell in ruby-on-rails!

      If Yellowpages.com is the big push of what Ruby on Rails can provide, I'll pass :D

    3. Re:What an idiot by fat_mike · · Score: 1

      Well duh, Linux Journal had it on its cover 6 times last year. It must be awesome them! How the hell do Linux Journal stay in business. Are the guys from Sluggy Freelance paying for the whole thing?

  9. 7 Reasons? by Anonymous Coward · · Score: 0

    why 7 reasons? seems like there was 1 -- I like PHP. after looking at the two languages, the guy learned a bit about OOP and applied it to PHP because he had previous experience with PHP and was productive with it.

    how is this news?

  10. Very uninformative article by DaleGlass · · Score: 4, Insightful

    There's a complete lack of points against Ruby in that article. And I don't say that as a fan, I don't know the langauge at all. It's just got a complete lack of any useful information to judge the usefulness of Ruby.

    Reasons:
    #1: Seems a very weak criticism, all languages are interchangeable really. Except some do some things much better than others.
    #2: Internal management problem, not really related to Ruby specifically.
    #3: Applies to every language
    #4: Potential for real criticism here, but without any DATA it's completely useless
    #5: Works for whatever language the author likes, again not related to Ruby
    #6: Potential for more real criticism here, but again lacks any useful information
    #7: Again something unrelated to Ruby specifically

    From the whole list, only 2 of the reasons point to Ruby in any manner, and those are so uninformative as to be useless anyway. I think most of the blame for this lies with slashdot, as the article tries to spin it into something against Ruby when the actual article is more about a failed migration than anything else.

    1. Re:Very uninformative article by Anonymous Coward · · Score: 0

      I think you miss the point. It's not a critique of Ruby as a language but of Ruby On Rails as a platform. I agree that Ruby-the-language is not worse than PHP-the-language (probably even better in many respects) but Ruby On Rails as a web development platform is way different from PHP (especially since PHP doesn't really provide much of a platform out of the box; you have to build it yourself). And as the author noted, the rigid structure that Ruby On Rails tries to enforce gets in your way when trying to accomplish your goals, which is much more important than the imperfections that PHP had.

      I think Ruby On Rails is a lot like Visual Basic: great for rapid development of some standard applications and to hide the complexity of the internal workings of a web application, but if you have special needs it just doesn't cut it and you need a more low-level tool.

    2. Re:Very uninformative article by discord5 · · Score: 3, Insightful

      I have to agree with you. I've been through a few webprojects in perl, php, rails and struts. Perl is my favorite, but that has largely to do with the jobs I had to do in the past, and it's certainly not the only language to get to a solution.

      The only thing that I'd have to agree with is that Rails does take up a bit more resources than the average PHP application (#4), but rails like any other framework does allow you access to your database. It's very well documented in Agile Web Development on Rails (not being paid, just giving an example I know of) where they introduce Active Record, and there's an small section on the subject itself. I'm pretty sure it's somwhere in the API reference as well.

      Some languages are more suited than others for a certain project, so it's perhaps more important to do a proper analysis of what you want to achieve and what languages will help you most to achieve those goals. The author offers very little detail into what exactly went wrong with his project, except that it didn't go as smooth as planned (welcome to the 90% of all projects, pull up a chair and have a drink).

      Finally, even though the article mentions he hired a programmer, it's often wise when learning a new language/API/tool to start with a small application so you'll get a firmer grasp on it. That way you'll get a better feel for possible trouble ahead. Sure, we don't all have the time to do that, but in that case it's often better to stick to what you know and what works for you instead of blindly charging forth and trying to ride the latest wave of technology buzzwords. Not that I'm saying that RoR is just a buzzword (it's pretty neat actually), but don't use it because it's hip. Use it because it solves a problem more easily than another language/framework.

    3. Re:Very uninformative article by Anonymous Coward · · Score: 0

      A few more resources?
      Rails is dog slow.. I know of more than one company that has gone under because of the huge amount of server costs due to ruby and rails. A few saved themselves by rewriting in PHP and getting rid of almost all of their servers.

    4. Re:Very uninformative article by Anonymous Coward · · Score: 0

      No, you got out of web development because you were disappointed to find that all the trendy, good looking and popular people were actually better programmers then you.

    5. Re:Very uninformative article by EsbenMoseHansen · · Score: 1

      You nailed it pretty well, but I thought an elaboration might need. So,

      The real criticism of rails is this: It's slow. So if you are going to build something that has to serve lots'and'lots of pages, don't do it. From what I've read, the reason for this is a combination of slow ruby (which will be cured) and trading efficiency for elegance is so easy. As an example, it is very easy to do a select by going through all the records in the db. And in rails, that way might look better... no sql fragments and so on.

      In my humble opinion, rails needs a way to write db-engine-agnostic efficient queries to be useful in the applications that needs to serve a lot. For the moment, I'd suggest at least care if you want to go this route.

      The other criticism is that if you have a big, homegrown non-ruby-library, you won't be able to use that in rails. True, but obvious.

      Does these criticism make rails useless today? Not at all. It's wonderful for making all those webapps that doesn't take a pounding. Many, many web applications serve less than a page per second, and for those, rails is just perfect. The smaller development cost will match up wonderfully with the lesser usage. And as it is small apps (I wrote one for managing the employees lunch-club), the chance that you really need any existing homegrown library is small, too.

      --
      Religion is regarded by the common people as true, by the wise as false, and by rulers as useful.
    6. Re:Very uninformative article by Chandon+Seldon · · Score: 1

      As an example, it is very easy to do a select by going through all the records in the db. And in rails, that way might look better... no sql fragments and so on.

      This is just an issue of poor programming (or FUD). The idea that the Rails developers wouldn't provide the ability to select specific records out of a table is absurd, and any developer who selects the whole table and manually searches instead is incompetent.

      As for ruby being slow, this is a much smaller deal than you'd expect. Most of these apps are database limited anyway - things like Rails caching will probably have a larger positive effect being able to execute less ruby instructions per microsecond.

      --
      -- The act of censorship is always worse than whatever is being censored. Always.
    7. Re:Very uninformative article by EsbenMoseHansen · · Score: 1

      As an example, it is very easy to do a select by going through all the records in the db. And in rails, that way might look better... no sql fragments and so on.

      This is just an issue of poor programming (or FUD). The idea that the Rails developers wouldn't provide the ability to select specific records out of a table is absurd, and any developer who selects the whole table and manually searches instead is incompetent.

      I don't agree on this wholeheartedly. Yes, rails allows SQL fragments, so you can do stuff like that if you wish, and by carefully writing the sql, it will work on most databases. However, it will no longer be truly database agnostic, which lessens the appeal somewhat. For simple selects, rails provide the find class function, which is nice, but even relatively simple stuff like selecting on a date, asking for a specific month is not possible without sql fragments. So, it is certainly easier to write something like entries.find(:all).collect { |entry| entry.date.month == 6 } to get all the entries from a june date. Yes, it doesn't scale, but the programmer in question might have judged that it didn't need to (perhaps the list of entries is expected to be small). And so on, I think you get my drift.

      As for ruby being slow, this is a much smaller deal than you'd expect. Most of these apps are database limited anyway - things like Rails caching will probably have a larger positive effect being able to execute less ruby instructions per microsecond.

      Good point, but it depends. Lots of applications are CPU bound on filling in templates, especially when caching is used. Yes, for DB bound applications, rails will do just fine. In any case, I am completely certain that ruby will get to be as fast as python as to make no difference, in time.

      --
      Religion is regarded by the common people as true, by the wise as false, and by rulers as useful.
    8. Re:Very uninformative article by vux984 · · Score: 1

      My take, was that the article isn't against Ruby at all. But rather that its against "Ruby on Rails". Rails, the framework, is very easy to use but if you come up against the limitations of the framework. Then you're stuck having to re-invent big parts of the wheel from scratch, outside of the framework.

      The issue is the /framework/ not the /language/.

    9. Re:Very uninformative article by DaleGlass · · Score: 1

      Whatever it is against, it still doesn't have any useful information.

      Where are the benchmarks? Where are the code examples? Where is a specific list of deficiencies?

      That's the stuff I want to see.

    10. Re:Very uninformative article by EsbenMoseHansen · · Score: 1

      A few more resources?
      Rails is dog slow.. I know of more than one company that has gone under because of the huge amount of server costs due to ruby and rails. A few saved themselves by rewriting in PHP and getting rid of almost all of their servers.

      It would be interesting to see where those resources are spent. I wonder if anyone has done an analysis.

      --
      Religion is regarded by the common people as true, by the wise as false, and by rulers as useful.
    11. Re:Very uninformative article by Chandon+Seldon · · Score: 1

      For simple selects, rails provide the find class function, which is nice, but even relatively simple stuff like selecting on a date, asking for a specific month is not possible without sql fragments.

      What's wrong with entries.find(:all, :conditions => [:month => 6])?

      --
      -- The act of censorship is always worse than whatever is being censored. Always.
    12. Re:Very uninformative article by Anonymous Coward · · Score: 0

      Haha. Good one.

      Anyway, Rails is dog slow; partially because Ruby itself is dog slow, but mostly because all the metaprogramming hoops it jumps through to make everything nice and pretty add a fuckton of overhead to your application's logic. Ruby isn't what makes Rails snazzy looking: Ruby is nice, but the reason a Rails app is so tiny and pretty is because Rails makes a herculean effort to DWIM. I have no data to back up my claims either, but I have written and deployed major public applications with both, and I figure a normal Rails app probably puts 2x the load on your DB server and 5-10x the load on your application servers as a well-written PHP app.

      The idea is that you get things done so much quicker with Rails that it's worth it, and that you spend the bucks you make from getting to market first on more servers and spend your days in your new mansion profiling and improving your app's performance. Now, your feelings on that reasoning can go whichever way you like assuming someone is a Rails guru -- but if you're not well versed enough to really see the productivity benefits versus a language you know better, then no, Rails isn't going to be much of a step forward from anything else.

      Rails certainly isn't bad, though. If anything, its rapid increase in popularity spurred development of frameworks using the same ideas in more traditional languages; and caused people to take notice of its competitors. And Ruby really is a nice language to program in. I find myself going to it for one-off and maintenance scripts in lieu of Perl or Python quite a bit recently.

    13. Re:Very uninformative article by EsbenMoseHansen · · Score: 1

      For simple selects, rails provide the find class function, which is nice, but even relatively simple stuff like selecting on a date, asking for a specific month is not possible without sql fragments.

      What's wrong with entries.find(:all, :conditions => [:month => 6])?

      According to the documentation, this would not work. What I need is something like SELECT * FROM entries WHERE MONTH(date)=6. What the above would get me is SELECT * FROM entries WHERE month=6.

      Or am I wrong? But even so, there must be limits to what find can do, and in those cases, a db agnostic way to access the databases would be very nice.

      --
      Religion is regarded by the common people as true, by the wise as false, and by rulers as useful.
    14. Re:Very uninformative article by darken9999 · · Score: 1

      I was only skimming the thread here, so maybe I missed something where you don't want to do this... but when you need something crazy, just pass the SQL.

      month = 6
      Entries.find_by_sql ["SELECT * FROM entries WHERE MONTH(date) = ?", month]

    15. Re:Very uninformative article by EsbenMoseHansen · · Score: 1

      We seem to be going in circles. I know this solution, is previously pointed out, but that solution is not database agnostic. So in these cases, you have the choice between database agnosticism and efficiency. And during these choices, programmers will make mistakes. I rather suspect that much of the rails's reputation of sluggishness is due to stuff like that.

      Of course, without the profiling data, we will never know.

      --
      Religion is regarded by the common people as true, by the wise as false, and by rulers as useful.
  11. Sensationalist without a clue by James+Kilton · · Score: 1, Insightful

    His only valid complaint was integration.

    Why the hell would you take a system written entirely in PHP and add to it / rewrite some of it in a different technology?

    I love Rails, and if I have my way I will never touch PHP again. But if I join a company who's intranet is all PHP, then by golly I'm going to use PHP!

    This guy is a sensationalist and not worth the attention.

    1. Re:Sensationalist without a clue by KaptajnKold · · Score: 1

      I love Rails [...] This guy is a sensationalist and not worth the attention.

      I guess your love of Rails explains your knee-jerk defensive reaction, but if you'd only bother to RTFA, you'd have noticed, that this guy doesn't really criticise Rails much at all. In fact he praises it, but then goes on to say why it was a mistake to use it in a particular project. It's whoever wrote the article summary, who's a sensationalist without a clue.

  12. article: -1, troll by Verte · · Score: 4, Interesting
    New article summary:
    1. I still have to program it
    2. We already knew PHP
    3. Rails has features I didn't use
    4. Rails has too many features
    5. I didn't really want to change my thought process
    6. I like my way of doing things
    7. How I justified trying something new.
    I'm not saying that these aren't valid- save 1 and 3, maybe. But they aren't new, and aren't interesting.
    --
    We at slashdot are scientists, specialists and kernel hackers. Your FUD will be found out.
    1. Re:article: -1, troll by Goaway · · Score: 1

      4 is spot on. Ruby is slow. It has nothing to do with features, and everything to do with having a weak language implementation.

    2. Re:article: -1, troll by z_gringo · · Score: 2, Informative

      He actually says the exact opposite of most of your points.

      He had one of the best rails programmers there was. It wasn't a problem with not knowing rails. He still wasn't finished after 2 years. He could accomplish the same thing faster in PHP.

      He specifically said that using and learning Rails helped him change his thought process for the better.

      --
      -- -- Warning. Do not stare directly at the sun.
    3. Re:article: -1, troll by Verte · · Score: 1

      Have you ever seen a C programmers' Python code? Or a LISP application ported to Java?

      --
      We at slashdot are scientists, specialists and kernel hackers. Your FUD will be found out.
    4. Re:article: -1, troll by Cl1mh4224rd · · Score: 1

      Have you ever seen a C programmers' Python code? Or a LISP application ported to Java?

      Are you even paying attention? Once again, the guy hired one of the best Ruby programmers out there to do the rewrite. He didn't try to do it himself. Your point is irrelevant.
      --
      People will pass up steak once a week, for crap every day.
    5. Re:article: -1, troll by Verte · · Score: 1

      You're missing the point. It's not about programming, not even about language. It's about thinking. It doesn't matter how good at Ruby you are when you're making, essentially, a PHP+MySQL application in Rails. What matters is that you have engineered your site holistically as a Rails site. Maybe I oversimplified. The thing is, all that structure only works when you work with the paradigm. I don't doubt that the author of the article tried somewhat, having made a decision to move to Ruby. But the feeling from the article is that he didn't reorganise the site as a Ruby site- the designer, not the programmer, didn't think in terms of Rails.

      --
      We at slashdot are scientists, specialists and kernel hackers. Your FUD will be found out.
    6. Re:article: -1, troll by budgenator · · Score: 1

      LISP application ported to Java Muhahahah, it would probably be easier to write a Lisp interepter in java, than do that!

      --
      Apocalypse Cancelled, Sorry, No Ticket Refunds
    7. Re:article: -1, troll by jadavis · · Score: 1

      But the feeling from the article is that he didn't reorganise the site as a Ruby site- the designer, not the programmer, didn't think in terms of Rails.

      He didn't discuss in the article how closely he was managing the implementation. If he was telling the Ruby programmer exactly what to do, then I'd understand your point.

      But the impression that I walked away with was that he was very open to the new ideas presented by an experienced Ruby developer, and let him do things the Rails way. It was not on track to meet the requirements for the end product after 2 years, so he canceled it.

      It seems like the project was set up to be a success from day one: the project requirements were already solidified before it started, the problems were already solved, he was open minded to new ways of thinking, and he hired a real expert to take control of the project. The only problem to be solved was the implied problem that the code was becoming unmaintainable, and he was hoping Rails implemented by an expert could solve that in a reasonable period of time.

      The fact that the project failed is not a good case study for Rails.

      --
      Social scientists are inspired by theories; scientists are humbled by facts.
    8. Re:article: -1, troll by Verte · · Score: 1

      "at every step, it seemed our needs clashed with Rails' preferences."

      --
      We at slashdot are scientists, specialists and kernel hackers. Your FUD will be found out.
    9. Re:article: -1, troll by jadavis · · Score: 1

      "at every step, it seemed our needs clashed with Rails' preferences."

      I'm not sure whether you were agreeing or disagreeing, but that reinforces my point: The take away from this article is that rails was constantly working against his end requirements, so that even in otherwise ideal circumstances, it didn't allow an experienced developer to solve the problem in a reasonable amount of time.

      I'd like to hear more details about the actual project and what caused it to fail.

      --
      Social scientists are inspired by theories; scientists are humbled by facts.
    10. Re:article: -1, troll by dubl-u · · Score: 1

      He had one of the best rails programmers there was. It wasn't a problem with not knowing rails.

      No, it was a problem of trying to use Rails to work just like he did in PHP. He wanted to use his existing database layout. He wanted to write SQL queries. The Rails attitude is that your database should derive from your OO model, and you should generally trust Rails to get your data for you.

      So you could sorta say he knew it. But until he tries it the way the authors meant it to be used, he still won't really get what its strong points are.

  13. He was incompetent...! by bogaboga · · Score: 3, Interesting

    Two years later, through blood and sweat, the project was then canceled because of limitations of Rails.

    While I do not doubt the hired programmers coding skills, I am afraid he was incompetent at planning.

    It's like choosing ISAM as the DB engine in MySQL instead if InnoDB then expecting to implement [referential] integrity using your own code.

    The fact that it took two years to realize imminent failure disturbs my mind. The worst thing is that this coder might have been an Open Source enthusiast that I'd expect to know better.

    I am afraid no home work was done or whatever home work was done, it not good enough. The results speak for themselves.

    1. Re:He was incompetent...! by Blackknight · · Score: 1

      Speaking of SQL, just use PostgreSQL and you don't have to worry about stuff like that.

    2. Re:He was incompetent...! by bogaboga · · Score: 1

      For PostgreSQL, I am still searching for a decent programmable GUI. Never found one! The Web based ones found in products like Webmin et al just do basic stuff. Think of Microsoft's Access which is a GUI to its JET database engine. Know of any?

    3. Re:He was incompetent...! by cpaalman · · Score: 1

      An Open Source enthusiast does not imply the person is an experienced coder.

      To that end I suspect that non-open source coders can suffer from the same dilemma, or that they could be well versed in picking the most appropriate language for developing a non-open source project.

      I agree with your other points, failure to match project expectations with language capabilities is a sure way to a projects eventual demise.

    4. Re:He was incompetent...! by Blackknight · · Score: 1

      PHPPgAdmin, it's similar to phpMyAdmin. I believe ODBC is also supported so you could even use Access (yuck) as a frontend.

      http://phppgadmin.sourceforge.net/

    5. Re:He was incompetent...! by teg · · Score: 1

      The fact that it took two years to realize imminent failure disturbs my mind. The worst thing is that this coder might have been an Open Source enthusiast that I'd expect to know better.

      Being an Open Source enthusiast doesn't immediately make you a good project manager. Those are two separate skillsets. Some are great both (Linus Torvalds, to give on example), but you'll also find coders who can't deal with constraints and will never finish anything if not pushed/prodded/guided the right way.

    6. Re:He was incompetent...! by Chandon+Seldon · · Score: 1

      For PostgreSQL, I am still searching for a decent programmable GUI. Never found one!

      Is that really a feature that you need, or is it just an excuse to avoid change?

      --
      -- The act of censorship is always worse than whatever is being censored. Always.
    7. Re:He was incompetent...! by Slashdot+Parent · · Score: 1

      Speaking of SQL, just use PostgreSQL and you don't have to worry about stuff like that. I would, however, have to worry about becoming an obnoxious fanboi, no?
      --
      They don't grade fathers, but if your daughter's a stripper, you fucked up. --Chris Rock
  14. Sigh by Anonymous Coward · · Score: 0

    The good old "Hmm, what do we need for this?" "Alright, let's take a look at our demands here." blah blah instead of some old fashioned Just do it(tm). What a waste.

    The guy also mentions in his blog that his project/creation cdbaby.com comprises 100,000 lines of source code, which I find infinitely hilarious. Perhaps someone with his "talent" should leave the programming in the hands of people who know how to get things done properly. (His American style of getting things done vs the European's way of programming)

  15. Also dumping python for PHP by z_gringo · · Score: 1

    I can totally relate to this guy. I am going through something very similar, ableit on a slightly smaller scale.

    We put a key system in Python a while back. After dealing with it for over a year, we are also going back to PHP. Everything else in the company is PHP. It just doesn't make sense to have this one Python. We can customize and improve the PHP a lot faster than the python.

    --
    -- -- Warning. Do not stare directly at the sun.
    1. Re:Also dumping python for PHP by LighterShadeOfBlack · · Score: 1

      I can totally relate to this guy. I am going through something very similar, ableit on a slightly smaller scale.

      We put a key system in Python a while back. After dealing with it for over a year, we are also going back to PHP. Everything else in the company is PHP. It just doesn't make sense to have this one Python. We can customize and improve the PHP a lot faster than the python. And none of this occurred to you before the system was coded? As with TFA, the culprit here is poor planning, not an issue with any specific language or technology.
      --
      Spelling mistakes, grammatical errors, and stupid comments are intentional.
    2. Re:Also dumping python for PHP by Pollardito · · Score: 1

      I can totally relate to this guy. I am going through something very similar, ableit on a slightly smaller scale.

      We put a key system in Python a while back. After dealing with it for over a year, we are also going back to PHP. Everything else in the company is PHP. It just doesn't make sense to have this one Python. We can customize and improve the PHP a lot faster than the python. And none of this occurred to you before the system was coded? As with TFA, the culprit here is poor planning, not an issue with any specific language or technology. it's possible that project was a pilot project to test-drive Python in hopes of using it as their new development standard and it didn't make enough of an improvement to warrant making a change overall. there's lots of reasons that one piece might have made sense to do in another language originally.
  16. Misleading summary by Craig+Maloney · · Score: 4, Insightful

    I read the article, and I believe the reasons the author switched back to PHP was because he was more comfortable with it than Ruby. If you read deeper, you'll note that he appreciated the experience in dealing with Ruby, and brought some of it back with him to PHP, but he did not think it was right for his application. Seeing this as a "OMG! Ruby replaced with PHP!" is just another fanboy reading into it what he will.

    Time to calm down here, people. Just because one person sees value in another set of tools doesn't mean you will too.

    1. Re:Misleading summary by chdig · · Score: 2, Informative
      He appreciated Ruby, brought back some programming concepts to PHP, and used them. The concepts and clear flow of programming in Ruby are great, emphasizing MVC and separation of code, and can be used in PHP too (which is something most people for some reason think isn't possible).

      This article is interesting (and more than just fanboi talk) because it dispels some key myths about both Ruby and PHP -- all 7 points fall into two categories:
      a) PHP can do it just as well or better.
      b) PHP doesn't force the programmer into one way of programming -- rather, he can do things his own way (use SQL statements, program the way he likes).

      I find his point 5 is the key here, and why many of us love our PHP:

      I don't need to adapt my ways to Rails. I tell PHP exactly what I want to do, the way I want to do it, and it doesn't complain. PHP exposes more of the guts of the language to the programmer. It's easier to make messy code, to leave security vulnerabilities, to have duplication, and to be inefficient in coding. But while this is true, it's also the kind of FUD that this article tackles. The author even wrote that he believed PHP was a bad language for years before returning to it, employing good programming concepts and realizing that it was the most powerful option available.

      With the amount of PHP FUD we see on /., it's nice to see a counterpoint
    2. Re:Misleading summary by vidarh · · Score: 2, Informative
      PHP is a bad language. It's a nasty mess, though it's gotten better with 5. What it has is simplicity, speed for web apps (compared to the current Ruby interpreter, and largely because the PHP interpreter is nicely integrated into Apache - this is not an inherent advantage of the language, but an implementation issue) and a huge number of built in, fast C extensions.

      I've picked PHP for web apps too, though I much prefer Ruby as a language (not too thrilled about Rails, mostly because I have an allergy to frameworks - I much prefer picking components based on my needs).

      What you say is right - it's far easier to fuck up in PHP than with Rails (but you can equally easily fuck up if you use Ruby alone), but one of my biggest problems with relying on Ruby for web apps right now is scalability. Yes, I know you can scale Rails, but the number of hoops you have to run through to get a Ruby based (regardless of Rails) application to scale is a hassle, and negate a lot of the things that make Ruby a great language for other things.

      The threading model in Ruby, for example, is completely fucked up and kills performance if you need to do many threads and a lot of IO at the same time. It also makes things like failover harder whenever you have to depend on badly behaved C libraries (the MySQL client library is a pet hate of mine, since it can lock indefinitely in connect() for example, making you jump through hoops if you want to use it safely in a multithreaded Ruby app without risk of stalling).

      Hopefully that gets taken care of in a future version, but it's a problem right now, and it's a larger problem because the interpreter isn't fully reentrant, making it harder to embed it and scale it with multiple threads outside the interpreter.

      It doesn't stop me using Ruby, or recommending Ruby, but a lot of the Rails fanboys shoot themselves in the foot by ignoring the problems. They'd do Rails (and Ruby) a lot more favors by being honest about what's hard so people know what they go to. Problem is, not many of them actually know what's hard to do with Ruby, because few sites get the kind of traffic that will start making scaling further hard work.

      It's hard work at various points with other languages and frameworks too, but the pain points are different, and what people are used to do with PHP is quite different from what they need to do to scale Ruby.

    3. Re:Misleading summary by KIondike · · Score: 1

      Exactly. I think the most relevant comment is: "It's the most beautiful PHP I've ever written, all wonderfully MVC and DRY, and and I owe it all to Rails." How much more clear can he be that trying Rails was a *positive* thing for his site, and his skills as a developer?

    4. Re:Misleading summary by FooBarWidget · · Score: 2

      "The threading model in Ruby, for example, is completely fucked up and kills performance if you need to do many threads and a lot of IO at the same time."
      As opposed to PHP which doesn't have threads at all?

      I really don't understand the obsession with threads. Why not just use processes? Running multiple processes allows you to fully utilize that dual core CPU of yours. Plus it doesn't involve messing with locks and conditional variables, an important source of bugs. If one process crashes, the others are unaffected. And finally, if an app uses 5 MB RAM and you run 10 instances of that app, then that doesn't equal 50 MB memory usage. Modern operating systems do their best to share memory between processes, and support copy-on-write memory handling. If your 250 MB process forks, then the child process only uses a few KB memory and not another 250 MB.

      In fact, Perl and Python have similar/the same problems. Perl threads are heavyweight: each thread copies the entire interpreter memory state! This makes thread creation hideously slow (a moderate-sized Perl app can take 15 seconds to create a thread), unstable (threads are still considered experimental) and memory consuming. Python threads are, like Ruby threads, user-space threads and not kernel threads.
      When I think about it, I don't even know one scripting language which has proper kernel threads support. Your "Rails fanboys" comment is completely pointless.

    5. Re:Misleading summary by CableModemSniper · · Score: 1

      When I think about it, I don't even know one scripting language which has proper kernel threads support.
      Ruby and Python.
      --
      Why not fork?
    6. Re:Misleading summary by nuzak · · Score: 1

      > Python threads are, like Ruby threads, user-space threads and not kernel threads.

      Completely incorrect. Of course Python does have the GIL which means they're only good for blocking on I/O and not actual parallel computation. And neither Jython nor IronPython have the GIL.

      Perl also has threading support (and no GIL) and no, it does not copy the entire interpreter state, and hasn't done so since perl 5.6 at least. Tcl supports running multiple threads, though I don't think the language itself actually supports their creation (it's more like the "multiplicity" option of old perl threads).

      All the various scripting languages that run on the JVM also support threads. Perhaps that's cheating.

      By the way, the year is currently 2007. Just in case that had to be cleared up too.

      --
      Done with slashdot, done with nerds, getting a life.
    7. Re:Misleading summary by FooBarWidget · · Score: 1

      "Completely incorrect. Of course Python does have the GIL which means they're only good for blocking on I/O and not actual parallel computation. And neither Jython nor IronPython have the GIL."

      Well the guys at #python told me that Python uses green/userspace threads.

      It's good that Jython/IronPython don't have a GIL but are they production-ready? They're kinda useless for most existing Python apps until they can run those apps perfectly fine. Last time I checked, someone said that they don't implement the entire CPython standard library.

      "Perl also has threading support (and no GIL) and no, it does not copy the entire interpreter state, and hasn't done so since perl 5.6 at least."

      Really? Then can you explain why:
      - My 78000 lines Perl program takes 15 seconds to create a thread? On top of that, it crashes right after thread creation.
      - Every single documentation on the Internet about Perl threads seem to suggest that they're heavyweight. I quote: "Perl ithreads are not lightweight!"
      - The official Perl threading documentation says that variables are, by default, not shared between threads unless you explicitly mark them as shared.

    8. Re:Misleading summary by vidarh · · Score: 1


      As opposed to PHP which doesn't have threads at all?
      </em>
      <p>
      This misses the point. Thanks to the clean integration with Apache and reasonable performance, PHP doesn't need threading support to scale. Scaling Ruby web apps without resorting to threading at some point or other on the other hand is a lot harder in part because people are prepared to go to great lengths to avoid the startup overhead with Ruby.
      <p>
      <em>
      I really don't understand the obsession with threads. Why not just use processes? Running multiple processes allows you to fully utilize that dual core CPU of yours. Plus it doesn't involve messing with locks and conditional variables, an important source of bugs.
      </em>
      <p>
      I agree, to a point. But going multi-process instead of multi-threading suddenly increases the communication overhead significantly, and it's extra work. As a result people often avoid it, especially since threads is deceptively simple in Ruby, and going multi-process is not.
      <p>
      Also, the cost of going multi-process with Ruby is significant because of the gc - you WILL triger copy on write for a large set of your data very easily. Proper threading would have made that far less of an issue.
      <p>
      Just a cleanly re-entrant interpreter with threading outside of the interpreter would fix this problem with Ruby.
      <p>
      So to reiterate: The problem isn't Ruby the language, but the current Ruby interpreter. It violates almost every single principle of a well written interpreter. Luckily there's a lot of work going on to fix it, so hopefully this issue will go away reasonably quickly (and there's of course all the Ruby reimplementations), but for now it can't be ignored if you want to scale - you either have to deal with it (and there certainly are ways to deal with it, but it adds effort) or you pick another language.
      <p>
      I'm all for Ruby - I made the decision to start moving various components at Edgeio (the startup where I work) to Ruby a long time ago - but it only does Ruby disservice when lots of newcomers to Ruby hit the wall because they aren't aware of where the challenges will be and expect everything to be plain sailing.
      <p>
      It's often a rough awakening for people when they suddenly have to deal with the performance going to hell or things locking up because they do silly things (like calling the MySQL client library or any other C extension using bocking connect()'s or other syscalls from the same process that their webserver is running in for example) that would be considered perfectly reasonable in PHP code. For this problem to go away with Ruby it takes one of two things: Either a Ruby Apache module that is good enough to be able to compete with PHP in speed and where people won't worry about data leaks, OR fixing the threading.
      <p>
      We've hit far more scaling problems with Ruby than most peope will ever do, in part because of some of the things we were prepared to use Ruby for (we run Ruby for a lot of our backend and middleware components - our frontend is still PHP for now). And yes, we did end up having to go multi-process to get reasonable performance, because once we got to a certain number of threads combined with lots of IO, Ruby performance just goes through the floor. Add into that database drivers that don't work well with user level threading, and we had to bite the bullet. It cost a LOT of additional work that we wouldn't have had to deal with if the normal Ruby interpreter had used kernel level threads.

    9. Re:Misleading summary by nuzak · · Score: 1

      The clue level on #python is pretty variable. Not worth consulting most of the time. You want reliable answers about the language itself, use the mailing lists. CPython has or had a "fake" threads implementation, but I don't think those even rise to the level of "green" threads. Stackless Python has green threads.

      Jython has been "production-ready" for years and years, with its only major problem being that it's quite old and neither supports the latest python or Java idioms. IronPython is definitely stable these days, and is probably the flagship "alternative language" for the .NET DLR. Both of them are intended to port the python syntax and most of the idioms; Neither of them are meant to be drop-in replacement implementations of the python runtime down to all the libraries, and some of the blame falls on the libraries, which take advantage of idiosyncrasies of CPython, like reference counting. It could also be argued that CPython fails to implement IronPython's libraries.

      Perl threads suck, they're crashy, and I think the only runtime that makes them work reliably is mod_perl. But they're still neither green threads nor does it run them in a separate interpreter instance.

      --
      Done with slashdot, done with nerds, getting a life.
    10. Re:Misleading summary by ctzan · · Score: 1

      Perl also has threading support (and no GIL) and no, it does not copy the entire interpreter state, and hasn't done so since perl 5.6 at least.

      No, that is wrong. Perl threading (ithreads - as currently implemented in 5.x) DOES really copy the entire interpreter state.

      And the implementation is incredibly dumb: think of a fork() that (instead of copying the entire memory at once or doing COW on pages on VM systems, etc.) will walk painfully through all the pointers, strings and objects and copy each other in turn, recursively.

      You come to wonder if the people who designed it were really morons, or it was some kind of joke.

    11. Re:Misleading summary by ctzan · · Score: 1

      My 78000 lines Perl program takes 15 seconds to create a thread

      Because the parent has no clue, and didn't bother to check the perl ithreads implementation, or try it with anything else than hello-world one-liners :)

      The time to fork a new thread is proportional with how many objects (strings, variables, etc) exists in the interpreter, since it has to COPY them all.

      To have some fun, let a threading perl load your 78000 script, then dump a core file (ex. 'ulimit -c unlimited' than 'dump' in the script), and run a

      strings | grep | wc -l on it.

    12. Re:Misleading summary by FooBarWidget · · Score: 1

      "This misses the point. Thanks to the clean integration with Apache and reasonable performance, PHP doesn't need threading support to scale. Scaling Ruby web apps without resorting to threading at some point or other on the other hand is a lot harder in part because people are prepared to go to great lengths to avoid the startup overhead with Ruby."

      If that wasn't your point, then I didn't understand (and actually still don't understand) your point. Ruby on Rails's startup overhead is large, yes. But I don't see why this means they must use threads. Typical Ruby on Rails setup these days are as follows:
      1. Run 10 (or any arbitrary number of) Mongrel instances.
      2. Setup Apache mod_proxy_balancer to proxy HTTP requests to one of the Mongrel instances, as load balancer.
      (1) will allow you to fully utilize concurrency and your multicore CPU.

      To scale this application, simply increase the number of Mongrel instances. Those instances may run on another computer. If the HTTP load balancer can't handle it, buy more load balancer servers and setup DNS load balancing to balance the load balancers, or upgrade the load balancer server.

      This isn't any different from PHP is it? To scale PHP, buy more web servers and install the PHP app on them (and setup your load balancer). To scale Rails, buy more web servers and install the Rails app on them (and setup your load balancer).

      Did you know PHP is similar to Rails with regard to using processes? The PHP documentation explicitly discourages people to use the threading backend in Apache, and encourage them to use the MPM backend instead, which creates child processes. Apache creates x child processes, each process processing one request at the same time. The main Apache process proxies requests to one of the child processes. This is architecturally very similar to Apache mod_proxy_balancer plus a pack of Mongrels.

      "I agree, to a point. But going multi-process instead of multi-threading suddenly increases the communication overhead significantly, and it's extra work."

      In theory, yes. But how significant is it in practice? If there's one thing I've learned from all those years I've spent on programming, then it's that performance issues are rarely at places where you expect them to be. Some stupid little thing that you've never thought about may consist 30% of the application's CPU usage, while the part that you spent a week trying to optimize turned out to be insignificant after all.
      My experience with web applications is that the time taken to send data through the communication channel is negligible compared to everything else (that is, the time taken to actually request the process). In Ruby on Rails, building the final output HTML seems to take a significant amount of time. I can't imagine that the time taken to send a few kilobytes over a Unix socket (or even a TCP socket) back to the load balancer, is significant compared to that.

      "Also, the cost of going multi-process with Ruby is significant because of the gc - you WILL triger copy on write for a large set of your data very easily. Proper threading would have made that far less of an issue."

      I do agree that the Ruby interpreter can and should be better than it is right now. But I don't think using multiple threads will make things any easier on the garbage collector. The current Ruby interpreter uses a simple mark-and-sweep algorithm, and its execution time is linear (proportional to the number of objects). If you put multiple threads in the Rails app then the heap will become larger, and GC will take more time than when you only have one thread.

      Still waiting for them to implement generational garbage collection...

    13. Re:Misleading summary by nuzak · · Score: 1

      By "interpreter state", I tend to think of actual separate interpreters, which perl supported with its mysterious "multiplicity" option. By my judgment, that was actualy a better implementation, and the current version is the worst of both worlds. I certainly didn't mean to endorse the way perl does it, but regardless of how brainless perl's thread implementation is, the threads are definitely scheduler entries in the kernel ala pthreads. At least they are on my platform -- there seem to be a lot of ways to implement threads in perl. I guess TMTOWTDI applies even in the internals. *sigh*

      --
      Done with slashdot, done with nerds, getting a life.
  17. He makes good points, but by FooBarWidget · · Score: 1
    ...some of his reasons are just nonsense.

    "#1 - "IS THERE ANYTHING RAILS/RUBY CAN DO THAT PHP CAN'T DO? ... (thinking)... NO.""
    I might as well ask the opposite: is there anything PHP can do that Rails can't? Nope. PHP doesn't give me any reason to switch back from Rails. This entire argument doesn't mean anything.

    "#3 - DON'T WANT WHAT I DON'T NEED"
    It's the "not invented here" syndrome. "I didn't write it, so I don't want it, I want to use everything I wrote myself." A pretty weak argument.
    I don't know the entire Rails core either. Nor do I have to. I use what I need, and that's it. Everything in Rails that I don't need, doesn't get in my way.

    "#4 - IT'S SMALL AND FAST"
    This statement is pretty meaningless without providing website statistics. How many visitors does he have per day?

    "#6 - I LOVE SQL"
    This is purely a personal thing. I like SQL for complex queries, but for simple CRUD operations on records, why should I have to type the same boilerplate code over and over and over and over again? It's much simpler to type

    user = User.new
    user.name = params[:name]
    user.save
    than to type

    $db->execute(sprintf("INSERT INTO users VALUES(NULL, %s)", $db->quote($_GET['user'])))
    The former is easier to read and easier to write.

    "#7 - PROGRAMMING LANGUAGES ARE LIKE GIRLFRIENDS: THE NEW ONE IS BETTER BECAUSE *YOU* ARE BETTER"
    I really don't understand what he's trying to argue here.

    #2 is actually a valid point, but this isn't really Rail's fault. I can't argue to #5 as that's purely subjective.
    1. Re:He makes good points, but by modmans2ndcoming · · Score: 1

      why are you typing boiler plate code over and over again? have you ever heard of a functions and classes?

    2. Re:He makes good points, but by bryanthompson · · Score: 2, Insightful

      About your point #6, not only is it easier, but it is easier to add onto later. When you use SQL to create objects, you have to go back to whatever line of code you used to do your insert command and adjust the fields. In Rails, you just run a migration to add a field to the table, then modify your form to add that extra field.

      And, I think you're pretty much right on about his other "points." The slashdot summary of his post is entirely misleading and total flamebait--and not written by him. I think the guy is just inexperienced and crawled back to PHP out of a lack of wanting to change his mindset. He does in the end give Rails some credit for introducing him to a logical MVC structure, and I doubt he meant to flame Rails. He just happened to make mostly subjective and uninformed points to justify going back to what he already knew... I'm guessing he named his post "7 reasons..." before actually counting the reasons. Blogging is teh hard :p

    3. Re:He makes good points, but by hattig · · Score: 1

      I think that using Rails taught him about OO programming, and then he went back to PHP and used OO programming there. I wouldn't be surprised to hear that there were huge blocks of duplicate code to do stuff that could have been in an object.

      #6 is interesting, because it's more that he doesn't trust Rails to get the SQL right. However it sounds like he would have had a User object in PHP (I don't "do" PHP, thank fuck, so excuse any incorrect structure) and indeed can write in the main part of the code:

      $u = new User();
      $u->setFirstName("Bob");
      $u->setLastName("Marley"); ...
      $u->persist();

      and he's probably moved all the SQL code into the objects (e.g., persist(), getByUsername(), etc), indeed he mentions using a simplistic pattern to do that (thus not separating the model from the controller, but I digress). I bet the 100,000 line website has SQL splattered all over it, duplicated everywhere, I remember my first Perl website and it was ass in this respect, although reasonably structured otherwise. Now he has a 12,000 line website that probably just duplicated the previous one. No advancement in the website itself, and look at it, it's rather basic. I can't see why it couldn't be implemented in RoR quite quickly myself. I estimate a month or two for a mod_perl version once back up to speed.

      I will admit I've had similar issues with heavyweight frameworks in Java, such as JPOX/JDO which clearly has a lot of good technology in it, but lost the vision of what it was meant to be, and thus you'd end up with the same amount of less legible code to do stuff as writing the prepared statements and supporting code yourself. Add to that unexpected behaviour when extracting nested objects via JDO, and you had a stress-fest. Never again! No more setMaxFetchDepth() then getting exceptions trying to access those nested objects past the JDO stage *blubber*.

    4. Re:He makes good points, but by FooBarWidget · · Score: 1

      Yes I have. But those functions and classes *are* the boilerplate code. Why should I have to write them manually?

    5. Re:He makes good points, but by Anonymous Coward · · Score: 0

      "#1 - "IS THERE ANYTHING RAILS/RUBY CAN DO THAT PHP CAN'T DO? ... (thinking)... NO."" I might as well ask the opposite: is there anything PHP can do that Rails can't? Nope. PHP doesn't give me any reason to switch back from Rails. This entire argument doesn't mean anything.

      Well, it might be a reference to the people who treat Ruby like it was the second coming of Christ. It is a (very good) web framework, not the one true way to web salvation. You need a positive reason to use the technology, not "I need a Rails website because it's Web 2.0-tastic".

      "#3 - DON'T WANT WHAT I DON'T NEED" It's the "not invented here" syndrome. "I didn't write it, so I don't want it, I want to use everything I wrote myself." A pretty weak argument. I don't know the entire Rails core either. Nor do I have to. I use what I need, and that's it. Everything in Rails that I don't need, doesn't get in my way.

      Well, the larger the system the harder it is going to be to understand. This is pretty inevitable. I find with large complex systems there is often a gap between the (often very good) tutorials that do "Hello, World" style stuff and the full documentation which consists of 1000+ method, function and class descriptions which refer to each other in the descriptions.

      "#6 - I LOVE SQL" This is purely a personal thing. I like SQL for complex queries, but for simple CRUD operations on records, why should I have to type the same boilerplate code over and over and over and over again? It's much simpler to type

      user = User.new
      user.name = params[:name]
      user.save
      than to type

      $db->execute(sprintf("INSERT INTO users VALUES(NULL, %s)", $db->quote($_GET['user'])))
      The former is easier to read and easier to write.

      This may be because you are doing store-and-retrieve only, for which I agree SQL is overkill. However many people with databases need to do complex relational algebra which becomes very clunky when you are using a programming language and not a dedicated relational algebra declarative language such as SQL. Expressing transactions is also difficult - the abstraction becomes 'leaky'.

      "#7 - PROGRAMMING LANGUAGES ARE LIKE GIRLFRIENDS: THE NEW ONE IS BETTER BECAUSE *YOU* ARE BETTER" I really don't understand what he's trying to argue here.

      He is suggesting that the experience of understanding what Ruby and Rails were trying to do helped him become a better programmer in general, even though he ended up going back to PHP.

    6. Re:He makes good points, but by FooBarWidget · · Score: 1
      "This may be because you are doing store-and-retrieve only, for which I agree SQL is overkill. However many people with databases need to do complex relational algebra which becomes very clunky when you are using a programming language and not a dedicated relational algebra declarative language such as SQL."

      That is true, but in most web applications most database actions are of the "store and retrieve records" type. For everything else, Rails doesn't prevent you from writing SQL. Indeed, most of my websites have some SQL-based finder methods in the models, usually for querying aggregate information. I've never had to write SQL manually when saving stuff though.

      "Expressing transactions is also difficult - the abstraction becomes 'leaky'."
      Not with Rails though:

      BankAccount.transaction do
          account1 = BankAccount.find_by_name('Joe')
          account2 = BankAccount.find_by_name('Jane')
          account1.amount -= 100
          account2.amount += 100
          account1.save!
          account2.save!
          BankAccount.transaction do
      ...more database actions here, for nested transactions...
          end
      end
      If an exception is thrown within the toplevel 'do' block, then the entire transaction is aborted with a 'ROLLBACK'.
    7. Re:He makes good points, but by Anonymous Coward · · Score: 0

      ...nevermind that you can write raw SQL into rails if you really want to...

    8. Re:He makes good points, but by The+Living+Fractal · · Score: 1

      Uhm. yea.

      There's no reason you couldn't write a very quick PHP function to do basically what you showed with the three Rails lines. In fact, you you could do it all in one line...

      But, whatever.

      --
      I do not respond to cowards. Especially anonymous ones.
    9. Re:He makes good points, but by Anonymous Coward · · Score: 0

      Oh I agree, I'm not trying to spread FUD about Rails not being able to do things - it is very comprehensive and a great deal of careful thought has been put into it.

      The code you have written is certainly very clear - it is a good example of how great Rails can be. However it is not really Object-Oriented, is it? You've lost the abstraction of persistent objects floating in the ether and are basically writing imperative-style code. That's what I meant by "leaky abstraction".

      This is not a bad thing necessarily - I can't think of an obvious OO way to deal with the issue, and I prefer the appearance of the Ruby code to the equivalent SQL. However where you are writing an application that is data and query driven the object-relational mapper provides you with little benefit. A more direct approach in those circumstances might be a clearer map to the problem domain, even though it might look uglier.

      That's not to say that the great majority of web development wouldn't be better off to focus on RoR's rapid development and wide feature set, just that there are times when a direct approach is not necessarily an indication of "NIH syndrome" or incompetence.

    10. Re:He makes good points, but by FooBarWidget · · Score: 1

      I already replied to a message like this before but I will do it again:

      Give me one good reason why I SHOULD write that "very quick PHP" function. In Rails, I don't have to. Nor do I think I should have to. And writing "very quick PHP functions" 90 times for 30 different tables and 3 different applications quickly become tiresome. As I said: boilerplate code.

    11. Re:He makes good points, but by The+PS3+Will+Fail · · Score: 1

      "I really don't understand what he's trying to argue here."
      I believe his point was that the RoR code he produced was better (very vague here) as compared to his existing PHP codebase not solely because of the language but also because in comparing to his old PHP code, he'd learned better ways of doing things over the years. The point is that a piece of code you write after 5 years of experience is better than the first piece of code you ever wrote - the language may change but the quality has much more to do with your experience as a programmer.

      Is it clear now?

    12. Re:He makes good points, but by profplump · · Score: 1

      You don't have to write it. You could, like Rails does, auto-generate it. You're allowed to use code to generate code. It's a groundbreaking idea I know, but it just might work.

    13. Re:He makes good points, but by Anonymous Coward · · Score: 0

      php can generate a lot of code but not equal to easier to maintain.

      if create a lot of function that just to replace SQL , it is meaningless.
      while rails provide a whole new concept that , object is the only thing we need.
      table entire is mapping to object that can be use in has_many , belongs_to relationship.
      I don't think using pure php can do so.

    14. Re:He makes good points, but by Ant+P. · · Score: 1

      Personal preference, I guess. It's like the difference between using Ubuntu and LFS -- you want other people to do all the hard work for you, but someone else might want to know exactly what their code's doing.

    15. Re:He makes good points, but by smellotron · · Score: 1

      $db->execute(sprintf("INSERT INTO users VALUES(NULL, %s)", $db->quote($_GET['user'])))

      ...writing "very quick PHP functions" 90 times for 30 different tables and 3 different applications quickly become tiresome


      There's an alternative. You could write a function once, instead of once per your 30 tables. Write it as a portable library script for your 3 applications. You're still "writing biolerplate", but I think you're overestimating the amount required:

        (as a part of $db class, or a $db subclass)
        function insert($table, $records) {
              $columns = array();
              $values = array();
              foreach ($records as $column => $value) {
                  $columns[] = $column; // assuming your literals are always safe
                  $values[] = $this->quote($value);
              }
              $sql = sprintf('INSERT INTO %s(%s) VALUES(%s)', $table,
                  join(',', $columns), join(',',$values));
              $this->execute($sql);
          }

          $db->insert('users', array('user' => $_GET['user']));

      This should work for any table (well if a column name has spaces in it, you'll need a $db->escapeLiteral() function, or a better column naming scheme!). If you ever work on more than one PHP project, it makes sense to try to carry around a common codebase between them for this.

      Everything's on a continuous scale, anyways. The less RoR you use, the more boilerplate you have to write yourself (because RoR has done all of the boilerplate for you, for basic CRUD operations). But the upside is the increase in freedom, if that is important to you.

      Ok... you wanted one good reason to write that boilerplate function. It doesn't require as drastic of a change as switching your entire web server platform. Most software developers are working on existing projects, rather than new projects. Or maybe you're working with an existing talent pool that will be difficult to migrate, or you have to interface with existing legacy PHP. Sure, use RoR for your next project, but for whatever projects that are in production, incremental change rules the day.
    16. Re:He makes good points, but by modmans2ndcoming · · Score: 1

      why are you complaining about constantly rewriting the boiler plait code? If you are using the same language, write the class once and use everywhere. in the context of our discussion I think that your complaint is unwarranted. In the end, someone has to write a class for it, if it si not written yet, then guess who the winner is?

  18. Re:thinking about something new? think again by deftcoder · · Score: 2, Insightful

    I denno, I ditched Windows for Debian Linux over a year ago and haven't looked back since. (I'm a programmer though, so my needs are a bit different than your typical Windows user)

    Then again, if this article is any indication, maybe I had better wait another year before I speak. :-)

    --
    Peace sells, but who's buying?
  19. Re:Thinking about abortion? think again by Anonymous Coward · · Score: 0, Funny

    I didn't realize Fetuses had such a command of the English language! This is astounding! We'll all have to rethink our positions on abortion now, obviously killing such a life form would be murder!

  20. Re:thinking about something new? think again by ducomputergeek · · Score: 2, Interesting
    I do the technical coding for a couple web designers (they make it look pretty and I make it work). Typically their clients have done enough research to have heard some buzz words so a typical conversation goes like this:

    Client: "We'd like our site/new site to be Web 2.0 with AJAX and Rails and....

    Web Designer: "This is the layout I've created with new logo, etc."

    Client: "Ohhh, that's pretty, but I don't like that shade of >, could you make it >, maybe a couple shades darker, but brighter...you know what I mean?"

    Web Desiger: "Sure"

    Me: "Okay now what are you looking for the site to do?"

    Client: "We want our site to be Search Engine Optimized, with built in Web 2.0 features."

    Me: "Okay, SEO is not a problem, we have a professional copy writer on staff that handles the ad copy for the pages. What keywords you you like to target in search engines?"

    Client: "Um...I want my page to be on the top of Google when they search for it..."

    Me: "Okay, is your site E-commerce: meaning your actually going to be selling goods from it?"

    Client: "No, just about our XYZ business. But it needs a Web 2.0 contact form so clients can email us from the web page and we can send them back a quote."

    Me: Okay, so you need a contact form (standard feature on just about every site we do). What else?"

    Client: "Well I need to be able to update upcoming events on a calender and news items."

    Web Designer: "We can use Joomla for that."

    Me: "Or we can find a news page script in Perl or PHP for that page with a nice easy to use backend. Same with an events calender. Then you can design your nice tabled based pages in Photoshop/Dreamweaver and I won't have to spend a week converting them to a CSS based Joomla template."

    Client: "PERL? PHP? That's not Web 2.0. It's suppose to be Ajax and something called Ruby on Rails! That is what > says about having your web site designed!"

    Me: *hands client copy of Cult Of Amateurs* And then i WANT TO SAY "Here read this and then get back to me about web 2.0. The short version: there is no such thing, it's a fancy buzzword no different than Dotcom ten years ago. Now we could everything you wanted on your site back then with CGI/PERL and now PHP and it will work.

    Instead I say, with a smile: "We can make it work."

    --
    "The problem with socialism is eventually you run out of other people's money" - Thatcher.
  21. whoops by Verte · · Score: 1

    clearly, I am also slow.

    --
    We at slashdot are scientists, specialists and kernel hackers. Your FUD will be found out.
  22. Initiation ... by ValiSystem · · Score: 1

    Think again ? no ! rush into rails learn how a good framework is built, and apply it to whatever technology you use. This is how i work, and it goes very well.

    Derek admits it at the end of TFA, too bashfully. But i don't see any shame in having to go through rails to know how to write good php code.

  23. Why do people keep comparing languages with API's? by Jugalator · · Score: 1

    Maybe he will like Ruby better than Rails? I heard that Ruby has less cruft that he disliked than Rails.

    This is getting ridiculous.

    --
    Beware: In C++, your friends can see your privates!
  24. Re:thinking about something new? think again by TheRaven64 · · Score: 3, Insightful
    I really don't understand the point or Ruby. It seems like it's semantically similar to Smalltalk, but with uglier syntax. Is it faster? Apparently not. On average, Ruby is 1/5 the speed of Smalltalk, and in some cases much worse. In only one test was it faster; startup (not important for long-running processes, such as stateful web apps).

    So, we have a slow language, with ugly syntax. The ugly syntax is subjective, so we'll overlook it for now. We have a slow Smalltalk, but maybe the framework makes up for it. Looking at Ruby on Rails, it seems like a cheap clone of the old NeXT WebObjects (cloned as GNUstepWeb and SOPE, uses Objective-C, which is typically faster than Smalltalk), and so far behind something like Seaside it's not even funny.

    So, why do people use Ruby? Or is it like Java, as Guy Steele said:

    And you're right: we were not out to win over the Lisp programmers; we were after the C++ programmers. We managed to drag a lot of them about halfway to Lisp. Aren't you happy?
    --
    I am TheRaven on Soylent News
  25. Yeah, the One True Way by Colin+Smith · · Score: 2, Insightful

    LISP.

    --
    Deleted
  26. sad by m2943 · · Score: 2, Interesting

    You know, the sad thing about all the comparisons you make is that they are all choices between bad technologies. Assembler vs. PL/I, C vs. Java, Windows vs. Linux--they're all questions like whether you want to be drawn or quartered, drowned or burned, poisoned or starved. At each of those choice points, there were better technologies available.

    As for PHP vs. Ruby, both technologies suck: except for minor differences in syntax and object model, they are naively designed and implemented. After decades of research in dynamic languages and OOP, it is a testament to widespread ignorance that people would produce and use something like that.

    But if I have to work with bad technologies, the one that's more popular, more mature, and more widely supported one is, relatively speaking, better. That's why I prefer to be poisoned with PHP rather than starved by Ruby: poison is quicker and less painful.

    1. Re:sad by iBod · · Score: 1

      >>I prefer to be poisoned with PHP rather than starved by Ruby: poison is quicker and less painful.

      Ha ha! My thinking exactly.

      I feel you are correct in your assessment of these (and other) technologies that abound now.

      They were designed by skilfull amateurs and enthusiastic students, who knew problem they needed to address, and addressed it pretty well, but without the benefit of deep technical knowledge and experience.

      If everyone had waited for heavyweight pros to address the problem, we'd still be waiting, or be working with some horrible kludge (a camel is a horse designed by a committee etc.).

      So viva PHP! and viva Ruby!

      They aren't perfect, and nothing ever is, but they power a great deal of the web, very effectively and usefully.

    2. Re:sad by sg_oneill · · Score: 1

      Part of the problem is, if we are really objective about it, the lisp/scheme family of languages are probably about as close to 'well designed' perfect as we will get. Conceptually.

      The problem with them is you pretty much have to unlearn so much of the ideas we take for granted in imperative languages, so much so, its been sugested your better off promoting scheme by teaching it to children then causing experienced programmers mind haemorages.

      Even Haskell might be a candidate, but holy fucking shit will I never get used to some of its ideas. Algebraic values that don't change, totally non imperative, monads, and .... aaahhh my brains on fire again.

      Because of this, I'll stick with my beloved python and hope one day, just one day, it catches on that I'll regularly get employment doing it.

      --
      Excuse the Unicode crap in my posts. That's an apostrophe, and slashdot is busted.
    3. Re:sad by iBod · · Score: 1

      >>Because of this, I'll stick with my beloved python and hope one day, just one day, it catches on that I'll regularly get employment doing it.

      Good philosophical viewpoint there.

      Agree about lisp etc in terms of purity and elegance but a successful language must not place purist impediments in the way of the majority of potential users.

      PHP succeeds like it does because it is a readily-understandable, practical tool, and it's easy to apply PHP to the problem in hand. Python is great in certain problem domains but doesn't have the sheer 'applicability' of PHP.

    4. Re:sad by m2943 · · Score: 2, Interesting

      If everyone had waited for heavyweight pros to address the problem, we'd still be waiting, or be working with some horrible kludge (a camel is a horse designed by a committee etc.).

      The heavyweight pros did address the problem, many times: Modula-3, Smalltalk, Sather, APL, OCAML, Haskell, Scheme, EuLisp, Icon, and on and on. What those languages lack are user communities.

      They aren't perfect, and nothing ever is, but they power a great deal of the web, very effectively and usefully.

      Ruby does not power the web; it is late to the party and offers no compelling advantages. If we need simplistic scripting languages, between Perl, Python, and PHP, we really have the bases more than covered. Ruby is superfluous. (Well, I suppose if it managed to kill Perl and replace it, that would be some minor progress, but I don't see that happening.)

    5. Re:sad by m2943 · · Score: 1

      The problem with them is you pretty much have to unlearn so much of the ideas we take for granted in imperative languages,

      Oh, nonsense. CommonLisp is an imperative language whose primary difference to Python is that people invested several decades in figuring out language semantics that could be compiled fairly reasonably. There is little difference between


      (loop for i from 30 downto 1 by 1 do
                  (print i))


      and


      for i in range(30,0,-1):
              print i


      except that the CommonLisp version is perhaps a little clearer and doesn't require special-casing in the compiler (it started out as a user-contributed macro).

      I'll stick with my beloved python and hope one day, just one day, it catches on that I'll regularly get employment doing it.

      Python is a pretty nice language, but it took a decade to get to this point, which it wouldn't have if Guido had done his homework from the start. And with all this work, the Python runtime is still pathetic and Python still doesn't have a good IDE.

      Instead of reinventing the wheel, the Python community should consider building P3K on top of a good existing dynamic language runtime, maybe SBCL or Mono.

    6. Re:sad by iBod · · Score: 0, Flamebait

      Agree Perl needs to be killed. It's a hopeless and dangerous irrelevance now.

    7. Re:sad by Splab · · Score: 1

      Well said. I've been programming PHP for quite some time and tried Ruby, for me it was more of the stupid stuff but none of the good stuff, and since I have all my code in PHP there was no point in switching.

      (Well I used to do PHP, these days I do C++)

    8. Re:sad by JimMcCusker · · Score: 1

      Oh for heaven's sake, that's not idiomatic python. This is equivalent:

      [print i for i in range(30, 0, 1)]

    9. Re:sad by jnana · · Score: 1

      >>> [print i for i in range(30, 0, 1)]
      File "<stdin>", line 1
      [print i for i in range(30, 0, 1)]
      ^
      SyntaxError: invalid syntax
      >>>

      You hit the "print is a statement" design flaw. If you were thinking p3k, then it requires parentheses.

    10. Re:sad by daveinthesky · · Score: 1

      Yup. I love getting my workmates with that one.

      I challenge them to a bet claiming that they cannot implement python's "print" in python (unlike lisp, where you can probably implement most of lisp in lisp itself). "Yes you can!" they always claim. heh heh heh..

      Gets them everytime!

    11. Re:sad by m2943 · · Score: 1

      Your code is wrong and it is certainly not idiomatic.

      More generally, using list comprehensions for side effects is just about the most awful programming style imaginable. Shame on you.

    12. Re:sad by nuzak · · Score: 1

      There's nothing hard about monads conceptually. The >>= operator is like a pipe, and >> is like a semicolon. The return statement is really badly named, and I can't offhand think of something it's related to, but it's not too hard once you get it. It's not really so different than learning loops and if statements -- it's just different kinds of control flow.

      The problem comes when you fit different monads together, because they all have different types, the syntax for interfacing them is confusing and arcane, the type system is highly unforgiving, and you don't get any help doing it. Basically, it's not monads that are throwing you, it's the type system. You can use monads in languages that aren't as strongly typed -- they still have their uses -- and they're not nearly as painful as they are in Haskell.

      And once you grok monads, you get to deal with things like Arrows and functional dependencies and whatever other shiny thing found its way into Haskell. Arrows actually seem a bit simpler than monads (because they're basically a subset), but I've never found a decent description of fundeps.

      --
      Done with slashdot, done with nerds, getting a life.
    13. Re:sad by JBv · · Score: 1

      print range(30, 0, -1)

  27. Article doesn't make sense by Blackknight · · Score: 1
    So rails sucks because you don't know how to use it? This article could apply to any language. Thinking about PHP? Think again, perl doesn't everything PHP can do and then some.

    When you're writing a project you need to look at what your existing code base uses and choose something that integrates with it, or just stick with what you know. Every application our company uses is written in perl and they run great, HTML::Mason makes it a lot like PHP any way.

    % print "Hello world!" isn't much different from

    <?php echo "Hello world!"; ?>
    1. Re:Article doesn't make sense by budgenator · · Score: 1

      Rails is to Ruby as Symfony is to PHP. I've tried Symfony myself and real had a hard time getting my head around it, likewise I'd probably have the same problem with RoR only worse because I'm more attuned to PHP or Perl, I do find that by using the Smarty templateing engine and MDB2 Database API that what I'm working on has shrunk dramatically and is much easier to understand. There are several Perl equivalents on CPAN, that are probably more reliable and mature than the PEAR equivalents in PHP, I assume that the only reason they aren't used more is because embperl is more arcane to use than PHP.

      --
      Apocalypse Cancelled, Sorry, No Ticket Refunds
  28. Re:thinking about something new? think again by MikeBabcock · · Score: 2, Interesting

    My wife and I ditched Windows for Linux 8 years ago at home. I stopped dual-booting and everything -- no more Windows, period. I still have to use it at work, but my wife didn't for years working in retail. One day, she had to use Windows at work and found it dreadful, I chuckled to myself.

    Yes, some of us are very happy over the long term using Linux. Am I a system administrator? Yes. Do I program? Yes. Am I the average Joe Computer User? No. Does my wife get a free sysadmin with the ability to recode around bugs? Yes.

    Just my $0.02, take it or leave it :-)

    --
    - Michael T. Babcock (Yes, I blog)
  29. 7) How far will it scale by giafly · · Score: 4, Insightful
    After 30 years development, "How far will it scale" is
    • the question that scares me most,
    • the one that you can never get honest information about from OS or component suppliers,
    • and the one that's hardest to test because the most-used features are rarely those you expected.
    Who said "prototype the thing, assuming a worst-case scenario"? No can do. With server code, this means you leave out features or spend $$$s more on hardware. And with client code such as AJAX, you know anything could break if used alongside idiot third-party widgets or when another IE patch makes Javascript even slower. You just don't know exactly where it will break in practice. So you add a lot of logging and try to spot when the next bottleneck is approaching. Worst case, it's in obfuscated, third-party modules that you can't change in practice, and you're re-factoring masses of code while angry villagers are breaking down the door. This is IMHO a risk with programming frameworks like Ruby on Rails, or MS dotNet for that matter.
    --
    Reduce, reuse, cycle
    1. Re:7) How far will it scale by mcrbids · · Score: 2, Informative

      After 30 years development, "How far will it scale" is

              * the question that scares me most,
              * the one that you can never get honest information about from OS or component suppliers,
              * and the one that's hardest to test because the most-used features are rarely those you expected. After my 10 years of development, "How far will it scale" is
      • the question that scares me most,
      • based only on an honest assessment of how I structure the software, and
      • utterly irrelevant to OS or component suppliers


      Seriously - if you want to scale, you need to avoid the Shlemiel the painter's algorithm. Avoid this sucker with passion and verve. Hunt for ANY CASE where this algorithm is hard at work, sucking away CPU cycles endlessly towards the abyss of swapped memory, session timeouts, and database deadlocks. When you've learned to look for it, you'll be amazed at just how rampant this nasty little bugger actually is.

      I wish there was something more to it than that, but I've seen time, and time, and time again, lousy performance made snappy simply by finding and refactoring code that uses this kind of algorithm. Simply put, it's code that processes each bit of data slower as you add more total information to process.

      And that's where PHP shines incredibly bright. For as much as you'd hate to admit it, Java's server "shared" VM is a variation of the dreaded painter's algorithm, as is any other form of "shared environment". PHP shares nothing. Each hit is unique, and the only thing that's shared are a few session variables. So, if you structure your application right, you can have 100 servers all serving your PHP application, no matter how computationally dense it is.

      And that, brother, is the key to real scalability - Knowing that you can add performance in a linear fashion as the amount of information processed grows. If load climbs faster than the amount of information being processed, hunt the painter! He's in there somewhere...
      --
      I have no problem with your religion until you decide it's reason to deprive others of the truth.
    2. Re:7) How far will it scale by olip · · Score: 1

      Thanks for this refreshing pointer to Joel's article.

      Java's server "shared" VM is a variation of the dreaded painter's algorithm, as is any other form of "shared environment". PHP shares nothing.

      I strongly disagree. Java has Pascal-style strings, so no painter performance penalty. Java does not share things so that you can't scale by adding new servers. Actually the session system is very similar to PHP : session variables are stored in memory, so your load-balancer has to manage session/server affinity, and if you can't afford to lose your session data, you have to activate session replication an this is a PITA (both design- and performance-wise), anyway you should not rely on session data in the first place.

      Usually, Java performance mostly depends on developper culture, quantity of black-box code, and the use of XML. I've seen really awesome performance achieved in Java.

    3. Re:7) How far will it scale by mcrbids · · Score: 1

      Actually the session system is very similar to PHP : session variables are stored in memory, so your load-balancer has to manage session/server affinity, and if you can't afford to lose your session data, you have to activate session replication an this is a PITA (both design- and performance-wise), anyway you should not rely on session data in the first place.

      But this isn't all that similar. PHP Session variables are stored in any number of places - on disk, in memory, in a database, or in any user-defined manner, which leads to interesting possibilities such as ShareDance.

      This gives you the ability to decouple session management from any specific server - your load balancer doesn't have to care one whit about sessions, making their use much more reliable and trustworthy. BTW, ShareDance scales VERY nicely, and for me, took about 20 minutes to install.

      Usually, Java performance mostly depends on developper culture, quantity of black-box code, and the use of XML. I've seen really awesome performance achieved in Java.

      Yes, you can avoid the painter's algorithm in Java, too. =) I didn't mean to pick on Java, but it's shared environment does cause issues when you try to get it to scale.

      --
      I have no problem with your religion until you decide it's reason to deprive others of the truth.
  30. framework != language by BestNicksRTaken · · Score: 2, Insightful

    thats because rails is a web FRAMEWORK not a programming language - you know RUBY is underneath it all, right?

    people get too tied up with cms's that they think will do everything. code a plugin yourself (assuming a decent api is available).

    --
    #include <sig.h>
    1. Re:framework != language by Anonymous Coward · · Score: 0
  31. Beautiful code by August+Lilleaas · · Score: 1

    To me, Rails is about beautiful code. At my level of app-making, I don't need huge performance and blah and blerg. All i care about is nice looking and agile code, really.

    But, of course, we all need to be told that apples is better than bananas.

    1. Re:Beautiful code by betterunixthanunix · · Score: 1
      Well, it really depends on what you are trying to do. Personally speaking, if I were designing some sort of publicly accessible website, I would be looking at what will perform best under very heavy loads (and CGI programs running on a system with highly optimized forking win on this, in my opinion. And apparently in the Slashdot maintainers' opinions, since this website is coded in PERL). If you are coding something for an internal intranet in a medium sized corporation, you might have a bit more flexibility, and can get away with a heavier framework to make your life easier.

      Then again, I advocate writing web apps in C++ or Ada, so you might be inclined to accuse me of being 20 years behind the times. I'll say this: if you can handle the formal design process, a C++ web app is no problem at all.

      --
      Palm trees and 8
    2. Re:Beautiful code by iBod · · Score: 1

      >>All i care about is nice looking and agile code, really.

      Oh really?

      And what do your client care about (assuming you're a professional)?

      BTW your website sucks for usability - black text on dark gray background!

    3. Re:Beautiful code by Anonymous Coward · · Score: 0

      and CGI programs running on a system with highly optimized forking win on this, in my opinion. And apparently in the Slashdot maintainers' opinions, since this website is coded in PERL

      Perl (not PERL) is not CGI. Slashdot uses mod_perl.
    4. Re:Beautiful code by August+Lilleaas · · Score: 1

      I am my own client, troll declined!

      Oh, and about the poor attempt on hurting me by saying how much my website sucks: I agree. And I'm as annoyed as you are about that. That's why I made an accessible version, but that link is pretty much impossible to find. And it's not like the accessible version is very accessible either.

      Finished! Move on, find someone else to harass, please.

    5. Re:Beautiful code by iBod · · Score: 1

      I'm sorry.

      I wasn't trying to hurt you, or troll you.

      I don't make it my business to 'harass' anyone either.

      Maybe you're a little too sensitive. When you post on /. you have to take the rough and tumble that goes with that. It's nothing personal.

    6. Re:Beautiful code by August+Lilleaas · · Score: 1

      Is "being on slashdot" an excuse for not calling what you just did a troll? =P

    7. Re:Beautiful code by iBod · · Score: 1

      Oh just grow up for fuck's sake.

      Go outside and play. Make friends with the other children.

    8. Re:Beautiful code by August+Lilleaas · · Score: 1

      The good old "grow-up" situation! I need to stop discussing with trolls, they'll just take you down to their level, which they are much more familiar with than me! They're always winning like that.

      *poof*

    9. Re:Beautiful code by iBod · · Score: 1

      Oh, the good old "call anyone who I disagree with a 'TROLL' situation".

      Yep, that's ok pal. Just try calling everyone a 'Troll' in real life.

      Learn to stand your own arguments upright. Get out of your room and your 17" LCD viewport.

      *POOF* indeed!

    10. Re:Beautiful code by Anonymous Coward · · Score: 0

      The Ruby zealots are always easy to spot...notice the use of the words "agile" and "beautiful code," neither of which the author likely has a fucking clue as to the meaning of. This is one of the tell-tale signs that a Ruby zealot infestation may have worked its way into your thread.

      The more you know!

    11. Re:Beautiful code by Tablizer · · Score: 1

      If you want "beautiful code", just print it in the Curlicue font :-)

  32. Why did he do it in the first place? by roman_mir · · Score: 1

    The guy says he's got a company with many people already using PHP and all the systems being coded that way. It is only logical to continue with PHP and gradually improve the systems. Whether it makes sense to use Rails for any new projects remains a question. Why Rails anyway? But the reality is that if there is a team and they are familiar and proficient with a technology, then switching this technology to another one is tricky and risky. Are there any reasons for it in the first place?

    There is no silver bullet. Many people believe that any new tech IS the silver bullet, in this case it's the Rails. But the reality is that at the end of it there will be the same mess in the code and the team will have to learn everything from scratch and then, once lots of code is done in Rails there will be yet another 'newest/greatest/shiny' thing that will come alone and will move Rails to the second shiny place.

    The only thing that makes sense in any kind of situation is to find a suitable technology that works and stick to it, making sure that the team become familiar with it and once everyone is familiar and there are standards that are followed, the solutions will be created that will work. Then the real question will remain, just like it always remains: What are the business requirements?

    Cheers.

  33. Basically by Anonymous Coward · · Score: 0

    The guy rewrote his code properly. It scares me when people make claims like "all business logic and HTML is separate". Of course it's separate, unless the author(s) of the code are hopelessly incompetent.

    The guy says he 'loves SQL' but actually mixing SQL and PHP in your business logic is a necessary evil. I hate SQL and consider it bad form to mix it with application code. Active record and friends are attempts to closer map databases to the application language. A noble goal that ends up adding significant overhead and being less expressive than SQL. I've also experimented with automated query generation and concluded that anything above basic SELECT generation is impractical.

    As for RAILS (which I don't like), the same criticisms could be equally applied to countless PHP frameworks. My custom framework now consists of a class loader and 3 - 4 supporting libs. There's nothing to enforce MVC or dictate how the framework is used because that itself ends up being limiting.

    1. Re:Basically by Anonymous Coward · · Score: 0

      You should take an SQL class. Seriously.

    2. Re:Basically by Anonymous Coward · · Score: 0

      And you should take a reading comprehension class. Seriously.

  34. (I'm the author of the article) - Please read: by linuxbaby · · Score: 5, Informative
    Hey gang -

    Longtime Slashdot reader, surprised to find my little personal blog post on Slashdot today, especially since the lead-in description framed it with the completely wrong point.

    I never said "the project was cancelled because of limitations of Rails" - more like I spent two years trying to make Rails do something it wasn't meant to do, then realized my old abandoned language (PHP, in my case) would do just fine if approached with my new Rails-gained wisdom.

    That's all.

    1. Re:(I'm the author of the article) - Please read: by Bodhidharma · · Score: 1

      I understand the temptation to try something new. I've wanted to do something in Rails but haven't had the time. Also, I've grown suspicious of frameworks in general. A lot of people swear by Struts, Spring, Rails, Grails, etc. I think frameworks can make easy things dead simple but hard things almost impossible. I do all my web apps as hand rolled MVC using servlets and JSPs. I've never coded myself into a corner with that.

      --
      A dyslexic man walks into a bra.
    2. Re:(I'm the author of the article) - Please read: by Anonymous Coward · · Score: 0

      You're serving XHTML 1.1 as text/html to IE, IIRC the specs say you "MUST NOT" serve xhtml 1.1 as text/html. If you want to do this you should switch the doctype to XHTML 1.0 strict. You should also be sending a Vary header to indicate you're serving different content based on the clients accept string.

      Love the basic HTML layout though, a brave choice for a music site ;-)

    3. Re:(I'm the author of the article) - Please read: by z_gringo · · Score: 1

      We with with python for some things a while back, and I am now putting those back into PHP, which is what everything else in the company is in. I think some of these were kind of trendy and were adopted sooner than they needed to be. I don't hate python either, but I think we are better off in PHP. I had recently heard a few people saying that PHP is obsolete or whatever, but I don't think it is going anywhere anytime soon.

      --
      -- -- Warning. Do not stare directly at the sun.
    4. Re:(I'm the author of the article) - Please read: by Gnavpot · · Score: 2, Funny

      surprised to find my little personal blog post on Slashdot today, especially since the lead-in description framed it with the completely wrong point

      I am very tempted to use the "You must be new here" /. joke.

      Slashdot summaries are always written like this. I don't know if the editors/submitters do not understand the point of the article they are linking to, or if said editors/submitters are so biased that they want to prove another point, using that article.
    5. Re:(I'm the author of the article) - Please read: by icepick72 · · Score: 3, Insightful
      This whole debacle on Slashdot isn't a result of the lead-in description. Anybody who has commented on the 7 points has read the original article in its entirety (well, hopefully!). There are many good discussions occurring around your points, some favorable, some not, but it's all good in the end.

      I have one burning question: What is the take of Jeremy Kemper (aka bitsweat) on this situation? Being "one of the best Rails programmers in the world", many of us would like to hear from him. Has he blogged or posted about this too? (need a link) Does he share the same view points on the situation?

    6. Re:(I'm the author of the article) - Please read: by meekers · · Score: 1

      I presume that they are serving XHTML as text/html to Internet Explorer since application/xhtml+xml does not work correctly in it. Your recommendations seem reasonable otherwise unless there is something that forces them to use XHTML 1.1 rather than XHTML 1.0. I should note that according to http://www.w3.org/TR/xhtml-media-types/#summary, serving XHTML 1.1 as text/html is a "SHOULD NOT" rather than a "MUST NOT", so they can continue to serve the document as text/html without breaking standards outright.

    7. Re:(I'm the author of the article) - Please read: by icepick72 · · Score: 2, Insightful

      Hey, if Jeremy Kemper is one of the best, did he raise any warning flags along the way? Do you think he could have curbed the end effect given his high level of expertise?

      Given that your O'Reilly Biography describes you as "Still a relative newbie among programmers, he'd appreciate any tips and advice you could give him", why is it you could pull off CDBaby in 2 months in PHP while an expert Rails programmers, including yourself as a second person on the project, could not pull it off on 2 years?

      The project doesn't seem that large after all. Had Jeremy worked on comparably large Rails projects before? If so, had he experienced the same problems before. Did he flag them to you?
      I'm not trying to lay blame. I have managed projects and seen the good, the bad and ugly and am always interested in getting the full story, from all the people involved, all opinions. Goodness knows I've pulled some doozies in my day that I'm embarrassed about.

    8. Re:(I'm the author of the article) - Please read: by seriousthought · · Score: 1

      The problem with your article is that you claim that you spent 2 years trying to make Rails do something it wasn't meant to do... and then you don't actually explain what it was that it wasn't meant to do. It sounds like from clues later in the article that perhaps you tried to shoehorn Rails ontop of your preexisting database which meant that all your table names, were not the correct format/naming scheme.

    9. Re:(I'm the author of the article) - Please read: by Anonymous Coward · · Score: 1, Insightful

      I'd also like to hear more details about what exactly was so hard in rails. I reckon that's the most useful information.

      If someone else is starting a project and considering rails this information might help them make their decision. San we heard more about what exactly was really hard to do in rails?

    10. Re:(I'm the author of the article) - Please read: by Anonymous Coward · · Score: 0

      Ya, we really need Jeremy Kemper's opinion here to fill out the story. It's unusual for a high profile developer to throw in the towel or not to see it coming until 2 years later. Do you think you can get an audience with Jeremy, maybe have him post or blog about it too?

    11. Re:(I'm the author of the article) - Please read: by Anonymous Coward · · Score: 0

      I presume that they are serving XHTML as text/html to Internet Explorer since application/xhtml+xml does not work correctly in it
      Exactly. Not all browsers accept XHTML, some do accept it and actually treat it as HTML (eg: lynx). The problem is that aren't sending HTTP Vary or cache control headers, meaning an intermediate proxy/cache may store the page as application/xhtml+xml.

      serving XHTML 1.1 as text/html is a "SHOULD NOT" rather than a "MUST NOT"

      I stand corrected.
    12. Re:(I'm the author of the article) - Please read: by Comatose51 · · Score: 1

      At the risk of being shot down myself, I have to agree with you on most points. I think your article was very sensible. More importantly, I took a similar route as you (PHP, then Ruby on Rails, and now Python/Django). I started my first web project in PHP. I loved PHP because it had nearly everything I needed and it was just so convenient. After my project launched, I realized my code was a mess. I tried to do MVC as much as possible but obviously lacked the experience to do it right. So I gave RoR a try and fell in love after getting over the initial learning curve. Active Records is simply amazing. Ruby itself is just beautiful. The use of code blocks and the ease of using introspection made it easy to write nice clean code. Still it took time and effort. My RoR project was abandoned after I moved to the Bay Area and took a new job. Then I started Python and Django on yet another new project. I'm still hacking away at it. Python is just a fun language to code in and Django is very well made, though I would say not as well polished as RoR. Both Python and Django are in some ways more "practical" than RoR but are at various points inconsistent. Ruby is very predictable after you learn it. Yesterday I revisited my old PHP code. It's still ugly code but I did get a lot done with PHP and the project was more complex than anything I've attempted since and it launched!

      PHP is an easy language to get things done. Both Ruby and Python, in my opinion, are much easier to read because you can say quite a bit in a few lines (list comprehension in Python can get hard to decipher though). So what would be interesting to know is how well you can maintain your new code and how easy it would be for someone else to do it. Personally, I would find it harder to write good and maintainable code in PHP than in Ruby and Python. In fact, I find myself digging through the Django framework code to look around but had a much harder time doing it with CakePHP (which I really don't like and prefer plain PHP over, sorry). It seems that some of it has to do with the languages they're written in.

      --
      EvilCON - Made Famous by /.
    13. Re:(I'm the author of the article) - Please read: by jadavis · · Score: 1

      why is it you could pull off CDBaby in 2 months in PHP while an expert Rails programmers, including yourself as a second person on the project, could not pull it off on 2 years?

      This is a particularly burning question, because it was a rewrite. That means all the requirements were known, and all the details worked out, all the problems solved -- in short, the Ruby programmer's work was cut out for him. All he needed to do was make a more maintainable replacement using the Ruby way in a reasonable amount of time.

      That should be the ideal (perhaps boring, but otherwise ideal) client for any programmer! What went wrong?

      --
      Social scientists are inspired by theories; scientists are humbled by facts.
    14. Re:(I'm the author of the article) - Please read: by Anonymous Coward · · Score: 0

      The article makes you sound like a decent programmer, but a real fuck-up of a manager. Use the right took for the job. A developer to code, and a manager to manage.

    15. Re:(I'm the author of the article) - Please read: by sciurus0 · · Score: 1

      I'm curious, did you ever try Symfony or CakePHP? If so, I'd be interested in hearing what you liked or disliked about them compared both to Rails and to PHP development without a framework.

    16. Re:(I'm the author of the article) - Please read: by Anonymous Coward · · Score: 0

      FWIW, I've done a lot of projects with Spring and never coded myself into a corner either. Spring isn't really a framework in the same way that Rails is. It's a collection of many small frameworks designed to inter-operate with each other and maintain a consistent philosophy (basically...everything depends on interfaces rather than concrete classes to allow user-defined implementations to be substituted to handle custom cases). This allows you to pick and choose which parts of it you use with the ability to sub out any piece of it if and when you determine that the default behavior won't work for you.

      Ironically enough, I've found JSP to be quite the opposite. It seems like every time I use JSP for anything, I run into performance problems. The fact that the syntax is incredibly painful only makes things worse. I now use FreeMarker for all my projects and have found it to make my life significantly easier. In stress tests (where JSP should shine, since it gets compiled rather than interpreted), we've found FreeMarker to be anywhere from 2 to 20 times faster than the equivalent Jasper-compiled JSP. Perhaps other JSP compilers are better.

    17. Re:(I'm the author of the article) - Please read: by Slashdot+Parent · · Score: 1

      I do all my web apps as hand rolled MVC using servlets and JSPs. I've never coded myself into a corner with that. Wait until you work on a complex application.

      What you describe will work fine for most any web tier (controller calls some type of business delegate that does the "real work), but try doing anything moderately complex with servlets and JSPs and you will run into trouble real quick.
      --
      They don't grade fathers, but if your daughter's a stripper, you fucked up. --Chris Rock
    18. Re:(I'm the author of the article) - Please read: by Mark+Imbriaco · · Score: 1

      As an aside, Jeremy hasn't worked for CD Baby since February when he started working for 37signals.

  35. Lame by Synn · · Score: 1

    His reasons are pretty lame.

    The biggest issue I'm having with rails is its lack of scaling due to a horrid threading model. We run mongrel, which can accept multiple requests per mongrel but only process one at a time due to Rails not being thread safe. So you end up having to run many many instances of mongrel on seperate ports to accept incoming requests. This wouldn't bo so bad, but the preferred methods of sending traffic to these mongrels(apache mod_proxy_balancer is what we use) have NO idea what the back end mongrels are doing. It'll happily send requests to busy mongrels when you have free ones doing absolutely nothing.

  36. hmmm by Vexorian · · Score: 1

    I prefer PHP, but this sounds too FUDish to support...

    --

    Copyright infringement is "piracy" in the same way DRM is "consumer rape"
  37. CDBaby.com by Anonymous Coward · · Score: 0, Interesting

    Am I the only one that's noticed that the site in question is pretty damn ugly and seems kinda primitive?

    1. Re:CDBaby.com by budgenator · · Score: 1

      One man's pretty damn ugly and seems kinda primitive in anothers elemental eligance; but yeah didn't seem like that site should have required 2 years of coding in RoR from a top of the line RoR coder.

      --
      Apocalypse Cancelled, Sorry, No Ticket Refunds
  38. Programmer vs language by icepick72 · · Score: 1
    I think his #6 point about Rails is most telling:

    #6 - I LOVE SQL Speaking of tastes: tiny but important thing : I love SQL. I dream in queries. I think in tables. I was always fighting against Rails and its migrations hiding my beloved SQL from me.

    Sounds like this guy dropped back to his default mode of putting a lot of his eggs in the database layer, which is good for speed. Some programmers handle levels of abstraction better than others. If he were to reapply Ruby/Rails again in a few years he may find his point #7 works against himself because he will have grown as a programmer.

    It would have been interesting had he listed technical more points of frustration. The high level of the article makes me think it's his own problem rather than any particular language -- he might not yet have the ability to conceptualize at a high enough level to understand the abstractions that Rails sits on. The source of frustration could be as simple as that.

    Although he sounds convincing and said he hired one of the best Ruby programmers in the world the article is lacking substance/evidence/proof. If the hiree is one of the best, I wonder -- given his investment in Ruby/Rails -- what his take on the entire situation is right now? Where is he blogging about this? I'm sure he's not discarding Rails and his outlook on that situation might not be bleak. For all we know he might be frustrated because the the author could never get the damn concepts, kept complaining about his beloved PHP, etc. (Now somebody will link to an article where the hiree is proving me wrong -- which is great -- because I've been run once before and know what it feels like...)

    The author argues that through Rail's faults he has learned which is a backhanded complement, decisively made, although he thinks it's true.

  39. Article Does Not Make Much Sense by aldheorte · · Score: 2, Insightful

    The article reads as a "I tried to use Rails without learning Rails or Ruby and gave up" story and then admits to using many of the Rails patterns in a home grown PHP solution. Well, obviously, if you are much more familiar with another language and refuse to learn the language underneath a framework, it will be hard to use that framework. Point by point:

    1. There is nothing that PHP cannot do that Rails cannot do - Well of course, and there's nothing that any language can do that Common Lisp cannot do. Almost all languages implement a Turing machine and can be used to solve any computational problem. The question is code readability, syntactical sugar, and adaptability, all important concepts. Also, the community that has grown around it that builds a knowledge base and plugins and libraries.

    2. Their entire company worked on PHP and integration was difficult - Sounds like they didn't understand RPC and services models. Sharing between different languages and platforms is an unfortunate fact of life. Also, it sounds like PHP was the problem here, not Rails, if interoperation was such a problem. "Interoperation" in the article is used oddly - it's actually more about transition to a new site, which has nothing to with the platform used and, if is such a heinous problem, is a problem with design of the new app.

    3. Didn't need 90% of Rails - Then why use it? Also, using a tenth of something is not an argument against it if it still the best tool for the job you are doing.

    4. The custom solution they jury rigged is "small and fast" - Many Rails apps are small and fast - there's no statistics or analysis here for comparison.

    5. The PHP custom app was built for to their tastes - Obviously. If you write a custom app it will miraculously suit your preferences and will probably be a very good solution to your problem. Custom apps if you can do them are often a good idea, keeping in mind the downside is that you don't have a community of knowledge, don't get patches for free, etc..

    6. He loves SQL - Fine, don't use ActiveRecord then. Or use ActiveRecord and make direct SQL calls. This goes against common wisdom, of course, regardless of platform, but if you really want to do it, it's there.

    7. Programming languages are like girlfriends? - No idea.

    The bottom line is that there are criticisms you can level at Rails or any language or framework. However, you actually have to bring facts and analysis to an argument, and this article offers neither.

    1. Re:Article Does Not Make Much Sense by perbu · · Score: 1

      I tried to use Rails without learning Rails or Ruby and gave up

      He did hire bitsweat - which is a rails core committer. You are trolling, aren't you?
    2. Re:Article Does Not Make Much Sense by Junta · · Score: 1

      The point is php did the work for him, that php was faster, and that all the failings with the php codebase were a matter of inexperience not of the language itself (i.e. his last point, though it could have been stated more plainly). A new programming tool will more often than not feel more impressive because it forces you to start from the beginning again, and you do things more easily and simply with successive iterations, even if you forced yourself to do so with the same language.

      With Rails, the problem is that the whole point, the shortcuts that the framework provided, didn't map to what he wanted to do. Your response is that 'well, he could have used Ruby/Rails, and opted not to use any of the shortcuts', but that robs Ruby/Rails of the entire advantage. Sure it's complete and you can code whatever you want, but if the shortcuts don't map to what you are doing, then it's no better than using plain php. Frameworks with very high-level primitives typically require that you shoehorn your project into their model more than the likes of php.

      Overall, his problem was that he picked a technology for the sake of the hype around it without sound technical reasoning. On the brightside, along the two years of bumbling along trying to follow the hype, he learned what he screwed up his first time around with php, and could make it better.

      --
      XML is like violence. If it doesn't solve the problem, use more.
    3. Re:Article Does Not Make Much Sense by thegrassyknowl · · Score: 1

      7. Programming languages are like girlfriends?

      Programming languages are nothing like girlfriends. Geeks want to have a lot of them and know several intimately at any one time but only ever get to know one at best?

      --
      I drink to make other people interesting!
    4. Re:Article Does Not Make Much Sense by Tablizer · · Score: 1

      6. He loves SQL - Fine, don't use ActiveRecord then. Or use ActiveRecord and make direct SQL calls. This goes against common wisdom, of course, regardless of platform, but if you really want to do it, it's there.

      What "common wisdom" is that? I agree that "helper" utils are useful for some of the more grunty aspects of SQL, but to totally hide from it is to wrap a high-level language/tool in a low-level API, which is ass backward.

  40. Re:thinking about something new? think again by 19thNervousBreakdown · · Score: 4, Interesting

    Try Ruby, code up a project in it after you actually understand the language, and you'll see the draw. For instance, just an hour ago I was writing a quick script to recurse through directories and apply ReplayGain. I had a loop like this:

    Dir.foreach(target) do |entry|
      if File.directory?(entry)
        recurse(target + '/' + entry)
      else
        dostuff(target)
      end
    end

    Later on, just on a whim, I decided I wanted it to sort the dir listing so I could judge how far it was through the process. I only had to change the first line:

    Dir.entries(target).sort().each() do |entry|

    A teensy tiny sript to be fair, but that's just an example that I was able to pull out of the last couple hours, I've done much larger things but it'd be hard to think of a good example. There's nine different ways to do everything, and they all work exactly like you'd expect. There's a million things that allow beautiful constructs, like lambda functions and yield statements, implict reference but easy to do deep copies, it goes on and on. The langugage is just an absolute joy to work with, and I'm saying this as a hard-line strict ANSI C++ programmer--so much so that I still find it hard to make myself use long long.


    The problem is, it's so easy that it attracts people who hardly understand programming. It also makes you want to try out weird new ideas. I've never looked very hard into it, but from everything I've heard about Rails and its almost code-generation level programming I get the impression that it's a great idea that got over-engineered to Frankenstein proportions, like the first home project of any size a fledgling programmer makes. Not saying these guys are that ... just that's what it reminds me of.


    One good measure I try to follow is, if you have to basically learn an entire new language to use your product, be it a framework or a word processor, unless you've purposefully designed it as a language, with all the deep thought that goes into that, you're probably doing something wrong. Really, the yardstick I try to go by is, you should only have to learn one thing to progress further, never two things at once, and it should always be apparent what directions are available. I looked over the Rails documentation and example source, and it doesn't meet that criteria.


    Ruby Isn't Rails. Check out the language, it's a thing of beauty, and it allows you to do things really quickly, really easily, and most importantly, the Right Way without a lot of extra effort (an area C++ fails miserably at, unfortunately). No, it's not the fastest language by a long shot, but haven't we always said that premature optimization is the root of all evil? They can (and in all likelihood will) fix that later. Plus, given how easy it is to add inline C, which can easily interact in both directions, make calls, construct objects, etc... well, when I discovered that it was like I was banging a smoking hot woman, who to be fair is a little slow, and I found the keys to a Porche at the bottom of her vagina.

    --
    <xml><I><am><so><damn>Web 2.0</damn></so></am></I></xml>
  41. Fond memories of PL/1 by istartedi · · Score: 1

    Late in high school, some geek friends asked if I wanted to attend a course in PL/1 with them. I thought about it for a day or so, and came to the conclusion that by the time I got to the end of college and was out in the working world, PL/1 might be history. Then, when I got out into the working world I could learn whatever specific language I had to learn. I didn't take the course.

    I'm not saying I call it right all the time. I was really skeptical about Java when it first came out, and it seems to have had a lot more staying power than I ever thought it would. OTOH, not only have I not had to code in PL/1, I've never even been at a company that was maintaining it.

    --
    For all intensive purposes, "whom" is no longer a word. That begs the question, "who cares"?
  42. Re:thinking about something new? think again by sg_oneill · · Score: 1

    Seaside would change the world, if only it had better support for templating.

    Continuation-passing style web coding. *drool*

    --
    Excuse the Unicode crap in my posts. That's an apostrophe, and slashdot is busted.
  43. Yeah, well. by stonecypher · · Score: 1

    Don't get me wrong - I'm no fan of Ruby. That said, Derek Sivers doesn't really say anything about Ruby here, except to complain that he doesn't understand it, doesn't know the standard library very well, didn't want to retrain his existing PHP staff, and has finally discovered how little of a difference the underlying language makes. He also makes the point that learning something teaches him things elsewhere, which makes it sound like Ruby is maybe his third language or so; he seems genuinely surprised that lessons learned in Language 1 carry on to Language 2. Next, he exposes his naïveté by calling PHP fast, and finally he cites his love of SQL as if it somehow has bearing in PHP vs Ruby.

    Way to go, Derek, you're becoming less of a noob today. How it is that you got onto Slashdot with that little diary note is beyond me.

    --
    StoneCypher is Full of BS
    1. Re:Yeah, well. by Anonymous Coward · · Score: 0

      Next, he exposes his naïveté by calling PHP fast,

      Compared to ruby it is and with an opcode cache PHP performs much better. The bottleneck for a web app is always going to be database queries.

    2. Re:Yeah, well. by stonecypher · · Score: 1

      Next, he exposes his naïveté by calling PHP fast,
      Compared to ruby it is
      Yeah, and compared to a wagon, a skateboard is fast; you still wouldn't make a shipping company on them. That's why it's called naïveté: it only seems like a good idea or a correct assessment if you have no idea what your other options are.

      The bottleneck for a web app is always going to be database queries.
      Sure, if you're using a standalone daemon which isn't part of your application to do your database work. Looks like you have the same problem the article author does: you don't know what your options are. Embedded databases like SQLite, modular databases like Mnesia, stream-query databases like Kdb, in-database execution like NetRexx and so on all provide databases fast enough that the script becomes the most common saddle. The reason you're used to thinking of databases as slow is that you're used to spending immense overhead on the upkeep needed for SQL style relationality, the cross-process invokation, the data copies, the opening and closing of pipes-or-sockets, and all that enormous unnessecary allocation thrash. Wake up, guy: there's more to database work than SQL. When you find yourself saying something like "the bottleneck is always going to be," nine times in ten you just need to learn what your alternatives are.

      Almost all PHP/SQL work requires nothing more complex than DETS, which has an average throughput two orders of magnitude higher than MySQL. Maybe you should stop evaluating the field when you only know about the trees over in that one little grove near the lake.
      --
      StoneCypher is Full of BS
  44. Re:thinking about something new? think again by kryten_nl · · Score: 1

    You don't charge your clients based on the number of hours it takes to fulfill their requests?

    --
    For the perfect anti-Unix, write an OS that thinks it knows what you're doing better than you do and let it be wrong.
  45. Navicat by Tteddo · · Score: 1

    I use Navicat for MySQL and I really like it. They make a PostgreSQL version too
    http://pgsql.navicat.com/

  46. not just PHP/Rails by kisrael · · Score: 1

    I see some similar things when I look at a variety of Java toolkits, some offering very OO "you can pretend you're a swing app and ignore the HTTPRequest cycle"

    I worry that a decade of homebrew Perl CGI has warped my brain, but frankly, HashMaps wrapping HTTP Request parameters seems really natural to me, and if you use a Model2+ approach w/ servlet and JSP pairs, you're writing your business logic in Java, your HTML in HTML (well, JSP... and honestly, I don't think I've ever been on a team that manage to leverage real benefit from tricks to let you edit HTML in HTML editors, and make that round trip) your CSS in CSS, your Javascript in Javascript, etc etc.

    I see the flow control stuff as glue language... directing a user from page to page just ISNT THAT HARD... and its the stuff that's tightly coupled to EVERYTHING, and so I long for that to be as simple and not-get-in-your-way as possible, so that you can spend your mental cycles thinking about the stuff that's actually doing the heavy lifting.

    Lots of toolkits offer lots of neat bells and whistles, but most really imply you need to learn the whole language and often new paradigm of thinking about flow control. And unlike APIs and things, your flow control tends not to be isolatable, so if you get something wrong, it's going to be harder to work your way out of. (And the more-OO-ish you get for flow control, the harder it'll be to make sense of your stacktrace, since the danger is that you screwed up something when establishing in your objects, not when the actual interaction was performed...)

    On the other hand, I know I tend to be resistant to new core server technologies, unless they make a SUPER clear value proposition. So I'm worried I'm going to be some crazy old curmudgeon. Still, like in TFA, the guy took some good design lessons from the new language, and then stuck with what people really know, and that makes a lot of sense to me.

    --
    SO YOU'RE GOING TO DIE: The Comic for Dealing with Death
  47. Re:thinking about something new? think again by garcia · · Score: 3, Insightful

    My wife and I ditched Windows for Linux 8 years ago at home. I stopped dual-booting and everything -- no more Windows, period. I still have to use it at work, but my wife didn't for years working in retail. One day, she had to use Windows at work and found it dreadful, I chuckled to myself.

    Funny, 10 years ago I ditched Windows (and OS/2) for Linux at home. I stopped dual-booting and everything -- no more Windows, period. I didn't have to use it at work because I was a college student and while I didn't have a wife, I had numerous girlfriends throughout that time period that had to use it when they were in my apartment or dorm. One day, I got a new computer and it came pre-installed with Windows XP and found it far more impressive than the kludge of shit I had been trying to do w/Linux to fit into a Windows world for the last (at the time) 6 years. I chuckled at myself for trying to hard for so many years when Microsoft actually had a product that worked for once.

    Yes, some of us are very happy over the long term using both Linux and Windows. Am I a system administrator? No. Do I program? Yes. Am I the average Joe Computer User? No. Does my wife get a husband that understands the best of both worlds and a network that works happily with whatever flavor we require? Yes.

    Just my $0.02, take it or leave it ;-)

  48. Re:Why do people keep comparing languages with API by Shados · · Score: 1

    Because we're not in 1985 anymore. In this day and age, languages are often (almost) exclusively selected depending on the APIs they offer. Not completly, but... Even if you're thinking about performance, that often even depends almost completly on the API you'll be using...

    Languages are becoming more and more cosmetics, its all in the API.

  49. My next framework is Stripes by Anonymous Coward · · Score: 0

    It's like Webwork/Struts 2, but without configuration files.

    http://mc4j.org/confluence/display/stripes/Home

  50. reminds me of winston churchill quote by bl8n8r · · Score: 1

    "I was nearly killing my company in the name of blindly insisting Rails was the answer to all questions, timeframes be damned."

          No folly is more costly than the folly of intolerant idealism -- winston churchill

    --
    boycott slashdot February 10th - 17th check out: altSlashdot.org
  51. Try CakePHP! by mararual · · Score: 1

    CakePHP ( http://www.cakephp.org/ ) is a framework with all the advantages of ruby on rails, but using PHP as it's language. So is a very good option for every PHP programmer who wants order, flexibility and ease of use, avoiding repetitive tasks such as CRUD and the use of helpers (i.e Html forms, Ajax) to increment productivity and maintenance. As stated on their website:
    "Cake is a rapid development framework for PHP which uses commonly known design patterns like ActiveRecord, Association Data Mapping, Front Controller and MVC. Our primary goal is to provide a structured framework that enables PHP users at all levels to rapidly develop robust web applications, without any loss to flexibility."
    For a nice introduction read the manual ( http://manual.cakephp.org/ ) and try the 15 minute blog tutorial, and for scripts, plugins, and a lot of community code try the bakery ( http://bakery.cakephp.org/ ).
    Any programmer that wants Rails' advantages combined with PHP's flexibility, documentation, server support should try this. Greetings

    1. Re:Try CakePHP! by mmxsaro · · Score: 1

      Yes yes, Cake rocks!

  52. Re:thinking about something new? think again by foniksonik · · Score: 1

    What you should have said is "What's your budget?" "$XX00.00"

    "Oh, well in that case we're going to have to skip straight to Web 3.0, the leaner meaner more efficient web! More ROI ya know!" "Really? What about 2.0?" "Oh that's what the expensive Agencies want to sell you on so they can charge millions for a website. They get the marketing magazines to interview them and hype it all up. BUT we are already ahead of the curve.... we do AJAX and MVC without all the overhead of RAILS or those other big packages... it's like buying an RV when you really just want to go to the Beach ;-p way to much crap to bring along."

    --
    A fool throws a stone into a well and a thousand sages can not remove it.
  53. Only one way to learn... by Gazzonyx · · Score: 1

    But if all my l337 friends are using a screwdriver to pound in a nail, doesn't that mean I'm obliged to follow them? "Yes, yes, please, by all means..."
    *stands around whistling, tapping foot and checking watch every few minutes*

    "Ah, back already? That's a mighty nice cast you're sporting there! Now, what did you learn? And, what are you going to do next time your 1337 friends have a bright idea?"

    --

    If I mod you up, it doesn't necessarily mean I agree with what you've said, sorry.

  54. PHP!? Oh the humanity!... by Cultural+Sublimation · · Score: 1

    Ah, the title seemed promising: someone had come to the conclusion that there is a world outside of the Rails hype-machine. Perhaps they were telling us to look into the truly innovative frameworks, such as Lift (for the Scala language), or even Ocsigen (for the OCaml language). But no. They decided to go back to PHP!? I am confused: is this story about S&M fetishes?

    I have been using Ocsigen myself for a few months now. It is based on OCaml, so it's very high-level while still being extremely fast (it can be compiled into native code, comparable in speed to C++). Moreover, OCaml has very strong types, and Ocsigen leverages that type-safety to ensure the produced markup will always be Xhtml compliant and that there are no inconsistencies or broken links within a website. Heck, you can even extend that type-safety into the database access, so there is no chance that you'll be processing data the wrong way. And best of all, all mistakes are detected at compile-time! It really is a pleasure to use...

  55. People are missing the last line by cortesoft · · Score: 2, Insightful

    Ok. All that being said, I'm looking forward to using Rails some day when I start a brand new project from scratch, with Rails in mind from the beginning. That seems to me that he thinks RoR will be a good framework to use, when he doesn't have the limitations of switching a current project to it. That is more a criticism of trying to rewrite a web app in a new language for no good reason than rails itself.
  56. Dumbass by danielk1982 · · Score: 2, Insightful

    Why would you throw out perfectly good code and rewrite everything?

    There's nothing wrong with PHP, especially if the current implementation does the job.

  57. Re:Why do people keep comparing languages with API by Shados · · Score: 1

    Wow, how did THAT happen? I replied to the wrong person in the post below... Eeesh, whoooops.

  58. Silver Bullet Syndrome by codepunk · · Score: 1

    Sounds like a classic case of silver bullet syndrome to me. Develop software for long enough and
    you will likely observe many who are afflicted with this nasty disorder. I cannot begin to tell you how many times I have been asked to implement the silver bullet, usually coincides with the vendor hosted golf game. Hundreds of thousands of dollars spent to implement a silver bullet that in most cases increases maintenance costs, bugs, performance issues etc and provides "zero" return on investment.

    If it is not broke, don't fix it. In this case the author had sloppy hard to maintain php code
    on the server. He finally came back to the solution that makes sense(fix the sloppy code) and drop
    the silver bullet.

    --


    Got Code?
  59. Excuse me, you didnt have to attempt it to know it by unity100 · · Score: 1

    Rails was a 'framework' built on php. Php was something that is built on C, to work with web pages.

    php is at the correct level (as far as the low levelness go), both upwards and downwards.

    its low level enough to allow you to do anything that a web page can do, and its high level enough to be whats c to assembler in programming.

    there isnt anything surprising with this.

  60. My take on the article by What+the+Frag · · Score: 1

    "1 - IS THERE ANYTHING RAILS/RUBY CAN DO THAT PHP CAN'T DO? ... (thinking)... NO."

    Very weak argument. You twist Ruby and PHP with the same result. Works also well for other high level languages.

    "2 - OUR ENTIRE COMPANY'S STUFF WAS IN PHP: DON'T UNDERESTIMATE INTEGRATION"

    Why ditch existing programs anyway?? Why not just use it for new projects?

    "3 - DON'T WANT WHAT I DON'T NEED
    I admire the hell out of the Rails core gang that actually understand every line inside Rails itself. But I don't. And I'm sure I will never use 90% of it. [...]"

    So in case you need a tool of the 90% you can consider happy that it already exists.

    "[...] With my little self-made system, every line is only what's absolutely necessary. That makes me extremely happy and comfortable."

    And if you need another feature you have to implement it yourself, rather than using the existing wheel which was implemented 10000 times before.

    "4 - IT'S SMALL AND FAST
    One little 2U LAMP server is serving up a ton of cdbaby.com traffic damn fast with hardly any load."

    You rails application looks also very well after posted on slashdot.

    "5 - IT'S BUILT TO MY TASTES I don't need to adapt my ways to Rails.[...]"

    Fine, than don't use it.

    "[...] I tell PHP exactly what I want to do, the way I want to do it, and it doesn't complain. [...] "

    Well, and I tell Ruby exactly what I want to do, the way I want to do it, and it doesn't complain unless I make an error.

    "[...] I was having to hack-up Rails with all kinds of plugins and mods to get it to be the multi-lingual integration to our existing 95-table database."

    If you are not happy with a 3rd-party plugin then why not write your own? You said before that you like to write code for yourself which is absolutely necessary for you.

    "6 - I LOVE SQL
    Speaking of tastes: tiny but important thing : I love SQL. I dream in queries. I think in tables. I was always fighting against Rails and its migrations hiding my beloved SQL from me."

    You can if you want. Nobody is telling you that you have to use ActiveRecord. And for migrations, you always can use the execute statement for own queries.

    "7 - PROGRAMMING LANGUAGES ARE LIKE GIRLFRIENDS: THE NEW ONE IS BETTER BECAUSE *YOU* ARE BETTER [...]"

    I don't fully understand this headline.

    "[...] Rails was an amazing teacher. [...]"

    It's a framework, not a teaching software. Every good specialized framework will tell you how to do the things the frameworks' way. Almost always you can roll your own way if you want/need.

    "[...] But don't forget you wrote that PHP years ago and are unfairly discriminating against it now."

    So, your code has feelings? Your code has human rights? This argument is not logical. Logical would be: What's the cost of riding the old framework and what is the cost of the new framework?

    Well I did on my old PHP project. The PHP code was a mess, badly designed. The "version 2" is written in Rails / Ruby-GTK GUI, with complete revisited data structures, resulting in a far more flexible application.

    Before posting such a pointless article, please think about what expectations you had when switching to Rails. Don't expect somebody is coding the project for you or convert your messy PHP stuff to nice looking Ruby stuff automatically.
    If you don't want to re-do the project, you should better keep away from re-implementing it.

  61. Re:thinking about something new? think again by TheRaven64 · · Score: 4, Insightful
    Nice strawman reply. To my question 'why would you choose Ruby over something like Smalltalk,' you replied 'because Ruby is better than C++.' While this is true, most things are better than C++. The only advantage C++ has over languages like Smalltalk, Lisp, Haskell, OCaml or Ruby is execution speed.

    Everything you've said is good about Ruby also applies to Smalltalk, which uses blocks (closures) to implement all control structures, has trivial syntax (the entire language can be defined on a single piece of paper, and taught to small children with no programming experience in a few hours). It's obvious that the choice between Ruby and C++ is not necessarily simple; Ruby has higher-level abstractions, C++ has faster execution speed, so the choice depends on which is important. The question is, why would you choose Ruby over any of the following:

    • OCaml
    • Haskell.
    • Common Lisp.
    • Smalltalk.
    These all have the same high-level abstractions as Ruby (more in some cases). They are all mature languages, and they are all 5-50 times faster in terms of execution speed than Ruby. I understand why you would choose a slow-and-expressive language over a fast-but-less-expressive one, but why would you choose a slow-and-expressive language over a fast-and-expressive one?

    Even Objective-C can do most of what you claim is great about Ruby, and some other things. For example, I have a category which allows me to send messages to arrays as if they were individual objects and have it perform a map operation in Objective-C, and I've implemented futures in the language, and yet I would still choose Smalltalk over it for anything where speed is not critical.

    I would hope, by now, that everyone knows that pretty much any language is better than C++, so 'better than C++' is not much of a recommendation anymore.

    --
    I am TheRaven on Soylent News
  62. Comparative languages by fishbowl · · Score: 1

    I no longer enjoy comparative language discussions with people who haven't at least taken, or preferably taught, university-level course
    in automata, grammars, compiler development, and who have programmed in a wide variety of language paradigms, e.g., you've got a really strong basis to compare Lisp to Haskell to XSLT, C to Java to Ruby, etc.

    Otherwise it always seems like getting into an argument with users of a consumer product over which "brand" is better, and the reasoning in the argument is rarely compelling. The author had a project that failed. They think they know the reasons. That's all I can take from it.

    --
    -fb Everything not expressly forbidden is now mandatory.
    1. Re:Comparative languages by jebblue · · Score: 1

      It didn't take me more than a week of earnestly looking at Rails to discover it isn't even half-baked. Of course if I had come from a university background, I'm sure this exercise would have taken at least a year or two.

  63. Re:thinking about something new? think again by Anonymous Coward · · Score: 0
    Wise words. I too fear and hate human progress. Some more:
    • Thinking about ditching the cave for a house? Think again.
    • Thinking about descending down from the trees? Think again.
    • Thinking about crawling out of the ocean? Think again.
  64. Because by munch117 · · Score: 1

    Why would you throw out perfectly good code and rewrite everything?
    Read TFA: He rewrote a 90K app in 12K. That should tell you that in this particular instance, a full rewrite was called for.
    1. Re:Because by danielk1982 · · Score: 1

      This is slashdot. Why would I RTFA?

  65. Re:thinking about something new? think again by xENoLocO · · Score: 1

    I don't see how it's beautiful. To the untrained eye it looks like PERL. In addition, say it takes you 5 minutes to make a script in Ruby, and me 10 minutes to make that script in PHP. With the difference in processing time, eventually that 5 minutes will be gained back and then some. ... and I won't have to spend money buying another server once I get a few thousand daily visitors.

    --
    "The need to build the internet comes from something inside us, something programmed... something we can't resist."
  66. #7 - PROGRAMMING LANGUAGES ARE LIKE GIRLFRIENDS by Dr_Barnowl · · Score: 3, Insightful

    This is his best point.

    My VB coding improved immeasurably after I learned C#. And I'm not just talking VB6, I'm talking VB3 as well.

    Learning a new language can teach you to do so much better in your old ones. I am *still* more productive, if you want something fast, in VB6 than I am in Java or C#. I can knock together a small cheap GUI very fast.

    Of course, sometimes you do run into the limits of your chosen platform. VB6 strings are all 2-byte unicode internally, which makes dealing with UTF-8 a real pain. Then the ugly kludges start coming out.

  67. Re:thinking about something new? think again by Anonymous Coward · · Score: 1, Insightful

    No, it's not the fastest language by a long shot, but haven't we always said that premature optimization is the root of all evil? They can (and in all likelihood will) fix that later.
    The fact that premature optimisation is bad does not excuse writing slow software.

    The point of that particular quote is not that you should write slow code. It is that you should base your optimisations on measurements rather than assumptions -- so you only work on the real bottlenecks, so you know when it's "fast enough", and so you can make informed decisions if a particular optimisation would make the code significantly harder to maintain.

    Yes, Ruby (like most scripting languages) lets you drop into C if you really need to... but that's a particularly extreme tradeoff. You should not start out on a Ruby project intending to do this, because it means that future Ruby programmers may not be able to maintain your code. Nor should you pick up Ruby on the basis of pie-in-the-sky promises that there'll be a new interpreter "real soon" that will be "real fast", because the developers might all die in a chain of freak accidents tomorrow. Use Ruby if it makes sense: if it's fast enough today, or if the improvement in programmer productivity is great enough that you can justify solving performance problems with expensive hardware.

    Just bear in mind that you're measuring that productivity improvement against other faster scripting languages, like Perl and Python, not against C++. And bear in mind that there are more people with those other languages in their skillset, so they'll be cheaper, easier to find, and easier to replace. And bear in mind that Ruby is currently a fad, so some of the people who love it today are fad-chasers who will leave your company like a shot when the Next Big Thing turns up...

    Ruby's the right tool for some jobs, but it's running a grave risk of being a victim of its own success, because when the pro-language hype is way up, so is the anti-language hype whenever anyone gets burned. Maybe you evangelists should cool off a little and prove Ruby's virtue by using it to make yourselves rich, instead of claiming that it's the best thing EVER because it, like, makes it really easy to recurse over directories, just like every other language apart from C++!
  68. Re:thinking about something new? think again by 19thNervousBreakdown · · Score: 1

    I'm not sure what you're doing in this discussion if you can't make a good guess as to what's in the recurse() function for the purposes of this discussion.

    You also seem to have missed the fact that Ruby isn't Rails.

    --
    <xml><I><am><so><damn>Web 2.0</damn></so></am></I></xml>
  69. Re:thinking about something new? think again by TheRaven64 · · Score: 0, Flamebait

    So, first a straw man, and then an ad hominem. Good to see your debating skills are on top form. You might find this set of weightings interesting. Two things are taken into account; the CPU time taken to run the code and the amount of code required to solve each problem, with a 1:2 weighting (concise code more important than fast code). The code complexity is determined by stripping comments and gziping the result. With these weightings, Ruby comes out ahead of two languages: Tcl and Prolog. Since Prolog is a highly domain-specific language (gorgeous for some things, a nightmare for others), and Tcl is a cruel practical joke, this doesn't seem like something to be proud of.

    --
    I am TheRaven on Soylent News
  70. Re:Excuse me, you didnt have to attempt it to know by Anonymous Coward · · Score: 0

    "Rails was a 'framework' built on php" ??

    Rails is a framework that built on top of Ruby , don't you know that ?
    before given any comment , please make sure you know what you are talking about,
    otherwise, futher discussion is meaningless.

  71. Did anyone miss the point completely? by Anonymous Coward · · Score: 0

    Anyone who (re)designs a web site just so they can write it in gobblydegook (or whatever) isn't making any business sense.

  72. Another option: OKWS and C++ -- really by Anonymous Coward · · Score: 1, Interesting

    There may only be 2 large websites in the world written in C++ (actually there are probably more), but if you are looking to write large websites with many tools and features and dynamic contents, check out OKWS. It's a platform for written large web site/application in C++, with security and performance advantages.

    Why don't you want to write in C++? It's too low level and does not have a lot of the abstractions already built in, like PHP, perl, etc... But OKWS offers those abstractions, from perl like regex and string operations, to all the CGI things you need. Plus reference counted memory and asynchronous callbacks. It's like written a big C++ application, but for the web. Really, it's not bad.

  73. Re:thinking about something new? think again by Anonymous Coward · · Score: 3, Informative

    I'd just like to point out that the parent is decieving. He's not a programmer. According to his website, "Bill is employed by Century College working on developing new recruitment and retention programs." I seriously doubt that means programs in the slashdot sense.

    He's just pissing in the GP poster's cornflakes; he isn't for real and should be modded appropriately. His only technical qualifications seem to be messing with his own blog, which he describes as "working on the website."

    Don't take my word for it though -- follow the links and decide for yourself how technical Bill might be. I personally have formed the opinion that he's a cereal-pisser.

    Here's his own list of articles with a more technical bent:

    http://www.lazylightning.org/taxonomy/term/6

  74. twitter by Jeffrey+Baker · · Score: 1

    I have only one thing to say about Rails and that is "waiting for twitter.com..."

  75. Re:thinking about something new? think again by rnicey · · Score: 1

    Here's the Java version (give or take a bit):

    parseFolders(File target)
    {
    for (File item : Collections.sort(target.getFiles()))
      if (item.isDirectory())
        parseFolders(item);
      else
        someAction(item);
    }

    Here's the Perl version (give or take a bit of syntax):
    sub parseFolders()
    {
      my $target = @_[0];
      foreach my $item (sort $target->files)
      {
          if ($item->isDirectory) {
            parseFolders($item);
          } else {
            action($item);
          }
      }

    C++?
    parseFolders(Folder folder)
    {
      folder.sortByName();
      for (int i = 0 ; i folder.getItemCount() ; i++)
      {
          File file = folder.getFileItem(i);
          if (file.isDirectory())
            parseFolders(file);
          else
            action(file);
      }
    }

    My point? Syntax is syntax. Evaluate a language based on it's toolkits, libraries, code maintainability and performance. Almost 90% of the time language choice doesn't matter much for single website projects with less than 25k lines of code (and I mean proper code, not hotwired bodge).

  76. Two Words by 0xC2 · · Score: 1
    --
    Be heard || Be herd
    1. Re:Two Words by poopdeville · · Score: 1

      Agreed. Very strong. Very flexible. The core developers are very nice. It's a bit of a moving target though -- packages get unofficially deprecated all the time.

      --
      After all, I am strangely colored.
    2. Re:Two Words by Chandon+Seldon · · Score: 1

      Catalyst is neat, but it doesn't have the single big advantage that Rails or Django has: Lack of choice (aka sane defaults). If there's one way to do it, you do it that way and you're done. If there are five ways to do it, you spend a day trying to figure out which way is better - and then later find out that some other component assumes you did it one of the ways you didn't chose.

      Now, when the sane defaults in Rails don't fit the bill, or when you really need some Perl libraries, or if you really need the factor-of-five speedup in the web app code that you can get from mod-perl, then Catalyst is the obvious choice. But for a new application that's database-performance limited anyway, being lazy (and using Rails) is the ultimate plan.

      --
      -- The act of censorship is always worse than whatever is being censored. Always.
  77. To get things straight: Rails did *NOT* invent MVC by Qbertino · · Score: 4, Insightful

    Rails did not invent MVC, nor did they invent scaffolding or any of the other stuff. They didn't even make it popular. Very many people get these facts wrong. The only thing Ruby On Rails did as a first was to apply professional marketing strategies when trying to make an open source web application framework popular. They were the first to build a project website that was appealing to the eye more than anything else and they heavyly pushed the concept of the screencast, right when broadband was becoming commonplace. I'm shure almost everybody has watched that famous 'a blog in 15 minutes' screencast. This screencast alone made Rails (and the editor presented in it, Textmate) extremely popular.
    Technology wise there are many frameworks and webkits that are far more mature and far more sophisticated than Rails and have been around for 6 years and more.

    --
    We suffer more in our imagination than in reality. - Seneca
  78. Re:thinking about something new? think again by jadavis · · Score: 3, Insightful

    I've been interested in learning at least one of those languages for a while. Usually what gets in my way is that I can't find the necessary libraries to complete whatever task I'm working on. Can you point me towards the language from your list that has:

    * a rich standard library with a good reference
    * a good extended library like CPAN
    * easy extension in C
    * good documentation
    * easily available compiler, etc.

    I don't mind buying a book, as long as I can get somewhere just from the online documentation. Out of the languages you mention, I got the furthest with OCaml. However, if I needed to do something simple like connect to a database and then contact a directory server using LDAP, I'd be lost.

    --
    Social scientists are inspired by theories; scientists are humbled by facts.
  79. Don't do rails! by shlepp · · Score: 0

    Doing rails is very bad... steer clear of drugs.

  80. Different first-person perspective by Anonymous Coward · · Score: 0

    (The post below provides insight into the situation. It was posted as a comment to the original blog. Another thing that comes out in the comments is that Derek has some serious issues that likely exacerbated the problems.)

    I'm a little reluctant to add to the wasteland that is this post and these comments, but here goes.

    I'm familiar with the situation here. The deal was this: Derek was not a programmer; he was a musician. He learned some PHP and cobbled together the old CDBaby site by himself. It was good.

    Then, he heard about Rails, and became infatuated with it. He proceeded to attempt a rolling rewrite of CDBaby's frontend and backend both (the backend is large, because of inter-label and digital distribution stuff) in Rails.

    At this time, Derek had no experience with the following things:

    * any language other than PHP
    * systems integration and interoperability
    * Rails
    * object-orientation
    * the MVC pattern
    * managing a development team

    Project fails. All right. As he has learned in #2, legacy compatibility trumps everything. Also, ship early and often.

    As you can see in Derek's post about MySQL encodings, he's not always the clearest thinker. Even above he says that REST means POST-only destruction, which misses the point entirely.

    His team was fine (mostly just Jeremy, until another developer was hired in the last months). Rails was fine. But there were a lot of things wrong with the project plan ("rewrite everything, eventually") and with the project leader, who was convinced he had found a silver bullet.

    No framework saves you from your own inexperience.

    Out.
    wellwisher | September 23, 2007 01:47 AM

  81. Re:thinking about something new? think again by Anonymous Coward · · Score: 0

    Not exactly. I actually chuckled when I saw your example, as you obviously have *no* idea about what Smalltalk is, and why your example is ridiculous in the context of the discussion.

    Of course, Ruby is better than C++, closure are cool, etc, etc. But your example would work even better in Smalltalk, and the grand-parent was specifically asking about why choosing Ruby over Smalltalk.

  82. Maybe you should change your focus... by Anonymous Coward · · Score: 0

    The site is... well ugly, and I wouldn't be surprised if this was a article created only to plug your site. You need to shift your focus to design.

  83. Re:thinking about something new? think again by Bozdune · · Score: 1

    ...well, when I discovered that it was like I was banging a smoking hot woman, who to be fair is a little slow, and I found the keys to a Porche at the bottom of her vagina.

    I really can't get past that bizarre analogy, dude. Blecch. Also, why did you need the keys to the porch?

  84. The BEST language to use is ... by Skapare · · Score: 1

    The best language to use is the one you KNOW best ... as long as it is at least up to the task for the project you have in mind ... and as long as the project needs no more programmers than you plus whoever else also knows this same language best. Yes, even the C language can be best for a project if it is what YOU know best how to code in.

    If you know all the ins and outs of a language, and have a strong grasp of what all it can do (most languages can do almost anything when coded by a programmer that knows it well) and cannot do (usually this is a function of the inverse of how well you know the language), then that language can work.

    Now, would that language be the most optimal for you to choose. Maybe not. If you factor in the time and effort to learn a new language well enough to know all the ins and outs of it, you very likely have added a huge amount of time to a project. Learning a new language that has more advanced tools that will let you develop faster and better is probably a good idea. BUT ... that learning process should not be tied to any immediate project. Think back to the things you did when learning the language you know best now. They were more than likely a lot smaller and more trivial than what you might contemplate doing today. That's a factor of your experience, particularly with the language (the same can also apply to the systems that will be used). Go ahead and learn a new language for the future doing smaller tasks with it, and grow them as you learn it. Use the language you still know best for the major tasks, even if it will take you longer to do them in that language than it would take for someone experienced in the new language to do it in the new one (because you are not yet that programmer experienced in the new one).

    Teams needs to be homogenous. Ironically, one good programmer can do alone a lot more than a small team can do. But some projects are just too big for one programmer. When you need a team, make sure they are all experienced at about the same level in that language AND they all consider that language to be their best language. The project lead is the only exception and can be more experienced than the team, but must still consider that language his/her best.

    --
    now we need to go OSS in diesel cars
  85. Classic second-system effect by dkionka · · Score: 1

    This has little to do with Ruby vs. PHP -- this is the classic second-system effect. When you do your big rewrite, you are so determined to avoid all the limitations of the first version that you keep making it more and more elaborate. You often give up, get very practical again, and create a small, useful, 3rd system.

  86. Re:Excuse me, you didnt have to attempt it to know by Anonymous Coward · · Score: 0

    Rails was a 'framework' built on php What??
  87. My 2 cents... by rdean400 · · Score: 1

    Rails was not at fault here. The fault was expecting Rails to be a silver bullet....that just by choosing Rails, everything will happen as if by magic. They ignore the fact that Rails can't do everything. If it tried, it would become bloated to the point that people start talking about it like they talk now about Java. Writing in Ruby, clean and elegant as it is, doesn't change that fact.

  88. Re:thinking about something new? think again by Hao+Wu · · Score: 1

    I chuckled at myself for trying to hard for so many years when Microsoft actually had a product that worked for once.
    There are countless people who still think that a Macintosh is something like System 7, 8, or 9.

    Some people even act like it's the Apple IIGS.

    --
    I suggest you read Slashdot
  89. Re:thinking about something new? think again by Anonymous Coward · · Score: 0

    To clean it up a little more:

    Dir.entries(target).sort.each do |entry|
        if File.directory?(entry)
            recurse(File.join(target, entry))
        else
            dostuff(target)
        end
    end

  90. Reasons for failure by sciurus0 · · Score: 1
    I think this post from wellwisher on his comments is informative:

    The deal was this: Derek was not a programmer; he was a musician. He learned some PHP and cobbled together the old CDBaby site by himself. It was good. Then, he heard about Rails, and became infatuated with it. He proceeded to attempt a rolling rewrite of CDBaby's frontend and backend both (the backend is large, because of inter-label and digital distribution stuff) in Rails. At this time, Derek had no experience with the following things:
    • any language other than PHP
    • systems integration and interoperability
    • Rails
    • object-orientation
    • the MVC pattern
    • managing a development team
    Project fails. All right. As he has learned in #2, legacy compatibility trumps everything. Also, ship early and often. As you can see in Derek's post about MySQL encodings, he's not always the clearest thinker. Even above he says that REST means POST-only destruction, which misses the point entirely. His team was fine (mostly just Jeremy, until another developer was hired in the last months). Rails was fine. But there were a lot of things wrong with the project plan ("rewrite everything, eventually") and with the project leader, who was convinced he had found a silver bullet. No framework saves you from your own inexperience.
  91. This guy is pretty clueless by Wiseman1024 · · Score: 1

    First off, he seems to think "Rails" is some kind of programming language. He failed to see it's merely a framework for Ruby, and that if the framework was getting in his way, he could just use bare Ruby. Ruby has a few questionable spots, such as the terrible Perlish syntax, half-assed first-class functions (different namespaces for functions and other values, as in Common Lisp, unlike Scheme), and difference between blocks, methods, and such, but it's undoubtedl superior to PHP, so provided you don't depend on some PHP library or extension that's not available on Ruby, it's going to be a more productive language to work in than PHP, as long as you hire the right person.

    Second, he's a buzzword bingo. "Business-logic"? Only clueless people talk like that. He probably wanted Rails because of the hype, too.

    Third, he was probably thinking things the wrong way; trying to make Rails work like PHP. You can't just rewrite programs for a completely different platform; you have to redesign them as well. He fails to understand this basic principle.

    Fourth, "Is there anything Rails can do, that PHP CAN'T do?" Well, and I ask, is there anything PHP can do that 6502 assembly CAN'T do?

    Fifth, "I realized the language didn't matter that much." At this point I stopped reading. This guy is really clueless. If language didn't matter much, we'd all be using FORTRAN. If this guy thinks it doesn't matter whether you do C or you do Python, then he better do something else but stop programming, much less managing programmers.

    --
    I was about to say 13256278887989457651018865901401704640, but it appears this number is private property.
    1. Re:This guy is pretty clueless by nuzak · · Score: 1

      > Second, he's a buzzword bingo. "Business-logic"? Only clueless people talk like that.

      Dude, I hate buzzwords as much as the next guy, but you better stay far the hell away from any non-hobby project if you think "business logic" is an empty buzzword from the web 2.0 or even the dot-com set.

      The passwords are md5 encoded with a 6-character salt? That's application logic. The passwords expire in 90 days, and password change requests are cc'd to sec_audit@yourcompany? That's business logic. If you can't see the the separation of concerns (THAT's a buzzword) or the parameters of the business logic here, you can go back to writing mp3 catalog applets hardwired to mysql.

      --
      Done with slashdot, done with nerds, getting a life.
    2. Re:This guy is pretty clueless by Wiseman1024 · · Score: 1

      All are application logic. What they really are is a more important requirement, and less important requirement. Business logic is just enterprise fappage from pointy haired moronic managers who want to hear the "business" word. The more times they hear the "business" word, the more interested they are, even though they wouldn't be able to tell a computer from an elephant in 100 million years.

      --
      I was about to say 13256278887989457651018865901401704640, but it appears this number is private property.
  92. Re:thinking about something new? think again by Anonymous Coward · · Score: 0

    Not exactly. The point of the poster was how easy he could turn it into a "sorted" parse routine.

    Of course, it is easy as hell in any modern language, but just don't blow his ruby bubble for now.

  93. Re:thinking about something new? think again by the_womble · · Score: 1

    Did you switch the platform you were developing on, or just what you used as a desktop?

    I imagine learning new APIs (and possibly languages) takes work, but switching from one GUI desktop to another is easy. All the more so as Linux desktops default to a Windows like config.

    Getting back to the topic, changing the platform you are developing on for no good reason is a lot of unnecessary work.

  94. Project failed due to Project Management and ..... by CFD339 · · Score: 3, Insightful

    ...stupid decisions based on myth over reality. You have front end people making decisions about browser security in utter discord with back end choices made for functionality. You have redesign of existing functional systems without starting back at the design specification. You have scale failures because you didn't test your nonexistent spec. for scale.

    I'm glad I don't work there.

    --
    The problem with quotes on the internet, is that nobody bothers to check their veracity. -- Abraham Lincoln
  95. Slightly different outlook... by Junta · · Score: 2, Insightful
    My thought is don't jump to new technology just because. Be extra wary of things with tons of hype surrounding them, and take the time to evaluate new technology (ensure the people evaluating has used the current tech so they can make a fair comparison). The adage 'if it isn't broke, don't fix it' carries a lot of weight. That said:

    Thinking about ditching C for Java? Think again. I will say a lot of companies have successfully ditched C for Java, or at least C for C++. I personally dislike the Java implementations I've seen, Java programs I've used still feel slow and stick out like a sore thumb on my desktop (I know, SWT was supposed to help this, and I do have some SWT apps, they still somehow feel bizarre). My personal opinion is that Java as widely implemented is some weird thing with the worst of all worlds. It requires compilation, but still acheives none of the performance benefits of C. I'd be inclined to use php, perl, or python depending on the scenario if Java was on the plate. But my rant aside, you can't pretend Java has been a total flop.

    Thinking about ditching Windows for Linux? Think again. Now that's just flamebait. My house is 100% Linux, my work is 98% Linux, and it's truly a great thing. One problem I would say would be overaggressive marketing to the masses, convincing people to try Linux before removable media was magically handled, before the desktop file managers had decent abstractions for common networking protocols (i.e. SMB), before something like NetworkManager existed to 'deal with your network' for you. With these added, the technical and non-technical advantages of Linux are available combined with the 'ease'-of-use MS offers. Meanwhile, some of the fast-tracks to having all that ease-of-use MS employed left gaping security issues to tackle they still struggle with, as well as a situation where the MS experts faced with a somewhat broken install just reinstalls because they feel its hopeless.

    Linux also represents something significant. Essentially it has come to represent a set of software that does things in a standard way that multiple businesses can implement and compete in a compatible way. This is the key thing that pushed the PC architecture, competition. You can choose Ubuntu, Red Hat(Fedore/CentOS), SuSE, Debian, Mandriva, Gentoo, or any number of others, and still run the same software. You can pull one together yourself if so inclined, or use a community maintained one, and/or have commercial support. MS rode the PC platform to success because they were the only software company to support it on arbitrary hardware vendors. So powerful was this advantage that the industry essentially gave them the monopoly before any other company had a serious offering to consider under the same terms (They had it pretty well gotten by Windows 3.0). Now Linux can represent the same phenomenon, but for the operating system. In order to overcome MS, it's had to be truly Free, but there remains a healthy commercial environment around it.
    --
    XML is like violence. If it doesn't solve the problem, use more.
    1. Re:Slightly different outlook... by Anonymous Coward · · Score: 0

      It requires compilation, but still acheives none of the performance benefits of C.
      That might have been true in 1999, but Java today will trounce any scripting language in anything except startup time (and there are a few promising efforts to try to reduce the that initial startup time). There are even instances where Java will out-perform C due to its ability to profile and optimize code at runtime.

      There are many valid criticisms of Java, but speed isn't one of them...especially when compared to scripting languages.

      Oh...and if SWT apps feel bizarre to you, it shouldn't have anything to do with SWT itself. SWT is basically a thin JNI layer of native widgets, so the look and feel should be identical to the way it would look and feel in a native app.
  96. Re:thinking about something new? think again by Anonymous Coward · · Score: 0, Troll

    I have a History BA with a CS minor. I am quite familiar with C/C++, VB/A, Perl, Bash shell scripting, awk/sed, numerous database software (mostly Access in my job but also mainly MySQL with PHP) and have experience (not daily) with various other languages.

    While I was trying to be "+1 Funny" and don't expect Insightful or Informative mods, I am far more experienced in technical matters (mostly for my job that's GIS) than you make me seem to be by the limited postings of that nature on my website.

  97. 2 years ? Not a tech but a management problem. by Gyver_lb · · Score: 1
    If it took them 2 years to find limitations, they didn't manage the project properly. When reading the rest of the article the flaws are obvious, they pickup Rails but :
    • Had 85 PHP coders and didn't plan their training,
    • Had a huge (95 tables) legacy database which brings specific problems with Rails and they apparently didn't care to find out how to solve them before deciding the switch,
    • Relied on hand-tuned SQL although Rails discourage this,
    • Obviously prefer in-house code to frameworks (so why use a framework?).


    So obviously Rails wasn't suited to what they wanted to do (if they are doing things right is another matter...) and they didn't realize it.
    It's as if you used a knife to eat porridge: sure you can, but using a spoon might be a better idea (or you could add a fork to the knife and eat a juicy steak with french fries).
    1. Re:2 years ? Not a tech but a management problem. by OrangeTide · · Score: 1

      I would have aborted the project unless there was a partially working prototype within the first 3 months, and expect it to be feature complete by 6 months. 2 years, I could have written the entire site in C and SQL and had time left over to debug it all.

      Even if you're doing hand-tuned SQL, in-house frameworks and had a huge legacy database I still don't see why it would take 2 years.

      I don't know Ruby or RoR, but I suspect a normal developer could make it do something after buying a book on it and experimenting with it for a short while. Although personally I prefer WebObjects.

      --
      “Common sense is not so common.” — Voltaire
  98. Re:thinking about something new? think again by garcia · · Score: 1

    This guy isn't informative. He seems to infer that I'm not telling the truth that I've been a Linux user for 10 years (I have). He also seems to infer that because of my career choice that I don't know how to write programs.

    This A/C from Illinois isn't Informative, he's just a troll and should be modded appropriately.

  99. Re:thinking about something new? think again by fimbulvetr · · Score: 1

    for file in `find . -type f`;
    do
    dostuff $file
    done

    or ...

    for file in `find . -type f | sort`
    do
    dostuff $file
    done

    It's just as easy in php, or perl, or...

  100. How does Django compare? by crivens · · Score: 1

    I'd love to know how Django compares to RoR. I like Django, though I've not written anything meaningful with it.

    1. Re:How does Django compare? by nuzak · · Score: 1

      Django does some pretty nifty things: its admin interface is a beautiful thing that's reminiscent of Naked Objects, it has transactional middleware that's nearly as elegant as J2EE declarative transactions, and it's reasonably zippy (though nearly anything will outrun rails).

      It does have some horrible horrible design problems though: the admin interface is a highly-coupled hairball that you simply cannot extend without really intimate knowledge of Django internals that often have nothing to even do with the admin interface. The ORM is reasonably expressive, but not really any more than ActiveRecord (and suffers from the same "N+1 Selects" antipattern created by the AR pattern in general), while Python has other ORMs like SQLAlchemy and Storm that blow it away in flexibility. The Django ORM also commits heinous abuse of keyword args to make its own little language.

      I tend to recommend Pylons, which has the added bonus of coming with some direct ports of rails idioms with its "helpers" library. Pylons isn't perfect either, but it's less complex than Django, and usually gets the job done. Django OTOH is much better suited for the specific application of content management with multiple subsites.

      --
      Done with slashdot, done with nerds, getting a life.
  101. Re:thinking about something new? think again by Anonymous Coward · · Score: 0

    if File.directory?(entry)


    Right. Who wouldn't love Ruby with such obviously clear syntax as this?
  102. Re:thinking about something new? think again by bockelboy · · Score: 1

    Meh.  That's hardly impressive, unless if someone has never seen a dynamic language.
    I like Python's version better:

    for root, dirs, files in os.walk('/home'):
      for file in files:
        do_something(file)

    If you want to sort the directories as you recurse through them, add 'dirs.sort()'.

    If you ask me, Ruby is like an ugly Python.

  103. Re:Thinking about abortion? think again by Moderatbastard · · Score: 0

    DFTT. Kthxbye.

    --
    1/3 of jokes get modded OT. If you get the joke, mod 1 in 3 insightful/interesting/underrated to restore karma balance.
  104. The shortest... by tcdk · · Score: 1

    ... route is probably the one you know.

    --
    TC - My Photos..
  105. Re:thinking about something new? think again by sporkmonger · · Score: 1

    If I wanted both language features and speed, I'd be opting for OCaml or GHC. Probably OCaml. Maybe Erlang if scalability was the primary concern.

    When speed and scalability don't matter as much, Ruby gives me a syntax that's easy to think in. Especially if text processing is going to be a significant factor. I really don't care for the regular expression situation in any of the four languages you listed. Ruby's regular expressions still don't handle Unicode, and there's issues in certain cases with really big regular expressions, but the vast majority of day-to-day coding doesn't hit those issues.

    The nice thing is, I typically deal mostly with http and friends, so mixing and matching languages is usually just a matter of http clients and servers, sending and receiving resources.

  106. Re:thinking about something new? think again by sporkmonger · · Score: 1
  107. Re:thinking about something new? think again by Jesus_666 · · Score: 1

    Haskell is actually used in the real world? Between the unpredictable whitespace rules, the rather ugly syntax and the fact that half of it consists of a procedural paradigm shoehorned onto a functional language I always assumed that its only use was as an example of functional programming in Programming 103.

    (As for why someone would choose Ruby over it: Coding performance. Most people are more comfortable around procedural/OO languages like Ruby than the functional/procedural Haskell with its Monads.)

    --
    USE HOT GRITS WITH STATUE OF NATALIE PORTMAN (NAKED AND PETRIFIED)
  108. Re:thinking about something new? think again by Smufe · · Score: 1

    Take a look at GODI. It's not a big collection of libraries and apps like cpan, but includes the libraries you just mentioned you needed (postgres,sqlite,mysql and ldap).

    http://godi.ocaml-programming.de/

  109. Re:thinking about something new? think again by TheSpoom · · Score: 3, Funny

    ...and I found the keys to a Porche at the bottom of her vagina.

    Ow.

    --
    It's better to vote for what you want and not get it than to vote for what you don't want and get it.
    - E. Debs
  110. Re:thinking about something new? think again by TheRaven64 · · Score: 3, Informative

    * a rich standard library with a good reference Common Lisp probably wins here. The Common Lisp spec is a weighty tome filled with small writing. Smalltalk doesn't really have much of a standard library, but the most popular implementations have quite large ones. If I can add Objective-C to the list, OpenStep is pretty close to a standard library for Objective-C and is a joy to use.

    * a good extended library like CPAN Hard to answer without understanding what it is you like about CPAN. There are a huge number of Common Lisp libraries around (from FastCGI to OpenGL bindings). Squeak (Smalltalk) has its own system for distributing third party libraries. Not sure about Haskell and OCaml. There is a huge amount of Objective-C code out there too, although a fair bit of it is Apple-only.

    * easy extension in C This is where Objective-C totally wins over everything else, since it's a pure superset of C. There is a standard mechanism for calling C from Lisp code, so it's fairly easy. Calling C from Smalltalk depends on the Smalltalk you use; it's hard in Squeak, but pretty easy with GNU Smalltalk. Not sure about Haskell and OCaml.

    * good documentation Lisp has a huge amount of documentation. Smalltalk does, but it tends to be specific to a given implementation (although modern Smalltalk tends to be a superset of Smalltalk80, so the older the documentation, the more likely it is to be applicable).

    * easily available compiler, etc. There are a few Smalltalk implementations around. The popular free one is Squeak, which is close to the original Smalltalk. There is also GNU Smalltalk, which is file-based, and so closer conceptually to other languages. For Common Lisp there are lots of compilers, but the best Free one is Steel-Bank Common Lisp (sbcl). There are a few Haskell implementations available. The one I learned on was HUGS, but I think GHC is more popular. For OCaml, I've honestly no idea. For Objective-C, the only compiler anyone really uses is GCC (although, no doubt the author of POC will no pounce on me and tell me he and at least one other person use it).
    --
    I am TheRaven on Soylent News
  111. Re:Why do people keep comparing languages with API by Jesus_666 · · Score: 1

    Well, Rails is presented as the Next Big Thing in web development and people were going on about how awesome it is and how it makes web development so much easier etc. Ruby was never presented as a web development thing, it was always Rails. On the other hand, PHP has zero credibility as a general-purpose scripting language, it's usually only seen as a web development tool. So he compared one web development environment (PHP) with another (Rails). Quite sensible, in my opinion.

    --
    USE HOT GRITS WITH STATUE OF NATALIE PORTMAN (NAKED AND PETRIFIED)
  112. Re:thinking about something new? think again by Santana · · Score: 1

    As you may already know, every situation has its requirements; some require fast execution, others require fast prototyping, etc. My point: judging a language merit only by its execution speed is not smart.

    I have come to Ruby after learning BASIC, C, C++, PHP and Perl, in that order. Ruby seems to me like an step further in my evolution as programmer. If I want execution speed, I use C. If I want development speed, I use Ruby.

    Being said that, I'm really curious about the languages you mentioned. Learning Ruby helped me to widen my view about programming and languages, because Ruby itself is an hybrid of concepts taken from other languages like LISP, Smalltalk and Perl. I've _played_ with Lua, Smalltalk and Common Lisp. Haskell is in my to-do list.

    I still prefer Ruby because it has all the features from those languages (all the features that I care of) and a syntax that is familiar to me, plus the amount of libraries available.

    By the way, execution speed is being targeted in Ruby 2.0 (as you may already know) with YARV.

    --
    The best way to predict the future is to invent it
  113. Re:thinking about something new? think again by jadavis · · Score: 1

    Thanks. After I posted I did indeed find those libraries (I posted quickly, based on what I remembered from OCaml before). It looks like OCaml is the most practical to use out of those listed based on the number of libraries available, tools, and documentation (the base documentation is quite good). I should also spend some time learning how to write OCaml extensions in C, hopefully it's as easy as writing extensions for python or ruby.

    I think my standards are a little too high with something like CPAN. I don't think Ruby has anything close to CPAN, especially when it comes to documentation.

    --
    Social scientists are inspired by theories; scientists are humbled by facts.
  114. Re:thinking about something new? think again by Anonymous Coward · · Score: 0

    "While being away from Ruby land, I did investigate the OCaml language
    further.

    I've earlier posted some information on OCaml in this group when I was just
    starting to look at the OCaml language. This is a follow up after I have
    gaining more experience.

    I can now confidently say that Ruby and OCaml are at the absolute top of
    programming languages. I'm a bit annoyed with the fact the OCaml is in fact
    so good the it steals ground from Ruby. Its a bit like a Japanese
    sportsmotorcycle compared to a European ditto with the nationalities
    reversed.

    OCaml with static linking with C object files is better suited for large
    system applications than Ruby both becuase its faster and due to
    distribution of runtime as exe rather than clear source files. What really
    surprised me was that OCaml actually competeded with Ruby in the discipline
    of rapid prototyping and still managed to produce better code than carefully
    developed C++ code requiring significantly more development time.

    Still many bright things are happening for Ruby and I am certainly not going
    to dismiss Ruby.
    I'm looking forward to see Ruby increasingly involved in building the future
    Web both via integration with Apache and the support of Web Services where
    Google have been kind enough to be a Ruby front runner. And this is possible
    the best recognition you can get, because I can't think of a greater
    application the Google.

    Ruby on the other hand is class example in OO development, but what is
    really great OO or not, is that you can actually write modules of 2K size
    that does meaningful things and plugs seamlessly into the development
    environment.
    Ruby initially impressed me with huge number of highly functional but
    redicously small library implementations in native Ruby. I spend hours
    searching for what the rest of the a database interface because it couldn't
    possibly all be in those 2.5 K.

    You can also write suprisingly short programs in OCaml, but overall there is
    more fuzz with getting the source file dependencies right in the makefile
    which also complicates integrating third party tools not in the standard
    distribution.

    While Ruby is a language with one of the easiest FFI's (foreign function
    interface), it is actually easier in OCaml. In fact it is so easy that
    provided you stick to certain datatypes, it can be almost be neglected
    whether you write a function in C or OCaml: Instead of writing a C prototype
    in a .h file, you write a similar line in OCaml and use it as if it was a
    native OCaml function. Accesing OCaml in the C function requires a macro on
    the argument to get the desired C type, not unlike Ruby. Callbacks the other
    way around is also quite managable although not as trivial. I once looked at
    an enormously complex JNI interface, only to discover that this was the new
    greatly simplified JNI interface... go figure.

    The OCaml syntax is not the best I've seen, so I tried to imagine all kinds
    of improvements. However, once I got used to it, I still didn't quite fancy
    it, but I was hard pressed coming up with anything better that would be
    equally efficient. OCaml is as terse as is possible without becoming
    entirely unreadable. I think you could actually mix some of Ruby's syntax
    with OCamls functional concepts and get an even greater language. Must do so
    one day :-)

    It appears that you actually write shorter programs in OCaml than in Ruby,
    however, you also maintain separate interface files for larger programs.

    I wrote a Ruby hack to convert Yacc grammar file into a Visual Parse ditto.
    This included lineparsing and grabbing a name, making it upper case and add
    a counter for each alternative of the rule. Ruby is a natural for these
    tasks. I started out doing a manual conversion, but halfway down realized it
    was actually worthwhile to write a Rubyscript just to complete the other
    half. And it actually was faster

  115. RoR != Ruby by the_greywolf · · Score: 1

    The article summary (no, I won't RTFA, not with a summary like this) suggests they have no idea that Ruby can replace PHP and that they needn't use Rails at all. They sound as if they think Ruby is Rails, and that PHP is somehow superior because the Rails framework failed them.

    If this isn't the case, ban the summary writer from ever submitting again. Maybe we can get better summaries some day.

    --
    grey wolf
    LET FORTRAN DIE!
  116. MOD PARENT UP AS FUNNY by rhizome · · Score: 2

    Something tells me the ongoing prejudice against Perl has a lot to do with organizations (or devs, or management) taking up the latest and greatest technologies such as those being disputed in this branch. All languages are going to have their quirks, but there is a simple performance tradeoff for enduring the idiosyncrasies of Perl. Nothing matches mod_perl for performance yet, besides C itself. Java? No. RoR? No. Python? No. While all of the language alternatives in this thread may all have modernizing advantages over Perl, its hackish OOP and its questionable maintainability, many of the criticisms are based on intellectualizing the problems involved. Many times it is just that someone thinks their pet language is better for arbitrary reasons. They were taught it in school, there's a universal force that draws everything to pure Computer Science ideals, there's money in them thar buzzwords, etc.

    Non-technical reasons very much outweight technical reasons to choose one language over the other.

    --
    When I was a kid, we only had one Darth.
    1. Re:MOD PARENT UP AS FUNNY by m2943 · · Score: 1

      its questionable maintainability, many of the criticisms are based on intellectualizing the problems involved.

      Questionable maintainability is exactly the problem with Perl, and it's not an "intellectualized" problem, it's a very real-world problem.

      Something tells me the ongoing prejudice against Perl has a lot to do with organizations

      Prejudice? You just clearly and concisely stated the reason for getting rid of Perl yourself. Of all the sins a programming language can commit, poor maintainability is probably the worst.

  117. Re:thinking about something new? think again by Johnny+Mnemonic · · Score: 1


    After twenty five years watching technology try to not suck

    If you've found a solution to a problem, consider carefully wrapping some other technology around it just because.

    If you had been around for thirty five years instead of just 25, you would have fought the introduction of the microcomputer, the GUI, and the mouse. And frankly, you've been around long enough to have seen the conversion from C to C++. In fact, I find it interesting that you consider Windows the status quo that should be defended--there was as day, not too long ago, that it was the new thing on the block. Would you have resisted it's adoption then, simply because Windows was the new girlfriend?

    I think what you mean to say is that 90% of all new developments suck. But it takes awhile to find the 10% that are truly useful, so we have to explore each development in turn. If you believe that 0%, or 100%, of new developments suck, you're going to either waste a lot of money, or stagnate.

    ps If you really think we would have better off with neither the mouse nor the GUI, you need to pull your head out of your ass and take a look around--it's the 21st century, where everyone has access to a computer.

    --

    --
    $tar -xvf .sig.tar
  118. Re:Thinking about abortion? think again by heinousjay · · Score: 0, Offtopic

    I was with you up until the "advancing arguments they couldn't possibly believe" bit. That is ridiculously arrogant of you to say. People do have different beliefs than you do, you know. Just because something doesn't fit through your filter, that doesn't mean it isn't perfectly logical to somebody else.

    --
    Slashdot - where whining about luck is the new way to make the world you want.
  119. Could have been worse... by Anonymous Coward · · Score: 0

    It could have been worse. We had an embedded product written in C and as far as we knew it was doing fine. Then our lead programmer discovered FORTH.

  120. Re:thinking about something new? think again by Nicolas+Roard · · Score: 1

    Seaside would change the world, if only it had better support for templating.

    That's pretty much wrong. For once, it's trivial to implement templating in Seaside. And guess what ? there was at least two or three templates implementation for Seaside. What happened to them ? I'm not even sure they are still maintained (I'd doubt it in fact). Why ? simply because templating brought little value to Seaside.

    Templating was crucial ten years ago. WebObjects was fantastic for that for example. But now, with CSS ? screw templating ! it's much, much better to have programmers outputing html via seaside and designers putting nice CSS clothes on top it.

    Why better ? because if you do it like Seaside does it, eg not by directly mixing HTML code with actual program code, but by having an "HTML" api in your language that output the html... well, you have all the joy of using Seaside (Smalltalk) development environment, the refactoring tools, etc, that apply to both your code and your html. There is thus no difference between refactoring your code and refactoring the html code -- they are both smalltalk code.

  121. I think he finally stumbled upon it... by plopez · · Score: 1

    when I took a real emotionless non-prejudiced look at it

    That excerpt id actually the core of what I would call professionalism. You do not let fear, predjudices or infatuation with new technology drive your decisions, you instead take a dispassionate look at the problem and then apply a solution. You use the right tool for the job, regardless of your personal prefs.

    Many of you will read this and say "welll Duh!". But I have been constantly shocked how little this approach seems to be used in IT. Anyone else agree/disagree?

    --
    putting the 'B' in LGBTQ+
  122. What Was Your Point? by Jane+Q.+Public · · Score: 1

    I read the blog post, and it confused me. Nowhere do you describe what it actually was that PHP supposedly does but Rails does not. Instead, the entire blog post glorifies PHP while not specifying what "limitations" of Rails held you back.

    So... what were they, in your view? I think that would clear up a lot of confusion/misunderstanding.

    1. Re:What Was Your Point? by linuxbaby · · Score: 1

      It doesn't really matter.

      If I knew my little personal blog post was going to be read by any more than 2 people on earth, I could have said:

      "I thought my old language was ugly, and since I needed to do a rewrite anyway, decided to do it in a new fancy framework. But it's surprisingly hard fitting an existing app into a framework. So hard that after 2 years of trying, I looked at the old language I thought was ugly and realized the problem wasn't the language, but my previously poor skills, now improved and defined by 2 years of working with this framework. I ditched the framework and rewrote in my old language, which was much smarter for our company's needs because it so easily integrated with all of our existing code."

      My post was not meant to be about strengths or weaknesses in Rails or PHP in particular. It's unfortunate that is the aspect that drew all the unintentional traffic and comments.

      Oh well. It's kinda funny to read hundreds of people calling me a dumbass. :-)

  123. Re:thinking about something new? think again by MikeBabcock · · Score: 1

    For the record (out of interest), I've run primarily a mix of Enlightenment with Gnome over that time period and several good KDE apps like Kopete and Amarok. There are indeed features of Windows XP I like, and I generally find its integration of its own apps to be a bit better, the performance and reliability of my desktop far outweigh those minor features Windows may have a one-up on.

    Having customized my desktop menu and hot keys in Enlightenment, and having applets and Epplets installed to taste, I also find my Linux desktop(s) prettier than Windows, but some may disagree of course.

    --
    - Michael T. Babcock (Yes, I blog)
  124. Interesting anecdote but some wrong conclusions by WebCowboy · · Score: 1

    The story you describe is still all too common, and I think that is the case because, though you make some appropriate observations you actually miss some very important conclusions as well. Primarily you have concentrated on the poor technical choices and neglected the flaws in project management and execution.

    While you are right in stating that in IT projects one must proceed with caution at times when choosing to implement new technologies, you have placed an over-emphasis on sticking with what is "mature", "well tested", "traditional". There are pitfalls to sticking with what works as well--in the form of missed opportunities to improve efficiency and competitiveness. The key is in WISELY choosing new technologies, and that very much involves employing real engineering principles and effective project management (all to often the latter seems to be an oxymoron, because there are too few effective software/IT project managers out there--the field is really still quite new).

    You start to key in on the root cause of this disaster when you suggest "get user feedback on software early and often". If you wait until there is software for them to give feedback on you are ALREADY TOO LATE. Before one single line of code is written, or one single software licens is bought, or even one single computer purchased, you must involve the end users in a formal "requirements gathering" process. If the project is a replacement of existing infrastructure you must observe the legacy system carefully. Not only is is it important to see what functionality needs replacing, it is also important to try and pull out of the end user what they don't like about a system and to carefully observe when users are compensating for a system's shortcomings. No mattter how efficient and reliable the old system is, in my experience there are ALWAYS shortcomings that can be addressed with new technologies. Some observations I've made that are signs a system could be improved:

    * The use of Microsoft Excel in normal information management processes. This is by FAR the biggest, most obvious sign that there may be a systems integration issue. Excel is a fine spreadsheet for most people so don't take it as a slight against that product itself. However, EINAFDB and EINAFRE (Excel is not a f'ing database and Excel is not a f'ing reporting engine). The same could be said if it was OO.o Calc or Gnumeric being used the same way. Hell, it is even OK to let the abuse of the desktop spreadsheet slide from time to time. The key is, are the SAME spreadsheets used ALL the time and are a part of "normal operating procedures", and to they involve little to no numerical analysis (ie. they are "data entry forms" or "data tables")? In those cases, their systems are probably sub-optimal. A spreadsheet is for crunching numbers--doing elabourate calculations--and presenting those numbers in an "all at once", interactive fashion. It can occasionally be used for ad-hoc reporting/data processing (though that is a minor abuse, it is an acceptable one). Otherwise it is like using a butterknife as a screwdriver or your shoe as a hammer--it might work "just well enough" but it can be done a lot better.

    * Manual data entry, especially from data sources that were obviously sourced from electronic systems. Do the users "cut and paste" from one screen to another a lot, or sit in front of an emulated terminal and type numbers from a dot-matrix printout or a printed report faxed from another department? It is time to ask where the data originates and the nature of that originating system. Also, keep in mind that manual entry can include "semi-automated" processes. Are they manually opening an MS Office file and launching macros to complete a step in a process? After identifying those sources of data, look at data entry from handwritten, verbal or visual sources. Does the data come from a paper recording chart, clipboards carried by operators, reading instrumentation on an old control panel? If the info is really important to the client,

    1. Re:Interesting anecdote but some wrong conclusions by Xiaran · · Score: 1

      The use of Microsoft Excel in normal information management processes. This is by FAR the biggest, most obvious sign that there may be a systems integration issue. Excel is a fine spreadsheet for most people so don't take it as a slight against that product itself. However, EINAFDB and EINAFRE (Excel is not a f'ing database and Excel is not a f'ing reporting engine).

      Yes! Thank you!. I don't know who you are but I like you and would work with you happily. Excel *is* a wonderful spreadsheet but it isnt a database or report reporting engine. Ive actually had a real life meeting with someone who was so enamored with Excel that she actually claimed that Excel was better than using an Oracle database(for a particular project... not the data volumes for this project were in the 10s of megabytes of data a day) because Excel had pivot tables!!!! Arghh!!! Excel is put in the hands of people that suddenly have a little knowledge and become dangerous. Actual quote from that meeting after I proposed that perhaps we need a real database was "But does Oracle do pivot tables?"... she was serious.

  125. Re:thinking about something new? think again by Anonymous Coward · · Score: 0

    Ruby also still has problems with unicode support. Suprising for a language first developed in Japan.

    I use python a lot, and each release seems to remove a few more warts. I also think Groovy will be sweet once it stabilizes.

  126. An interview with Derek at start of Ruby proj... by puzzlesmith · · Score: 1

    Here's an interview with Derek about his decision to switch to Rails in 2005, read together these two articles make an interesting case study... http://www.oreillynet.com/ruby/blog/2005/11/migrating_to_ruby_on_rails_and.html

  127. Misleading Post by Jane+Q.+Public · · Score: 2, Insightful

    The original Slashdot post implies some things that are not substantiated by the actual content of the article (blog post). It sure seems as though the poster him/herself has something against Rails.

    The actual blog post (and poster) imply that Rails was not designed to do things that they were trying to do. That may or may not be... but that is not the fault of Rails. If the tool was inappropriate for the project, then the project manager should have determined that before starting.

    Also, while it is implied (and even stated) that Rails was not designed to do these things... nowhere is he specific about what those things actually are. Rather than berating Rails, the blog post glorifies PHP. Those are two very different things.

    In introductory Business Law at my college, there was discussion of the classic case of the tavern visitor in the 1700s who stated "My horse can pisse better beer than this!" (sic) The tavern owner sued the patron for slander. (In those days most taverns made their own beer.)

    The judge ruled that the statement was not slander, because the customer did not insult the tavern owner's beer at all... rather, he had complimented his horse!

    There really is a big difference. So... I want to know what he does not like about Rails, since he really did not explain that.

  128. Re:thinking about something new? think again by Chandon+Seldon · · Score: 1

    I won't have to spend money buying another server once I get a few thousand daily visitors.

    No programming language is so inefficient that you'll notice a performance difference in a web app for thousands of daily visitors. Not PHP vs. Ruby. Not a Scheme interpreter written in Visual Basic 2.0 vs. hand tuned assembly language. Web app throughput is measured in requests per second on modern servers (usually thousands or tends of thousands, but maybe hundreds for the Scheme in VB thing), and there are 86,400 seconds in a day.

    --
    -- The act of censorship is always worse than whatever is being censored. Always.
  129. Re:thinking about something new? think again by Watts+Martin · · Score: 3, Insightful

    On a practical level rather than a "my code is more beautiful than yours" level, one answer is simple: deployment. If you're writing a program that's intended to be used pretty much just by you (or other people on your dev team, perhaps), it really doesn't matter what you write it in. If you're writing a program that's going to have to be rolled out to production systems that you don't have absolute control over -- like, say, a commercial web-hosting service -- there are new issues.

    Ruby is getting a lot of attention because of Rails, and Rails' attention is making it moderately easy to find web hosts that support it. It is easier to deploy a Rails application than it is to deploy a Django application, if you're taking into account "I must find a web host that supports my framework/language." If you are writing, a web app in Smalltalk using Seaside, well, not only are you definitely not shoving that out to your $8/month Dreamhost account, the chances are you're going to have to have complete control of the production side (i.e., colocation or self-hosting). Also, of course, if you're writing for a business, maintainability becomes an issue with any "obscure" language: eventually, the original development team won't be there, and if you can't replace them because the dozen other people in your area who know the language you chose are happy at the research labs they're working at, you find yourself in a very uncomfortable place. I've heard the even a kindergartner can learn Smalltalk so fast they'll be writing complete CRM systems in a week! speech, too, but in practice it seems those kindergartners are few and far between.

    Frankly, deployment issues are one of the reasons I'm slinking back to PHP myself; as much as I love Rails in theory, as it turns out, in practice Rails is a sufficient resource pig that many shared hosts that claim to support Rails put serious limitations on it unless you bump up your service level. (I know I'm inviting arguments from Rails fans here, but yes, I've really looked into this.)

  130. Mod PARENT UP! by Anonymous Coward · · Score: 0

    One thing I want to add is that lately a lot of projects have started adopting languages like Ruby because it attracts programmers who want to code in the language, not programmers who already know the language. I probably wouldn't go this direction, but given the shortage of decent programmers, it might be the only way to get some great talent on your project.

    Captcha: poison

  131. Re:Thinking about abortion? think again by Anonymous Coward · · Score: 1, Funny

    One less person telling everyone else what to do.

  132. My guess by Slashdot+Parent · · Score: 1

    What went wrong? I don't have any extra information on the subject, but my guess from reading the article is that it had something to do with the 95 legacy RDBMS tables and the many integration points with non-Ruby systems.

    I mean, really. Can you imagine getting 95 legacy tables into ActiveRecord, and actually convincing AR to behave properly under load? Good luck with that.

    Also, if the new app had many integration points with PHP systems, that could be a fun one to work out. You can't, to my knowledge, just include a PHP library in Ruby. ;)

    I've done projects in Rails, and I happen to detest PHP, but if a client approached me with the following tech specs:
    • 95 tables
    • high load
    • many integration points with PHP
    • possibly more than one database? (I don't know this to be the case, but with 95 tables, I suspect more than one database)
    • much i18n
    I would have advised against RoR.

    I mean, really. Use the right tool for the job. Don't use a framework that is going to be fighting you instead of helping you.
    --
    They don't grade fathers, but if your daughter's a stripper, you fucked up. --Chris Rock
    1. Re:My guess by jadavis · · Score: 1

      my guess from reading the article is that it had something to do with the 95 legacy RDBMS tables...

      What makes you think the tables are "legacy"? I didn't see the author say he wanted to get rid of them. A database isn't just a persistent store for one application, but must be usable from many applications (which may be written in different languages) and meaningful to all of those applications. If ActiveRecord has a problem using existing data in a well-designed schema, that's a serious problem with ActiveRecord.

      Also, if the new app had many integration points with PHP systems, that could be a fun one to work out. You can't, to my knowledge, just include a PHP library in Ruby. ;)

      A good point. That was probably a big part of the problem right there.

      possibly more than one database? (I don't know this to be the case, but with 95 tables, I suspect more than one database)

      It's quite possible that's one database. In fact, it may be quite reasonable. 95 tables just means that there are 95 different kinds of facts that you might want to store. That's a somewhat large number if it's one application with a narrow scope, but it's a small number if you take into account the whole business.

      * much i18n

      What's wrong with internationalization in RoR?

      --
      Social scientists are inspired by theories; scientists are humbled by facts.
    2. Re:My guess by Slashdot+Parent · · Score: 1

      What makes you think the tables are "legacy"? The fact that the 95 tables predated the Rails rewrite.

      I didn't see the author say he wanted to get rid of them. Who said the author wanted to get rid of them? Only you. You don't get rid of something just because it's legacy.

      If ActiveRecord has a problem using existing data in a well-designed schema, that's a serious problem with ActiveRecord. Agreed. It is a big problem with ActiveRecord. AR wants you to structure your tables "just so", and if you have a different structure, then AR is working against you instead of for you.

      Anyhow, I'm guessing (wild-assedly, of course.. I know nothing of the OP's issues) that the bigger database issue here was performance. Any O/R tool is going to have trouble generating optimal SQL queries with such a large schema, and OP says that there was a heavy DB load.
      --
      They don't grade fathers, but if your daughter's a stripper, you fucked up. --Chris Rock
    3. Re:My guess by jadavis · · Score: 1

      The fact that the 95 tables predated the Rails rewrite.

      I read more into the word "legacy" than you meant by it. It carries a slightly negative connotation, at least to me.

      Agreed. It is a big problem with ActiveRecord. AR wants you to structure your tables "just so", and if you have a different structure, then AR is working against you instead of for you.

      Yes, if he's able to rewrite to those 95 tables in PHP much faster, that indicates to me that AR is the problem.

      --
      Social scientists are inspired by theories; scientists are humbled by facts.
    4. Re:My guess by pavera · · Score: 1

      Your first point is the biggest problem with RoR. Rails is hideously bad at playing nice with others. Have a legacy DB that Rails didn't create for you? As another reply said, if I see that is the case, I rule out Rails as a web framework right there. It won't work end of story.

      AR really wants the DB set up in its particular way, and if its not, nothing will make it work.

      There are many many more mature and powerful ORMs out there that will handle this kind of thing, some are built into existing web frameworks... but RoR and AR are not it. If you aren't starting completely from scratch (meaning database too) then RoR is the wrong choice 100% of the time.

  133. SBCL by TheLink · · Score: 2, Funny

    A colleague has been learning Common Lisp and is using SBCL and it has cored on him more than a few times in the past few weeks. According to him Common Lisp is great but SBCL is not production ready and there is no free Common Lisp that is, so if we are to use a Lisp it'll probably have to be something like Allegro.

    I also did try learning CL, but I personally found it hard to find out how to write production code in Lisp - most of the examples on the web are all very nice for CS stuff (e.g. run this from emacs via slime) , but not real world stuff. While you're strictly in the Lisp world everything is nice and all that - 101 ways to do "fibonacci" etc, but seems like the lisp docs are written by people who are so much smarter than I am that they probably find a lot of things so obvious that they don't list them in FAQs ;).

    Example questions I asked:
    How do you compile and make an SBCL program executable? (I know now, but still...).
    How do you trap and handle posix/unix signals? (not sure the ways I found are best practice)
    How do you redirect STDOUT and STDERR to syslog?[1]
    Any examples of production style boilerplate code?
    How do I write a program that listens on UDP port X on all interfaces for packet and know which interface each packet came in from?

    I'm currently using Perl and it is a lot slower than sbcl but so far it hasn't cored on me for a long while. With the exception of the last item the above sort of things are also easy or not too hard to find out (just man perlipc gives a lot of real world details).

    I would like to learn a _fast_ high level language AND be able to use it to write production grade code (and no, I don't regard Java as high level, even if you program your java program to do XML and reinvent lisp badly).

    [1] I do this for most of my programs. I disagree with people who say "STDOUT and STDERR should be closed (or sent to /dev/null) for daemons/servers because daemons aren't supposed to output stuff". While I do agree that daemons aren't normally supposed to send stuff out via STDOUT and STDERR, that is exactly why I want such output to go to syslog (or the equivalent)! Believe me it has been helpful. Even if your code has no bugs that show up that way, you could find bugs in 3rd party libs that you use ;).

    I usually try to get it prefixed by the program name and PID (or parent PID) e.g.
    Sep 22 03:07:16 host progname[1312] STDOUT: <std output here>
    Sep 22 03:07:17 host progname[1312] STDERR: <std err here>

    --
    1. Re:SBCL by m2943 · · Score: 1

      According to him Common Lisp is great but SBCL is not production ready and there is no free Common Lisp that is,

      Of course not; I never claimed they were. They have pretty good compilers and garbage collectors, though, which is a good place to start.

      I also did try learning CL, but I personally found it hard to find out how to write production code in Lisp - most of the examples on the web are all very nice for CS stuff (e.g. run this from emacs via slime) , but not real world stuff

      All true--which is why I did not recommend that you actually use CommonLisp, and which is why it failed in the real world.

      See, all the good compiler and language people went off doing one thing and all the real world people went off doing another thing, and the end result was two disasters: CommonLisp and Python/Perl/PHP etc.

      Well, to be honest, I think the more likely resolution of this is systems like IronPython and Jython anyway. At least some of the language and runtime people eventually figured out that they were no good at the real world language stuff, so they created reasonably universal runtimes that people can now do their scripting languages on top of.

    2. Re:SBCL by TheLink · · Score: 1

      "I did not recommend that you actually use CommonLisp, and which is why it failed in the real world."

      The nagging thing is there are a few real world successes. How'd they do it, and why can't others do it?

      That said I read how some lisp people did the orbitz thing ( http://www.paulgraham.com/carl.html ), and it doesn't really seem like a roaring success story for Lisp IMO - for "real world" reasons they didn't use the other Lisp stuff and stuck mainly to macros. And I don't see why they'd need macros so much for such a "static problem" - you'd only write it once and it seems more a matter of organizing the data correctly, being able to cache, index and update it well.

      "See, all the good compiler and language people went off doing one thing and all the real world people went off doing another thing, and the end result was two disasters: CommonLisp and Python/Perl/PHP etc."

      Yeah, I think you've summarized the problem. One bunch went off to solve "CS type" problems and another bunch went off to solve "OS/server type" problems. Quite sad really. I see a bit of that in the hardware vs software world too[1].

      I tested out parrot and PIR is even slower than Perl5. OK so it's a work in progress, but on some coin counting recursion benchmark the latest parrot appears to be much slower than one some versions back (both being slower than perl5 - which itself is slower than python).

      python + psyco can be fast sometimes, but it is deprecated etc.

      Oh well.

      [1] In the x86 world there is no good way to "get the time of day", either the method is not standard/available on all machines, or slow, or flawed (doesn't work in multicore/SMP). In many programs it is common to do "wake me up when at least one of these events happens, or at latest X seconds from now" (I suppose in theory the X seconds from now should also be considered an event, but in practice, theory != practice ;) ).

      --
    3. Re:SBCL by chromatic · · Score: 1

      I tested out parrot and PIR is even slower than [Perl 5]. OK so it's a work in progress, but on some coin counting recursion benchmark the latest parrot appears to be much slower than one some versions back (both being slower than [Perl 5] - which itself is slower than python).

      I'd like to see those benchmarks, if you have time. My e-mail address should be obvious from my URL. Thanks!

  134. Re:thinking about something new? think again by Anonymous Coward · · Score: 0

    Pycaml is a Python binding for OCaml. From their website:

    "If there's a native library you want to use that has a python wrapping, for very little extra cost, it can have an ocaml binding. This also means that ocaml code can import pure python modules and use them, making it ideal for using to implement test-case code on event processing systems. [Pycaml also] allows ocaml code to embed the python interpreter, define modules, classes, structures, etc."

    If you want to use C and/or C++ libraries in OCaml, you can use SWIG. See SWIG's OCaml docs for details.

    As for LDAP in particular, there's OcamLDAP. OCaml has many other native libraries. Check out the the OCaml Hump.

  135. Rule 1 by driddint · · Score: 1

    Don't fight the platform

  136. Can anyone point to to a good therapist? by Zero__Kelvin · · Score: 1

    "#7 - PROGRAMMING LANGUAGES ARE LIKE GIRLFRIENDS: THE NEW ONE IS BETTER BECAUSE *YOU* ARE BETTER"
    Great. Now I have to go see a therapist to try and figure out why I suddenly turned into a psycho stalker with Daddy issues ..."
    --
    Guns don't kill people; Physics kills people! - John Lithgow as Dick Solomon on Third Rock From The Sun
  137. The real problems - from the original link by QuestorTapes · · Score: 2, Insightful

    On of the comments on the existing site contains this additional information:

    > I'm a little reluctant to add to the wasteland that is this post
    > and these comments, but here goes.

    > ...The deal was this: Derek was not a programmer; he was a musician.
    > He learned some PHP and cobbled together the old CDBaby site by himself.
    > It was good.

    > Then, he heard about Rails, and became infatuated with it. He proceeded
    > to attempt a rolling rewrite of CDBaby's frontend and backend both
    > (the backend is large, because of inter-label and digital distribution
    > stuff) in Rails.

    > At this time, Derek had no experience with the following things:
    >
    > * any language other than PHP
    > * systems integration and interoperability
    > * Rails
    > * object-orientation
    > * the MVC pattern
    > * managing a development team

    Concluding with:

    > No framework saves you from your own inexperience.

  138. Re:thinking about something new? think again by geniusj · · Score: 1

    Python's syntax is prettier to most people, but its library is more inconsistent. Ruby has the most consistent standard library that I know. I've been using it since 2000.

  139. Maybe there is a simpler explanation by qb001 · · Score: 1

    Do you think Derek could have written his new site from scratch in two months if he didn't have two huge messes behind him?

  140. Re:thinking about something new? think again by jadavis · · Score: 1

    Hard to answer without understanding what it is you like about CPAN.

    It's a centralized place where you can find high-quality, up-to-date modules, with good documentation (or at least a reasonable synopsis) for almost anything you might want. I just spent about 5 minutes typing in everything I could think of into search.cpan.org, and got a hit for all of them, from YAML to XMPP.

    I would certainly like to see more diversity of languages in the open source world. Right now it's almost all a mix of imperative, procedural, and OOP. SQL is the only exception, and a lot of people spend a lot of time trying to code around SQL as much as possible.

    I think it's just difficult to justify using one of those languages, unfortunately. Most of what really matters in most projects that I've worked on is not the language at all, but:

    * Easy access to all the APIs and protocols that I need to use
    * documentation
    * frameworks available for the problem domain, if applicable
    * the database design

    As an example, I think PHP is a bad language in many ways. But it doesn't affect the database design, and it scores high on all the other counts for web projects.

    Thank you for your comments though. I will continue learning OCaml, and I'll give clisp a try (I'll get to the others later). I think it will help me be a better programmer, but I don't think it's very practical in the short term. I'll have to be content with that :)

    --
    Social scientists are inspired by theories; scientists are humbled by facts.
  141. TROLL ALERT! by mcrbids · · Score: 1

    Your post leaves alot to be desired. Such as, for example, any useful information to back up your claims of being "naively implemented". Here's my breakdown of your post:

    You know, the sad thing about all the comparisons you make is that they are all choices between bad technologies. Assembler vs. PL/I, C vs. Java, Windows vs. Linux--they're all questions like whether you want to be drawn or quartered, drowned or burned, poisoned or starved. At each of those choice points, there were better technologies available.

    ANY examples? None? How am I to assume you actually have any?

    As for PHP vs. Ruby, both technologies suck: except for minor differences in syntax and object model, they are naively designed and implemented.

    Care to define "suck"? With a short learning curve, they allow a programmer to get started quickly, both are free, offer reasonable performance on current hardware, and offer a robust set of information processing functions.

    What exactly is it that "sucks"?

    After decades of research in dynamic languages and OOP, it is a testament to widespread ignorance that people would produce and use something like that.

    Ignorance of.... (?) More of that "hidden information" you pretend to have, perhaps?

    But if I have to work with bad technologies, the one that's more popular, more mature, and more widely supported one is, relatively speaking, better.

    Ignoring unsupported adjectives like "bad", I can agree with this sentence, though it's like saying "stuff people like tends to be more popular". It's still a non-statement.

    That's why I prefer to be poisoned with PHP rather than starved by Ruby: poison is quicker and less painful.

    What is this sentence even saying? Your post is a pointless, information-less, indefensible set of vague insults. Why you were modded up is an exercise left to the moderator, but your post is nothing but pure troll.

    --
    I have no problem with your religion until you decide it's reason to deprive others of the truth.
  142. Re:thinking about something new? think again by tom's+a-cold · · Score: 1

    If you've found a solution to a problem, consider carefully wrapping some other technology around it just because. Unfortunately my experience was that usually new technology/approaches typically were just because, usually driven by management (not always, and I'm not blaming them).
    I've also been in the business over 25 years. You've got a one-sided comparison going... you're looking at all the reasons the new choice is unfounded, but it's often the case that the old solution was chosen for even worse reasons, and even if you finally got it working after years of struggle, that probably led to so many compromises that it's not really something you can live with anyway.

    Oh, and Cascade really was worse. Cycle time to correct defects was too long, and there was this unfounded assumption that software could be built like a civil-engineering project. It was just an incorrect approach, no tradeoff there. For UI-intensive systems, JAD sessions work better. As for assembler, maintaining anything of non-trivial complexity was more trouble than it was worth. Been there, had no fun. I use assembler or C where I have to, but something higher-level wherever I can. And except in some unusual circumstances, I'd rather run a server on Linux (or BSD, or Solaris, or even bloody HP/UX) than Windows. So sometimes there is such a thing as progress. But in each of these cases, there was still cost and risk in making the transition. No free lunches here. But I agree that "because it's flavor of the month" is a piss-poor reason to adopt any solution. If there's no return on investment, there's no case for change. I wonder if what you're reacting to is not the new technology, but the over-promising that its advocates used to sell it?



    --
    Get your teeth into a small slice: the cake of liberty
  143. Re:thinking about something new? think again by Bearhouse · · Score: 1

    Having been there, I think I know what you mean.

    But are you sure it's not a case of 'the devil you (and your team, h/w & s/w providers...) know'?

    Like many, I heard the siren song of 4Gls, only to see my ship wrecked on the rocks of back-end debugs and broken promises of 'easy' extensions & maintenance. My ass. Oh, and sorry, I suppose that I should be using a car analogy...

    All new tech brings its own unique advantages, and drawbacks.

    But - some new tech offers really different and useful stuff.

    Do I want to go back to coding stuff in dBase? Well, no...

    But, having been bitten by 'fashion', do I really look at stuff before saying "yes, we'll do everything with this from now on", hell yes...

  144. What I came away with.. by Anonymous Coward · · Score: 0

    The title to me didn't match what I came away with from this article. To me "Do you want to foo? Think again" usually implies they are opposed to foo. In this case it really literally does mean think again.

                I have written up a few apps in Ruby on Rails ridiculously quickly. But, I do agree with the article writer; independent of language, if it comes to where the implementers are fighting against limitations and language design decisions they do not like, they really should pick out a different language. In this case... well, Ruby on Rails, if they're having to fight Rails to get things done, ignore the features it uses to make things easier, that puts Ruby on equal footing with PHP overall. Then, if they are more comfortable programming in PHP, that gives PHP the edge. If I were a huge Ruby junky I'd use Ruby. If I preferred Perl, I'd use Perl. The beauty of web apps is that you get your app to emit a (HTML typically) data stream, and at that point it shouldn't matter what language it's using. (Well, it does matter due to performance.. but anyway..) Do have validation and sanity checks to avoid security problems though!

  145. Where's the gap between research and design? by lennier · · Score: 1

    "As for PHP vs. Ruby, both technologies suck: except for minor differences in syntax and object model, they are naively designed and implemented. After decades of research in dynamic languages and OOP, it is a testament to widespread ignorance that people would produce and use something like that."

    So if we have all this research on programming languages - how come it never seems to jump the gap to applied language design, let alone implementation, and why is it that for all the professional, tenured academics supposedly doing this research, it usually tends to be amateurs without any of this knowledge who take the radical step of actually sitting down and producing something usable?

    Suggests that our academic system is seriously broken, doesn't it, if the people who supposedly know best how to build languages can't be bothered actually doing it?

    --
    You are not a brain: http://books.google.com/books?id=2oV61CeDx-YC
    1. Re:Where's the gap between research and design? by Anonymous Coward · · Score: 0

      No, actually, the languages get built. The problem is that the people who write the code, or teach the languages, can't be bothered actually learning them.

      See the list somewhat above for examples. Smalltalk, Lisp, Haskell, etc...

  146. Quite true. by Poromenos1 · · Score: 1

    I totally agree with the AJAX part. AJAX isn't inherently bad, it was just overused. Also, coming back to the article, why is the author comparing a framework to a language? I bet he could do everything he wanted in Ruby as easily as with PHP if he hadn't used Rails (I don't know Ruby, but I know you can do it in Python without using any frameworks).

    The whole article is just a bad comparison.

    --
    Send email from the afterlife! Write your e-will at Dead Man's Switch.
  147. Re:Thinking about abortion? think again by hairyfeet · · Score: 0, Offtopic

    If we are going to swing offtopic (and that stupid troll just ticks me off anyway) We might as well hear from the great one,Mr. Bill Hicks on the subject. I always thought the man could make a better point with humor than all the debates rolled into one. http://www.youtube.com/watch?v=dJcebIEOkhY

    --
    ACs don't waste your time replying, your posts are never seen by me.
  148. My Paradigm Can Beat Up Your Paradigm by Tablizer · · Score: 1

    After decades of research in dynamic languages and OOP, it is a testament to widespread ignorance that people would produce and use something like that.

    After a long time asking for OOP fans to objectively prove that OOP is better, I've come to the tentative conclusion that people like what fits their own personal psychology the best. I challenge anybody to objectively prove that their Silver Bullet is objectively a Silver Bullet. You can't because other people will weigh differing factors different than you. If you use raw code-size, Perl will probably win because it uses symbols in place of words and context-based shortcuts, but "readability" and modifiability may be called into question. Some people have fast eyes and slow fingers, and visa versa, so they favor different aspects of presentation and verbosity.

    Nobody has ever won a language/paradigm holy-war with evidence and logic alone. Votes are all we have, and they don't settle much. Will you be the first to pull the sword out of the logic stone? I doubt it. But I welcome a hearty try...

  149. Real reason I switched back to PHP by TheScreenIsnt · · Score: 2, Funny

    Old dog. New trick.

  150. Re:thinking about something new? think again by killjoe · · Score: 2, Insightful

    >I understand why you would choose a slow-and-expressive language over a fast-but-less-expressive one, but why would you choose a slow-and-expressive language over a fast-and-expressive one?

    Library, Library, Library, Library.

    Then comes community, documentation, availability of tools.

    Let me ask you a question.

    Smalltalk has been around for ages. If it's so great then how come it never caught on?

    --
    evil is as evil does
  151. Re:thinking about something new? think again by An+Onerous+Coward · · Score: 1

    I was right with you until you offered up the proposition that anyone, anywhere could learn anything from that pretentious pile of horse dung that is Andrew Keene's "Cult of the Amateur."

    --

    You want the truthiness? You can't handle the truthiness!

  152. Re:To get things straight: Rails did *NOT* invent by Tablizer · · Score: 1

    I've found it best to borrow frameworks from prior projects and improve on them and/or tune them to the new application, for each app has a different flavor of needs. Striving for the Ultimate Generic Framework is a lost cause. And, don't make frameworks that you cannot easily toss. Keep them small and relatively simple, even if it means a small amount of duplication.

    Make judicious use of named parameters (emulate them if not supported by the lang) and associative arrays (or objects, which serve a similar purpose) so that parameters and interfaces can be expanded without busting existing calls or making long sequential parameter lists. A library that supports string lists with adjustable delimiters is also helpful for indicating things such as table column order.

  153. Re:thinking about something new? think again by Kjella · · Score: 1

    Look, I hear what you're saying but every time I think "Ok, but I can solve this with a library." I'm very fond of Qt, where you'd do something like:

    void recurse( QString dirPath ) {
        QDir dir( dirPath );
        QFileInfoList fileInfos = dir.entryInfoList( QDir::NoDotAndDotDot );
        foreach( QFileInfo fileInfo, fileInfos ) {
            if ( fileInfo.isDir() )
                recurse( fileInfo.filePath() );
            else if ( fileInfo.isFile() )
                dostuff( fileInfo.filePath() );
        }
    }

    To me, using a lib to make C++ easy and usable is a smaller leap than going to a whole new language. What if I have a piece of code )'d like to use in a Ruby project? It's rewrite time, baby. While with a library, I can drop in any existing code.

    --
    Live today, because you never know what tomorrow brings
  154. Re:thinking about something new? think again by Almahtar · · Score: 1

    I remember when I was in college and I sucked at programming... I had a software engineering professor that (for some LUNATIC reason) would not let us use #include but insisted on us using C. He seriously expected us to copy+paste every line of #included code manually. That was his idea of good software engineering. Even though I sucked hardcore at programming, Ruby made it easy for me to recurse our source tree and replace every "#delude" we put in our files with the contents of the files we meant to include.

    I'm not the greatest coder by far. I lack a lot, but thanks to Ruby I was able to save my group hours and hours of work, and it was really easy for me.

  155. Re:Project failed due to Project Management and .. by Anonymous Coward · · Score: 0

    You have front end people making decisions about browser security in utter discord with back end choices made for functionality

    You have idiot consultants who claim to be "Experts" but are no more than hackers who probably managed to install visual Basic and make a few web pages. It's crummy to say the least. Any designer who uses IE-specific code is a wanker in my book, particularly when they come into a company, decide that there'll be a "Web Interface" to everything then ignore the fact that the company has blocked the use of IE. They're like every other idiot who does it the Gates way not because they know what they're doing, but because it's what "being a highly paid computer consultant for dummies" said to do.

    There is very little use for "web-based" interfaces to anything. Any product or service with a web interface is usually a toy or gimmic.

  156. Is there a good PHP 5 FW comparable to Rails? by jopet · · Score: 1

    Just out of curiosity: does anyone know if there is some framwork based on PHP5 that is comparable to Rails?
    There are a couple of things I do not like about Ruby/Rails too much -- lacking Unicode support, localization not part of the core framework, HTML templates not editable with standard HTML editors.
    Would some PHP framework solve these issues?
    How about Java frameworks?

    1. Re:Is there a good PHP 5 FW comparable to Rails? by Qbertino · · Score: 1

      CakePHP and Symfony are the two 400 pound Gorillas in the PHP FW Arena. Zend Framework is being pushed big time by Zend and a huge wave of hype they managed to build within the last 10 weeks or so but I advise everyone not to fall for the hype until it's riped a bit. It's not nearly as mature or as well tested as Symfony or Cake and could use another year or two on the market before it has proven itself.

      --
      We suffer more in our imagination than in reality. - Seneca
  157. Derek: In case no one has asked... by sleight · · Score: 1

    ... can you cite some more specifics, either here, or on your blog post, about the limitations that you encountered?

  158. Re:thinking about something new? think again by sg_oneill · · Score: 1


    "Templating was crucial ten years ago. "

    I gather you don't work with graphics designers?

    The templating thing is crucial in real-world web design, because of the workflow of large team web design. Consultant specs it up. Team nuts out a plan. Graphics designer goes off and makes pretty pages, gives it to the team to use.

    All you have to train your designer is "Stick these sorts of things "{firstNAME} , {secondName} in the templates: and hope he has a bit of a grasp of good page design.

    CSS is all good and fine, but the reality is , you the coder don't make presentation. You make the logic.

    And sure Seaside does have some template engines, but if they aint supported, then good luck convincing the boss to invest in it.

    Which is a shame, because Seaside really has some cool shit going on, and other than the whole templating separation of logic and presentation, it eats rails for breakfast.

    --
    Excuse the Unicode crap in my posts. That's an apostrophe, and slashdot is busted.
  159. Re:thinking about something new? think again by Paradise+Pete · · Score: 1
    Right. Who wouldn't love Ruby with such obviously clear syntax as this?

    Assuming you're being sarcastic, The ? is simply part of the method name. It could just as easily been written is_directory. But because a question mark is allowed in method names, the convention is for methods which return a boolean to end with ?. It only looks a little odd when a parameter is passed. Parentheses are optional on method calls, so when there's no parameter you can write something like if socket.connected? which to me is pretty darn clear.

  160. Re:thinking about something new? think again by Anonymous Coward · · Score: 0

    WTF? What makes you think he's from Illinois?

  161. Re:thinking about something new? think again by Anonymous Coward · · Score: 0

    Well, if he's not from IL, that's at least where he was surfing from. Oh wait, I shouldn't know that being that I'm nothing but an uneducated cereal-pissing non-Slashdotesque geek -- right?

  162. Re:thinking about something new? think again by dubl-u · · Score: 2, Insightful

    Looking at Ruby on Rails, it seems like a cheap clone of the old NeXT WebObjects

    It has been a long time since I did WebObjects work, but I don't think they're particularly similar. The spirit is certainly very different.

    So, why do people use Ruby?

    I think there are two big crowds. One is the smart OO guys who have been suffering through Java for years. Smalltalk is not commercially viable, but Ruby is. Suddenly, they can escape all the Java idiocy. For the ones doing web stuff, and in particular the ones who have dealt with the absurdity of trying to program via large XML framework config files, Rails is a similarly big relief.

    The other crowd comes from PHP and other low-rent web development. Ruby + Rails lets them get something up as quickly as in PHP, but provides them better long-term tools and something much closer to what I'd call object-oriented development. Of course, a lot of those people quickly get in over their heads in Rails, as a lot of the shoddier Rails plugins demonstrate.

    So maybe it would be better if Rails were written in Smalltalk or Lisp. But Ruby it is, and it's not so bad. If Java's half-way between C++ and Lisp, then Ruby's cut the distance in half again.

  163. Different Tools For Different Jobs by Jane+Q.+Public · · Score: 1

    Many people choose Ruby simply because it has Rails... a web framework of awesome (but probably not unique) capabilities. The combination is (usually) a winner.

    Is that a good reason for choosing a language? Well, it depends on what you are trying to do. Do ANY of those other languages have good, solid, modern web frameworks that are freely and easily available? With good open-source licensing? Maybe they do, I am just asking. If so, I have never heard of them.

    On the other hand, I should point out that one of the nice things about Ruby is its on-the-fly extensibility. One can extend classes and methods at any time... even runtime. No doubt that is possible with Lisp as well but I do not know about those other languages. Most OO languages need re-compiling before extensions can be made, and/or are limited to specific models of inheritance. Ruby makes use of "mixins" rather than old-style inheritance, for greater flexibility. Perhaps I am wrong... but can you tell me which of those other languages possesses all of those features? Including the web framework?

    Also, unlike some other languages (Java is a good example), everything in Ruby is an Object. There are no "primitives" and then "objects" that have to be handled differently. In that way it is more internally and externally consistent than most languages.

    Ruby has a rich but not bloated set of built-in methods, and is a terse but not cryptic language to use. (Examples of how few lines of Ruby code it takes to do something in comparison to other languages are all over the web, yet the syntax is easily readable.) I am only guessing, but my guess is that those other languages fail in one of those respects: i.e., in comparison each is overly verbose, has a limited set of built-in methods, or has a comparatively cryptic syntax.

    Can you tell me which of those other languages possesses all of those features? Including the modern web framework? (Which of course is not a feature of the language, but IS a reason for choosing it.)

    1. Re:Different Tools For Different Jobs by TheRaven64 · · Score: 1

      One can extend classes and methods at any time... even runtime As you could with Smalltalk since the '70s.

      Most OO languages need re-compiling before extensions can be made, and/or are limited to specific models of inheritance Not true. C++, Eiffel, and Objective-C, maybe a few others require this, but most OO languages don't (and I'd hesitate to call C++ OO).

      Can you tell me which of those other languages possesses all of those features? Including the modern web framework? Smalltalk. In Smalltalk, classes and metaclasses are objects. You create a new class by sending a message to it copying it. You subclass by taking the copy and sending messages to it to add methods and instance variables. Blocks of code are just another object type, so you can add your own control structures to the language trivially (boolean objects, for example, have an ifTrue: method, that takes a block (closure) and executes it if the value is true) - there are no control structures that are separate from the message passing mechanism, so every control structure you have looks and behaves like an original one.

      All of the features you listed about why Ruby is so great have been in Smalltalk for 30 years. Commercial Smalltalks are 5-10 times faster than Ruby, and open source ones are 2-5 times faster depending on the benchmark. The best web programming framework I have ever used is Seaside, which is only available for Smalltalk. It makes writing a web app as easy as writing a desktop app, unlike Rails which is a cheap knock-off of WebObjects.

      --
      I am TheRaven on Soylent News
    2. Re:Different Tools For Different Jobs by Jane+Q.+Public · · Score: 1

      I am not very familiar with Smalltalk, so I am not trying to argue with you; I am willing to accept what you say at face value. I have known that it was there, or course, for a long time, but not any details. I want to ask you about some of my points that you have not addressed. First, though:
      JQP: "Most OO languages need re-compiling before extensions can be made, and/or are limited to specific models of inheritance"
      TR64: "Not true. C++, Eiffel, and Objective-C, maybe a few others require this, but most OO languages don't (and I'd hesitate to call C++ OO)."
      I stated that most languages of which I was aware require a re-compile, not all. And MOST of which I am aware still do. Perhaps you are aware of more than I. But if so, what are they? Besides Smalltalk and Lisp of course. I am curious.

      By the way, you forgot Java, probably the most popular OO language today, which requires recompiling AND has a limiting inheritance scheme. Which brings up that you did not address my "or": most are saddled with sadly limiting inheritance models. What sort of inheritance does Smalltalk use?

      I am also curious about the set of built-in methods for Smalltalk. There is much to be said for having a small (sometimes called "primitive") set of commands in a language, from which more-complex constructs can be built (which is apparently the strategy of C, and to some extent Lisp if I am not mistaken). But this is also largely what distinguishes "high level" from "low level" programming languages. I am interested to know where Smalltalk falls in that range.

      I had never heard of Seaside, which is not surprising considering the relatively low popularity of Smalltalk today. Which of course is part of what this discussion is about: whether Smalltalk "should" be enjoying more popularity than it currently does.

    3. Re:Different Tools For Different Jobs by TheRaven64 · · Score: 1

      I stated that most languages of which I was aware require a re-compile, not all. And MOST of which I am aware still do. Perhaps you are aware of more than I. But if so, what are they? Besides Smalltalk and Lisp of course. I am curious.

      Actually, you may be right. I haven't done a complete count. A few in the 'don't' category include:

      Lisp (+CLOS), Smalltalk, Javascrip, Ruby, Io, Self, OCaml (depending on the implementation).

      This is not counting a lot of procedural languages with OO extensions, like PHP and Python.

      By the way, you forgot Java, probably the most popular OO language today

      I try very hard to.

      Which brings up that you did not address my "or": most are saddled with sadly limiting inheritance models. What sort of inheritance does Smalltalk use?

      Smalltalk uses single inheritance, but any language with a proper forwarding mechanism does not need more than this. You can implement something semantically equivalent to multiple inheritance in Smalltalk (and Objective-C, for that matter). Any message you send (method you call in C++-speak) to a Smalltalk object that is not understood will be passed as a parameter to a fall-back method. You can use this to tell a second object to execute it instead. In Smalltalk, everything is an object, including the messages you send to objects, so it's very easy to subvert this mechanism to your own desires.

      You can also implement prototypes fairly easily in Smalltalk, since classes are mutable at runtime. You can get the class of an object, copy it, add methods to it, and then instantiate it (or just modify the original).

      I am also curious about the set of built-in methods for Smalltalk.

      It's a really nice way of working. The basic syntax of smalltalk is:

      object message:parameter.

      It implements closures (which it calls blocks) with the following syntax:

      [ :x | code]

      Where x is a bound variable and code contains references to x or any other variables valid in the scope where the block is declared. Since blocks are first class objects in their own right, you can use them to define flow control constructs. The only one that is typically implemented in the compiler (rather than the library) is a simple if statement. This is a method on the boolean type, so it looks something like this: aBoolean ifTrue:[ .... ]. There is also an ifTrue:ifFalse: variant, which executes the first parameter if it's true and the second parameter if it's false. You could use this quite easily to create more complex structures. In fact, the while loop is typically implemented in the class BlockClosure, of which blocks are instances. When a block receives a whileTrue: message, it executes itself, sends ifTrue: to the return value with the parameter and calls itself. An implementation of the while loop would look something like this:

      whileTrue: aBlock
      | res |
      res := self value.
      res ifTrue:aBlock.
      res ifTrue:[self whileTrue:aBlock].

      This simple method has one local variable (res). This is set to the value returned when the block is executed. If this is true, then it executes aBlock, and then recursively calls itself (these two lines could be in a block so you only pass one message to the boolean, but it doesn't make much difference).

      You can extend this further, for example adding a forEach: message to an array, so you would do something like:

      anArray forEach:[ :x | {do something with x} ].

      And it would execute the block once for each value in the array, setting it to x. Because this is how all control structures are implemented, there is no distinction between ones that came with the language, and ones you wrote, just as in an OO language there should be no distinc

      --
      I am TheRaven on Soylent News
    4. Re:Different Tools For Different Jobs by Jane+Q.+Public · · Score: 1

      Thank you for your explanation. I have only one thing to add and that regards inheritance. That is the one real distinguishing point I see here.

      Both single inheritance and multiple inheritance schemes have problems. With single inheritance, for example, you are limited in regard to what you can inherit. If you need more, often you must go to quite a bit of trouble to "simulate" inheriting from multiple classes (which is a desirable feature). You mentioned a way to "work around" the limitations in Smalltalk, for example. Multiple inheritance, on the other hand, can easily lead to ambiguity and conflict among classes. There is more but I think those are the two most common objections.

      Ruby attempts to get the best of both worlds with "mixins". It largely succeeds; mixins have most of the advantages but few of the problems inherent (no pun intended) in the other schemes.

      Mixins are not easily explained in a short space, but info is available on the web.

    5. Re:Different Tools For Different Jobs by TheRaven64 · · Score: 1

      From what I have seen of mixins, they seem to be what Smalltalk and Objective-C call categories.

      --
      I am TheRaven on Soylent News
  164. Pardon the repetition by Jane+Q.+Public · · Score: 1

    It was a cut-and-paste mistake.

  165. What a false dichotomy! by kyz · · Score: 4, Insightful

    I've now written two large business applications in Rails. I did the UML modelling first. Then I wrote a fully constrained RDBMS schema, normalised to 3NF, using the Rails naming conventions. Then I wrote the Rails app on top of the rigorously constrained database.

    If you want multi-key uniqueness constraints, just define it in your database already! Why do you think Rails prevents you from configuring your database layer?

    When I need to do transactions, I use Rails' full support for transactions. There, that wasn't so difficult, was it?

    I let Rails save me hours of backbreaking labour writing conventional SQL queries. Then I use the completed application, identify the query bottlenecks (thanks to Rails' built-in profiling) and re-write the slowest of the dumb auto-created SQL using hand-written SQL, which I can get to using find_by_sql, finder_sql, etc. Rails lets you put your own SQL into the application almost anywhere.

    --
    Does my bum look big in this?
    1. Re:What a false dichotomy! by tacocat · · Score: 2, Insightful

      You are obviously very familiar not only with Rails, but databases. Many Rails users are not and there's not much attention paid to the database as a business model enforcement in the Rails "way" of doing things. Specifically, the Ruby on Rails book is way too lean on this subject.

      My first and only Rails convention was a real learning experience. I was outnumbered by easily 20:1 in an argument that counter your statements. The generally accepted concept in that room was that Rails manages everything for you. If you have to create all these database centric constraints, indices, rules... then you aren't doing it Right. I was essentially shouted down on the notion that proper handling of unique values should be to manage the errors returned when you violate a constraint rather than doing a test and action without the database constraint. I'm not kidding about this either. I was one of three people who were in the database camp and we were all relatively new to Rails

      The other probable answer to how this could happen is that Rails developers are ex-php developers who still don't know anything about what a database is beyond some kind of file system for storing data.

    2. Re:What a false dichotomy! by kyz · · Score: 2, Insightful

      Personally, I think Rails has a way to go. I agree with you that it should auto-detect a lot more of the database schema and require much less manual configuration in the model layer and better parsing of database errors. Rails' intention is Don't-Repeat-Yourself by means of making your database schema a first-class citizen in the Ruby language. So future Rails releases will be more along those lines.

      I think the reason it doesn't right now because it was designed to work with MySQL MyISAM tables, which are not really relational database tables.

      I try to judge computer languages/framework by their authors' intents rather than what its novice users think about them. So I approve of Rails, even if it could do more to teach people about database design, because it successfully teaches people about the MVC pattern and Don't-Repeat-Yourself.

      --
      Does my bum look big in this?
    3. Re:What a false dichotomy! by Alan+Shutko · · Score: 1

      Actually, if you read DHH's blog (here's a google cache link, the original seems to have moved http://64.233.167.104/search?q=cache:B9zIVL4XR4sJ:www.loudthinking.com/arc/2005_09.html+single+layer+of+cleverness&hl=en&ct=clnk&cd=1&gl=us&client=firefox-a) it looks like his intent is to pull all that logic from the database completely, and use it merely as a table-store.

    4. Re:What a false dichotomy! by nightowl03d · · Score: 1

      Actually rather than waiting to decide whether I need to configure the database layer, or whether I need to use Rails' full support for transactions, or when to use finder_sql or find_by_sql, I prefer to go directly to http://www2.sqlonrails.org/ and just DO IT!

  166. Re:thinking about something new? think again by Dimitri-san · · Score: 1
    for file in `find . -type f`;
    do
    dostuff $file
    done

    Or, as a single line:

    find . -type f -exec dostuff {} \;

    Behold, the power of the shell!

  167. Huh? by Slashdot+Parent · · Score: 3, Insightful

    Referential integrity and unique constraints should always be enforced by the database. Why even have a database if you're not going to use it?

    Perhaps I'm missing something in your post, because it sounds to me like you're advocating every application that accesses the database to enforce data integrity rules. This is a recipe for data corruption, as I'm sure you already know.

    --
    They don't grade fathers, but if your daughter's a stripper, you fucked up. --Chris Rock
    1. Re:Huh? by tacocat · · Score: 1

      I know this only too well.

      But Rails sells itself on not requiring anyone to know a lot about SQL. That's what bothers me about it.

      IMHO there isn't enough focus on getting the database built to enforce the business rules in the Model. Rather it's sold as "The MODEL does everything you need!!" and lulls you into a sense that the application should enforce all the rules and the database should carry a minimum of them. I think this is extremely short sighted.

      Databases were created many years ago and have an advantage over anything else in that they are designed to do one thing only, do it extremely well, and have been optimized over decades to do it better than anything else. Why duplicate this in some slow language like Ruby? And yes, Ruby is slow when you compare it to C and even Perl. Pretty, easy, but slow.

      I don't think Rails is entirely to blame as a technical solution. I think the marketing is to blame and the hype makes it downright dangerous.

  168. Re:OMG Thinking Fundamentalism? think again by Anonymous Coward · · Score: 0, Funny

    Hour 1
    Mommy, I am only 0.05 inches long, but I have all my necessary cells for reproduction. I love the sound of Dad's voice going "Uhhhhg-! Yeah, Baby!".
    Every time I hear it, I wave to those other less fortunate spermatozoa. But strangely, they do not wave back...
    The sound of your heart beat is my favorite rap. And Jesus LOVES me. And Ponies too!

    Hour 2
    Mommy, Well here I go through the Fallopian tube! Gosh!....

    Hour 3
    You know what Mommy, I think I have 4 cells now, including Mr. Sperm!

    Hour 4
    Mommy, my I am trying to glue myself to the uterus wall, but I can't seem to stick!
    (Is this the "Court of The Crimson King" like Daddy was humming??)

    Hour 5
    You went to the doctor last week. I KNEW it! And you took those 'pills'. That is why I can't glue to the wall.
    Please dear Jesu! Please help Reverend Billy-Bob ban the Birth Control Pill!

    Hour 6
    I can hear the sound of a bathroom! Oh! I am going down a long tube again! Whee!
    OH-OH! (SPLASH!)
    OMG I am in water! Mom! Please don't flush! No! ...swirl

    And thus folks, ends the sad story of a child, one of 7 Trillion in the naked toilet!
    Please help save these eggs and sperms! And if you must spill your seed, son, make sure you are married, and it is done into the proper egg container. (Ask your mom.)
    And ONLY at the proper time of month.
    AND, Little Mandy? Stay away from those evil pills in the circular dispenser!


    ....an aqk Pinoqachole Horror Production. god bless.

  169. Re:thinking about something new? think again by Nicolas+Roard · · Score: 1

    But again, writing your OWN templating engine is absolutely trivial, if you really need to do so. Yet somehow it doesn't stick with Seaside because even the ones that did write and release such templating engines ends up realizing they are more a burden than a good thing.

    And frankly, if your designers don't know how to design with CSS... you have a problem.

    But anyway, this whole point is moot. Even if the designer handles me some weird template page, it will be fairly trivial to take the template and stick it into Seaside -- remember, in Seaside you are not working with HTML, you work with Smalltalk code that happens to map to html.

    Therefore, you usually do not use the 1:1 mapping between said code and html to create your pages/components, but rather group bits and pieces of the "html" you need as full Smalltalk methods. Yay for html refactoring ! (and that's without even talking about the components model).

    Between this possibility and the components, you end up working at a high description level; you express the structure and logic of the "page", not how it looks or even which bits of html it will output. Therefore it really is no more trouble to add some pure HTML if you need to because your designer hasn't learn a damn thing in ten years than to add whatever additional divs you'd need to your high level structure in order to accommodate the cool CSS design your competent designer would have come with. I'm probably not clear enough, but believe me, templates are not the problem with Seaside. Play a bit with it, you'll see.

  170. Re:thinking about something new? think again by Nicolas+Roard · · Score: 1
    Smalltalk has been around for ages. If it's so great then how come it never caught on?

    If you look at Smalltalk today, this question is indeed absolutely inexplicable, and when you start programming in Smalltalk you just can't understand how is it possible at all that it's not used everywhere (at the very least, it should be much, much more present than it is). It's the closest thing to an ideal programming world (ok, I probably should include lisp on a lisp machine).

    That beeing said, it's sadly fairly explicable:
    • Smalltalk environments were BLOODY EXPENSIVE (and needed expensive workstations to run usually). We now have some very high quality free VM that works on any OS. And even the expensive commercial Smalltalk are now affordable or even free for non-commercial use.
    • Smalltalk was slow ! (of course now it's not a concern, for various reasons; mainly we now have very, very fast machines, and also Smalltalk VM are much much faster, some with JIT, etc. See Strongtalk ...)
    • Smalltalk "looks weird" to an imperative programmer (and believe me, I wouldn't call C++ an object-oriented language, so I readily include C++ programmers in that list)
    • Not file-based, but image-based. Quite unsettling at first, and can leads to some annoyance (but also brings so much power that it's an easy tradeoff to make!)


    So basically, 1/ It was not familiar, with a quite big conceptual jump to make (procedural to true OOP) 2/ It was not easily accessible 3/ It was slow. Of those 3 reasons, the first two are very likely the reason why Smalltalk didn't take over the world. That doesn't mean it shouldn't.

    There's another reason sometimes quoted about Smalltalk: That it's so great that companies just do not advertise its use: it's a competitive weapon.

    The irony of course for reason #3 (slowness) is the last fad language is Ruby (which I do quite like), who happens to be magnitude slower than the slowest Smalltalk.
  171. OK I finally RTFA and... by TheLink · · Score: 1

    My conclusion is, while he might have "rewritten the stuff in PHP in 2 months", he spent > 2 years designing the app (and prototyping in rails) then he finally "typed in" the final version in PHP.

    No surprise it's easier, better and actually doable.

    He could have even done it in perl and it would be readable by nonperl people given it's the Xth time round ;).

    But I suppose he was fluent in PHP, so "retelling the same story (with improvements)" in PHP would have been easier for him.

    --
  172. Re:OMG Thinking Fundamentalism? think again by fractoid · · Score: 0, Offtopic

    Every sperm is sacred!

    --
    Rampant carbon sequestration destroyed the Dinosaurs' tropical paradise. I'm here to help repair the damage.
  173. I purposely avoided commenting about the choice... by CFD339 · · Score: 1

    ...in his article of IE simply to avoid the "IE Sucks" discussion. Consultants do what consultants are paid to do. Someone owned the project scope and was responsible. That person utterly failed to reconcile things like scalability and product choice. Regardless of the merits of IE based code, the PM allowed it to be done without checking with the desktop people.

    --
    The problem with quotes on the internet, is that nobody bothers to check their veracity. -- Abraham Lincoln
  174. Re:thinking about something new? think again by Anonymous Coward · · Score: 0

    I don't get your point.

    Is there something more special than changing in Perl
    a 'for(<*>) { ... }' to 'for(sort <*>) { ... }' ?

    (or, FWIW for(map { .. } grep { .. } sort { ... } etc).

    You can do tricks like that in any high-level dynamic
    language.

  175. Re:thinking about something new? think again by root-a-begger · · Score: 1

    I have used Ruby and Rails (limited and recently) and Smalltalk (significantly and years ago).
    Your question:
    "why would you choose a slow-and-expressive language over a fast-and-expressive one?" is something I struggled with when I was choosing a language for my new web app http://www.shellshadow.com/ . I spent too much time on this choice.

    My previous company was patternWare (Smalltalk and later Java app frameworks). I knew lots about frameworks. I see Ruby on Rails and say, "its nice but not near as enterprise quality and scalable as what I've built myself". But the bottom line is it is "nice" and "does what it claims for building web apps".

    A retrospective on my decision for using Ruby on Rails is:

    1 - I'm building a web app as "a part" of my business. Its not the whole of my business. If I build it correctly with Rails, I can always outsource a rewrite in something "more scalable" if need be. This time may never come, but I know that my web app code is very clean due to choosing Rails. Note: As a prior life in building app frameworks, I don't recommend using "magic". I use Rails for the core http request cycle and MVC separation and consider myself using Ruby for the rest of my needs.

    2 - Mindshare. My new startup, shellshadow, has two other key components to my technology beside the web app. I need to easily find top talent for each of these three components.

    I wanted to use Smalltalk. I also wanted to use Erlang (longer post required).
    But the bottom line is I needed to find good talent that could plug into my business as I grew.
    Ruby (and Rails) fits "right now". Smalltalk (and Seaside) does not. I can buy more server horsepower. Finding and scaling programmer talent is harder.

    Jon

  176. Technology implication by arnonrgo · · Score: 1
    Reading his post I saw a few quotes that raised a red flag for me such as:

    "But at every step, it seemed our needs clashed with Rails' preferences. (Like trying to turn a train into a boat. It's do-able with a lot of glue. But it's damn hard. And certainly makes you ask why you're really doing this.)"
    and

    #2 - OUR ENTIRE COMPANY'S STUFF WAS IN PHP: DON'T UNDERESTIMATE INTEGRATION
    By the old plan (ditching all PHP and doing it all in Rails), there was going to be this One Big Day, where our entire Intranet, Storefront, Members' Login Area, and dozens of cron shell scripts were ALL going to have to change..
    and

    Speaking of tastes: tiny but important thing : I love SQL. I dream in queries. I think in tables. I was always fighting against Rails and its migrations hiding my beloved SQL from me.

    What these quotes say really is that this guy doesn't know about "Technology Mapping 101". Here is what I wrote about technology mapping* about 2 years ago (incidentally that's about the same time this guy started his Ruby adventure :) )


    "Technology mapping can have a significant impact on the ability to actually implement the architecture. The wrong mapping can make adhering the architectural guidelines very cumbersome and sometimes nearly impossible."
    Every technology or framework has its own architecture. This architecture poses constrains and makes certain things easy (like using the ActiveRecord pattern in Rails) and certain things harder (like not using O/R Mapping ) so, for instance, on the case mentioned above a better technology mapping might have been RBatis (iBatis for Ruby/Rails) which lets you map SQL statements to objects. It is important to note (in Rails case) that one of the core tenets for Rails is preferring convention of configuration when you don't do that you have to work hard(er) - as you are working against the framework

    Another problem with the technology mapping here was his point #2. It is a pity he only saw it in after the fact. It can be justifiable to switch everything but you've got to allow this change to occur iteratively. While I generally dislike the software architecture = building architecture metaphor, using it here does make sense: building software for an existing business (vs. greenfield development) is like building a new intersection. You have got to think about building all the detours that would allow the traffic (business) to continue to operate, sure it might run slower in the intermediate phase but it can't stop altogether.

    So again, Once you have an architecture that fits your business, take a look at the technology options you have. try to choose the best fit. Whatever you choose - take a look at the implications of that technology and think about the tradeoffs you may find that you either have to adjust your architecture or change the technology altogether - if you don't you might find you waited 2 years of development effort or even more..


    * Technology Mapping is one of the steps of a set of activities I identified as needed to make sure your have a solid architecture. The activities goes by the acronym SPAMMED and you can read about them more in this article and/or this presentation


    copied from my blog

  177. Re:Thinking about abortion? think again by Anonymous Coward · · Score: 0

    That's why formal logic should be law. Anyone not using formal logic and reason should be sent in for re-edumacation!

  178. Re:thinking about something new? think again by shiftless · · Score: 1

    ... then you can design your nice tabled based pages in Photoshop/Dreamweaver and I won't have to spend a week converting them to a CSS based Joomla template.

    Why are you using tables instead of CSS? CSS can be a pain in the ass sometimes, sure, but its advantages far outweigh the trouble.

  179. Re:thinking about something new? think again by TheRaven64 · · Score: 1

    You know you could have just run gcc -E on the source files, which runs the preprocessor and (recursively) pulls in all of the included files before submitting the work, right?

    --
    I am TheRaven on Soylent News
  180. Re:thinking about something new? think again by WNight · · Score: 1

    IMHO, because of how people who use it are self-hosted in the language, like Squeak. That means there's a very steep learning curve in the sense that everything is new. Nothing is very hard, but it's all very different.

    Switching from Perl to Ruby on the other hand... Ruby accepts perlisms, is written in standard text files, etc.

    Of course it lacks everything that Squeak comes with, but if you've never had more how do you know what you're missing?

  181. Consider games by Chemisor · · Score: 1

    >> Thinking about ditching Windows for Linux? Think again.
    > Now that's just flamebait. My house is 100% Linux, my work is 98% Linux, and it's truly a great thing.

    Well, sure some people can do this, but most of us like to play a game now and then. Considering that there are no games on Linux, aside from the multitude of simple puzzle games and alpha-stage ugly-looking bug-ridden clones; considering that the fabled Wine doesn't run any games I actually want to play; and considering that OpenOffice is an enormous pig compared to MSOffice and can't print a letter and a proper envelope (which is all a home user usually needs it for), Linux just doesn't seem like a great deal. Sure I run Linux. In fact I run it almost all the time, because I like coding in it, but I still can't ditch the Windows XP partition because I like an occasional game.

  182. Did you read the part about SQL? by master_p · · Score: 1

    One important thing about Rails is that it hides the SQL from you. This might be good for some purposes, but not so good if you really want to get things going. This is specifically mentioned in the article.

    1. Re:Did you read the part about SQL? by Blnky · · Score: 1

      One important thing about Rails is that it hides the SQL from you. This might be good for some purposes, but not so good if you really want to get things going. This is specifically mentioned in the article. Hides? I don't think that is the appropriate description. 'Provides ways to completely avoid most SQL' may be a better description. From the "Agile Development with Rails":

      You can execute SQL statements using the underlying Active Record connection adapter. [...] At the lowest level, you can call execute to run a (database-dependent) SQL statement.

      The methods to do this are just as visible in the controller as the ActiveRecord methods. They aren't hidden at all. You just don't end up using them near as much as the ActiveRecord methods.
  183. Good old saying by AbbyNormal · · Score: 1

    Always use the best tool for the job. Sure you could build a house with a spoon instead of a hammer...Of course, this is only if you are solely in charge of the project and tools. I've seen some amazing decisions from upper management regarding application development tools.

    --
    Sig it.
  184. Don't count C++ out yet by master_p · · Score: 1

    There are cases where every performance optimization counts. In these areas, C++ comes on top of every other language.

    And almost all successful desktop apps are made in C++. For example, uTorrent, a much smaller, faster bitorrent client is made in C++. The author claims that he wanted a small footprint, no external dependencies, no further downloads.

    Every tool has its usefulness...use the right tool for the right job.

  185. Java? by master_p · · Score: 1

    Nice SDK, huge set of libraries, very good IDEs, close to C/C++ syntax-wise, interfaces with C, very fast...and you don't have to follow the J2EE specs if you don't like them.

  186. Re:thinking about something new? think again by Dan+Ost · · Score: 1

    The thing about girlfriends is that you have to be honest with yourself what you're looking for.

    I ditched C++, Java, and Perl for Python 5 years ago and am extremely happy with that decision.

    --

    *sigh* back to work...
  187. Re:thinking about something new? think again by TheRaven64 · · Score: 1

    GNU Smalltalk (GST) is a file-based Smalltalk implementation, with an easy way of calling C functions. If you're coming from something like Ruby, using GST as a stepping stone to something like Squeak might make your life easier.

    --
    I am TheRaven on Soylent News
  188. Re:thinking about something new? think again by nuzak · · Score: 1

    The image-based nature of smalltalk, combined with proprietary and expensive development environments, contributed to making smalltalk far less relevant today than it should have been. Largely, you cannot write a smalltalk script or library. You have to open up your image, go into smalltalk land, and keep everything in the image. Interface to the external system was an afterthought, and actively discouraged in the walled garden of smalltalk.

    Even now there's not many free implementations that support scripts or small standalone executables. Possibly GNU smalltalk, but frankly it's less impressive than ruby.

    Smalltalk did have a chance a while back: IBM was pushing it with VisualAge, smalltalk ISV's were popping up, it was getting popular for writing CBT software. Then came this upstart called Java, and the rest is a sad history.

    --
    Done with slashdot, done with nerds, getting a life.
  189. Re:thinking about something new? think again by WNight · · Score: 1

    Thanks. It might help. Certainly a lot of Smalltalk features like named parameters are things I keep implementing in Ruby.

  190. Re:thinking about something new? think again by smackjer · · Score: 1

    You can get a paying job doing Ruby.

    --

    This is my sig. There are many like it, but this one is mine.
  191. Somebody tell the old guy to watch the language by Anonymous Coward · · Score: 0

    using obscenities in tech writing of this nature no longer makes you sound like the badass rebel you once thought you were

  192. TFA isn't "Thinking about Rails, think again..." by DragonWriter · · Score: 1

    Nothing in the article says anything negative about Rails. Indeed, the author says toward the end, "All that being said, I'm looking forward to using Rails some day when I start a brand new project from scratch, with Rails in mind from the beginning."

    TFA really boils down to "If you have a large existing production system that essentially does what you want, and mostly the way you want it, its generally a bad idea to throw it out and start over just so you can use a fancy new tool that takes a completely different approach to the problem domain than the one taken by your existing tool and, more importantly, than the approach you want to take for the project."

    Which is also the reason that plenty of large COBOL systems hang around, with bits and pieces in other languages added on and interfaced to them, but the main system left in COBOL and maintained there rather than reimplemented, until changes to the requirements would force a complete reimplementation even if the language didn't change.

    "If it works, don't fix it."

  193. Re:thinking about something new? think again by Almahtar · · Score: 1

    Heh :-) Where were you 2 years ago?

  194. Re:thinking about something new? think again by PurplePhase · · Score: 1

    Rails is also terrible in my experience at consistence and installation reproducibility. After my initial installation of Ruby, RoR, and all required gems... well, we can't reproduce it on another Windows machine and MacOSX has no better luck. Our Lead Architect upgraded RoR by one point version...and Rails could no longer start with our website. We only used the RoR standards for development, taking most everything from Dave Thomas' book. Even so I had to bugfix some of RoR for it to behave as expected (problems with RAILS_ENV and the second copy).

    Similarly I'll bitch about Ruby install problems because I was developing GUIs in Ruby but once the 1.8.4 release came out, the Windows all-in-one installer no longer included Tk/Tcl. Well so much for that's that.

    As with everything, I don't care if *you* want to take a day or a month to get a development environment or OS to install. Just don't call me stupid when I don't want to waste my time on that crap. If there isn't a simple, reproducible way to install the environment, what chance does distribution have?

    And I'm really sorry to see it go: RoR has been great to work with! I can do so much for my customers with it, but if we have to devote 40 workhours to getting a new development environment running there's no gain except for large projects with few developers.

    Please fix it, guys!

    8-PP

  195. Learning to program... aint it a bitch by BadAsh71 · · Score: 0

    I've seen this countless times... thankfully, a lot of you have mentioned the same things. This is simply a case of a guy that was a mediocre spaghetti code writing PHP Programmer who took 2 years to learn a more formalized, more structured Programming Language (Ruby) and its MVC oriented Framework who got a little lost along the way and decided to return to what he knows, PHP. Luckily, he is taking with him some of the more structured programming experience he gained along the way and will undoubtedly be a better programmer for the effort.

    Is it a waste to take 2 years out of your life and learn better coding practices only to throw it away and go back to a less structured programming language? Yes and No... if he learned something along the way and it makes his PHP code better, more structured then it was a great lesson.

    I wish him good luck and I hope others out there reading the Slashdot and Digg Article Titles don't go nuts and drop Ruby on Rails for PHP. Read the article and educate yourself.

  196. Re:thinking about something new? think again by Eivind+Eklund · · Score: 1
    Smalltalk requires replacing your entire environment, including editor, access to files, etc. It also has a "weird" syntax. Ruby plugs nicely into the Unix environment.

    I suspect that's why Smalltalk is "more or less dead", and Ruby is taking the world fairly much by storm.

    Eivind.

    --
    Doubting the existence of evolution is like doubting the existence of China: It just shows that you're uninformed.
  197. Re:thinking about something new? think again by TheRaven64 · · Score: 1

    Smalltalk requires replacing your entire environment, including editor, access to files, etc. Depends entirely on your Smalltalk implementation. This is true of Squeak, for example, but not of GNU Smalltalk, which plugs nicely into a UNIX environment and has a clean way of calling C functions.
    --
    I am TheRaven on Soylent News
  198. bullshit by just_asgard · · Score: 1

    this man did really stupid thing. why did he start to rewrite his _working_ project? because ror became trendy? it's bullshit. how can anybody read this guy's comments about ror? he even doesn't understand that language is just an instrument and if you can't adopte to language semantic and syntax it doesn't mean that language is 'bad'.