Skip to main content



      Home
Home » Eclipse Projects » Rich Client Platform (RCP) » n00b RCP deployment problem
n00b RCP deployment problem [message #463808] Thu, 15 February 2007 15:08 Go to next message
Eclipse UserFriend
Originally posted by: null.bitbucket.net

Hi everyone,

I'm running into a deployment-related exception when I use the export
wizard on my Eclipse RCP project's .product and launch the resulting win32
executable. For now the product is based on plug-ins, just to keep it
simple. I have my project's plug-in and clicked the "add required
plug-ins" button. After I run the export wizard, I can see my
Activator.class in my plug-in's jar file under the <deployment>/plugins
directory.

Running the project from within Eclipse (debug and release) are working
fine; it's running from the launcher that's failing. Any ideas what I'm
doing wrong here?


!SESSION 2007-02-15 11:46:59.304
-----------------------------------------------
eclipse.buildId=unknown
java.version=1.5.0_06
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_US
Command-line arguments: -os win32 -ws win32 -arch x86

!ENTRY org.eclipse.osgi 4 0 2007-02-15 11:47:00.382
!MESSAGE An error occurred while automatically activating bundle <snip>(5).
!STACK 0
org.osgi.framework.BundleException: The activator <snip>.Activator for
bundle <snip> is invalid
at
org.eclipse.osgi.framework.internal.core.AbstractBundle.load BundleActivator(AbstractBundle.java:141)

<snip>...

Root exception:
java.lang.ClassNotFoundException: <snip>.Activator
at
org.eclipse.osgi.framework.internal.core.BundleLoader.findCl ass(BundleLoader.java:402)
<snip>...
more info: n00b RCP deployment problem [message #463816 is a reply to message #463808] Thu, 15 February 2007 16:59 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: null.bitbucket.net

If it'll help, here's the code for my activator class. It's pretty much
straight modified from the Eclipse RCP book:

package <snip>;

import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.ui.plugin.AbstractUIPlugin;
import org.osgi.framework.BundleContext;

/**
* The activator class controls the plug-in life cycle
*/
public class Activator extends AbstractUIPlugin {

// The plug-in ID
public static final String PLUGIN_ID = "<snip>";

// The shared instance
private static Activator plugin;

/**
* The constructor
*/
public Activator() {
plugin = this;
}

/*
* (non-Javadoc)
* @see
org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framew ork.BundleContext)
*/
public void start(BundleContext context) throws Exception {
super.start(context);
}

/*
* (non-Javadoc)
* @see
org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framewo rk.BundleContext)
*/
public void stop(BundleContext context) throws Exception {
plugin = null;
super.stop(context);
}

/**
* Returns the shared instance
*
* @return the shared instance
*/
public static Activator getDefault() {
return plugin;
}

/**
* Returns an image descriptor for the image file at the given
* plug-in relative path
*
* @param path the path
* @return the image descriptor
*/
public static ImageDescriptor getImageDescriptor(String path) {
return imageDescriptorFromPlugin(PLUGIN_ID, path);
}
}
Fixed: n00b RCP deployment problem [message #463818 is a reply to message #463816] Thu, 15 February 2007 19:24 Go to previous message
Eclipse UserFriend
Originally posted by: null.bitbucket.net

Hi everyone,

I managed to track it down - there was a problem in my build.properties
file that was placing my Activator.class file in the wrong path.

FYI - in case someone else runs into the same problem, I ended up fixing
it by going back to the bare-bones distribution in the RCP tutorial part 1
( http://www.eclipse.org/articles/Article-RCP-1/tutorial1.html), making
sure I could get that to deploy, then comparing the directories in the
plugin.xml, <x>.product and build.properties to see if there was anything
fishy.

-caffeinated
Previous Topic:Starting an RCP app invisibly
Next Topic:Invoke default editor on mouse double-click
Goto Forum:
  


Current Time: Mon Apr 14 18:05:33 EDT 2025

Powered by FUDForum. Page generated in 0.22699 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top