Uploaded image for project: 'Wise'
  1. Wise
  2. WISE-303

Unnecessary dependency on org.apache.commons classes

    XMLWordPrintable

Details

    Description

      wise-core just uses few org.apache.commons classes

      Usage of org.apache.commons stuff means that we have dependency on 5 org.apache.commons modules in https://github.com/jboss-wise/wise-gwt-gui/blob/master/gui/src/main/webapp/WEB-INF/jboss-deployment-structure.xml
      qui-gwt is not using org.apache.commons stuff, only wise-core

      Please try to get rid of org.apache.commons dependencies. Base64 is in JDK8, I think it's not necessary to use extra dependency for basic file operations, etc.

      Used classes:

      git grep org.apache.commons | grep import | cut -d: -f2 | sort | uniq | cut -d' ' -f2 | sed "s/;//g"
      org.apache.commons.codec.binary.Base64
      org.apache.commons.io.FileUtils
      org.apache.commons.lang.builder.EqualsBuilder
      org.apache.commons.lang.builder.HashCodeBuilder
      org.apache.commons.lang.builder.ToStringBuilder
      org.apache.commons.lang.StringUtils
      

      Details where these classes are used:

      for i in `git grep org.apache.commons | grep import | cut -d: -f2 | sort | uniq | cut -d' ' -f2 | sed "s/;//g" | sed "s/.*\.\(.*\)/\1/g"`; do echo $i; git grep "$i\."; echo ""; done
      Base64
      core/src/main/java/org/jboss/wise/core/client/impl/wsdlResolver/Connection.java:                        + new String(Base64.encodeBase64(usernamePassword.getBytes())));
      core/src/test/java/org/jboss/wise/core/client/impl/wsdlResolver/ConnectionTest.java:                "Basic " + new String(Base64.encodeBase64("username:password".getBytes())));
      
      FileUtils
      core/src/main/java/org/jboss/wise/core/client/impl/reflection/BasicWSDynamicClientImpl.java:            FileUtils.forceDelete(new File(tmpDir));
      core/src/main/java/org/jboss/wise/core/client/impl/reflection/builder/ReflectionBasedBasicWSDynamicClientBuilder.java:                FileUtils.forceMkdir(tmpDirFile);
      
      EqualsBuilder
      core/src/main/java/org/jboss/wise/core/client/impl/reflection/WebParameterImpl.java:        return EqualsBuilder.reflectionEquals(this, obj);
      integration-testsuite/common/src/test/java/org/jboss/wise/test/integration/smooks/pojo/clientside/ExternalObject.java:        return EqualsBuilder.reflectionEquals(this, o);
      integration-testsuite/common/src/test/java/org/jboss/wise/test/integration/smooks/pojo/clientside/InternalObject.java:        return EqualsBuilder.reflectionEquals(this, o);
      
      HashCodeBuilder
      core/src/main/java/org/jboss/wise/core/client/impl/reflection/WebParameterImpl.java:        return HashCodeBuilder.reflectionHashCode(this);
      
      ToStringBuilder
      core/src/test/java/org/jboss/wise/core/mapper/mappingObject/ExternalObject.java:        return ToStringBuilder.reflectionToString(this);
      core/src/test/java/org/jboss/wise/core/mapper/mappingObject/InternalObject.java:        return ToStringBuilder.reflectionToString(this);
      integration-testsuite/common/src/test/java/org/jboss/wise/test/integration/smooks/pojo/clientside/ExternalObject.java:        return ToStringBuilder.reflectionToString(this);
      integration-testsuite/common/src/test/java/org/jboss/wise/test/integration/smooks/pojo/clientside/InternalObject.java:        return ToStringBuilder.reflectionToString(this);
      
      StringUtils
      core/src/main/java/org/jboss/wise/core/client/impl/reflection/builder/ReflectionBasedBasicWSDynamicClientBuilder.java:        if (userName != null || (StringUtils.trimToNull(wsdlUrl) != null && Connection.isLocalAddress(wsdlUrl))) {
      core/src/main/java/org/jboss/wise/core/client/impl/wsdlResolver/Connection.java:        if (StringUtils.trimToNull(username) != null && StringUtils.trimToNull(password) != null) {
      

      Attachments

        Activity

          People

            rhn-support-asoldano Alessio Soldano
            rsvoboda@redhat.com Rostislav Svoboda
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: