CreatePartnerWebServiceModule

How to Create a Partner Web Service Module Using NetBeans 6.0

  1. Download, install and run the stable NetBeans 6.0 latest
  2. Invoke Tools > Plugins > Available Plugins and select 'RESTful Web Services' plugin to install
  3. Choose File > New Project. Under Categories, select NetBeans Modules. Select 'Module' project type. Click Next.
  4. In Name and Location step, specify values for Project Name and Project Location. Click Next.
  5. In Basic Module Configuration step specify your module code name base similar to package name format, e.g., com.thepartner.services.nbcomponents. Click OK to finish.
  6. Refer to REST Partner Service Registration page to create one component description (XML) for each service. Note also the section to modify layer.xml. Note that the example on the page is for WSDL-based service. For WADL based services, refer to attached 'Yahoo News Search' component file yahoo-ns_CreatePartnerWebServiceModule.xml and its WADL file yahoo-ns_CreatePartnerWebServiceModule.wadl.
  7. To install and test your service component NB module, right click on your project node and do: 'Install/Reload in Development IDE'. A confirmation dialog appear, click Yes. Create a RESTful Web Service sample project, and open CustomerResource class. The Component Palette should be visible on the right hand side and should contains your service components.
  8. For complete testing, drag-n-drop the component on to CustomerResource source editor. You should see default parameter dialog for generation of wrapper resource class, just click OK. The wrapper resource class is named 'XxxResource' for component Xxx. You need to review and do further customization to the resource GET method if needed. Finally, test run the service by right click on project CustomerDB and do 'Test RESTful Web Services'. You should see URI for top-level resource name 'xxx' in the left panel. Click on it and use the right panel to invoke GET XML representation. The GET invocation should return expected output.
  9. When all the components in the plugin are ready to ships, right click on your project node and do: 'Create NBM'. You can then use the created NBM for submission to NB plugin portal site. The location of the NBM file is in the build output window at the bottom of the IDE.


Check out this blog entry from Geertjan for a step by step example of using this framework. This blog walks you though integrating Dilbert service into this framework.

Not logged in. Log in, Register

By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo