Skip to content

ksurendra/jaqblog

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

JAQ Blog

A producttion ready blog portal built with HTML, Angular and Java.

jaqblog-home

Demo

Build and Deployment

System requirements

PreRequisites

  • An account with CosmicJS
  • All the content will be stored and managed in Cosmic JS CMS

Test environment settings

  • Java 1.8.0_162
  • Angular CLI 1.6.8
  • NodeJS 10.5.0
  • NPM 6.1.0
  • Yarn 1.7.0
  • Apache Maven 3.3.9
  • Apache Tomcat 8.5.27

ComicJS Setup

JAQ blog uses CosmisJS as the backend to hold the content (Users and Blog). The following are required

  • Create a free account with CosmicJS
  • Add New Bucket and name it (say) 'myblog'
  • Select Apps from the left nav, and install Angular Blog
  • Select Basic Settings and note the below 3 properites.
    • Bucket id
    • API Read Access Key
    • API Write Access Key
      jaqblog-cosmisjs-settings
  • Enter the above 3 values in the file /ui.resources/src/config/cosmo.config.ts

How to Build

JAQ Blog is built as primary Java application with Angular embedded within it. Maven is used to build the project.

  • Fork and Clone the project to your local machine
  • Open the file
  • From the folder, use the command mvn clean package to build JAQBlog's WAR file.

How to Deploy/Run

Using Tomcat as an example:

  • Open tomcat's admin console like http://sampleserver.com:8080/manager/html
  • Choose Select WAR file to upload , uplaod the jaqblog.war
  • If the deployment is successful, you can see /jaqblog in the deployed applications.
  • Open a new browser and use this url http://samplesever.com:8080/jaqblog . You should see Java Hello World!
  • To run the blog, use the url http://samplesever.com:8080/jaqblog/initializr . You should see the blog home page loaded

Features of the application

  • View blog posts
  • Register to the blog
  • Login
  • Add a new blog

Architecture

JAQ Blog Application Stack

jaqblog-stack

JAQ Blog with CosmicJS Process Flow

jaqblogcosmis-processflow

JAQ Stack Flow (JAQ Blog is built using JAQ Stack)

jaqstack-process-flow

Extend

JAQ blog has been built as Java first web application with all of front-end managed using Angular.

This can be extendable to use Java to make REST calls to any CMS (or any service) and have Angular consume the return data and act accordingly.

  • Java
    • Sample Java servlets are defined at /Users/konathal/Personal/SurenProjects/suren-blog/git/jaqblog/src/main/java/com/jaqstack/servlet
  • MongoDB
    • Sample Java class to connect to MongoDB /Users/konathal/Personal/SurenProjects/suren-blog/git/jaqblog/src/main/java/com/jaqstack/data/MongoExample.java

For more examples on the above, you may see JAQ Stack's examples on Github

Credits

  • The core of the blog was forked from Angular Blog
  • Designed, developed and architected by Suren Konathala Contact/Tweet @surenkonathala

About

Blog portal built with HTML, Angular and Java

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published