springboot + jpa + security blog system

Write at the top

Demo site: blog.ydemo.cn

China Open Source Project source code cloud: https://git.oschina.net/oneper/base/tree/dev/

Interested students can swing down to the source code, then deploy war package to your own server, how to package, the binding domain and a series of operations to see my recent blog, documented problems encountered, if you have questions, please leave a message.

introduction

Indeed, for a long time, I did not find an elegant java blog system. To write their own a bar, thinking about open source php excellent blog so much, why waste time going to get, and more besides write their own problems, consider any rate not fully, with this, and so, own their own scare. Happens is that early April day in open China's search box, search the next blog, appeared tale. Point to open a look, interface fresh, beautiful layout, lifted the spirit. The best thing about it is that the author of the open source, easy to learn. This time the emergence of executive power of the word in my mind, it is better to let the action decision thinking, to overcome laziness, so I have to realize once.


Select the frame

Read the description of the technical architecture of the original author, and I gave up going to get bloated ssm ssh like architecture. First, Xueyibujing; secondly, the integration framework is different, absorbing frame CRUD is not a day to do a thing. For spring boot fire is not fire thing, who cares, since I am also a beginner, it is dry. Springmvc at least understand the process, you can immediately know how the project is run. So I chose springboot. Read the author's statement, saying that there is no permission to add this one, just in March to study the spring security4 more than half. Currently architecture is springboot + springsecurity + jpa (? Oh yes, there orm layer, easy to use for the jpa). As for page rendering, jetbrick-template authors use has been great. In view of the above three are new to knowledge, in order to add the new new, chosen template engine thymeleaf. Development tools with idea. The above, together with new projects can be integrated, easy.


project instruction

Author of the project looked very simple, but doing it is not so different story. Let me deal with a lot of the details of the huge gap between the perceived and author. Thus, the ability to make their project and on the other, it simplifies a lot of features. But also facilitate them to learn with it, after all, I was a novice. Now basically the same overall project and run the original author.

1. Development of functions:

  1. User management: only for individual users, the user does not provide CRUD can be extended.
  2. Role Management: security framework must, associated with the corresponding user roles, can be extended.
  3. Article published: Published Bowen.
  4. Friends Chain Management: management of the site to mount that link.
  5. Classification, Labeling Management: mainly to publish articles provide convenient.
  6. Attachment Management: Using seven cattle cloud on the article to use the image file unified management.

Depending on the selected frame, some of the features provided by the author for not being realized, keep things simple, the main face of beginners. I removed the specific feature: comment this piece, site settings system settings, clear the cache, export sql, configuration plug-ins, extensions theme template. The rest are basically the same, can be packaged as a jar war and other forms of direct operation.

2. Project Framework

  • Main frame: spring boot 1.5.2+ spring security4 + jpa 
  • Cache: ehcache
  • Admin Template: H-UI admin
  • Front theme template: pingshu
  • Database: mysql
  • Template engine: thymeleaf
  • Image storage: Seven cattle

The front end of the frame are not described, basically using the same.

Here I feel the most meaningful thing to do is to integrate springboot and security, expand the JPA database access, as well as showing how seven cattle cloud storage implementation.

3. Quick Start

Cloud code address: https: //git.oschina.net/oneper/base/tree/dev/

Development tools: idea.

Import items from the code to the cloud idea, modify the configuration file mysql application.yml the resources, and then run directly DemoApplication.java main () method.

The browser then visit: http: // localhost: 8080 /

Admin address: http: // localhost: 8080 / login    

Home jumps to login.

Need to re-visit http: // localhost: 8080 / admin / index

4. After running the project Mito

Homepage:

Enter Caption

Details page

Enter Caption


Background Homepage:

Enter Caption

Tomo链

Enter Caption

annex:

Enter Caption

label:

Enter Caption



Published 22 original articles · won praise 9 · views 30000 +

Guess you like

Origin blog.csdn.net/qq_19408473/article/details/70799484