O'Reilly logo

Apache OFBiz Cookbook by Ruth Hoffman

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Writing OFBiz Java Services

OFBiz "Services" are reusable code snippets implemented as Java methods. What makes using OFBiz Services so compelling? Unlike OFBiz Events or servlets, the Service context is controlled by OFBiz, thus relieving the programmer from having to do such mundane tasks as managing transactions, handling retries, and validating input and output values. Once written, a Service may be invoked as many times and by as many Service consumers as required.

Getting ready

To start writing Services, we must first perform the following:

  1. Navigate to the Component's source directory containing the Java class file to be used for the new Service method.
  2. Check for any Java class or JAR file dependencies in the build.xml file.
  3. To test your Service, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required