Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 832447

Summary: WSRP type factories require a lang value to create a Property even though it's optional according to XSD
Product: [JBoss] JBoss Enterprise Portal Platform 5 Reporter: Martin Weiler <mweiler>
Component: PortalAssignee: Thomas Heute <theute>
Status: CLOSED UPSTREAM QA Contact:
Severity: high Docs Contact:
Priority: high    
Version: 5.2.1.GACC: epp-bugs, mvecera
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2025-02-10 03:20:09 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Martin Weiler 2012-06-15 12:26:52 UTC
Description of problem:
Issuing a request such as setPortletProperties, including a properties element without 'lang' attribute, is rejected on the server.

Example request:

<env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'>
 <env:Header/>
 <env:Body>
  <v1:setPortletProperties xmlns:v1='urn:oasis:names:tc:wsrp:v1:types'>
   <v1:registrationContext xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:nil='true'/>
   <v1:portletContext>
    <v1:portletHandle>_efbab2d27f0000012637246a5e865a57</v1:portletHandle>
   </v1:portletContext>
   <v1:userContext>
    <v1:userContextKey>foo</v1:userContextKey>
   </v1:userContext>
   <v1:propertyList>
    <v1:properties name='GREETING'>
     <v1:stringValue>false</v1:stringValue>
    </v1:properties>
   </v1:propertyList>
  </v1:setPortletProperties>
 </env:Body>
</env:Envelope>

How reproducible:
Always
  
Actual results:
ERROR [SOAPFaultHelperJAXWS] SOAP request exception
java.lang.IllegalArgumentException: Property requires a non-null, non-empty language
	at org.gatein.common.util.ParameterValidation.throwIllegalArgExceptionIfNullOrEmpty(ParameterValidation.java:116)
	at org.gatein.wsrp.WSRPTypeFactory.createProperty(WSRPTypeFactory.java:741)
	at org.gatein.wsrp.WSRPTypeFactory.createProperty(WSRPTypeFactory.java:735)
	at org.gatein.wsrp.spec.v1.V1ToV2Converter$V1ToV2Property.apply(V1ToV2Converter.java:1296)
	at org.gatein.wsrp.spec.v1.V1ToV2Converter$V1ToV2Property.apply(V1ToV2Converter.java:1290)
	at com.google.common.collect.Lists$TransformingRandomAccessList.get(Lists.java:448)
	at java.util.AbstractList$Itr.next(AbstractList.java:345)
	at java.util.AbstractCollection.toArray(AbstractCollection.java:124)
	at java.util.ArrayList.addAll(ArrayList.java:472)
	at org.gatein.wsrp.spec.v1.V1ToV2Converter.toV2PropertyList(V1ToV2Converter.java:684)
	at org.gatein.wsrp.endpoints.v1.PortletManagementEndpoint.setPortletProperties(PortletManagementEndpoint.java:174)

Expected results:
setPortletProperties method should get invoked successfully if optional lang parameter is missing in the request.

Comment 1 Michal Vanco 2012-06-19 10:31:38 UTC
See comment at https://bugzilla.redhat.com/show_bug.cgi?id=832887#c6

Comment 3 Red Hat Bugzilla 2025-02-10 03:20:09 UTC
This product has been discontinued or is no longer tracked in Red Hat Bugzilla.