Eclipse builds an appfuse Development Environment

Source: Internet
Author: User
I. appfuse provides some features required by many applications, including:
* Authentication and authorization
* User Management
* Remember Me (this will save your login information so that you do not need to log on again every time)
* Password reminder
* Registration and registration
* SSL Conversion
* Email
* URL rewriting
* Skin
* Page Modification
* Templated Layout
* File Upload

Ii. Preparations
Install JDK 5 +, tomcat, Maven, and MySQL.

3. Use Maven to create a project
MVN archetype: generate-B-darchetypegroupid = org. appfuse. archetypes-darchetypeartifactid = appfuse-Basic-spring-Archetype-darchetypeversion = 2.1.0-dgroupid = com. mapbar-dartifactid = appfuse-darchetyperepository = http://oss.sonatype.org/content/repositories/appfuse

4. Download source code
There is only one class in the generated project: App. What about other classes? The project generated by default is embedded, and other classes are introduced as jar instead of source code. If you want to generate the source code in this project, you can:
MVN appfuse: Full-Source
Problem:
[Error] 175002: SVN: PROPFIND request failed on '/SVN/appfuse/tags/appfuse_2.0.
1/data/common/src'
[Error] 175002: SVN: Connection timed out: connect
Need to add: https://svn.java.net/svn/appfuse ~ SVN/</trunk> to the following location
<Configuration>
<Genericcore >$ {amp. genericcore} </genericcore>
<Fullsource >$ {amp. fullsource} </fullsource>
<Trunk> https://svn.java.net/svn/appfuse ~ SVN/</trunk>-- Add
</Configuration>


5. Component eclipse Maven Eclipse: Eclipse downloads all dependency packages. It takes some time.
Error: the artifact org. springframework: spring-A spects referenced in aspectj plugin as an aspect Library, is not found the proje ct Dependencies
Then you need to add spring-aspects dependency. Add dependency package

<Dependency>
<Groupid> org. springframework </groupid>
<Artifactid> spring-aspects </artifactid>
<Version> 3.1.1.release </version>
</Dependency>


6. Import the project to myeclipse

7. configure the database to modify Pom. xml
<Dbunit. datatypefactoryname> org. dbunit. dataset. datatype. defaultypefactory </dbunit. datatypefactoryname>
<Dbunit. Operation. type> clean_insert </dbunit. Operation. type>
<Hibernate. dialect> org. hibernate. dialect. mysql5innodbdialect <JDBC. groupid> mysql </jdbc. groupid>
<JDBC. artifactid> mysql-connector-Java </jdbc. artifactid>
<JDBC. version> 5.0.5 </jdbc. version>
<JDBC. driverclassname> com. MySQL. JDBC. Driver </jdbc. driverclassname>
<JDBC. url> <! [CDATA [JDBC: mysql: // localhost/appfuse? Createdatabaseifnotexist = true & amp; useunicode = true & amp; characterencoding = UTF-8]> </jdbc. url>
<JDBC. Username> root </jdbc. Username>
<JDBC. Password> </jdbc. Password>


Modify the last <JDBC. Username> root </jdbc. Username> <JDBC. Password> </jdbc. Password> to the username and password set by the MySQL database.

8. Start:
MVN Eclipse: eclipse-dwtpversion = 2.0 pack into war package
MVN jetty: Run to start the jetty container
Open http: // localhost: 8080 in the browser.

Refer:
Http://blog.csdn.net/clearwater21cn/article/category/107237
Http://blog.csdn.net/shagoo/article/details/4103937
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.