Step 5: Launching the Vendor Application

In this step the application will be launched from within the Eclipse IDE and tested using the OSGi console.

  1. Select Run > Run... to open the Run dialog.
  2. Select the launch configuration you created in Step 5 of the previous tutorial.
  3. On the Plug-ins page, under Workspace Plug-ins confirm that the checkboxes to the left of the projects we developed during the tutorial are checked:
  4. Under the Start column, select false for both the org.eclipse.soda.sat.tutorial.vendor.hotdog bundle and the org.eclipse.soda.sat.tutorial.vendor.popcorn bundle. This will prevent these bundles from starting automatically when we launch the application.
  5. Create plug-in project

  6. Turn to the Arguments page and add -Dorg.eclipse.soda.sat.core.util.trace=true to the VM arguments field. This enables SAT's tracing capability that will provide additional information with regards to why an imported service was not acquired.
  7. Arguments

  8. Click the Run button to launch the Equinox OSGi Framework.
  9. In the Eclipse Console view you will see output very similar to the following:
    [DEBUG] - SAT Core: The bundle org.eclipse.soda.sat.core failed to acquire the service
              org.osgi.service.log.LogService.
              
    [INFO]  - The Customer bundle has been started
    
    [DEBUG] - SAT Core: The bundle org.eclipse.soda.sat.tutorial.customer failed to acquire the
              service org.eclipse.soda.sat.tutorial.vendor.service.VendorService matching the
              filter "(spiciness<=8)".
    
  10. These [DEBUG] messages designed to help understand why a bundle failed to acquire an imported service. You can safely ignore the first [DEBUG] message, since SAT optionally imports the LogService, which in this case is not available.
  11. The second [DEBUG] message is more interesting in that it is saying that the org.eclipse.soda.sat.tutorial.customer bundle failed to acquire a VendorService with a spiciness property of less than or equal to 8. Since we have not yet started either of the bundles that export a VendorService this is hardly surprising.