[JBoss JIRA] (FORGE-1802) Console hangs when running an invalid script
by Ivan St. Ivanov (JIRA)
[ https://issues.jboss.org/browse/FORGE-1802?page=com.atlassian.jira.plugin... ]
Ivan St. Ivanov reassigned FORGE-1802:
--------------------------------------
Assignee: Ivan St. Ivanov
> Console hangs when running an invalid script
> --------------------------------------------
>
> Key: FORGE-1802
> URL: https://issues.jboss.org/browse/FORGE-1802
> Project: Forge
> Issue Type: Sub-task
> Components: UI - Shell
> Affects Versions: 2.5.0.Final
> Reporter: Antonio Goncalves
> Assignee: Ivan St. Ivanov
> Priority: Critical
> Fix For: 2.x Future
>
>
> I am executing a script (with the {{run}} command) and the console hanged and stopped working completely (I had to kill the process). I realized that there is an error in the script (missing {{;}} at the end of line {{--named ISBN}}).
> Take the following script, and save it on a {{hangs.fsh}} file
> {code}
> # ##################### #
> # Creates a new project #
> # ##################### #
> project-new --named cdbookstore --topLevelPackage org.agoncal.training.javaee6adv --type war --finalName cdbookstore ;
> # Setup the persistence unit in persistence.xml
> # ############
> jpa-setup --persistenceUnitName cdbookstorePU ;
> # ######################## #
> # Creates the domain model #
> # ######################## #
> # ISBN constraint
> # ############
> constraint-new-annotation --named ISBN
> # Genre entity
> # ############
> jpa-new-entity --named Genre ;
> jpa-new-field --named name --length 100 ;
> {code}
> Now, execute the script, and see the error message :
> {code}
> [temp]$ run hangs.fsh
> project-new --named cdbookstore --topLevelPackage org.agoncal.training.javaee6adv --type war --finalName cdbookstore ;
> ***SUCCESS*** Project named 'cdbookstore' has been created.
> [cdbookstore]$ jpa-setup --persistenceUnitName cdbookstorePU ;
> ***SUCCESS*** Persistence (JPA) is installed.
> [cdbookstore]$ constraint-new-annotation --named ISBN
> ***SUCCESS*** Bean Validation Constraint Annotations org.agoncal.training.javaee6adv.constraints.ISBN was created
> [ISBN.java]$ jpa-new-entity --named Genre ;
> Exception when parsing/running: jpa-new-entity --named Genre , org.jboss.forge.roaster.model.impl.JavaAnnotationImpl cannot be cast to org.jboss.forge.roaster.model.MemberHolder
> [ISBN.java]$
> {code}
> At this point, I can't interact with the console and need to kill the process.
--
This message was sent by Atlassian JIRA
(v6.2.3#6260)
10 years, 6 months
[JBoss JIRA] (FORGE-1876) Addon services should be exposed through @Produces methods
by George Gastaldi (JIRA)
[ https://issues.jboss.org/browse/FORGE-1876?page=com.atlassian.jira.plugin... ]
George Gastaldi updated FORGE-1876:
-----------------------------------
Status: Closed (was: Pull Request Sent)
Resolution: Done
> Addon services should be exposed through @Produces methods
> -----------------------------------------------------------
>
> Key: FORGE-1876
> URL: https://issues.jboss.org/browse/FORGE-1876
> Project: Forge
> Issue Type: Enhancement
> Components: Furnace CDI
> Affects Versions: 2.6.0.Final
> Reporter: George Gastaldi
> Assignee: George Gastaldi
> Fix For: 2.6.1.Final
>
>
> Having an addon that depends on the furnace-cdi container and declares the following class:
> {code}
> import javax.enterprise.inject.Produces;
> import javax.ws.rs.client.Client;
> import javax.ws.rs.client.ClientBuilder;
> public class RestClientProducer
> {
> @Produces
> public ClientBuilder createClientBuilder()
> {
> ClientBuilder builder = ClientBuilder.newBuilder();
> return builder;
> }
> @Produces
> public Client createClient(ClientBuilder builder)
> {
> return builder.build();
> }
> }
> {code}
> Then:
> - {{WeldServiceRegistry.hasService(javax.ws.rs.client.Client.class)}} should return true
> - {{AddonRegistry.getServices(javax.ws.rs.client.Client.class).get()}} should call the producer method and return the requested service
--
This message was sent by Atlassian JIRA
(v6.2.3#6260)
10 years, 6 months
[JBoss JIRA] (FORGE-1876) Addon services should be exposed through @Produces methods
by George Gastaldi (JIRA)
[ https://issues.jboss.org/browse/FORGE-1876?page=com.atlassian.jira.plugin... ]
George Gastaldi commented on FORGE-1876:
----------------------------------------
Also worth mentioning that the JAR where the {{javax.ws.rs.client.Client.class}} belongs is not managed by CDI, hence it's not listed as serviceType in WeldServiceRegistry
> Addon services should be exposed through @Produces methods
> -----------------------------------------------------------
>
> Key: FORGE-1876
> URL: https://issues.jboss.org/browse/FORGE-1876
> Project: Forge
> Issue Type: Enhancement
> Components: Furnace CDI
> Affects Versions: 2.6.0.Final
> Reporter: George Gastaldi
> Assignee: George Gastaldi
> Fix For: 2.6.1.Final
>
>
> Having an addon that depends on the furnace-cdi container and declares the following class:
> {code}
> import javax.enterprise.inject.Produces;
> import javax.ws.rs.client.Client;
> import javax.ws.rs.client.ClientBuilder;
> public class RestClientProducer
> {
> @Produces
> public ClientBuilder createClientBuilder()
> {
> ClientBuilder builder = ClientBuilder.newBuilder();
> return builder;
> }
> @Produces
> public Client createClient(ClientBuilder builder)
> {
> return builder.build();
> }
> }
> {code}
> Then:
> - {{WeldServiceRegistry.hasService(javax.ws.rs.client.Client.class)}} should return true
> - {{AddonRegistry.getServices(javax.ws.rs.client.Client.class).get()}} should call the producer method and return the requested service
--
This message was sent by Atlassian JIRA
(v6.2.3#6260)
10 years, 6 months
[JBoss JIRA] (FORGE-1876) Addon services should be exposed through @Produces methods
by George Gastaldi (JIRA)
[ https://issues.jboss.org/browse/FORGE-1876?page=com.atlassian.jira.plugin... ]
George Gastaldi reopened FORGE-1876:
------------------------------------
> Addon services should be exposed through @Produces methods
> -----------------------------------------------------------
>
> Key: FORGE-1876
> URL: https://issues.jboss.org/browse/FORGE-1876
> Project: Forge
> Issue Type: Enhancement
> Components: Furnace CDI
> Affects Versions: 2.6.0.Final
> Reporter: George Gastaldi
> Assignee: George Gastaldi
> Fix For: 2.6.1.Final
>
>
> Having an addon that depends on the furnace-cdi container and declares the following class:
> {code}
> import javax.enterprise.inject.Produces;
> import javax.ws.rs.client.Client;
> import javax.ws.rs.client.ClientBuilder;
> public class RestClientProducer
> {
> @Produces
> public ClientBuilder createClientBuilder()
> {
> ClientBuilder builder = ClientBuilder.newBuilder();
> return builder;
> }
> @Produces
> public Client createClient(ClientBuilder builder)
> {
> return builder.build();
> }
> }
> {code}
> Then:
> - {{WeldServiceRegistry.hasService(javax.ws.rs.client.Client.class)}} should return true
> - {{AddonRegistry.getServices(javax.ws.rs.client.Client.class).get()}} should call the producer method and return the requested service
--
This message was sent by Atlassian JIRA
(v6.2.3#6260)
10 years, 6 months
[JBoss JIRA] (FORGE-1876) Addon services should be exposed through @Produces methods
by George Gastaldi (JIRA)
[ https://issues.jboss.org/browse/FORGE-1876?page=com.atlassian.jira.plugin... ]
George Gastaldi updated FORGE-1876:
-----------------------------------
Status: Pull Request Sent (was: Reopened)
Git Pull Request: https://github.com/forge/furnace-cdi/pull/1
> Addon services should be exposed through @Produces methods
> -----------------------------------------------------------
>
> Key: FORGE-1876
> URL: https://issues.jboss.org/browse/FORGE-1876
> Project: Forge
> Issue Type: Enhancement
> Components: Furnace CDI
> Affects Versions: 2.6.0.Final
> Reporter: George Gastaldi
> Assignee: George Gastaldi
> Fix For: 2.6.1.Final
>
>
> Having an addon that depends on the furnace-cdi container and declares the following class:
> {code}
> import javax.enterprise.inject.Produces;
> import javax.ws.rs.client.Client;
> import javax.ws.rs.client.ClientBuilder;
> public class RestClientProducer
> {
> @Produces
> public ClientBuilder createClientBuilder()
> {
> ClientBuilder builder = ClientBuilder.newBuilder();
> return builder;
> }
> @Produces
> public Client createClient(ClientBuilder builder)
> {
> return builder.build();
> }
> }
> {code}
> Then:
> - {{WeldServiceRegistry.hasService(javax.ws.rs.client.Client.class)}} should return true
> - {{AddonRegistry.getServices(javax.ws.rs.client.Client.class).get()}} should call the producer method and return the requested service
--
This message was sent by Atlassian JIRA
(v6.2.3#6260)
10 years, 6 months