java/buildconf/checkstyle.xml | 42 ++++------
java/code/src/com/redhat/rhn/domain/server/VirtualInstanceFactory.java | 2
java/code/src/com/redhat/rhn/frontend/action/SetLabels.java | 2
java/code/src/com/redhat/rhn/frontend/xmlrpc/XmlRpcServlet.java | 4
java/code/src/com/redhat/rhn/taskomatic/task/TaskConstants.java | 2
java/code/src/com/redhat/rhn/testing/TestStatics.java | 2
java/spacewalk-java.spec | 5 -
7 files changed, 31 insertions(+), 28 deletions(-)
New commits:
commit 0bed52d0b835a9453da34a979e68855b3325577d
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Wed May 30 16:17:32 2012 +0200
switch checkstyle to be run on RHEL6
diff --git a/java/spacewalk-java.spec b/java/spacewalk-java.spec
index 4912003..fb1fe07 100644
--- a/java/spacewalk-java.spec
+++ b/java/spacewalk-java.spec
@@ -13,8 +13,9 @@
%define jardir %{_localstatedir}/lib/tomcat6/webapps/rhn/WEB-INF/lib
%endif
-%if 0%{?rhel} && 0%{?rhel} < 6
-# checkstyle is broken on Fedora 14 - we skip for now
+%if 0%{?rhel} && 0%{?rhel} >= 6
+# checkstyle is broken on Fedoras - we skip for now
+# RHEL5 checkstyle4 is incompatible with checkstyle5
%define run_checkstyle 1
%endif
commit c213bff185085c2c58201aec662fdb53989e3f71
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Wed May 30 16:39:06 2012 +0200
checkstyle: VirtualInstanceFactory - Redundant 'static' modifier.
diff --git a/java/code/src/com/redhat/rhn/domain/server/VirtualInstanceFactory.java
b/java/code/src/com/redhat/rhn/domain/server/VirtualInstanceFactory.java
index de00456..e09faae 100644
--- a/java/code/src/com/redhat/rhn/domain/server/VirtualInstanceFactory.java
+++ b/java/code/src/com/redhat/rhn/domain/server/VirtualInstanceFactory.java
@@ -53,7 +53,7 @@ public class VirtualInstanceFactory extends HibernateFactory {
private static Logger log = Logger
.getLogger(VirtualInstanceFactory.class);
- private static interface HibernateCallback {
+ private interface HibernateCallback {
Object executeInSession(Session session);
}
commit c0b99dc2f9aa2ca53697ee3cf2cb797ee92d0089
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Wed May 30 09:44:36 2012 -0400
checkstyle: TestStatics - Utility classes should not have a public or default
constructor.
diff --git a/java/code/src/com/redhat/rhn/testing/TestStatics.java
b/java/code/src/com/redhat/rhn/testing/TestStatics.java
index 2354776..aebbe78 100644
--- a/java/code/src/com/redhat/rhn/testing/TestStatics.java
+++ b/java/code/src/com/redhat/rhn/testing/TestStatics.java
@@ -24,4 +24,6 @@ public class TestStatics {
*/
public static final String TESTORG = "testOrg";
public static final String TESTUSER = "testUser";
+
+ private TestStatics() { }
}
commit 4e46909066c9c3d838ea3990b1facf1823a87f94
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Wed May 30 09:44:06 2012 -0400
checkstyle: TaskConstants - Utility classes should not have a public or default
constructor.
diff --git a/java/code/src/com/redhat/rhn/taskomatic/task/TaskConstants.java
b/java/code/src/com/redhat/rhn/taskomatic/task/TaskConstants.java
index c1c75c3..ba47c52 100644
--- a/java/code/src/com/redhat/rhn/taskomatic/task/TaskConstants.java
+++ b/java/code/src/com/redhat/rhn/taskomatic/task/TaskConstants.java
@@ -161,4 +161,6 @@ public class TaskConstants {
"repomdgenerator_package_changelog";
public static final String MODE_NAME = "Task_queries";
+
+ private TaskConstants() { }
}
commit d61ea11e575cba5c8604e579ce48f93b9f2b57c4
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Wed May 30 09:42:36 2012 -0400
checkstyle: the name [todo] is not a valid Javadoc tag name
diff --git a/java/code/src/com/redhat/rhn/frontend/xmlrpc/XmlRpcServlet.java
b/java/code/src/com/redhat/rhn/frontend/xmlrpc/XmlRpcServlet.java
index 2c61e19..815763b 100644
--- a/java/code/src/com/redhat/rhn/frontend/xmlrpc/XmlRpcServlet.java
+++ b/java/code/src/com/redhat/rhn/frontend/xmlrpc/XmlRpcServlet.java
@@ -33,8 +33,8 @@ import redstone.xmlrpc.XmlRpcCustomSerializer;
* A basic servlet class that registers handlers for xmlrpc calls
*
* @version $Rev$
- * @todo pull in namespace + classes for handlers from, say, a properties file
- * @todo perhaps override doGet ??
+ * todo pull in namespace + classes for handlers from, say, a properties file
+ * todo perhaps override doGet ??
*/
public class XmlRpcServlet extends HttpServlet {
commit 71b3d0be7efc17fbde9f704fd72e64d8af451e0d
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Wed May 30 09:41:08 2012 -0400
checkstyle: SetLabels - Utility classes should not have a public or default
constructor.
diff --git a/java/code/src/com/redhat/rhn/frontend/action/SetLabels.java
b/java/code/src/com/redhat/rhn/frontend/action/SetLabels.java
index 26e7855..b25192d 100644
--- a/java/code/src/com/redhat/rhn/frontend/action/SetLabels.java
+++ b/java/code/src/com/redhat/rhn/frontend/action/SetLabels.java
@@ -26,4 +26,6 @@ public final class SetLabels {
public static final String PATCH_INSTALL_SET = "install_patch_list";
public static final String PATCH_REMOVE_SET = "removable_patch_list";
public static final String PACKAGE_UPGRADE_SET = "upgrade_package_list";
+
+ private SetLabels() { }
}
commit 061abe4ad194f7b1da0fd4a16420f020b5e05ec5
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Wed May 30 16:07:17 2012 +0200
checkstyle 5: cannot initialize module TreeWalker - Unable to instantiate
GenericIllegalRegexp
diff --git a/java/buildconf/checkstyle.xml b/java/buildconf/checkstyle.xml
index 5208a6a..b8cb442 100644
--- a/java/buildconf/checkstyle.xml
+++ b/java/buildconf/checkstyle.xml
@@ -145,13 +145,6 @@ MINUS_ASSIGN, MOD, MOD_ASSIGN, NOT_EQUAL, PLUS, PLUS_ASSIGN,
QUESTION, RCURLY, S
<module name="MethodParamPad">
<property name="allowLineBreaks" value="true"/>
</module>
- <module name="GenericIllegalRegexp">
- <!-- \s matches whitespace character, $ matches end of line. -->
- <property name="format" value="\s+$"/>
- <property name="message" value="Line has trailing
spaces."/>
- </module>
-
-
<!-- Modifier Checks -->
<!-- See
http://checkstyle.sf.net/config_modifiers.html -->
@@ -232,4 +225,10 @@ MINUS_ASSIGN, MOD, MOD_ASSIGN, NOT_EQUAL, PLUS, PLUS_ASSIGN,
QUESTION, RCURLY, S
<module name="FileTabCharacter"/>
+ <module name="RegexpSingleline">
+ <!-- \s matches whitespace character, $ matches end of line. -->
+ <property name="format" value="\s+$"/>
+ <property name="message" value="Line has trailing
spaces."/>
+ </module>
+
</module>
commit 3d36b0139a1d650fe911d44782a67d6733aa4ea4
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Wed May 30 16:04:37 2012 +0200
checkstyle 5: cannot initialize module TreeWalker - Unable to instantiate
TabCharacter
diff --git a/java/buildconf/checkstyle.xml b/java/buildconf/checkstyle.xml
index fc5d174..5208a6a 100644
--- a/java/buildconf/checkstyle.xml
+++ b/java/buildconf/checkstyle.xml
@@ -133,8 +133,6 @@
<property name="option" value="eol" />
</module>
<module name="ParenPad"/>
-<!-- <module name="TypecastParenPad"/> -->
- <module name="TabCharacter"/>
<module name="WhitespaceAfter">
<property name="tokens" value="COMMA, SEMI,
GENERIC_END"/>
</module>
@@ -232,4 +230,6 @@ MINUS_ASSIGN, MOD, MOD_ASSIGN, NOT_EQUAL, PLUS, PLUS_ASSIGN, QUESTION,
RCURLY, S
<property name="headerFile"
value="${checkstyle.header.file}"/>
</module>
+ <module name="FileTabCharacter"/>
+
</module>
commit fef0aaad34675b53c5f50415f4bc006f448c6edd
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Wed May 30 16:01:02 2012 +0200
checkstyle 5: TreeWalker is not allowed as a parent of RegexpHeader
diff --git a/java/buildconf/checkstyle.xml b/java/buildconf/checkstyle.xml
index 9b33b04..fc5d174 100644
--- a/java/buildconf/checkstyle.xml
+++ b/java/buildconf/checkstyle.xml
@@ -100,20 +100,6 @@
<module name="StaticVariableName"/>
<module name="TypeName"/>
-
- <!-- Checks for Headers -->
- <!-- See
http://checkstyle.sourceforge.net/config_header.html#RegexpHeader
-->
- <!-- Following interprets the header file as regular expressions. -->
- <module name="RegexpHeader">
- <!-- The follow property value demonstrates the ability -->
- <!-- to have access to ANT properties. In this case it uses -->
- <!-- the ${basedir} property to allow Checkstyle to be run -->
- <!-- from any directory within a project. -->
- <property name="headerFile"
value="${checkstyle.header.file}"/>
- </module>
-
-
-
<!-- Checks for imports -->
<!-- See
http://checkstyle.sf.net/config_import.html -->
<module name="AvoidStarImport"/>
@@ -235,4 +221,15 @@ MINUS_ASSIGN, MOD, MOD_ASSIGN, NOT_EQUAL, PLUS, PLUS_ASSIGN,
QUESTION, RCURLY, S
-->
</module>
+ <!-- Checks for Headers -->
+ <!-- See
http://checkstyle.sourceforge.net/config_header.html#RegexpHeader -->
+ <!-- Following interprets the header file as regular expressions. -->
+ <module name="RegexpHeader">
+ <!-- The follow property value demonstrates the ability -->
+ <!-- to have access to ANT properties. In this case it uses -->
+ <!-- the ${basedir} property to allow Checkstyle to be run -->
+ <!-- from any directory within a project. -->
+ <property name="headerFile"
value="${checkstyle.header.file}"/>
+ </module>
+
</module>