You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by ji...@codehaus.org on 2004/09/23 11:48:14 UTC

[jira] Created: (MPCHECKSTYLE-27) checkstyle use the root classloader to instantiate checker

Message:

  A new issue has been created in JIRA.

---------------------------------------------------------------------
View the issue:
  http://jira.codehaus.org/browse/MPCHECKSTYLE-27

Here is an overview of the issue:
---------------------------------------------------------------------
        Key: MPCHECKSTYLE-27
    Summary: checkstyle use the root classloader to instantiate checker
       Type: Bug

     Status: Unassigned
   Priority: Major

 Original Estimate: Unknown
 Time Spent: Unknown
  Remaining: Unknown

    Project: maven-checkstyle-plugin
   Versions:
             2.4.1

   Assignee: 
   Reporter: Zhang Yang

    Created: Thu, 23 Sep 2004 5:47 AM
    Updated: Thu, 23 Sep 2004 5:47 AM
Environment: Maven 1.0

Description:
when i make myself checker, i have to change the forehead.conf to add my jar file to the root class loader, otherwise, when i put the jar file in my project.xml dependency list, the plugin show me the error "Unable to create a Checker: cannot initialize module TreeWalker - Unable to instantiate net.zhyang.checkstyle.ConstantsCheck".

I think the reason is the checkstyle always try to find class in same classloader(root classloader). if you put your checkstyle.jar in the root classloader, i have to put myself custom checker in the root classloader.

And the
      <properties>
        <classloader>root</classloader>
      </properties>
is also deprecated,if you run under debug, you can see the warning message about it, it's the time to remove it from project.xml.

after i removed them, i can run myself checker.


---------------------------------------------------------------------
JIRA INFORMATION:
This message is automatically generated by JIRA.

If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa

If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


[jira] Updated: (MPCHECKSTYLE-27) checkstyle use the root classloader to instantiate checker

Posted by "Carlos Sanchez (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MPCHECKSTYLE-27?page=all ]

Carlos Sanchez updated MPCHECKSTYLE-27:
---------------------------------------

    Fix Version:     (was: 3.0)
        Version: 3.0
    Description: 
when i make myself checker, i have to change the forehead.conf to add my jar file to the root class loader, otherwise, when i put the jar file in my project.xml dependency list, the plugin show me the error "Unable to create a Checker: cannot initialize module TreeWalker - Unable to instantiate net.zhyang.checkstyle.ConstantsCheck".

I think the reason is the checkstyle always try to find class in same classloader(root classloader). if you put your checkstyle.jar in the root classloader, i have to put myself custom checker in the root classloader.

And the
      <properties>
        <classloader>root</classloader>
      </properties>
is also deprecated,if you run under debug, you can see the warning message about it, it's the time to remove it from project.xml.

after i removed them, i can run myself checker.

  was:
when i make myself checker, i have to change the forehead.conf to add my jar file to the root class loader, otherwise, when i put the jar file in my project.xml dependency list, the plugin show me the error "Unable to create a Checker: cannot initialize module TreeWalker - Unable to instantiate net.zhyang.checkstyle.ConstantsCheck".

I think the reason is the checkstyle always try to find class in same classloader(root classloader). if you put your checkstyle.jar in the root classloader, i have to put myself custom checker in the root classloader.

And the
      <properties>
        <classloader>root</classloader>
      </properties>
is also deprecated,if you run under debug, you can see the warning message about it, it's the time to remove it from project.xml.

after i removed them, i can run myself checker.

      Assign To:     (was: Carlos Sanchez)

See MPCHECKSTYLE-33 to find the reason this can't be fixed as of now

> checkstyle use the root classloader to instantiate checker
> ----------------------------------------------------------
>
>          Key: MPCHECKSTYLE-27
>          URL: http://jira.codehaus.org/browse/MPCHECKSTYLE-27
>      Project: maven-checkstyle-plugin
>         Type: Bug
>     Versions: 3.0, 2.4.1
>  Environment: Maven 1.0
>     Reporter: Zhang Yang

