Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Question on SmartGWT DataSourceDMI sample

    Hi all,

    I am using SmartGWT 2.3 and Firefox 6.0.

    I modified the DataSourceDMI sample by adding a REMOVE button and set a breakpoint in SupplyItemDMI.java's remove() method.

    When I select a record and then click the REMOVE button, the debugger stop, I noticed that only the itemID in the SupplyItem bean is populated, all other fields are null. When I viewed RPC request in Developer Console, the request contain the SupplyItem bean and is fully populated.

    I thought the server suppose to populate the SupplyItem bean using data from the request before invoking the remove() method, am I corrected?

    Code:
        public SupplyItem remove(SupplyItem record)
            throws Exception
        {
            log.info("procesing DMI remove operation");
    
            // on a removal, just return
            return SupplyItemStore.removeItem(record.getItemID());
        }

    #2
    Can you show the complete server-side log for the request? Always provide this for server issues.

    Comment


      #3
      Here are the Server Logs taken from SmartClient Developer Console with "DEBUG" level. These logs include removing an record.



      === 2011-10-06 09:50:32,637 [main] INFO PreCache - Isomorphic PreCache complete (907ms)
      === 2011-10-06 09:50:39,902 [l0-0] INFO RequestContext - URL: '/dsdmi/sc/DataSourceLoader', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:50:39,918 [l0-0] DEBUG XML - Parsed XML from C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\ds\supplyItem.ds.xml: 0ms
      === 2011-10-06 09:50:40,011 [l0-0] DEBUG XML - Parsed XML from C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\ds\supplyItemDMI.ds.xml: 0ms
      === 2011-10-06 09:50:40,027 [l0-0] DEBUG XML - Parsed XML from C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\system\schema\ServerObject.ds.xml: 16ms
      === 2011-10-06 09:50:40,043 [l0-0] INFO RequestContext - URL: '/dsdmi/sc/modules/ISC_Grids.js', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:50:40,168 [l0-3] INFO RequestContext - URL: '/dsdmi/sc/modules/ISC_Forms.js', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:50:40,199 [l0-0] INFO Compression - /dsdmi/sc/modules/ISC_Grids.js: 668777 -> 169025 bytes
      === 2011-10-06 09:50:40,355 [l0-3] INFO Compression - /dsdmi/sc/modules/ISC_Forms.js: 552559 -> 134115 bytes
      === 2011-10-06 09:50:40,433 [l0-2] INFO Compression - /dsdmi/sc/modules/ISC_Core.js: 666492 -> 173006 bytes
      === 2011-10-06 09:51:12,291 [l0-2] INFO RequestContext - URL: '/dsdmi/sc/IDACall', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:51:12,322 [l0-2] DEBUG XML - Parsed XML from (in memory stream): 0ms
      === 2011-10-06 09:51:12,338 [l0-2] DEBUG XML - Parsed XML from C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\system\schema\List.ds.xml: 0ms
      === 2011-10-06 09:51:12,338 [l0-2] DEBUG RPCManager - Processing 1 requests.
      === 2011-10-06 09:51:12,369 [l0-2] DEBUG RPCManager - Request #1 (DSRequest) payload: {
      criteria:{
      },
      operationConfig:{
      dataSource:"supplyItemDMI",
      operationType:"fetch",
      textMatchStyle:"exact"
      },
      startRow:0,
      endRow:75,
      componentId:"isc_ListGrid_0",
      appID:"builtinApplication",
      operation:"supplyItemDMI_fetch",
      oldValues:{
      }
      }
      === 2011-10-06 09:51:12,385 [l0-2] INFO IDACall - Performing 1 operation(s)
      === 2011-10-06 09:51:12,416 [l0-2] DEBUG AppBase - [builtinApplication.null] No userTypes defined, allowing anyone access to all operations for this application
      === 2011-10-06 09:51:12,416 [l0-2] DEBUG AppBase - [builtinApplication.null] No public zero-argument method named '_null' found, performing generic datasource operation
      === 2011-10-06 09:51:12,416 [l0-2] INFO SQLDataSource - [builtinApplication.null] Performing fetch operation with
      criteria: {} values: {}
      === 2011-10-06 09:51:12,432 [l0-2] INFO SQLWhereClause - [builtinApplication.null] empty condition
      === 2011-10-06 09:51:12,432 [l0-2] INFO SQLDataSource - [builtinApplication.null] derived query: SELECT $defaultSelectClause FROM $defaultTableClause WHERE $defaultWhereClause
      === 2011-10-06 09:51:12,775 [l0-2] INFO PoolManager - [builtinApplication.null] SmartClient pooling disabled for 'HSQLDB' objects
      === 2011-10-06 09:51:12,775 [l0-2] DEBUG PoolableSQLConnectionFactory - [builtinApplication.null] Initializing SQL config for 'HSQLDB' from system config - using DriverManager: org.hsqldb.jdbcDriver
      === 2011-10-06 09:51:12,807 [l0-2] DEBUG PoolableSQLConnectionFactory - [builtinApplication.null] org.hsqldb.jdbcDriver lookup successful
      === 2011-10-06 09:51:12,807 [l0-2] DEBUG PoolableSQLConnectionFactory - [builtinApplication.null] DriverManager fetching connection for HSQLDB via jdbc url jdbc:hsqldb:hsql://localhost/isomorphic
      === 2011-10-06 09:51:12,807 [l0-2] DEBUG PoolableSQLConnectionFactory - [builtinApplication.null] Passing JDBC URL only to getConnection
      === 2011-10-06 09:51:12,838 [l0-2] DEBUG PoolableSQLConnectionFactory - [builtinApplication.null] Returning unpooled Connection
      === 2011-10-06 09:51:12,838 [l0-2] INFO SQLDriver - [builtinApplication.null] Executing SQL query on 'HSQLDB': SELECT supplyItem.nextShipment, supplyItem.itemName, supplyItem.category, supplyItem.itemID, supplyItem.unitCost, supplyItem.SKU, supplyItem.description, supplyItem.inStock, supplyItem.units FROM supplyItem WHERE ('1'='1')
      === 2011-10-06 09:51:13,197 [l0-2] INFO DSResponse - [builtinApplication.null] DSResponse: List with 3959 items
      === 2011-10-06 09:51:13,306 [l0-2] INFO DSResponse - DSResponse: List with 75 items
      === 2011-10-06 09:51:13,306 [l0-2] DEBUG RPCManager - Content type for RPC transaction: text/plain; charset=UTF-8
      === 2011-10-06 09:51:13,306 [l0-2] DEBUG RPCManager - DMI response, dropExtraFields: true
      === 2011-10-06 09:51:13,338 [l0-2] INFO Compression - /dsdmi/sc/IDACall: 14932 -> 2819 bytes
      === 2011-10-06 09:51:18,666 [l0-2] INFO RequestContext - URL: '/dsdmi/sc/system/development/ISC_Core.js', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:51:18,666 [l0-3] INFO RequestContext - URL: '/dsdmi/sc/system/development/ISC_Grids.js', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:51:18,666 [l0-0] INFO RequestContext - URL: '/dsdmi/sc/system/development/ISC_Forms.js', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:51:18,681 [l0-0] INFO Download - done streaming: C:/Documents and Settings/chuj.MITEL/workspace/DataSourceDMI/war/dsdmi/sc/system/development/ISC_Forms.js
      === 2011-10-06 09:51:18,759 [l0-4] INFO RequestContext - URL: '/dsdmi/sc/system/development/ISC_DataBinding.js', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:51:18,744 [l0-3] INFO Download - done streaming: C:/Documents and Settings/chuj.MITEL/workspace/DataSourceDMI/war/dsdmi/sc/system/development/ISC_Grids.js
      === 2011-10-06 09:51:18,884 [l0-4] INFO Download - done streaming: C:/Documents and Settings/chuj.MITEL/workspace/DataSourceDMI/war/dsdmi/sc/system/development/ISC_DataBinding.js
      === 2011-10-06 09:51:19,025 [l0-0] INFO Compression - /dsdmi/sc/system/development/ISC_Forms.js: 588373 -> 142569 bytes
      === 2011-10-06 09:51:19,025 [l0-3] INFO Compression - /dsdmi/sc/system/development/ISC_Grids.js: 671567 -> 169649 bytes
      === 2011-10-06 09:51:19,228 [l0-4] INFO Compression - /dsdmi/sc/system/development/ISC_DataBinding.js: 496742 -> 123920 bytes
      === 2011-10-06 09:51:19,728 [l0-2] INFO Download - done streaming: C:/Documents and Settings/chuj.MITEL/workspace/DataSourceDMI/war/dsdmi/sc/system/development/ISC_Core.js
      === 2011-10-06 09:51:19,869 [l0-2] INFO Compression - /dsdmi/sc/system/development/ISC_Core.js: 670053 -> 173839 bytes
      === 2011-10-06 09:51:22,478 [l0-2] INFO RequestContext - URL: '/dsdmi/sc/IDACall', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:51:22,494 [l0-2] DEBUG XML - Parsed XML from (in memory stream): 0ms
      === 2011-10-06 09:51:22,494 [l0-2] DEBUG RPCManager - Processing 1 requests.
      === 2011-10-06 09:51:22,494 [l0-2] DEBUG RPCManager - Request #1 (RPCRequest) data: {
      appID:"isc_builtin",
      className:"builtin",
      methodName:"getAvailableScriptEngines",
      arguments:[
      ],
      is_ISC_RPC_DMI:true
      }
      === 2011-10-06 09:51:22,494 [l0-2] INFO IDACall - Performing 1 operation(s)
      === 2011-10-06 09:51:22,509 [l0-2] DEBUG XML - Parsed XML from jar:file:/C:/smartgwtee-2.4/lib/isomorphic_core_rpc.jar!/isc_builtin.app.xml: 0ms
      === 2011-10-06 09:51:22,525 [l0-2] DEBUG XML - Parsed XML from C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\system\schema\Method.ds.xml: 0ms
      === 2011-10-06 09:51:22,540 [l0-2] DEBUG RPCDMI - appConfig: isc.Application.create({
      rpcBindings:[
      {
      ID:"builtin",
      className:"com.isomorphic.rpc.BuiltinRPC",
      visibleMethods:[
      {
      name:"downloadWSDL"
      },
      {
      name:"downloadClientContent"
      },
      {
      name:"downloadClientExport"
      },
      {
      name:"xmlToJS"
      },
      {
      name:"uploadProgressCheck"
      },
      {
      name:"saveFile"
      },
      {
      name:"appendToFile"
      },
      {
      name:"loadFile"
      },
      {
      name:"deleteFile"
      },
      {
      name:"loadSharedXML"
      },
      {
      name:"saveSharedXML"
      },
      {
      name:"getAvailableScriptEngines"
      },
      {
      name:"devConsoleEvalServerScript"
      },
      {
      name:"evalJava"
      },
      {
      name:"getLogNames"
      },
      {
      name:"getLogEntries"
      },
      {
      name:"getLogThresholds"
      },
      {
      name:"setLogThreshold"
      }
      ]
      },
      {
      ID:"builtin_tools",
      className:"com.isomorphic.tools.BuiltinRPC",
      visibleMethods:[
      {
      name:"getDataSourceFromTable"
      },
      {
      name:"getDataSourceJSONFromTable"
      },
      {
      name:"getDataSourceFromHibernateMapping"
      },
      {
      name:"getDataSourceJSONFromHibernateMapping"
      },
      {
      name:"getTables"
      },
      {
      name:"getFieldsFromTable"
      },
      {
      name:"getBeanFields"
      },
      {
      name:"getHibernateBeans"
      },
      {
      name:"getDatabaseProductNameAndVersion"
      },
      {
      name:"getDatabaseTableTypes"
      },
      {
      name:"setAttributes"
      },
      {
      name:"clearAttributes"
      },
      {
      name:"getAttributes"
      },
      {
      name:"getAttribute"
      },
      {
      name:"getDataSourceConfigFromJavaClass"
      },
      {
      args:"cName",
      language:"groovy",
      name:"getJavaSource",
      script:"\n if (!com.isomorphic.auth.DevModeAuthFilter.devModeAuthorized(request)) throw new Exception(\"Not Authorized\"); \n //import org.apache.bcel.Repository;\n\n try {\n return org.apache.bcel.Repository.lookupClass(cName).toString();\n } catch (Throwable e) {\n return \"Unable to reverse engineer class \"+cName+\": \"+e.getMessage();\n }\n "
      },
      {
      name:"loadDataSource"
      },
      {
      name:"dsFromXML"
      },
      {
      name:"dsConfigFromXML"
      },
      {
      name:"getDefinedDataSources"
      }
      ]
      },
      {
      ID:"builtin_adminconsole",
      className:"com.isomorphic.tools.AdminConsole",
      visibleMethods:[
      {
      name:"getDefinedDatabases"
      },
      {
      name:"testDB"
      },
      {
      name:"saveDBConfig"
      },
      {
      name:"setDefaultDB"
      },
      {
      name:"importDataSources"
      },
      {
      name:"discoverJNDIDatabases"
      }
      ]
      }
      ]
      })

      === 2011-10-06 09:51:22,556 [l0-2] WARN RequestContext - rpcRequest.execute() failed:
      === 2011-10-06 09:51:22,572 [l0-2] DEBUG RPCManager - Content type for RPC transaction: text/plain; charset=UTF-8
      === 2011-10-06 09:51:22,572 [l0-2] INFO Compression - /dsdmi/sc/IDACall: 285 -> 218 bytes
      === 2011-10-06 09:51:27,556 [l0-2] INFO RequestContext - URL: '/dsdmi/sc/IDACall', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:51:27,587 [l0-2] INFO Compression - /dsdmi/sc/IDACall: 81 -> 86 bytes
      === 2011-10-06 09:51:27,837 [l0-2] INFO RequestContext - URL: '/dsdmi/sc/IDACall', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:51:27,884 [l0-2] INFO Compression - /dsdmi/sc/IDACall: 23038 -> 3470 bytes
      === 2011-10-06 09:51:40,977 [l0-2] INFO RequestContext - URL: '/dsdmi/sc/IDACall', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:51:41,008 [l0-2] INFO Compression - /dsdmi/sc/IDACall: 23399 -> 3496 bytes
      === 2011-10-06 09:52:05,679 [l0-2] INFO RequestContext - URL: '/tools/serverLogViewer.jsp', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:52:11,991 [l0-2] INFO RequestContext - URL: '/dsdmi/sc/IDACall', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:52:11,991 [l0-2] DEBUG XML - Parsed XML from (in memory stream): 0ms
      === 2011-10-06 09:52:12,007 [l0-2] DEBUG RPCManager - Processing 1 requests.
      === 2011-10-06 09:52:12,007 [l0-2] DEBUG RPCManager - Request #1 (DSRequest) payload: {
      criteria:{
      SKU:"860700",
      category:"Pastes and Gum",
      description:"A general purpose glue suitable for paper and card. Includes a quality brush for easy application. Washable & Non-Toxic",
      inStock:false,
      itemID:6,
      itemName:"Glue UHU Office Paste 250ml",
      nextShipment:null,
      unitCost:1.73,
      units:null,
      _selection_1:true
      },
      operationConfig:{
      dataSource:"supplyItemDMI",
      operationType:"remove"
      },
      componentId:"isc_ListGrid_0",
      appID:"builtinApplication",
      operation:"supplyItemDMI_remove",
      oldValues:{
      SKU:"860700",
      category:"Pastes and Gum",
      description:"A general purpose glue suitable for paper and card. Includes a quality brush for easy application. Washable & Non-Toxic",
      inStock:false,
      itemID:6,
      itemName:"Glue UHU Office Paste 250ml",
      nextShipment:null,
      unitCost:1.73,
      units:null,
      _selection_1:true
      }
      }
      === 2011-10-06 09:52:12,007 [l0-2] INFO IDACall - Performing 1 operation(s)
      === 2011-10-06 09:52:12,007 [l0-2] DEBUG RPCManager - Content type for RPC transaction: text/plain; charset=UTF-8
      === 2011-10-06 09:52:12,007 [l0-2] DEBUG RPCManager - DMI response, dropExtraFields: true
      === 2011-10-06 09:52:12,022 [l0-2] INFO Compression - /dsdmi/sc/IDACall: 394 -> 303 bytes
      === 2011-10-06 09:52:20,975 [l0-2] INFO RequestContext - URL: '/dsdmi/sc/IDACall', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:52:21,006 [l0-2] INFO Compression - /dsdmi/sc/IDACall: 26166 -> 3826 bytes
      === 2011-10-06 09:53:46,127 [l0-2] INFO RequestContext - URL: '/dsdmi/sc/DataSourceLoader', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:53:46,221 [l0-3] INFO RequestContext - URL: '/dsdmi/sc/modules/ISC_Grids.js', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:53:46,252 [l0-5] INFO RequestContext - URL: '/dsdmi/sc/modules/ISC_Forms.js', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:53:46,471 [l0-4] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\load_skin.js
      === 2011-10-06 09:53:46,471 [l0-5] INFO Compression - /dsdmi/sc/modules/ISC_Forms.js: 552559 -> 134115 bytes
      === 2011-10-06 09:53:46,564 [l0-2] INFO Compression - /dsdmi/sc/modules/ISC_Core.js: 666492 -> 173006 bytes
      === 2011-10-06 09:53:46,486 [l0-3] INFO Compression - /dsdmi/sc/modules/ISC_Grids.js: 668777 -> 169025 bytes
      === 2011-10-06 09:53:48,533 [l0-2] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\skin_styles.css
      === 2011-10-06 09:53:56,220 [l0-5] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\pickers\comboBoxPicker.png
      === 2011-10-06 09:53:56,236 [l0-3] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\DynamicForm\unchecked.png
      === 2011-10-06 09:53:56,236 [l0-4] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\DynamicForm\date_control.png
      === 2011-10-06 09:53:56,236 [l0-2] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\ToolStrip\background.png
      === 2011-10-06 09:53:56,236 [l0-3] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_start.png
      === 2011-10-06 09:53:56,251 [l0-7] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_Disabled_end.png
      === 2011-10-06 09:53:56,251 [l0-6] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\ListGrid\header.png
      === 2011-10-06 09:53:56,251 [l0-2] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_stretch.png
      === 2011-10-06 09:53:56,251 [l0-4] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_end.png
      === 2011-10-06 09:53:56,251 [l0-5] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_Disabled_stretch.png
      === 2011-10-06 09:53:56,251 [l0-3] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_Disabled_start.png
      === 2011-10-06 09:53:56,267 [l0-3] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\loadingSmall.gif
      === 2011-10-06 09:53:56,267 [l0-2] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\blank.gif
      === 2011-10-06 09:53:56,439 [l0-2] INFO RequestContext - URL: '/dsdmi/sc/IDACall', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:53:56,439 [l0-2] DEBUG XML - Parsed XML from (in memory stream): 0ms
      === 2011-10-06 09:53:56,454 [l0-2] DEBUG RPCManager - Processing 1 requests.
      === 2011-10-06 09:53:56,454 [l0-2] DEBUG RPCManager - Request #1 (DSRequest) payload: {
      criteria:{
      },
      operationConfig:{
      dataSource:"supplyItemDMI",
      operationType:"fetch",
      textMatchStyle:"exact"
      },
      startRow:0,
      endRow:75,
      componentId:"isc_ListGrid_0",
      appID:"builtinApplication",
      operation:"supplyItemDMI_fetch",
      oldValues:{
      }
      }
      === 2011-10-06 09:53:56,454 [l0-2] INFO IDACall - Performing 1 operation(s)
      === 2011-10-06 09:53:56,454 [l0-2] INFO DSResponse - DSResponse: List with 75 items
      === 2011-10-06 09:53:56,454 [l0-2] DEBUG RPCManager - Content type for RPC transaction: text/plain; charset=UTF-8
      === 2011-10-06 09:53:56,454 [l0-2] DEBUG RPCManager - DMI response, dropExtraFields: true
      === 2011-10-06 09:53:56,470 [l0-2] INFO Compression - /dsdmi/sc/IDACall: 14850 -> 2812 bytes
      === 2011-10-06 09:53:58,001 [l0-2] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\Dialog\say.png
      === 2011-10-06 09:53:58,048 [l0-7] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\Window\window_L.png
      === 2011-10-06 09:53:58,048 [l0-7] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\Window\window_BL.png
      === 2011-10-06 09:53:58,064 [l0-7] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\Window\window_B.png
      === 2011-10-06 09:53:58,064 [l0-4] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\Window\window_T.png
      === 2011-10-06 09:53:58,064 [l0-7] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\Window\window_BR.png
      === 2011-10-06 09:53:58,079 [l0-3] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\Window\window_TL.png
      === 2011-10-06 09:53:58,079 [l0-5] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\Window\window_TR.png
      === 2011-10-06 09:53:58,079 [l0-7] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\Scrollbar\vscroll_track.png
      === 2011-10-06 09:53:58,079 [l0-7] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\Scrollbar\vscroll_end.png
      === 2011-10-06 09:53:58,095 [l0-7] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\Scrollbar\vthumb_grip.png
      === 2011-10-06 09:53:58,095 [l0-7] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\Scrollbar\vthumb_start.png
      === 2011-10-06 09:53:58,111 [l0-2] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\headerIcons\close.png
      === 2011-10-06 09:53:58,111 [l0-6] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\Window\window_R.png
      === 2011-10-06 09:53:58,111 [l0-4] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\Scrollbar\vscroll_start.png
      === 2011-10-06 09:53:58,095 [l0-3] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\Scrollbar\vthumb_end.png
      === 2011-10-06 09:53:58,095 [l0-5] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\Scrollbar\vthumb_stretch.png
      === 2011-10-06 09:54:02,563 [l0-5] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_Over_stretch.png
      === 2011-10-06 09:54:02,579 [l0-3] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_Over_end.png
      === 2011-10-06 09:54:02,579 [l0-4] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_Over_start.png
      === 2011-10-06 09:54:11,391 [l0-4] INFO RequestContext - URL: '/dsdmi/sc/system/development/ISC_Core.js', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:54:11,391 [l0-3] INFO RequestContext - URL: '/dsdmi/sc/system/development/ISC_Grids.js', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:54:11,391 [l0-5] INFO RequestContext - URL: '/dsdmi/sc/system/development/ISC_Forms.js', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:54:11,391 [l0-6] INFO RequestContext - URL: '/dsdmi/sc/system/development/ISC_DataBinding.js', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:54:11,407 [l0-3] INFO Download - done streaming: C:/Documents and Settings/chuj.MITEL/workspace/DataSourceDMI/war/dsdmi/sc/system/development/ISC_Grids.js
      === 2011-10-06 09:54:11,454 [l0-6] INFO Download - done streaming: C:/Documents and Settings/chuj.MITEL/workspace/DataSourceDMI/war/dsdmi/sc/system/development/ISC_DataBinding.js
      === 2011-10-06 09:54:11,500 [l0-5] INFO Download - done streaming: C:/Documents and Settings/chuj.MITEL/workspace/DataSourceDMI/war/dsdmi/sc/system/development/ISC_Forms.js
      === 2011-10-06 09:54:11,657 [l0-3] INFO Compression - /dsdmi/sc/system/development/ISC_Grids.js: 671567 -> 169649 bytes
      === 2011-10-06 09:54:11,688 [l0-6] INFO Compression - /dsdmi/sc/system/development/ISC_DataBinding.js: 496742 -> 123920 bytes
      === 2011-10-06 09:54:11,688 [l0-3] INFO RequestContext - URL: '/dsdmi/sc/skins/Enterprise/images/Scrollbar/vthumb_Over_start.png', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:54:11,704 [l0-5] INFO Compression - /dsdmi/sc/system/development/ISC_Forms.js: 588373 -> 142569 bytes
      === 2011-10-06 09:54:11,704 [l0-3] INFO Download - done streaming: C:/Documents and Settings/chuj.MITEL/workspace/DataSourceDMI/war/dsdmi/sc/skins/Enterprise/images/Scrollbar/vthumb_Over_start.png
      === 2011-10-06 09:54:11,797 [l0-6] INFO RequestContext - URL: '/dsdmi/sc/skins/Enterprise/images/Scrollbar/vthumb_Over_stretch.png', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:54:11,860 [l0-6] INFO Download - done streaming: C:/Documents and Settings/chuj.MITEL/workspace/DataSourceDMI/war/dsdmi/sc/skins/Enterprise/images/Scrollbar/vthumb_Over_stretch.png
      === 2011-10-06 09:54:12,141 [l0-6] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\ListGrid\header_menu.png
      === 2011-10-06 09:54:12,469 [l0-4] INFO Download - done streaming: C:/Documents and Settings/chuj.MITEL/workspace/DataSourceDMI/war/dsdmi/sc/system/development/ISC_Core.js
      === 2011-10-06 09:54:12,594 [l0-4] INFO Compression - /dsdmi/sc/system/development/ISC_Core.js: 670053 -> 173839 bytes
      === 2011-10-06 09:54:15,469 [l0-4] INFO RequestContext - URL: '/dsdmi/sc/IDACall', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:54:15,469 [l0-4] DEBUG XML - Parsed XML from (in memory stream): 0ms
      === 2011-10-06 09:54:15,469 [l0-4] DEBUG RPCManager - Processing 1 requests.
      === 2011-10-06 09:54:15,469 [l0-4] DEBUG RPCManager - Request #1 (RPCRequest) data: {
      appID:"isc_builtin",
      className:"builtin",
      methodName:"getAvailableScriptEngines",
      arguments:[
      ],
      is_ISC_RPC_DMI:true
      }
      === 2011-10-06 09:54:15,469 [l0-4] INFO IDACall - Performing 1 operation(s)
      === 2011-10-06 09:54:15,485 [l0-4] DEBUG RPCDMI - appConfig: isc.Application.create({
      rpcBindings:[
      {
      ID:"builtin",
      className:"com.isomorphic.rpc.BuiltinRPC",
      visibleMethods:[
      {
      name:"downloadWSDL"
      },
      {
      name:"downloadClientContent"
      },
      {
      name:"downloadClientExport"
      },
      {
      name:"xmlToJS"
      },
      {
      name:"uploadProgressCheck"
      },
      {
      name:"saveFile"
      },
      {
      name:"appendToFile"
      },
      {
      name:"loadFile"
      },
      {
      name:"deleteFile"
      },
      {
      name:"loadSharedXML"
      },
      {
      name:"saveSharedXML"
      },
      {
      name:"getAvailableScriptEngines"
      },
      {
      name:"devConsoleEvalServerScript"
      },
      {
      name:"evalJava"
      },
      {
      name:"getLogNames"
      },
      {
      name:"getLogEntries"
      },
      {
      name:"getLogThresholds"
      },
      {
      name:"setLogThreshold"
      }
      ]
      },
      {
      ID:"builtin_tools",
      className:"com.isomorphic.tools.BuiltinRPC",
      visibleMethods:[
      {
      name:"getDataSourceFromTable"
      },
      {
      name:"getDataSourceJSONFromTable"
      },
      {
      name:"getDataSourceFromHibernateMapping"
      },
      {
      name:"getDataSourceJSONFromHibernateMapping"
      },
      {
      name:"getTables"
      },
      {
      name:"getFieldsFromTable"
      },
      {
      name:"getBeanFields"
      },
      {
      name:"getHibernateBeans"
      },
      {
      name:"getDatabaseProductNameAndVersion"
      },
      {
      name:"getDatabaseTableTypes"
      },
      {
      name:"setAttributes"
      },
      {
      name:"clearAttributes"
      },
      {
      name:"getAttributes"
      },
      {
      name:"getAttribute"
      },
      {
      name:"getDataSourceConfigFromJavaClass"
      },
      {
      args:"cName",
      language:"groovy",
      name:"getJavaSource",
      script:"\n if (!com.isomorphic.auth.DevModeAuthFilter.devModeAuthorized(request)) throw new Exception(\"Not Authorized\"); \n //import org.apache.bcel.Repository;\n\n try {\n return org.apache.bcel.Repository.lookupClass(cName).toString();\n } catch (Throwable e) {\n return \"Unable to reverse engineer class \"+cName+\": \"+e.getMessage();\n }\n "
      },
      {
      name:"loadDataSource"
      },
      {
      name:"dsFromXML"
      },
      {
      name:"dsConfigFromXML"
      },
      {
      name:"getDefinedDataSources"
      }
      ]
      },
      {
      ID:"builtin_adminconsole",
      className:"com.isomorphic.tools.AdminConsole",
      visibleMethods:[
      {
      name:"getDefinedDatabases"
      },
      {
      name:"testDB"
      },
      {
      name:"saveDBConfig"
      },
      {
      name:"setDefaultDB"
      },
      {
      name:"importDataSources"
      },
      {
      name:"discoverJNDIDatabases"
      }
      ]
      }
      ]
      })

      === 2011-10-06 09:54:15,485 [l0-4] WARN RequestContext - rpcRequest.execute() failed:
      === 2011-10-06 09:54:15,485 [l0-4] DEBUG RPCManager - Content type for RPC transaction: text/plain; charset=UTF-8
      === 2011-10-06 09:54:15,485 [l0-4] INFO Compression - /dsdmi/sc/IDACall: 285 -> 218 bytes
      === 2011-10-06 09:54:19,422 [l0-4] INFO RequestContext - URL: '/dsdmi/sc/IDACall', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:54:19,453 [l0-4] INFO Compression - /dsdmi/sc/IDACall: 81 -> 86 bytes
      === 2011-10-06 09:54:19,703 [l0-4] INFO RequestContext - URL: '/dsdmi/sc/IDACall', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:54:19,734 [l0-4] INFO Compression - /dsdmi/sc/IDACall: 49097 -> 4886 bytes
      === 2011-10-06 09:54:23,000 [l0-4] INFO RequestContext - URL: '/dsdmi/sc/IDACall', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:54:23,031 [l0-4] INFO Compression - /dsdmi/sc/IDACall: 49458 -> 4912 bytes
      === 2011-10-06 09:54:29,953 [l0-4] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\ListGrid\row_Over.png
      === 2011-10-06 09:54:31,296 [l0-4] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\ListGrid\row_Over_Selected.png
      === 2011-10-06 09:54:31,312 [l0-3] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_stretch.png
      === 2011-10-06 09:54:31,312 [l0-5] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_end.png
      === 2011-10-06 09:54:31,328 [l0-6] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_start.png
      === 2011-10-06 09:54:31,328 [l0-2] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\pickers\comboBoxPicker.png
      === 2011-10-06 09:54:31,765 [l0-6] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_Over_stretch.png
      === 2011-10-06 09:54:31,765 [l0-5] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_Over_end.png
      === 2011-10-06 09:54:31,765 [l0-2] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_Over_start.png
      === 2011-10-06 09:54:33,734 [l0-5] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_Down_end.png
      === 2011-10-06 09:54:33,734 [l0-2] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_Down_start.png
      === 2011-10-06 09:54:33,734 [l0-6] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\button\button_Down_stretch.png
      === 2011-10-06 09:54:33,906 [l0-6] INFO RequestContext - URL: '/dsdmi/sc/IDACall', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header
      === 2011-10-06 09:54:33,906 [l0-6] DEBUG XML - Parsed XML from (in memory stream): 0ms
      === 2011-10-06 09:54:33,906 [l0-6] DEBUG RPCManager - Processing 1 requests.
      === 2011-10-06 09:54:33,906 [l0-6] DEBUG RPCManager - Request #1 (DSRequest) payload: {
      criteria:{
      SKU:"996600",
      category:"Roll-on Glue",
      description:"Odourless liquid adhesive for use on paper and cardboard. Unique rubber roll-on applicator is easy to use. Available in Pink or Blue. Contains 30ml of glue.",
      inStock:false,
      itemID:8,
      itemName:"Glue Pentel 30CC Roll On 30ml",
      nextShipment:null,
      unitCost:1.83,
      units:"Ea",
      _selection_1:true
      },
      operationConfig:{
      dataSource:"supplyItemDMI",
      operationType:"remove"
      },
      componentId:"isc_ListGrid_0",
      appID:"builtinApplication",
      operation:"supplyItemDMI_remove",
      oldValues:{
      SKU:"996600",
      category:"Roll-on Glue",
      description:"Odourless liquid adhesive for use on paper and cardboard. Unique rubber roll-on applicator is easy to use. Available in Pink or Blue. Contains 30ml of glue.",
      inStock:false,
      itemID:8,
      itemName:"Glue Pentel 30CC Roll On 30ml",
      nextShipment:null,
      unitCost:1.83,
      units:"Ea",
      _selection_1:true
      }
      }
      === 2011-10-06 09:54:33,921 [l0-6] INFO IDACall - Performing 1 operation(s)
      === 2011-10-06 09:54:33,921 [l0-6] DEBUG RPCManager - Content type for RPC transaction: text/plain; charset=UTF-8
      === 2011-10-06 09:54:33,921 [l0-6] DEBUG RPCManager - DMI response, dropExtraFields: true
      === 2011-10-06 09:54:33,921 [l0-6] INFO Compression - /dsdmi/sc/IDACall: 433 -> 321 bytes
      === 2011-10-06 09:54:35,577 [l0-6] INFO Download - Returning 304: Not modified on conditional get of: C:\Documents and Settings\chuj.MITEL\workspace\DataSourceDMI\war\dsdmi\sc\skins\Enterprise\images\blank.gif
      === 2011-10-06 09:54:43,686 [l0-6] INFO RequestContext - URL: '/dsdmi/sc/IDACall', User-Agent: 'Mozilla/5.0 (Windows NT 5.1; rv:6.0) Gecko/20100101 Firefox/6.0': Moz (Gecko) with Accept-Encoding header

      Comment


        #4
        Sorry, this is expected behavior - the default is to remove by primaryKey rather than by complete values, so auto-population of beans likewise just populates the primaryKey field.

        If you want all values populated on your bean, you can use DataSource.setProperties() in conjunction with dsRequest.getOldValues().

        Comment


          #5
          Thanks for the answer.

          It makes sense for the REMOVE operation. However, in my code, I have a generic CUSTOM operation (ex. retry operation), and the primary key is not populated when the CUSTOM method is invoked (actually, only one one out of fifteen fields is populated). Should I use dsRequest.getOldValues() to obtain the primary key?

          How do SmartGWT decides which bean value to populate base on which operation?

          Comment


            #6
            To clarify - you're saying that for a custom operation, executed via performCustomOperation(), you are passing a map of 15 properties and SGWT Server is only populating one of those 15 properties in a matching server-side bean, and that single populated property is not the primaryKey? If so, please supply the DataSource definition containing the custom op, the source of the server-side bean and the source of the client-side program that invokes the op.

            Comment


              #7
              Yes, you are corrected, the single populated property is NOT the primary key. Only the "message" property is populated.

              Here are my codes and thanks for your help.

              Data Source
              Code:
              <DataSource ID="distributionupdate" serverType="sql" tableName="distributionupdate" autoDeriveSchema="true">
                  <fields>
                  	<!-- 
                  		 Normally with the autoDeriveSchema set to true, all fields are automatically derived, and we don't 
                  		 need to specify individual fields. However, if we need to override the default attribute, then we need
                  		 to add the field that we want to override.
                  	--> 	
                  	<field name="trans_id_trans_cnt" type="int" title="Action ID" primaryKey="true"/>
                  	<field name="timestamp" type="datetime" title="Date/Time"/>
                  	<field name="name" type="text" title="To" tableName="sub_network_element_core"/>
                  	<field name="action" type="int" tableName="distributiontransactionlog" optionDataSource="action" valueField="value" displayField="label"/>
                  	<field name="dei_id" type="int" title="Form Name" tableName="distributiontransactionlog" optionDataSource="deidefinition" valueField="dei_id" displayField="name"/>
                      <field name="update_type" type="int" optionDataSource="update_type" valueField="value" displayField="label"/>   
                      <field name="message" type="text" title="Reason"/>	
                      <field name="dest_app_id" type="int"/>       
                      <field name="appviewid" type="text"/>
                      <field name="app_error_id" type="int"/>      
                      <field name="status" type="int" optionDataSource="sdsccstatus" valueField="value" displayField="label"/>
                      <field name="transaction_timestamp" type="datetime" title="Last Retried"/>      
                  </fields>
                  
                  <operationBindings>
                		<binding operationType="fetch">
                  		<selectClause>
                  			distributionupdate.trans_id_trans_cnt,
                  			distributionupdate.dest_app_id,
                  			distributionupdate.update_type,
                  			distributionupdate.appviewid,
                  			distributionupdate.app_error_id,
                  			distributionupdate.message,
                  			to_timestamp(distributionupdate.timestamp::int) as timestamp,
                  			distributionupdate.status,
                  			to_timestamp(distributionupdate.transaction_timestamp::int) as transaction_timestamp,
                  			distributiontransactionlog.action,
                  			distributiontransactionlog.dei_id,
                  			sub_network_element_core.name
                  		</selectClause>
                  		<tableClause>
                  			distributionupdate, distributiontransactionlog, sub_network_element_core
                  		</tableClause>
                  		<whereClause>
                  			distributionupdate.trans_id_trans_cnt = distributiontransactionlog.trans_id_trans_cnt AND
                  					distributionupdate.dest_id = sub_network_element_core.network_element_id AND
                  					($defaultWhereClause)
                  		</whereClause>
                  	</binding>
                   	<binding operationType="remove" serverMethod="remove">
                  		<serverObject lookupStyle="new" className="com.mitel.masusp.ui.server.SdsccDistributionUpdateDMI"/>
                  	</binding>
                  	<binding operationId="retryID" operationType="custom" serverMethod="retry">
                  		<serverObject lookupStyle="new" className="com.mitel.masusp.ui.server.SdsccDistributionUpdateDMI"/>
                  	</binding>
                  </operationBindings>
              </DataSource>
              Server-side Bean
              Code:
              public class DistributionUpdate implements Serializable 
              {
                 private static final long serialVersionUID = -2546034751607176406L;
              
                 protected String trans_id_ne_id;
                 protected int trans_id_trans_cnt;
                 protected String dest_id;
                 protected int dest_app_id;
                 protected int update_type;
              	protected String appviewid;
              	protected int app_error_id;
              	protected String message;
              	protected String timestamp;
              	protected int status;
              	protected String transaction_timestamp;
              	protected String lciinstanceid;
              	protected int action;
              	
              	public DistributionUpdate(){}
              
              	public String getTrans_id_ne_id()
                 {
                 	return trans_id_ne_id;
                 }
              
              	public void setTrans_id_ne_id(String trans_id_ne_id)
                 {
                 	this.trans_id_ne_id = trans_id_ne_id;
                 }
              
              	public int getTrans_id_trans_cnt()
                 {
                 	return trans_id_trans_cnt;
                 }
              
              	public void setTrans_id_trans_cnt(int trans_id_trans_cnt)
                 {
                 	this.trans_id_trans_cnt = trans_id_trans_cnt;
                 }
              
              	public String getDest_id()
                 {
                 	return dest_id;
                 }
              
              	public void setDest_id(String dest_id)
                 {
                 	this.dest_id = dest_id;
                 }
              
              	public int getDest_app_id()
                 {
                 	return dest_app_id;
                 }
              
              	public void setDest_app_id(int dest_app_id)
                 {
                 	this.dest_app_id = dest_app_id;
                 }
              
              	public int getUpdate_type()
                 {
                 	return update_type;
                 }
              
              	public void setUpdate_type(int update_type)
                 {
                 	this.update_type = update_type;
                 }
              
              	public String getAppviewid()
                 {
                 	return appviewid;
                 }
              
              	public void setAppviewid(String appviewid)
                 {
                 	this.appviewid = appviewid;
                 }
              
              	public int getApp_error_id()
                 {
                 	return app_error_id;
                 }
              
              	public void setApp_error_id(int app_error_id)
                 {
                 	this.app_error_id = app_error_id;
                 }
              
              	public String getMessage()
                 {
                 	return message;
                 }
              
              	public void setMessage(String message)
                 {
                 	this.message = message;
                 }
              
              	public String getTimestamp()
                 {
                 	return timestamp;
                 }
              
              	public void setTimestamp(String timestamp)
                 {
                 	this.timestamp = timestamp;
                 }
              
              	public int getStatus()
                 {
                 	return status;
                 }
              
              	public void setStatus(int status)
                 {
                 	this.status = status;
                 }
              
              	public String getTransaction_timestamp()
                 {
                 	return transaction_timestamp;
                 }
              
              	public void setTransaction_timestamp(String transaction_timestamp)
                 {
                 	this.transaction_timestamp = transaction_timestamp;
                 }
              
              	public String getLciinstanceid()
                 {
                 	return lciinstanceid;
                 }
              
              	public void setLciinstanceid(String lciinstanceid)
                 {
                 	this.lciinstanceid = lciinstanceid;
                 }
              
              	public int getAction()
                 {
                 	return action;
                 }
              
              	public void setAction(int action)
                 {
                 	this.action = action;
                 }
              }
              Client-side program
              Code:
              final DataSource ds = DataSource.get("distributionupdate");
              ...
              final IButton retryButton = new IButton("Retry");
              
              		retryButton.addClickHandler(new ClickHandler()
              		{
              			@Override
                       public void onClick(ClickEvent event)
                       {
              				for (final Record record: listGrid.getSelectedRecords())
              				{
              					ds.performCustomOperation("retryID", record, new DSCallback()
              					{
                 					@Override
                                public void execute(DSResponse response, Object rawData,
                                      DSRequest request)
                                {
                 	               listGrid.deselectRecord(record);
                 	               
                                }
                 				}, new DSRequest());
              				}
                       }
              		});

              Comment


                #8
                We're confused - your DataSource doesn't specify that a bean should be used. Are you doing something server-side to instantiate and populate this bean? If so, please show the code.

                Also, please use the "RPC" tab in the developer console to verify that the client is actually sending the information you think it is.

                Comment


                  #9
                  Yes, I have verified that the data is corrected using the "RPC" tab in the Developer Console that the entire record (every fields of the bean) is sent to the server).

                  As to my DataSource doesn't contain the bean that I am using, I thought you don't need it because I was following the "DataSourceDMI" example.

                  In the SupplyItemDMI.java of the above example, based on the following comment, I thought SmartGWT will auto create the bean by using Java Reflection.

                  I set a break point on every fields in the bean and Eclipse did stop at the only field that is populated. It seems the Reflection is not working correctly. I tried to download the source code so I can debug but can't find the particular file that handle this.

                  SupplyItemDMI.java
                  Code:
                      // Declared parameters of the method are automatically provided.  For example, if your
                      // method declares a parameter of type HttpServletRequest, the current HttpServletRequest
                      // will be passed.
                      // If you declare a parameter that is a Java Bean, SmartClient will create an instance of
                      // the bean and apply the DSRequest data to the bean via Java reflection, matching
                      // DataSource fields to Java setter methods.  For example, for the DataSource field
                      // "itemName", SupplyItem.setItemName() is called.
                      public SupplyItem add(SupplyItem record)
                          throws Exception
                      {
                          log.info("procesing DMI add operation");
                  
                          // most ORM systems can store a new Object with a single call like this.
                          SupplyItemStore.storeItem(record);
                  
                          // return the record-as-saved so SmartClient can update client-side caches.  This
                          // pattern ensures client-side components receive server-generated fields (such as an
                          // auto-generated primaryKey value).  SmartClient can then update caches in place
                          // instead of re-fetching data.
                          return record;
                      }
                  my server side code
                  Code:
                     public DistributionUpdate retry(DistributionUpdate record) throws Exception
                     {
                  	return record;
                     }

                  Comment


                    #10
                    Hi Isomorphic,

                    Just wondering whether you have an answer to my question.

                    Thanks.

                    Comment


                      #11
                      A local test with a DMI that accepts a Javabean auto-populated by the framework from record data sent up from the client is working OK for us. If you can provide a minimal, self-contained, runnable example that demonstrates the problem, we'll take another look.

                      Comment

                      Working...
                      X