SpaceJump
SpaceJump

Reputation: 483

Hybris Commerce - How to expose Web Services

I'm fairly new to Hybris Commerce and its extensions. I installed Hybris 5.7 and 6 and (hopefully) installed the platformwebservices extensions this way:

<extension name='tomcatembeddedserver' />
<extension name='platformservices' />
<extension name='lucenesearch' />
<extension name='platformwebservices' />

In the admin UI under Platform/Extensions I see this:

enter image description here

What do those two red X mean for the platformwebservices extension. Are the rest services now exposed?

EDIT: It seems the services are running. But I get a 403 Forbidden response. This is what I enter with cUrl:

curl -u admin:nimda http://localhost:9001/ws410/rest/countries

Upvotes: 0

Views: 5153

Answers (3)

SpaceJump
SpaceJump

Reputation: 483

Found the solution: It seems that the admin user was not part of the webservicegroup. After performing a system update with "Create essential data" checkbox checked, that usergroup was created and it finally worked.

Upvotes: 1

Benoit Vanalderweireldt
Benoit Vanalderweireldt

Reputation: 2989

They mean :

  • No "coremodule" for this extension ("A core module consists of an items.xml file, a manager class, classes for the JaLo Layer and the ServiceLayer and JUnit test classes. The following directories are required: /src, /resources, /testsrc")
  • No "hmcmodule" for this extension ("Configures an hMC module for the extension. Required directory: /hmc.Used to configure the HMC")

So yes they are exposed from an extension that doesn't have a core and hmc module that's all.

Upvotes: 1

Abubakkar
Abubakkar

Reputation: 15644

It just says whether that particular extension contains that hyrbis module or not.

You could see it to the right on small panel on the same screen as mentioned in your question.

Hybris Info

I am not sure exactly how platformwebservices extension work as I never used it.

Regarding webservices, you need to add webmodule to your extension and then you can use spring based controllers to expose webservices. Might need to add following line to your extensions info to add webmodule.

<webmodule jspcompile="false" webroot="/rest" />

Upvotes: 0

Related Questions