title: No suitable method found with new Maven
body: <p>I am migrating from Maven 2.2.1 to 3.3.3 and an error appears which seems seems to be caused partly because of strange design.  Exception occurs at line :</p>
  
  <pre><code>DataSource ds = service.generatePdfDocument(dataBean.getModel(), getFormName() + "_A0024", OUTPUT_FILE_NAME, parameters);
  </code></pre>
  
  <p>whit the first parameter of the method. New Maven says: </p>
  
  <pre><code>no suitable method found for generatePdfDocument(java.lang.Object,java.lang.String,java.lang.String,java.util.Map&lt;java.lang.String,java.lang.Object&gt;)
  </code></pre>
  
  <p>There are two methods which fit this description, which differ only in the type of first parameter:</p>
  
  <pre><code>public DataSource generatePdfDocument(EkMessage pModel, String pFormName, String pOutputFileName, Map&lt;String, Object&gt; parameters) throws IOException, CloneNotSupportedException {
      return this.generatePdfDocument(pModel.getXml(), pFormName, pOutputFileName, parameters);
  }
  </code></pre>
  
  <p>and </p>
  
  <pre><code> public DataSource generatePdfDocument(MessageType pMessage, String pFormName, String pOutputFileName, Map&lt;String, Object&gt; parameters) throws IOException, CloneNotSupportedException {
      LOG.debug("Generating pdf document... ");
      ...
  }
  </code></pre>
  
  <p>so that first method is calling the second one. However, Maven does not want to accept any of these two, as dataBean.getModel() is a generic (dataBean extends DetailData):</p>
  
  <pre><code>@Getter
  @Setter
  public abstract class DetailData&lt;T extends Object&gt; extends GeneralDataBean {
  
  private static final Logger LOG = LoggerFactory.getLogger(DetailData.class);
  
      private T model;
  ...
  }
  </code></pre>
  
  <p>This used to be OK with Maven 2.2.1, but Maven 3.3.3 fails. I would like to know what is the best way to refactor the code without using instanceOf(). </p>