gaohailong / OnlineBookstore

An Online Bookstore implemented in Java that provides a platform for seller and buyer to trade.一个用Java实现的买卖家在线交易书籍的网上书店。

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

OnlineBookstore

An Online Bookstore implemented in Java that provides a platform for seller and buyer to trade.
一个用Java实现的买卖家在线交易书籍的网上书店。

Screenshot

Environment

  1. Java: JDK 1.7.0_79
  2. Server: Jetty 8
  3. Database: MySQL 5.1
  4. IDE: eclipse-jee-mars

Deployment

One way to depoly this program is just to put Directory OnlineBookstore into webapp in Tomcat's or Jetty's Directory, while the other way is for debugging:

MySQL

  1. setup MySQL 5.1 and start MySQL service;
  2. create a database named 'online_bookstore' and run online_bookstore.sql to import data;
  3. if you want to change the username and password of database, you can rewrite them in OperDB.java.

Project

  1. import OnlineBookstore into IDE;
  2. select the JDK bin's installing path for the project while not using JRE;

Server

  1. install Jetty plugin in eclipse;
  2. right click the project and click Run As -> Run Jetty. Be careful that Jetty's version should be '8.x.x', or annotations of WebServlet would not work and servlets' path cannot be found.
  3. you can also change the port and the context of this project(server) in Run As -> Run Configuration.

Visit

http://localhost/OnlineBookstore/SearchClServlet?dowhat=searchByRand

Key Points

  • use simple Java Servlet to get/forward request and send response.
  • use MVC pattern to decouple View(JSP) from Controller(XXXClServlet) and Model(XXXBeanCl and XXXBean).
  • create 6 key tables to undertake the tasks of all the bussinesses.For details you can reach online_bookstore.sql.

For More

If you want to learn more about the development of this project, you can visit 网上书店简介.pdf and 网上书店开发文档.pdf.

About

An Online Bookstore implemented in Java that provides a platform for seller and buyer to trade.一个用Java实现的买卖家在线交易书籍的网上书店。


Languages

Language:Java 100.0%