[JBoss JIRA] (FORGE-1787) When scaffolding with --webRoot parameter, pageTemplate.xhtml is not right
by Antonio Goncalves (JIRA)
Antonio Goncalves created FORGE-1787:
----------------------------------------
Summary: When scaffolding with --webRoot parameter, pageTemplate.xhtml is not right
Key: FORGE-1787
URL: https://issues.jboss.org/browse/FORGE-1787
Project: Forge
Issue Type: Bug
Components: Scaffold
Affects Versions: 2.5.0.Final
Reporter: Antonio Goncalves
Priority: Blocker
When scaffolding a JSF application, without using a {{--webRoot}} parameter, the navigation in the {{pageTemplate.xhtml}} works as expected :
{code}
scaffold-setup ;
scaffold-generate --targets org.agoncal.training.javaee6adv.model.Author ;
scaffold-generate --targets org.agoncal.training.javaee6adv.model.CD ;
{code}
The template navigation looks like :
{code}
<ul>
<li>
<h:link outcome="/CD/search" value="CD"/>
</li>
<li>
<h:link outcome="/author/search" value="Author"/>
</li>
</ul>
{code}
But if I specify the {{--webRoot}} parameter, then the navigation does not work as there is a {{/}} missing :
{code}
scaffold-setup ;
scaffold-generate --webRoot admin --targets org.agoncal.training.javaee6adv.model.Author ;
scaffold-generate --webRoot admin --targets org.agoncal.training.javaee6adv.model.CD ;
{code}
The template :
{code}
<ul>
<li>
<h:link outcome="admin/CD/search" value="CD"/>
</li>
<li>
<h:link outcome="admin/author/search" value="Author"/>
</li>
</ul>
{code}
The correct navigation would be :
{code}
<ul>
<li>
<h:link outcome="/admin/CD/search" value="CD"/>
</li>
<li>
<h:link outcome="/admin/author/search" value="Author"/>
</li>
</ul>
{code}
The only way to make it work is to add a {{/}} to the {{webroot}}, which is not very intuitive :
{code}
scaffold-setup ;
scaffold-generate --webRoot /admin --targets org.agoncal.training.javaee6adv.model.Author ;
scaffold-generate --webRoot /admin --targets org.agoncal.training.javaee6adv.model.CD ;
{code}
--
This message was sent by Atlassian JIRA
(v6.2.3#6260)
10 years, 7 months
[JBoss JIRA] (FORGE-1630) The path is not right
by Antonio Goncalves (JIRA)
[ https://issues.jboss.org/browse/FORGE-1630?page=com.atlassian.jira.plugin... ]
Antonio Goncalves commented on FORGE-1630:
------------------------------------------
Another use case is when I execute a script on a sub-sub-directory. Let's say I execute a script under {{a/b/c}} directory :
{code}
[Forge]$ run a/b/c/proj.fsh
[Forge]$ project-new --named testrun --topLevelPackage com.testrun --type war --finalName testrun
***SUCCESS*** Project named 'testrun' has been created.
[testrun]$ ***SUCCESS*** Project named 'testrun' has been created.
[Forge]$ jpa-new-entity --named MyEntity
{code}
I would expect it to stay under {{testrun}}, the name of the project (see the prompt on the last line) :
{code}
[Forge]$ run a/b/c/proj.fsh
[Forge]$ project-new --named testrun --topLevelPackage com.testrun --type war --finalName testrun
***SUCCESS*** Project named 'testrun' has been created.
[testrun]$ ***SUCCESS*** Project named 'testrun' has been created.
[testrun]$ jpa-new-entity --named MyEntity
{code}
> The path is not right
> ---------------------
>
> Key: FORGE-1630
> URL: https://issues.jboss.org/browse/FORGE-1630
> Project: Forge
> Issue Type: Sub-task
> Components: UI - Shell
> Affects Versions: 2.1.1.Final
> Reporter: Antonio Goncalves
> Fix For: 2.x Future
>
>
> Let's say I have a simple script which just creates a project :
> {code}
> project-new --named testrun --topLevelPackage com.testrun --type war --finalName testrun
> {code}
> When I execute this script, it creates the project {{testrun}} but it goes back to the root path. So, when I create a new entity, it doesn't create it at the right place :
> {code}
> [Forge]$ run proj.fsh
> [Forge]$ project-new --named testrun --topLevelPackage com.testrun --type war --finalName testrun
> ***SUCCESS*** Project named 'testrun' has been created.
> [testrun]$ ***SUCCESS*** Project named 'testrun' has been created.
> [Forge]$ jpa-new-entity --named MyEntity
> ***SUCCESS*** Entity MyEntity created
> [MyEntity.java]$ pwd
> /Users/antoniombp/Documents/Code/temp/Forge/MyEntity.java
> [MyEntity.java]$ exit
> ~/Documents/Code/temp/Forge$ ll
> -rw-r--r-- 1 antoniombp staff 1.5K Mar 4 19:34 MyEntity.java
> -rw-r--r--@ 1 antoniombp staff 89B Mar 4 19:33 proj.fsh
> drwxr-xr-x 4 antoniombp staff 136B Mar 4 19:33 testrun/
> {code}
--
This message was sent by Atlassian JIRA
(v6.2.3#6260)
10 years, 7 months
[JBoss JIRA] (FORGE-1784) When having a scaffold-generate command in a script, it times out
by Antonio Goncalves (JIRA)
[ https://issues.jboss.org/browse/FORGE-1784?page=com.atlassian.jira.plugin... ]
Antonio Goncalves commented on FORGE-1784:
------------------------------------------
This time I got the following message in the logs when it timed out :
{code}
18:47:17,929 WARNING [org.metawidget.config.impl.BaseConfigReader] (AeshProcess: 86) class org.jboss.forge.addon.scaffold.faces.metawidget.inspector.ForgeInspector must be immutable, but appears to have a setter method (public void org.jboss.forge.addon.scaffold.faces.metawidget.inspector.ForgeInspector.setTypeUnderInspection(java.lang.String))
18:47:18,434 WARNING [org.metawidget.config.impl.BaseConfigReader] (AeshProcess: 87) class org.jboss.forge.addon.scaffold.faces.metawidget.inspector.ForgeInspector must be immutable, but appears to have a setter method (public void org.jboss.forge.addon.scaffold.faces.metawidget.inspector.ForgeInspector.setTypeUnderInspection(java.lang.String))
18:47:18,773 WARNING [org.metawidget.config.impl.BaseConfigReader] (AeshProcess: 88) class org.jboss.forge.addon.scaffold.faces.metawidget.inspector.ForgeInspector must be immutable, but appears to have a setter method (public void org.jboss.forge.addon.scaffold.faces.metawidget.inspector.ForgeInspector.setTypeUnderInspection(java.lang.String))
18:47:19,059 WARNING [org.metawidget.config.impl.BaseConfigReader] (AeshProcess: 89) class org.jboss.forge.addon.scaffold.faces.metawidget.inspector.ForgeInspector must be immutable, but appears to have a setter method (public void org.jboss.forge.addon.scaffold.faces.metawidget.inspector.ForgeInspector.setTypeUnderInspection(java.lang.String))
18:47:19,461 WARNING [org.metawidget.config.impl.BaseConfigReader] (AeshProcess: 90) class org.jboss.forge.addon.scaffold.faces.metawidget.inspector.ForgeInspector must be immutable, but appears to have a setter method (public void org.jboss.forge.addon.scaffold.faces.metawidget.inspector.ForgeInspector.setTypeUnderInspection(java.lang.String))
{code}
> When having a scaffold-generate command in a script, it times out
> -----------------------------------------------------------------
>
> Key: FORGE-1784
> URL: https://issues.jboss.org/browse/FORGE-1784
> Project: Forge
> Issue Type: Sub-task
> Components: UI - Shell
> Affects Versions: 2.5.0.Final
> Reporter: Antonio Goncalves
> Fix For: 2.x Future
>
>
> I have a long script with several commands and at the end, when I scaffold JSF pages, the script times out :
> {code}
> [CD.java]$ scaffold-setup ;
> ***SUCCESS*** CDI has been installed.
> ***SUCCESS*** EJB has been installed.
> ***SUCCESS*** Servlet API has been installed.
> ***SUCCESS*** JavaServer Faces has been installed.
> ***SUCCESS*** Scaffold was setup successfully.
> [CD.java]$ scaffold-generate --webRoot admin --targets org.agoncal.training.javaee6adv.* ;
> ***ERROR*** 02-Forge/generate.fsh: timed out.
> [agoncal-training-javaee6-advanced]$ ***SUCCESS*** Scaffold was generated successfully.
> {code}
> Nothing special in the logs. But because the {{scaffold-generate}} command takes time to execute, it displays a time out message. The worse is that it displays {{***ERROR***}} and then {{***SUCCESS***}}. At the end of the day, my JSF artifacts are created, but the script ends and it doesn't execute the commands that follow.
--
This message was sent by Atlassian JIRA
(v6.2.3#6260)
10 years, 7 months
[JBoss JIRA] (FORGE-1785) Explicitly setup in scaffolding, not in Bean Validation nor in JPA
by Antonio Goncalves (JIRA)
Antonio Goncalves created FORGE-1785:
----------------------------------------
Summary: Explicitly setup in scaffolding, not in Bean Validation nor in JPA
Key: FORGE-1785
URL: https://issues.jboss.org/browse/FORGE-1785
Project: Forge
Issue Type: Enhancement
Components: Scaffold
Affects Versions: 2.5.0.Final
Reporter: Antonio Goncalves
Fix For: 2.x Future
By now, most of the {{setup}} commands are optional (see [FORGE-1686] or [FORGE-1479]). Forge takes the setup by default if not specified. Same should happen with scaffolding. Today, to scaffold a JSF application, we need to execute :
{code}
scaffold-setup
scaffold-generate --targets org.test.model.* ;
{code}
It would be better if, following the same principals, the setup command would run as a default, and only this would be needed :
{code}
scaffold-generate --targets org.test.model.* ;
{code}
If we want to explicitelly scaffold an AngularJS app, then we would go :
{code}
scaffold-setup --provider AngularJS ;
scaffold-generate --targets org.test.model.* ;
{code}
--
This message was sent by Atlassian JIRA
(v6.2.3#6260)
10 years, 7 months
[JBoss JIRA] (FORGE-1784) When having a scaffold-generate command in a script, it times out
by Antonio Goncalves (JIRA)
[ https://issues.jboss.org/browse/FORGE-1784?page=com.atlassian.jira.plugin... ]
Antonio Goncalves commented on FORGE-1784:
------------------------------------------
Strange, I've executed the same script again, and this time I have a stack trace
{code}
[agoncal-training-javaee6-advanced]$ scaffold-generate --webRoot admin --targets org.agoncal.training.javaee6adv.* ;
Exception in thread "Aesh Process Loop 104588629" java.util.concurrent.RejectedExecutionException: Task AeshProcess{pid=86, manager=org.jboss.aesh.console.ProcessManager@150f7bf0, consoleCallback=org.jboss.aesh.console.AeshConsoleImpl$AeshConsoleCallbackImpl@2b91d45d, operation=ControlOperator: END, Buffer: scaffold-generate --webRoot admin --targets org.agoncal.training.javaee6adv.* } rejected from java.util.concurrent.ThreadPoolExecutor@730d3c03[Shutting down, pool size = 1, active threads = 1, queued tasks = 0, completed tasks = 85]
at java.util.concurrent.ThreadPoolExecutor$AbortPolicy.rejectedExecution(ThreadPoolExecutor.java:2048)
at java.util.concurrent.ThreadPoolExecutor.reject(ThreadPoolExecutor.java:821)
at java.util.concurrent.ThreadPoolExecutor.execute(ThreadPoolExecutor.java:1372)
at org.jboss.aesh.console.ProcessManager.startNewProcess(ProcessManager.java:44)
at org.jboss.aesh.console.Console.processOperationResult(Console.java:628)
at org.jboss.aesh.console.Console.processInternalOperation(Console.java:594)
at org.jboss.aesh.console.Console.execute(Console.java:582)
at org.jboss.aesh.console.Console.access$700(Console.java:60)
at org.jboss.aesh.console.Console$6.run(Console.java:499)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:744)
{code}
> When having a scaffold-generate command in a script, it times out
> -----------------------------------------------------------------
>
> Key: FORGE-1784
> URL: https://issues.jboss.org/browse/FORGE-1784
> Project: Forge
> Issue Type: Sub-task
> Components: UI - Shell
> Affects Versions: 2.5.0.Final
> Reporter: Antonio Goncalves
> Fix For: 2.x Future
>
>
> I have a long script with several commands and at the end, when I scaffold JSF pages, the script times out :
> {code}
> [CD.java]$ scaffold-setup ;
> ***SUCCESS*** CDI has been installed.
> ***SUCCESS*** EJB has been installed.
> ***SUCCESS*** Servlet API has been installed.
> ***SUCCESS*** JavaServer Faces has been installed.
> ***SUCCESS*** Scaffold was setup successfully.
> [CD.java]$ scaffold-generate --webRoot admin --targets org.agoncal.training.javaee6adv.* ;
> ***ERROR*** 02-Forge/generate.fsh: timed out.
> [agoncal-training-javaee6-advanced]$ ***SUCCESS*** Scaffold was generated successfully.
> {code}
> Nothing special in the logs. But because the {{scaffold-generate}} command takes time to execute, it displays a time out message. The worse is that it displays {{***ERROR***}} and then {{***SUCCESS***}}. At the end of the day, my JSF artifacts are created, but the script ends and it doesn't execute the commands that follow.
--
This message was sent by Atlassian JIRA
(v6.2.3#6260)
10 years, 7 months
[JBoss JIRA] (FORGE-1784) When having a scaffold-generate command in a script, it times out
by Antonio Goncalves (JIRA)
Antonio Goncalves created FORGE-1784:
----------------------------------------
Summary: When having a scaffold-generate command in a script, it times out
Key: FORGE-1784
URL: https://issues.jboss.org/browse/FORGE-1784
Project: Forge
Issue Type: Sub-task
Components: UI - Shell
Affects Versions: 2.5.0.Final
Reporter: Antonio Goncalves
I have a long script with several commands and at the end, when I scaffold JSF pages, the script times out :
{code}
[CD.java]$ scaffold-setup ;
***SUCCESS*** CDI has been installed.
***SUCCESS*** EJB has been installed.
***SUCCESS*** Servlet API has been installed.
***SUCCESS*** JavaServer Faces has been installed.
***SUCCESS*** Scaffold was setup successfully.
[CD.java]$ scaffold-generate --webRoot admin --targets org.agoncal.training.javaee6adv.* ;
***ERROR*** 02-Forge/generate.fsh: timed out.
[agoncal-training-javaee6-advanced]$ ***SUCCESS*** Scaffold was generated successfully.
{code}
Nothing special in the logs. But because the {{scaffold-generate}} command takes time to execute, it displays a time out message. The worse is that it displays {{***ERROR***}} and then {{***SUCCESS***}}. At the end of the day, my JSF artifacts are created, but the script ends and it doesn't execute the commands that follow.
--
This message was sent by Atlassian JIRA
(v6.2.3#6260)
10 years, 7 months