Build and Run Shopizer 2.0.5

Updated on May 9th, 2020

There are new features released under 2.2.0.We highly recommend using Shopizer 2.2.0 for your project.

With the latest 2.0.5 release, Shopizer team has done a number of changes including migrating to Spring Boot ( 2.0.5 is based on Spring Boot 1.3.5 ). Please read Shopizer 2.0.5 for more details. In this post, I will try to give you an overview to Build and Run Shopizer 2.0.5 on your local machine. Shopizer comes with a predefined demo DB which can be used out of the box to run demo application.

I am assuming that you have a basic understanding of following terms

  1. Java ( we will be using JDK 1.8)
  2. Spring
  3. Maven
  4. Build
  5. Elastic Search ( 2.4.1 )

I have following configurations for this post

JAVA

java version "1.8.0_101"
Java(TM) SE Runtime Environment (build 1.8.0_101-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.101-b13, mixed mode

Maven

Apache Maven 3.3.9 (bb52d8502b132ec0a5a3f4c09453c07478323dc5; 2015-11-10T08:41:47-08:00)
Java version: 1.8.0_101, vendor: Oracle Corporation
Default locale: en_US, platform encoding: UTF-8
OS name: "mac os x", version: "10.12.3", arch: "x86_64", family: "mac"

 

I will start by cloning Shopizer from GitHub ( You can use UI client ), for this post I am using Git command line tool

clone shopizer

 

Elastic Search

Shopizer uses Elastic Search for its front end search before we build Shopizer, we need to start Elastic Search server and make sure to update configuration with the correct port number and host information. Please update

configs.properties

file under

sm-core/resources

with the correct value for Elastic Search

Once the clone is completed, move to the root folder and run following command to build Shopizer

mvn:clean install

This will make sure that you have your build and packet created by Maven

build

 

Spring boot provides embedded support for Tomcat 8, which mean you don’t need standalone Tomcat to run your application.

Run the following command to start embedded Tomcat 8 for Shopizer 2.0.5

mvn spring-boot:run

application-started

When you run your application, Spring Boot will detect that you have a Spring MVC controller and start up an embedded Apache Tomcat 8 instance, by default.

You are all set to run your shop and admin panel. Go ahead and use following URL to open shop and back-end system for Shopizer

Back-end / Admin : localhost:8080/admin/logon.html

backend-login

use following details to log in to the backend

username : admin
password: password

backend

 

Web shop : http://localhost:8080/shop

shop-frontend

I hope this will help you to set up and run default OOTB Shopizer 2.0.5. Let me know in case you have any questions or comments.

In our next post, we will cover how to set up the development environment for Shopizer using IntelliJ IDEA’s.

0 0 vote
Article Rating

Java Development Journal

Hello!! Welcome to the Java Development Journal. We love to share our knowledge with our readers and love to build a thriving community.

follow me on:
Subscribe
Notify of

This site uses Akismet to reduce spam. Learn how your comment data is processed.

13 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
Mahesh Sachdeva
3 years ago

ERROR] Failed to execute goal org.springframework.boot:spring-boot-maven-plugin:1.3.5.RELEASE:run (default-cli) on project shopizer: Unable to find a suitable main class, please add a ‘mainClass’ property -> [Help 1] org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.springframework.boot:spring-boot-maven-plugin:1.3.5.RELEASE:run (default-cli) on project shopizer: Unable to find a suitable main class, please add a ‘mainClass’ property at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:212) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145) at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116) at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80) at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51) at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106) at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863) at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288) at org.apache.maven.cli.MavenCli.main(MavenCli.java:199) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289) at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229) at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415) at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356) Caused by: org.apache.maven.plugin.MojoExecutionException: Unable to find a suitable main class,… Read more »

Mahesh Sachdeva
3 years ago

Hi Umesh

I have figured out the issue . Problem was solved when I run the spring boot from sm-shop folder

Regards
Mahesh

Umesh Awasthi
3 years ago

I was about to point our the same thing :), Good you already figured it out

Jasmin
2 years ago
Reply to  Umesh Awasthi

I am still getting this issue even when running mvn spring-boot:run in sm-shop. I cant seem to find a solution.

Here are my applications

Apache Maven 3.5.2 (138edd61fd100ec658bfa2d307c43b76940a5d7d; 2017-10-18T20:58:13+13:00)
Maven home: C:\Program Files\apache-maven-3.5.2
Java version: 1.8.0_161, vendor: Oracle Corporation
Java home: C:\Program Files\Java\jdk1.8.0_161\jre
Default locale: en_NZ, platform encoding: Cp1252
OS name: “windows 10”, version: “10.0”, arch: “amd64”, family: “windows”

Is anyone able to help?

Admin
Java Development Journal
2 years ago
Reply to  Jasmin

This can only happen if you are not in the sm-shop module and running from the main folder.

Rambabu
2 years ago

Hi Umaesh,
do you have any full development test data to configure multiple shops, multiple languages include multiple currencies. please direct me if there is any admin console page that i can configure rather than setting up in database.

Admin
Java Development Journal
2 years ago
Reply to  Rambabu

No, sample store data contains information only for 1 store, This is a good suggestion and we can plan to add it in future releases.

Rambabu
2 years ago

Hi Umesh,
I managed to create a new store from admin panel. but can not able to invoke the url of the new store, it showing me a blank page and cant able to map products and pages. could you please assist me to configure multiple stores.
Regards

begin
1 year ago

Got ELFactory issue when tested with Tomcat 7/JDK 8

Admin
Java Development Journal
1 year ago
Reply to  begin

what version?

Prasanna
9 months ago

Have a question about the sample application. Followed instructions on Shopizer github, resolved build issues (had to add one dependency and exclude another!), gave it a go using sprint-boot:run. The application comes up however it is just a page with ‘default store’. The books listing shown in the setup video https://www.youtube.com/watch?v=SCiRreBUFNA is not seen. I was hoping to play around with the demo app listing but it isn’t there. Also any changes I make in the admin webapp aren’t reflecting in the shop app. To look into this changed application.properties to redirect console output to a log wherein didn’t see… Read more »

Admin
Java Development Journal
9 months ago
Reply to  Prasanna

Hello Prasanna,

I added that book data from the back office, if you are using the default setup with Shopizer, you will get the HSQL sample data as part of the setup and you will get some sample PDP pages.Are you changes getting reflected after you restart the server or they never visible on the frontend?

bala
5 months ago

Hi Umesh, I have downloaded 2.9 version and is able to setup application using H2 DB sample data. But when i try to configure the multiple store, it always redirect to default store. Please suggest me options to create multiple store

13
0
Would love your thoughts, please comment.x
()
x