You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@turbine.apache.org by 조영호 <yo...@easydesk.co.kr> on 2021/10/27 11:45:21 UTC
a test webapp build using turbine-archetype problem
I installed turbine-5.1-SNAPSHOT successfully.
Thanks Georg!
By the way, I tried to build a webapp using turbine-archetype.
But I got the following error message.
[INFO]
----------------------------------------------------------------------------
[INFO] Using following parameters for creating project from Archetype:
turbine-webapp-5.1:2.0.0-SNAPSHOT
[INFO]
----------------------------------------------------------------------------
[INFO] Parameter: groupId, Value: com.easydesk.quark
[INFO] Parameter: artifactId, Value: helloQuark
[INFO] Parameter: version, Value: 1.0
[INFO] Parameter: package, Value: com.easydesk.quark
[INFO] Parameter: packageInPathFormat, Value: com/easydesk/quark
[INFO] Parameter: turbine_database_jndipath, Value: jdbc/turbine
[INFO] Parameter: turbine_database_driver, Value: com.mysql.cj.jdbc.Driver
[INFO] Parameter: app_volume_local_repo, Value: ${settings.localRepository}
[INFO] Parameter: turbine_database_timezone, Value: UTC
[INFO] Parameter: docker, Value: false
[INFO] Parameter: groupId, Value: com.easydesk.quark
[INFO] Parameter: turbine_database_url, Value: jdbc:mysql://localhost:3306/
[INFO] Parameter: turbine_app_name, Value: HelloWorld
[INFO] Parameter: turbine_database_name, Value: helloWorld
[INFO] Parameter: turbine_database_password, Value:
[INFO] Parameter: version, Value: 1.0
[INFO] Parameter: turbine_intake_file, Value: intake.xml
[INFO] Parameter: turbine_database_adapter, Value: mysql
[INFO] Parameter: package, Value: com.easydesk.quark
[INFO] Parameter: turbine_database_user, Value: youngho
[INFO] Parameter: artifactId, Value: helloQuark
[INFO]
------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 29.678 s
[INFO] Finished at: 2021-10-27T20:19:03+09:00
[INFO] Final Memory: 24M/177M
[INFO]
------------------------------------------------------------------------
[ERROR] Failed to execute goal
org.apache.maven.plugins:maven-archetype-plugin:3.2.0:generate
(default-cli) on project turbine-webapp-5.1: Unable to add module to the
current project as it is not of packaging type 'pom' -> [Help 1]
I don't know the problem here.
How can I go one step further ?
Thanks,
Youngho
Re: a test webapp build using turbine-archetype problem
Posted by Jeffery Painter <je...@jivecast.com>.
Hello Youngho,
I think I have pushed the necessary changes to get you going now. I
think as developers, we tend to have local snapshots on our machines and
don't always test in a clean environment when building from scratch. We
are also migrating from SVN to github and that has its own growing pains
for us old timers.
I have gone through the following steps and I was able to build a fresh
app using the latest from the repos:
Clean setup (removed my /home/userdir/.m2 cached repo) for getting
current snapshot of Turbine to build
Step 1: Build and install latest turbine-5.1-SNAPSHOT
git clone https://gitbox.apache.org/repos/asf/turbine-core.git
cd turbine-core
mvn clean install
Step 2: Get latest torque 5 (which includes the torque-maven-plugin for
5.0 required later in the archetype code)
svn checkout https://svn.apache.org/repos/asf/db/torque/trunk/ torque
cd torque
mvn clean install
Step 3: Build all fulcrum components (just updated parent POMs to
turbine-parent 9 release)
git clone --recurse-submodules
https://github.com/apache/turbine-fulcrum-build.git
cd turbine-fulcrum-build
mvn clean install
Step 4: Build latest version of the archetype:
git clone https://github.com/apache/turbine-archetypes.git
cd turbine-archetypes
mvn clean install
Once you have the archetype installed, I use a shell script I wrote to
help automate building a new app. Feel free to do the same. There are
two new variables Georg added for docker, you can just hit "enter" and
accept the defaults if not using docker and that worked for me.
###################################
# Begin build_app.sh shell script
export ORG=org.mycompany
export APP_NAME=helloworld
export DB_NAME=helloworld
export DB_USER=db_username
export DB_PASS=db_password
## Create the database (comment out if you don't want to drop your
database!)
mysql -u ${DB_USER} -p${DB_PASS} -e "drop database ${DB_NAME}"
mysql -u ${DB_USER} -p${DB_PASS} -e "create database ${DB_NAME}"
## Generate the app
mvn archetype:generate \
-DarchetypeGroupId=org.apache.turbine \
-DarchetypeArtifactId=turbine-webapp-5.1 \
-DarchetypeVersion=2.0.0-SNAPSHOT \
-DgroupId=${ORG}.${APP_NAME} \
-DartifactId=${APP_NAME} \
-Dversion=1.0 \
-Dturbine_app_name=${APP_NAME} \
-Dturbine_database_adapter=mysql \
-Dturbine_database_user=${DB_USER} \
-Dturbine_database_password=${DB_PASS} \
-Dturbine_database_name=${DB_NAME} \
-Dturbine_database_timezone=US/Eastern \
-Dturbine_database_url=jdbc:mysql://localhost:3306/ \
-Dgoals=generate-sources,pre-integration-test
###################################
Let me know if that helps!
-
Jeffery Painter
On 10/27/21 7:45 AM, 조영호 wrote:
> I installed turbine-5.1-SNAPSHOT successfully.
> Thanks Georg!
>
> By the way, I tried to build a webapp using turbine-archetype.
>
> But I got the following error message.
>
> [INFO]
> ----------------------------------------------------------------------------
>
> [INFO] Using following parameters for creating project from Archetype:
> turbine-webapp-5.1:2.0.0-SNAPSHOT
>
> [INFO]
> ----------------------------------------------------------------------------
>
> [INFO] Parameter: groupId, Value: com.easydesk.quark
>
> [INFO] Parameter: artifactId, Value: helloQuark
>
> [INFO] Parameter: version, Value: 1.0
>
> [INFO] Parameter: package, Value: com.easydesk.quark
>
> [INFO] Parameter: packageInPathFormat, Value: com/easydesk/quark
>
> [INFO] Parameter: turbine_database_jndipath, Value: jdbc/turbine
>
> [INFO] Parameter: turbine_database_driver, Value: com.mysql.cj.jdbc.Driver
>
> [INFO] Parameter: app_volume_local_repo, Value: ${settings.localRepository}
>
> [INFO] Parameter: turbine_database_timezone, Value: UTC
>
> [INFO] Parameter: docker, Value: false
>
> [INFO] Parameter: groupId, Value: com.easydesk.quark
>
> [INFO] Parameter: turbine_database_url, Value: jdbc:mysql://localhost:3306/
>
> [INFO] Parameter: turbine_app_name, Value: HelloWorld
>
> [INFO] Parameter: turbine_database_name, Value: helloWorld
>
> [INFO] Parameter: turbine_database_password, Value:
>
> [INFO] Parameter: version, Value: 1.0
>
> [INFO] Parameter: turbine_intake_file, Value: intake.xml
>
> [INFO] Parameter: turbine_database_adapter, Value: mysql
>
> [INFO] Parameter: package, Value: com.easydesk.quark
>
> [INFO] Parameter: turbine_database_user, Value: youngho
>
> [INFO] Parameter: artifactId, Value: helloQuark
>
> [INFO]
> ------------------------------------------------------------------------
>
> [INFO] BUILD FAILURE
>
> [INFO]
> ------------------------------------------------------------------------
>
> [INFO] Total time: 29.678 s
>
> [INFO] Finished at: 2021-10-27T20:19:03+09:00
>
> [INFO] Final Memory: 24M/177M
>
> [INFO]
> ------------------------------------------------------------------------
>
> [ERROR] Failed to execute goal
> org.apache.maven.plugins:maven-archetype-plugin:3.2.0:generate
> (default-cli) on project turbine-webapp-5.1: Unable to add module to the
> current project as it is not of packaging type 'pom' -> [Help 1]
>
>
> I don't know the problem here.
>
> How can I go one step further ?
>
>
>
> Thanks,
>
>
> Youngho
>
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@turbine.apache.org
For additional commands, e-mail: user-help@turbine.apache.org
Re: a test webapp build using turbine-archetype problem
Posted by Georg Kallidis <ge...@cedis.fu-berlin.de>.
Hi Youngho,
to get an instance of an archetype you should change into an empty folder,
because it seems, that an already existing pom.xml is rejected by the
plugin, if not type pom ..
Then run (as you probably did, but now from this clean folder or at least
a folder with no pom.xml in the root)
mvn archetype:generate -DarchetypeCatalog=local
and select
local -> org.apache.turbine:turbine-webapp-5.1 (This archetype sets up a
web application project based on Apache Turbine 5.x and Torque 5.x)
This installs the archetype instance into a folder named <artifactId>,
that is in your case helloQuark.
If you want to play around with an already generated archetype instance
you may check after mvn install (in the turbine-archetypes repo)
target/test-classes/projects/project/first/integrationtest.
But be aware, that this will get deleted again (running mvn clean in the
repo workspace root)!
Have fun!
Best regards, Georg
BTW dev@turbine: We have to update the docs in
https://github.com/apache/turbine-archetypes/tree/master/src/main/resources/archetype-resources/docs
and of course should release this archetype after the next turbine core
release...
Von: 조영호 <yo...@easydesk.co.kr>
An: user@turbine.apache.org
Datum: 27.10.2021 14:21
Betreff: a test webapp build using turbine-archetype problem
I installed turbine-5.1-SNAPSHOT successfully.
Thanks Georg!
By the way, I tried to build a webapp using turbine-archetype.
But I got the following error message.
[INFO]
----------------------------------------------------------------------------
[INFO] Using following parameters for creating project from Archetype:
turbine-webapp-5.1:2.0.0-SNAPSHOT
[INFO]
----------------------------------------------------------------------------
[INFO] Parameter: groupId, Value: com.easydesk.quark
[INFO] Parameter: artifactId, Value: helloQuark
[INFO] Parameter: version, Value: 1.0
[INFO] Parameter: package, Value: com.easydesk.quark
[INFO] Parameter: packageInPathFormat, Value: com/easydesk/quark
[INFO] Parameter: turbine_database_jndipath, Value: jdbc/turbine
[INFO] Parameter: turbine_database_driver, Value: com.mysql.cj.jdbc.Driver
[INFO] Parameter: app_volume_local_repo, Value:
${settings.localRepository}
[INFO] Parameter: turbine_database_timezone, Value: UTC
[INFO] Parameter: docker, Value: false
[INFO] Parameter: groupId, Value: com.easydesk.quark
[INFO] Parameter: turbine_database_url, Value:
jdbc:mysql://localhost:3306/
[INFO] Parameter: turbine_app_name, Value: HelloWorld
[INFO] Parameter: turbine_database_name, Value: helloWorld
[INFO] Parameter: turbine_database_password, Value:
[INFO] Parameter: version, Value: 1.0
[INFO] Parameter: turbine_intake_file, Value: intake.xml
[INFO] Parameter: turbine_database_adapter, Value: mysql
[INFO] Parameter: package, Value: com.easydesk.quark
[INFO] Parameter: turbine_database_user, Value: youngho
[INFO] Parameter: artifactId, Value: helloQuark
[INFO]
------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 29.678 s
[INFO] Finished at: 2021-10-27T20:19:03+09:00
[INFO] Final Memory: 24M/177M
[INFO]
------------------------------------------------------------------------
[ERROR] Failed to execute goal
org.apache.maven.plugins:maven-archetype-plugin:3.2.0:generate
(default-cli) on project turbine-webapp-5.1: Unable to add module to the
current project as it is not of packaging type 'pom' -> [Help 1]
I don't know the problem here.
How can I go one step further ?
Thanks,
Youngho