Skip to Content
author's profile photo Former Member
Former Member

Customizing ycommcercewebservices by creating new extension using hybris 5.2

Hi, In order to customize ycommercewebservices, I have created an extension by extgen using ycommercewebservices template. After that I have: 1. commented out ycommercewebservices from /config/localextensions.xml 2. Added newly created custom commercewebservice extension in /config/localextensions.xml 3. Added webservice root context in project.properties like below commercewebservices.rootcontext=/whitespacecommercewebservices/v1/ 4. Commented out all items of ycommercewebservice-items.xml, since it was errors for duplication item types. 5. Removed from customextension-web-spring.xml 6. Compiled the code and started hybrisserver 7. I am getting below exception in order to server start up. Please see the attached log file for more detailed exception.

Kindly suggest the resolution.

Regards, Punit Djwivedilink text

      org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'cartControllerV1': Injection of resource dependencies failed; nested exception is org.springframework.beans.factory.BeanNotOfRequiredTypeException: Bean named 'commerceStockFacade' must be of type [de.hybris.platform.ycommercewebservices.stock.CommerceStockFacade], but was actually of type [com.hybris.whitespace.stock.impl.DefaultCommerceStockFacade]

INFO | jvm 1 | main | 2014/12/15 19:20:41.570 | at org.springframework.context.annotation.CommonAnnotationBeanPostProcessor.postProcessPropertyValues(CommonAnnotationBeanPostProcessor.java:306)

1799-error-log.txt (78.1 kB)
Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Dec 15, 2014 at 09:05 PM

    Hello Punit,

    in the 1st step, you need to comment out ycommercewebserviceshmc extension also in localextension.xml, since ycommercewebserviceshmc requires ycommercewebservices. So In 4th step, you don't need to comment out items in ycommercewebservice-items.xml( this extension should not change). because you already comment out this extension in localextension.xm.

    I tried create a new ycommercewebservices use ant extgen, added it to localextension.xml and comment out ycommercewebservices and ycommercewebserviceshmc. Compile and start server without any problem. Also please do ant clean all to rebuild it.

    I hope this helps,

    Best Regards,

    Mingming

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Dec 16, 2014 at 10:15 AM

    Thanks for your valuable inputs. It is working fine now.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.