[JAVA] Run JamWiki

Introduction

When I searched to run a wiki that runs on Java, I found a jamwiki that was last updated in 2013. For the time being, I deployed it to my own Mac, tomcat and tried to make it work. The source is open source.

JamWiki deploy

Step1

  1. Download Source (1.3.2) from the official
  2. Import project from IntelliJ (maven project)
  3. Error in IntelliJ dependency

Step2

  1. Change pom.xml directly under the project.

pom.xml


<dependency>
  <groupId>info.bliki.wiki</groupId>
  <artifactId>bliki-core</artifactId>
  <version>3.0.19</version>
</dependency>
  1. Create a war with maven for the time being. Life cycle / package from JAMWiki Super POM
  2. Pass all the tests and confirm that the war is done

Step3 Added jdbc driver for mysql for your own use. Then update various libraries and add lombok for extension. Do not update de.congrace.exp4j.

  1. Change pom.xml directly under the project.
  2. Change SQL

sql:sql.mysql.properties


create_date TIMESTAMP DEFAULT CURRENT_TIMESTAMP NOT NULL, \
  1. Create war with maven.

Step4

  1. Launch Mysql and create a database.

mysql


create database wiki;
  1. Start tomcat and deploy JamWiki.war.
  2. Set up JamWiki and finish the initialization work.

JamWiki specifications

Table structure

It seems that there are 25 tables.

mysql


show tables from wiki;

There are only 12 table create statements in sql.mysql.properties. .. ..

Java configuration

I am using Spring 3.x series.

Transition to top page

http://localhost:8080/jamwiki-1.3.2/
↓
http://localhost:8080/jamwiki-1.3.2/en/StartingPoints

Go to /jamwiki-war/src/main/webapp/index.jsp and Redirected by the following description in index.jsp

index.jsp


<c:redirect url="${defaultVirtualWiki}/${defaultTopic}" />

(default) The elements of the top page may be defined below. ?? ?? /jamwiki-core/src/main/resources/pages/ja/

Posting an article

Only upload articles (xml) with administrator privileges? ?? ?? (I can't find any new posts or new creations ^^;) When you post, records will be added to "jam_topic", "jam_topic_links", and "jam_topic_version".

Page structure

The contents to be output are separated by the following description in /jamwiki-war/src/main/webapp/WEB-INF/jsp/wiki.jsp.

wiki.jsp


<jsp:include page="${pageInfo.contentJsp}" flush="true" />

Control of mapping etc. is controlled by /jamwiki-clone/jamwiki-war/src/main/webapp/WEB-INF/jamwiki-servlet.xml.

Recommended Posts

Run JamWiki
[Cygwin] Run Redmine