I would like to have your opinion regarding the project i am about to embark on. I know that most of you have alot of experience in JSP thus my question is :
I am looking to build an online catalog for a small jewler, no ecommerce, just an online catalog. SO as a start, it would be listing watches with pics and specs etc...
I was thinking i definitely need a DB(planning for MySql) and figure JSP is good not only for the start but also for evolving with a cart module for example if the business evolves.(scalability) + I am a java kind of guy(i work with j2me currently), i think the experience with JSP has more value than with PHP.
Do you think JSP/Tomcat/MySql are the right tools to start?
The rationale for selecting a server-side technology often has a lot to do with the existing skill set of the development team (in this case you ). I would say that JSP and Tomcat is a good choice given your Java background. The only downside for your client is that the cost of good Java web hosting is much higher than for simpler technologies (at least in the UK anyway!)
I'm not so sure about the choice of MySQL for the database, however. What alternatives have you considered? The last I heard MySQL didn't support transactions or stored procedures. I did hear it now supports sub-queries (finally) in version 4.1. I don't know which DB to recommend to you - it might depend on the hosting arrangement, but bear those things in mind.
I will pretty much concur with what Julian said with the following additions:
- If MySQL doesn't suit your needs, I've been using PostgreSQL quite successfully. Supports transactions, sub-queries, and result set 'slicing and dicing' via the LIMIT and OFFSET clauses (great for paging through a large result set in managable chunks).
- In the US, I've seen the price of JSP/Servlet hosting plummet as competition has increased. So especially for a commercial site, I do not believe that cost of hosting is any sort of barrier.
If your market is likely to be largely UK-based would there be any disadvantage of having your site hosted in the States? I'm thinking of stuff like latency (how much of an issue is that?) and your host's IP not resolving to the UK so, e.g. you wouldn't turn up in UK-only results in Google.
I have experience with JSP and PHP, and with MySQL, Oracle, and MSSQL.
I am going to differ from the others slightly. I think the choice of language depends on the size and complexity of the site. If it will be less than 10 different types of pages, you will get it up much faster with PHP. If it will be much more than that, you'll be better off with JSP. The reason is that PHP's weak typing allows you to get individual pages working faster, but it causes problems once the complexity goes up that JSP's stronger typing prevents.
As long as the site has no e-commerce, I think you are fine with MySQL, and you'll get it up and running much faster than the other options. If on the other hand you think e-commerce might be added later, I'd recommend PostgreSQL - like others, because its transaction handlig is much stronger - or if you have a budget, Oracle. MySQL has alternate table types that support some kinds of transaction handling, but you lose some of MySQL's other features to get the transactions, plus its flavor of SQL is much less standard.
Let us know what you decide and how it works out!
Joined: Aug 02, 2004
I would agree that PHP would be quicker than JSP if you (or your development team) are familiar both technologies. However, if you have to learn PHP/Perl but if you already know Java and HTML, etc. do you still think it would be quicker to learn PHP/Perl and code a small site than to learn JSP and code it?
Joined: Mar 04, 2004
I don't know Perl so I can't speak to that.
I think that for anyone that knows Java and HTML, using PHP or JSP will be quite easy. Coding in PHP is very much like coding in JSP scriptlets; the only things you really have to remember are putting the silly dollar signs in front of the variable names and the fact that you don't have to declare variables. Other than that the syntax is c-like, just like JSP scripts.
Honestly I think installing PHP or Tomcat is likely to be more time consuming than getting productive in PHP or JSP - we're talking less than a day here.
I'd like to emphasize, though, that I'm only recommending PHP for small or simple sites. Once you start getting any real complexity, you'll be wishing you were using JSP, or even taking the trouble to convert.
Once you start getting any real complexity, you'll be wishing you were using JSP
And since the OP specifically called out for scalability and the site evolving, I'd say JSP was a slam-dunk.
Joined: Aug 02, 2004
Thanks Warren. I'd thought that PHP syntax was Perl-based. Really should take a look sometime...
Joined: Aug 13, 2004
Hi Guys, I would like to thank all of you for taking the time to answer my question.
I really enjoyed reading thru your msgs.
Regarding the DB, i am not familiar with postgreSql, but i have worked before with MySql and found it fairly simple(limited use for little apps). Maybe the limitations will appear once am deep into the project. So thanks for pointing out these limitations.
I have thought of starting up with php, but so many elements pushed me to JSP, my java background, the value of jsp on the market(much much higher demand) and the scalability. I know for sure that if the project goes thru, a cart page would have to be implemented where the order is sent by email, and confirmed with the customer by phone, since all the customers will be targeted in the current city where the company is operating, so for scalability, JSP had another +. And finally i think the success of this project might give me follow thru contracts on the side(or so i hope).
Frankly, since i never embarked on such a project, i will be using the book by James Turner : MySql and JSP web applications as a guide since in the book a full project is developped. If u have any other suggestions please do not hesitate to post them.
Again thanks for taking the time to answer my msg! Mike
Another good option for the database would be Firebird. High performance, scalable, secure and stable. Open source development of the commercial Interbase codebase which is in use with such highprofile organisations as the US DOE for tracking nuclear material. I've used it myself on several projects and it's nice and easy to use.