4 Replies Latest reply on Oct 12, 2003 1:46 AM by jcordes

    Unable to create read-only/"static" beans...

    aparaapara

      I am trying to configure (JBOSS3.2.2RC3)a few beans for read-only type of access, but I am still seeing findByPrimaryKey being executed.

      In jboss.xml:

      <ejb-name>ComponentType</ejb-name>
      <read-only>true</read-only>
      <configuration-name>Standard CMP 2.x EntityBean (static final entity)</configuration-name>


      ...

      <container-configuration extends="Standard CMP 2.x EntityBean">
      <container-name>Standard CMP 2.x EntityBean (static final entity)</container-name>
      <call-logging>false</call-logging>
      <sync-on-commit-only>false</sync-on-commit-only>
      <insert-after-ejb-post-create>false</insert-after-ejb-post-create>
      <commit-option>D</commit-option>
      </container-configuration>


      In jbosscmp-jdbc.xml (I am not sure why I have to specify read-only in both places):


      <ejb-name>ComponentType</ejb-name>
      <read-only>true</read-only>
      <table-name>componenttype</table-name>


      However, I am still seeing:

      02:01:00,870 DEBUG [findByPrimaryKey] Executing SQL: SELECT id, name, description, componentValueHomeName FROM componenttype WHERE id=?

      Am I missing something else?

      Thanks.
      -AP_