Unused Resources

The view displays unused resources from selected module and its dependent modules.

To display a module's unused resources, right-click the module and select Dependency Visualizer > Find Unused Resources. The Unused Resources view is displayed.

On the Unused Resources view, the total number of unused resources is displayed. This includes:
  • Process
  • Schemas
  • WSDL
  • Shared Resource
  • Policy
  • Job Shared Variables
  • Module Shared Variables

The Include Application Modules check box is now removed from the Unused Resources view. Implicitly, application modules are included during unused resources calculation. When calculating unused resources for application modules, associated shared modules are also considered.

If you add, remove, or re-factor unused resources in the application and you need to find unused resources again, use Refresh button in the Unused Resources view to get the updated unused resources. Refresh operation takes some time when using with large projects.

If you remove or close any project from the Project Explorer view, the Unused Resources view is cleared.

To delete unused resources by type, select the resource and right-click > Delete.

When you try to delete an unused artifact which has dependencies as well as references on the other unused artifacts, a new Delete unused resources dialog box opens.

It shows the list of selected resources. To see the list of corresponding dependencies, click Preview button. To delete dependent resources, click Ok.

To delete all the unused resources together in one go, select all the resources and right-click > Delete. However, you need to repeat this process more than once to remove all unused resources.

Generate EAR without unused resources

To generate an application archive file (.EAR) without unused resources, select the BusinessWorks > Deployment > Exclude unused resources from packaging check box in the Preferences dialog box.

When you create an .EAR file, preview of unused resources is displayed in the Create Application Archive wizard.

An .EAR file is generated without unused resources.

From CLI, use -removeunused argument for export command in the bwdesign utility. For more information, see Using bwdesign utility.