IBM Support

JR46590: CMVC 228330 - Developing SOI overlays with REST services results in an IllegalArgumentException

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • Websphere Commerce does not currently support SOI overlays on
    REST services.  When combining the overlay approach with
    extending the service client library, an
    IllegalArgumentException is seen when processing a custom
    element:
    
     3/8/13 13:03:44:049 CST] 00000039 resourcehandl E
    com.ibm.commerce.foundation.rest.resourcehandler.AbstractResourc
    eHandler handleException CWXFR0200E: The following exception
    occurred in method splitOrderItems:
    java.lang.IllegalArgumentException: Class 'OrderType' does not
    have a feature named 'elementname'.
     [3/8/13 13:03:44:049 CST] 00000039 SystemErr     R
    java.lang.IllegalArgumentException: Class 'OrderType' does not
    have a feature named 'elementname'
     [3/8/13 13:03:44:049 CST] 00000039 SystemErr     R     at
    org.eclipse.emf.ecore.sdo.util.SDOUtil$Accessor.setFeatureName(S
    DOUtil.java:891)
     [3/8/13 13:03:44:049 CST] 00000039 SystemErr     R     at
    org.eclipse.emf.ecore.sdo.util.SDOUtil$Accessor.process(SDOUtil.
    java:1077)
     [3/8/13 13:03:44:049 CST] 00000039 SystemErr     R     at
    org.eclipse.emf.ecore.sdo.util.SDOUtil$Accessor.init(SDOUtil.jav
    a:758)
     [3/8/13 13:03:44:049 CST] 00000039 SystemErr     R     at
    org.eclipse.emf.ecore.sdo.util.SDOUtil$Accessor.create(SDOUtil.j
    ava:678)
     [3/8/13 13:03:44:049 CST] 00000039 SystemErr     R     at
    org.eclipse.emf.ecore.sdo.util.SDOUtil.get(SDOUtil.java:195)
     [3/8/13 13:03:44:049 CST] 00000039 SystemErr     R     at
    org.eclipse.emf.ecore.sdo.impl.EDataObjectImpl.get(EDataObjectIm
    pl.java:95)
     [3/8/13 13:03:44:049 CST] 00000039 SystemErr     R     at
    com.ibm.commerce.foundation.rest.bodmapping.BODMappingUtility.se
    tNormalData(BODMappingUtility.java:876)
    

Local fix

Problem summary

Problem conclusion

  • When the custom element is being processed by REST, a warning
    will be logged in the trace file instead of throwing an
    exception.  REST will invoke the new customizable facade client
    methods instead of the existing facade client methods for
    ChangePerson, ProcessPerson, ChangeOrder and ProcessOrder
    requests.
    
     Existing facade client methods REST currently invokes:
     RespondOrderType changeOrder(ChangeOrderType aChangeOrder);
     AcknowledgeOrderType processOrder(ProcessOrderType
    aProcessOrder);
     RespondPersonType changePerson(ChangePersonType aChangePerson);
     AcknowledgePersonType processPerson(ProcessPersonType
    aProcessPerson);
    
     New facade client methods REST will be calling:
     RespondOrderType changeOrder(ChangeOrderType aChangeOrder,
    Map<String, String[]> transformedRestRequestMap);
     AcknowledgeOrderType processOrder(ProcessOrderType
    aProcessOrder, Map<String, String[]> transformedRestRequestMap);
     RespondPersonType changePerson(ChangePersonType aChangePerson,
    Map<String, String[]> transformedRestRequestMap);
     AcknowledgePersonType processPerson(ProcessPersonType
    aProcessPerson, Map<String, String[]>
    transformedRestRequestMap);
    
     The new facade client methods have references to both the BOD
    created by Commerce and a hash map containing the REST request
    inputs.  A custom facade client can implement new facade client
    methods to create a final version of the BOD that also contains
    the custom elements before the BOD is sent for processing.
    
     The new facade client methods will be invoked when one of the
    REST requests listed below is invoked:
     CartHandler
           addOrderItem
           udpateOrderItem
     PaymentInstructionHandler
           addPaymentInstruction
           updatePaymentInstruction
     ShippingInfoHandler
           updateOrderShippingInfo
    
     PersonCheckoutProfileHandler
           updateCheckoutProfile
     PersonContactHandler
           addPersonContact
           updatePersonContact
     PersonHandler
           registerPerson
           updatePerson
    
     -------------------------------------------------------------
     The latest available maintenance information can be obtained
    from the Recommended Fixes for WebSphere Commerce technote:
     http://www.ibm.com/support/docview.wss?rs=3046&uid=swg21261296
    

Temporary fix

Comments

APAR Information

  • APAR number

    JR46590

  • Reported component name

    WC BUS EDITION

  • Reported component ID

    5724I3800

  • Reported release

    700

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt

  • Submitted date

    2013-05-08

  • Closed date

    2013-08-13

  • Last modified date

    2013-08-13

  • APAR is sysrouted FROM one or more of the following:

  • APAR is sysrouted TO one or more of the following:

Fix information

  • Fixed component name

    WC BUS EDITION

  • Fixed component ID

    5724I3800

Applicable component levels

  • R700 PSY

       UP

[{"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSYSYL","label":"WebSphere Commerce Enterprise"},"Component":"","ARM Category":[],"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"7.0","Edition":"","Line of Business":{"code":"","label":""}}]

Document Information

Modified date:
13 August 2013