[jboss-jira] [JBoss JIRA] (DROOLS-386) CommandFactoryServiceImpl cannot be cast to CommandFactoryService

Nicolas-Xavier Vanderlinden (JIRA) issues at jboss.org
Sun Dec 22 08:37:32 EST 2013


    [ https://issues.jboss.org/browse/DROOLS-386?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12933052#comment-12933052 ] 

Nicolas-Xavier Vanderlinden commented on DROOLS-386:
----------------------------------------------------

{code}
    private static void loadProvider() {
        try {
            Class<CommandFactoryService> cls = (Class<CommandFactoryService>) Class.forName( "org.drools.core.command.impl.CommandFactoryServiceImpl" );
            setCommandFactoryProvider( cls.newInstance() );
        } catch ( Exception e2 ) {
            throw new RuntimeException( "Provider org.drools.core.command.impl.CommandFactoryProviderImpl could not be set.",
                                                       e2 );
        }
    }

    private static synchronized void setCommandFactoryProvider(CommandFactoryService provider) {
        CommandFactory.provider = provider;
    }
{code}

{code}
public class CommandFactoryServiceImpl implements KieCommands {
{code}
                
> CommandFactoryServiceImpl cannot be cast to CommandFactoryService
> -----------------------------------------------------------------
>
>                 Key: DROOLS-386
>                 URL: https://issues.jboss.org/browse/DROOLS-386
>             Project: Drools
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>    Affects Versions: 6.0.0.Final
>         Environment: JBoss AS 7.1.1
>            Reporter: Nicolas-Xavier Vanderlinden
>            Assignee: Mark Proctor
>
> Caused by: java.lang.ClassCastException: org.drools.core.command.impl.CommandFactoryServiceImpl cannot be cast to org.drools.command.CommandFactoryService
> 	at org.drools.command.CommandFactory.loadProvider(CommandFactory.java:372) [knowledge-api-6.0.1.Final.jar:6.0.1.Final]
> CommandFactoryServiceImpl does not implement CommandFactoryService

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the jboss-jira mailing list