title: Problem with AOP/AspectJ not executing on criterion
body: <p>Does anyone know why the following AOP/AspectJ doesn't work in Examples <strong>2,3</strong> ?</p>
  
  <p>Note: <strong>Example 1 works</strong>.</p>
  
  <p>My goal is to intercept the firing of Hibernate <a href="https://docs.jboss.org/hibernate/orm/3.2/api/org/hibernate/Query.html" rel="nofollow noreferrer">Query</a>'s <code>executeUpdate()</code>, which occurs throughout the application. Hibernate Query is an interface, and I see in the code that the implementing class I get back  is <a href="https://docs.jboss.org/hibernate/orm/3.2/api/org/hibernate/impl/QueryImpl.html" rel="nofollow noreferrer">QueryImpl</a>. So that is the class I want to target, although I've tried generic filters too.</p>
  
  <p>XML</p>
  
  <pre><code>&lt;aop:config&gt;
      &lt;aop:aspect id="myAspect" ref="aspectBean"&gt;
  
         &lt;!-- EXAMPLE 1: SIMPLE TEST: WORKS OK. 
              I intercept all methods in all my custom classes in "dao" package. --&gt;
          &lt;aop:pointcut id="test1" expression="execution(* myapp.dao.*.*(..))" /&gt; 
          &lt;aop:before pointcut-ref="test1" method="doTest1" /&gt; 
  
         &lt;!-- EXAMPLE 2: DOESN'T WORK.
              Target everything in Hibernate's Impl package with executeUpdate() function --&gt;         
          &lt;aop:pointcut id="executeUpdate2" expression="execution(* org.hibernate.impl..*..executeUpdate(..))" /&gt;
          &lt;aop:before pointcut-ref="executeUpdate2" method="handleExecuteUpdate" /&gt; 
  
          &lt;!-- EXAMPLE 3: DOESN'T WORK.
              Target QueryImpl specifically --&gt;   
          &lt;aop:pointcut id="executeUpdate3" expression="execution(* org.hibernate.impl.QueryImpl.executeUpdate(..))" /&gt; 
          &lt;aop:before pointcut-ref="executeUpdate3" method="handleExecuteUpdate" /&gt; 
  
      &lt;/aop:aspect&gt;
  &lt;/aop:config&gt;
  &lt;bean id="aspectBean" class="myapp.util.AOPAspect"&gt;
  &lt;/bean&gt;
  </code></pre>
  
  <p>I know for a fact the Hibernate hierarchy is correct. Example #1 works great so I know the AOP/AspectJ is wired properly. Is there something about external library traversal that doesn't support AOP/AspectJ?</p>