Source:
<code>public void apply( WorkspaceConfigImpl workspaceConfig, ComponentImpl pluginComponent, @Nullable FileContentProvider contentProvider) throws DevfileException { checkArgument(workspaceConfig != null, "Workspace config must not be null"); checkArgument(pluginComponent != null, "Component must not be null"); checkArgument( PLUGIN_COMPONENT_TYPE.equals(pluginComponent.getType()), format("Plugin must have `%s` type", PLUGIN_COMPONENT_TYPE)); String workspacePluginsAttribute = workspaceConfig.getAttributes().get(WORKSPACE_TOOLING_PLUGINS_ATTRIBUTE); final String pluginId = pluginComponent.getId(); final String registryUrl = pluginComponent.getRegistryUrl(); try { <START> URL tryUrl = new URL(pluginComponent.getId()); <END> pluginComponent.setReference(pluginComponent.getId()); } catch (MalformedURLException e) { } final ExtendedPluginFQN fqn = componentFQNParser.evaluateFQN(pluginComponent, contentProvider); if (!isNullOrEmpty(fqn.getReference())) { workspaceConfig .getAttributes() .put( WORKSPACE_TOOLING_PLUGINS_ATTRIBUTE, append(workspacePluginsAttribute, fqn.getReference())); } else { workspaceConfig .getAttributes() .put( WORKSPACE_TOOLING_PLUGINS_ATTRIBUTE, append( workspacePluginsAttribute, componentFQNParser.getCompositeId(registryUrl, pluginId))); } for (CommandImpl command : workspaceConfig.getCommands()) { String commandComponent = command.getAttributes().get(COMPONENT_ALIAS_COMMAND_ATTRIBUTE); if (commandComponent == null) { continue; } if (!commandComponent.equals(pluginComponent.getAlias())) { continue; } command.getAttributes().put(PLUGIN_ATTRIBUTE, fqn.getId()); } pluginComponent.setId(fqn.getId()); }</code><technical_language>cool if test case for it</technical_language>

Target:
public void apply( WorkspaceConfigImpl workspaceConfig, ComponentImpl pluginComponent, @Nullable FileContentProvider contentProvider) throws DevfileException { checkArgument(workspaceConfig != null, "Workspace config must not be null"); checkArgument(pluginComponent != null, "Component must not be null"); checkArgument( PLUGIN_COMPONENT_TYPE.equals(pluginComponent.getType()), format("Plugin must have `%s` type", PLUGIN_COMPONENT_TYPE)); String workspacePluginsAttribute = workspaceConfig.getAttributes().get(WORKSPACE_TOOLING_PLUGINS_ATTRIBUTE); final String pluginId = pluginComponent.getId(); final String registryUrl = pluginComponent.getRegistryUrl(); final ExtendedPluginFQN fqn = componentFQNParser.evaluateFQN(pluginComponent, contentProvider); if (!isNullOrEmpty(fqn.getReference())) { workspaceConfig .getAttributes() .put( WORKSPACE_TOOLING_PLUGINS_ATTRIBUTE, append(workspacePluginsAttribute, fqn.getReference())); } else { workspaceConfig .getAttributes() .put( WORKSPACE_TOOLING_PLUGINS_ATTRIBUTE, append( workspacePluginsAttribute, componentFQNParser.getCompositeId(registryUrl, pluginId))); } for (CommandImpl command : workspaceConfig.getCommands()) { String commandComponent = command.getAttributes().get(COMPONENT_ALIAS_COMMAND_ATTRIBUTE); if (commandComponent == null) { continue; } if (!commandComponent.equals(pluginComponent.getAlias())) { continue; } command.getAttributes().put(PLUGIN_ATTRIBUTE, fqn.getId()); } pluginComponent.setId(fqn.getId()); }