I am trying to configure a Glassfish server with MyEclipse 5.0 M2 but I always have a very long error log in the console. Most of the errors are NullPointerExceptions in ServerBeansFactory due to ServerBeansFactory.getServerBean(configContext) is returning “null”. Why?
public static Config getConfigModel(ConfigContext configContext) throws ConfigException {
74
75 //create the config bean for this instance
76 if (configContext != null) {
77 Server server = ServerBeansFactory.getServerBean(configContext);
78 String configRef = server.getConfigRef();
79 String configXpath = ServerXPathHelper.getConfigIdXpath(configRef);
80 configModel = (Config) ConfigBeansFactory.getConfigBeanByXPath(configContext, configXpath);
81 } else {
82 String msg = localStrings.getString(
83 "serverContext.config_context_is_null");
84 throw new ConfigException(msg);
85 }
86 return configModel;
87 }
The config i’m using for Glassfish connector is:
Home dir: /opt/glassfish
Config dir: /opt/glassfish/config
Server name: localhost
Domain name: domain1
Domain dir: /opt/glassfish/domains/domain1
Optional params: <nothing>
From the command line (as a regular user) i can start the server using:
/opt/glassfish/bin/asadmin start-domain domain1
Any ideas?
Thanks in advance,
JMB