title: Call overloaded method from Drools: `unable to resolve method using strict-mode`
body: <p>I'm newbie with java and drools and I have to build a java RESTful Web Services / rules engine.  We already have Genesys Rule Authoring (GRAT) and Genesys Rule Engine (GRE) (version 8.1.2) who run drools version 5.2.  We have the need to take the source of GRAT packages and use them in a "lite rule engine" for our development environments.  For my POC, I have install drools 5.2 and create a project who can digest my package and fire rules just like I want.  But for some package I have this kind of error : </p>
  
  <pre><code>BuildError: Unable to Analyse Expression $routingparams.priority = obtenirValeurParametre($routingparams.priority,"100");
  $routingparams.target1 = obtenirValeurParametre($routingparams.target1, "AVGRP_GPAP_AEP_TA_MDP_E");:
  [Error: unable to resolve method using strict-mode: com.desjardins.gtd.dpsccc.routage.gpap.routingparams.ObtenirValeurParametre.obtenirValeurParametre(java.lang.Integer, java.lang.String)]
  [Near : {... ngparams.priority = obtenirValeurParametre($routin ....}]
  </code></pre>
  
  <p>If you look at package at the end, you'll see that the function obtenirValeurParametre(String, String).  You'll also see this function call with (Integer, String) and the error is on this line.  In drools package I can't have the same function with different params.  I have try to use "drools.dialect.mvel.strict" = false, but it doesn't change anything.</p>
  
  <pre><code>KnowledgeBuilderConfiguration kbConfig =KnowledgeBuilderFactory.newKnowledgeBuilderConfiguration();
  kbConfig.setProperty("drools.dialect.mvel.strict", "false");
  System.setProperty("drools.dialect.mvel.strict", "false");
  KnowledgeBuilder kbuilder = KnowledgeBuilderFactory.newKnowledgeBuilder( kbConfig );
  </code></pre>
  
  <p>As GRE run drools 5.2 like me and it work for GRE, I think that it must exist a solution other then add .toString() or something like this.  Considering that we have a lot of package and some of them have thousand of rules, I don't want to make adjustments on each rule.</p>
  
  <p>Someone have an idea to solve that issues?  He/She will be my hero! </p>
  
  <pre><code>package com.desjardins.gtd.dpsccc.routage.gpap.routingparams
  
  import java.util.*;
  
  function String obtenirValeurParametre(String valeurActuelle, String parametre){
      if(parametreEstVide(parametre)) return "";  
      if("*".equals(parametre)) return valeurActuelle;
      else return parametre;
  }
  
  function boolean parametreEstVide(String parametre){
      if(parametre.startsWith("{") &amp;&amp; parametre.endsWith("}")) return true;
      else return false;
  }
  
  declare RoutingParams
      target1: String
      priority: Integer
  end 
  
  declare ContexteInteraction
      destination: String
  end 
  
  #from row number: 1
  rule "Row 1 DT-6249 UNIT_Test Alain"
  salience 99000 
      agenda-group "level1"
      dialect "mvel"
      when
          ContexteInteraction( destination == 'GPAP_AEP_TA_MDP')
          $routingparams:RoutingParams(); 
          $contexteInteraction:ContexteInteraction();
      then
          $routingparams.priority = obtenirValeurParametre($routingparams.priority,'100')
          $routingparams.target1 = obtenirValeurParametre($routingparams.target1, 'AVGRP_GPAP_AEP_TA_MDP_E')
  end
  </code></pre>
  
  <p>Thanks</p>
  
  <p>Alain</p>