>
>
> when i make myself checker, i have to change the forehead.conf to add my jar file to the root class loader, otherwise, when i put the jar file in my project.xml dependency list, the plugin show me the error "Unable to create a Checker: cannot initialize module TreeWalker - Unable to instantiate net.zhyang.checkstyle.ConstantsCheck".
> I think the reason is the checkstyle always try to find class in same classloader(root classloader). if you put your checkstyle.jar in the root classloader, i have to put myself custom checker in the root classloader.
> And the
>       <properties>
>         <classloader>root</classloader>
>       </properties>
> is also deprecated,if you run under debug, you can see the warning message about it, it's the time to remove it from project.xml.
> after i removed them, i can run myself checker.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


[jira] Closed: (MPCHECKSTYLE-27) checkstyle use the root classloader to instantiate checker

Posted by "Carlos Sanchez (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MPCHECKSTYLE-27?page=all ]
     
Carlos Sanchez closed MPCHECKSTYLE-27:
--------------------------------------

    Fix Version: 3.0
     Resolution: Fixed
      Assign To: Carlos Sanchez

> checkstyle use the root classloader to instantiate checker
> ----------------------------------------------------------
>
>          Key: MPCHECKSTYLE-27
>          URL: http://jira.codehaus.org/browse/MPCHECKSTYLE-27
>      Project: maven-checkstyle-plugin
>         Type: Bug
>     Versions: 2.4.1
>  Environment: Maven 1.0
>     Reporter: Zhang Yang
>     Assignee: Carlos Sanchez
>      Fix For: 3.0

>
>
> when i make myself checker, i have to change the forehead.conf to add my jar file to the root class loader, otherwise, when i put the jar file in my project.xml dependency list, the plugin show me the error "Unable to create a Checker: cannot initialize module TreeWalker - Unable to instantiate net.zhyang.checkstyle.ConstantsCheck".
> I think the reason is the checkstyle always try to find class in same classloader(root classloader). if you put your checkstyle.jar in the root classloader, i have to put myself custom checker in the root classloader.
> And the
>       <properties>
>         <classloader>root</classloader>
>       </properties>
> is also deprecated,if you run under debug, you can see the warning message about it, it's the time to remove it from project.xml.
> after i removed them, i can run myself checker.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


[jira] Reopened: (MPCHECKSTYLE-27) checkstyle use the root classloader to instantiate checker

Posted by "Carlos Sanchez (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MPCHECKSTYLE-27?page=all ]
     
Carlos Sanchez reopened MPCHECKSTYLE-27:
----------------------------------------


There's a problem if not using root classloader

> checkstyle use the root classloader to instantiate checker
> ----------------------------------------------------------
>
>          Key: MPCHECKSTYLE-27
>          URL: http://jira.codehaus.org/browse/MPCHECKSTYLE-27
>      Project: maven-checkstyle-plugin
>         Type: Bug
>     Versions: 2.4.1
>  Environment: Maven 1.0
>     Reporter: Zhang Yang
>     Assignee: Carlos Sanchez
>      Fix For: 3.0

>
>
> when i make myself checker, i have to change the forehead.conf to add my jar file to the root class loader, otherwise, when i put the jar file in my project.xml dependency list, the plugin show me the error "Unable to create a Checker: cannot initialize module TreeWalker - Unable to instantiate net.zhyang.checkstyle.ConstantsCheck".
> I think the reason is the checkstyle always try to find class in same classloader(root classloader). if you put your checkstyle.jar in the root classloader, i have to put myself custom checker in the root classloader.
> And the
>       <properties>
>         <classloader>root</classloader>
>       </properties>
> is also deprecated,if you run under debug, you can see the warning message about it, it's the time to remove it from project.xml.
> after i removed them, i can run myself checker.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org