facebook

Problems Starting WebSphere4 from Eclipse

💡
Our Forums Have Moved

For help with installation, bugs reports or feature requests, please head over to our new forums.
Genuitec Community on GitHub

  1. MyEclipse IDE
  2.  > 
  3. General Development
Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
    Posts
  • #196589 Reply

    dkraus
    Member

    I recently downloaded a copy of MyEclipse for evaluation.

    Has anyone had a problem trying to start WebSphere4 from inside Eclipse for the purpose of stepping through code? I getting a NullPointerException when the application server’s xml configuration file is read. Is there any documentation on this topic? Below is the error message:

    WSVR0008E: Error encountered reading C:\WebSphere\AppServer\config\plugin-cfg.xml
    java.lang.NullPointerException

    at com.ibm.xmi.base.impl.XMIFactoryImpl.load(XMIFactoryImpl.java:259)
    at com.ibm.etools.emf.resource.impl.ResourceFactoryImpl.load(ResourceFactoryImpl.java:91)
    at com.ibm.etools.emf.resource.impl.ResourceFactoryImpl.load(ResourceFactoryImpl.java:79)
    at com.ibm.etools.emf.resource.impl.ResourceSetImpl.load(ResourceSetImpl.java:225)
    at com.ibm.ws.runtime.StandardServer.readConfig(StandardServer.java:463)
    at com.ibm.ws.runtime.StandardServer.readConfig(StandardServer.java:247)
    at com.ibm.ws.runtime.StandardServer.parseCommandLine(StandardServer.java:234)
    at com.ibm.ws.runtime.StandardServer.parseConfig(StandardServer.java:152)
    at com.ibm.ws.runtime.StandardServer.main(StandardServer.java:516)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.ibm.ws.bootstrap.WSLauncher.main(WSLauncher.java:158)

    java.lang.Throwable
    at com.ibm.ejs.ras.TraceEventGeneratorImpl.fireTraceEvent(Tr.java:1570)
    at com.ibm.ejs.ras.TraceEventGeneratorImpl.fireTraceEvent(Tr.java:1455)
    at com.ibm.ejs.ras.Tr.fatal(Tr.java:933)
    at com.ibm.ws.runtime.StandardServer.readConfig(StandardServer.java:476)
    at com.ibm.ws.runtime.StandardServer.readConfig(StandardServer.java:247)
    at com.ibm.ws.runtime.StandardServer.parseCommandLine(StandardServer.java:234)
    at com.ibm.ws.runtime.StandardServer.parseConfig(StandardServer.java:152)
    at com.ibm.ws.runtime.StandardServer.main(StandardServer.java:516)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.ibm.ws.bootstrap.WSLauncher.main(WSLauncher.java:158)

    #196590

    Scott Anderson
    Participant

    This problem looks like an error on your WebSphere domain. Have you tried starting WebSphere outside of MyEclipse to verify that it will run this domain properly?

    Other things to check:
    Give a look at example configuration for WebSphere4 here: http://www.myeclipseide.com/modules.php?op=modload&name=FAQ&file=index&myfaq=yes&id_cat=20&categories=WebSphere&parent_id=14#14

    On the JDK page, did you specify IBM’s JDK for use with WebSphere? You should point to the top-level directory for it (java), not the internal ‘jre’ subdirectory.

    –Scott
    MyEclipse Support

    #196595

    dkraus
    Member

    I have been successfully running WebSphere outside of the MyEclipse domain.

    I have configured the JDK at the top level, and have used the JDK which exists at “websphere\appserver\java”.

    My config file is “websphere\appserver\config\plugin-cfg.xml”. It is the only xml file in this directory. Could not find a server-cfg.xml file anywhere.

    The contents of this file are:

    <?xml version=”1.0″?>
    <Config>
    <Log LogLevel=”Error” Name=”c:/WebSphere/AppServer/logs/native.log”/>
    <VirtualHostGroup Name=”default_host”>
    <VirtualHost Name=”*:80″/>
    <VirtualHost Name=”*:9080″/>
    </VirtualHostGroup>
    <ServerGroup Name=”PTCPIK/Default Server”>
    <Server CloneID=”unu1pp4s” Name=”Default Server”>
    <Transport Hostname=”PTCPIK” Port=”9080″ Protocol=”http”/>
    </Server>
    </ServerGroup>
    <UriGroup Name=”PTCPIK_sampleApp/default_app_URIs”>
    <Uri AffinityCookie=”JSESSIONID” Name=”/servlet/snoop/*”/>
    <Uri AffinityCookie=”JSESSIONID” Name=”/servlet/snoop2/*”/>
    <Uri AffinityCookie=”JSESSIONID” Name=”/servlet/hello”/>
    <Uri AffinityCookie=”JSESSIONID” Name=”/ErrorReporter”/>
    <Uri AffinityCookie=”JSESSIONID” Name=”*.jsp”/>
    <Uri AffinityCookie=”JSESSIONID” Name=”*.jsv”/>
    <Uri AffinityCookie=”JSESSIONID” Name=”*.jsw”/>
    <Uri AffinityCookie=”JSESSIONID” Name=”/j_security_check”/>
    <Uri AffinityCookie=”JSESSIONID” Name=”/servlet/*”/>
    </UriGroup>
    <UriGroup Name=”PTCPIK_sampleApp/examples_URIs”>
    <Uri Name=”/webapp/examples/*”/>
    </UriGroup>
    <ServerGroup Name=”PTCPIK/WebSphere Portal”>
    <Server CloneID=”unu1seri” Name=”WebSphere Portal”>
    <Transport Hostname=”PTCPIK” Port=”9081″ Protocol=”http”/>
    </Server>
    </ServerGroup>
    <UriGroup Name=”Personalization Runtime/PersAdmin_URIs”>
    <Uri Name=”/wps/PersAdmin/*”/>
    </UriGroup>
    <UriGroup Name=”Personalization Email/Personalize Email_URIs”>
    <Uri Name=”/wps/PersEmail/*”/>
    </UriGroup>
    <UriGroup Name=”WPS Enterprise Application/wps.war_URIs”>
    <Uri Name=”/wps/*”/>
    </UriGroup>
    <UriGroup Name=”WS Proxy/wsproxy.war_URIs”>
    <Uri Name=”/wps/wsproxy/*”/>
    </UriGroup>
    <Route ServerGroup=”PTCPIK/Default Server”
    UriGroup=”PTCPIK_sampleApp/default_app_URIs” VirtualHostGroup=”default_host”/>
    <Route ServerGroup=”PTCPIK/Default Server”
    UriGroup=”PTCPIK_sampleApp/examples_URIs” VirtualHostGroup=”default_host”/>
    <Route ServerGroup=”PTCPIK/WebSphere Portal”
    UriGroup=”Personalization Runtime/PersAdmin_URIs” VirtualHostGroup=”default_host”/>
    <Route ServerGroup=”PTCPIK/WebSphere Portal”
    UriGroup=”Personalization Email/Personalize Email_URIs” VirtualHostGroup=”default_host”/>
    <Route ServerGroup=”PTCPIK/WebSphere Portal”
    UriGroup=”WPS Enterprise Application/wps.war_URIs” VirtualHostGroup=”default_host”/>
    <Route ServerGroup=”PTCPIK/WebSphere Portal”
    UriGroup=”WS Proxy/wsproxy.war_URIs” VirtualHostGroup=”default_host”/>
    </Config>

    #196596

    dkraus
    Member

    Contents of xml file was garbled in last attempt. try one more time.

    <?xml version=”1.0″?>
    <Config>
    <Log LogLevel=”Error” Name=”c:/WebSphere/AppServer/logs/native.log”/>
    <VirtualHostGroup Name=”default_host”>
    <VirtualHost Name=”*:80″/>
    <VirtualHost Name=”*:9080″/>
    </VirtualHostGroup>
    <ServerGroup Name=”PTCPIK/Default Server”>
    <Server CloneID=”unu1pp4s” Name=”Default Server”>
    <Transport Hostname=”PTCPIK” Port=”9080″ Protocol=”http”/>
    </Server>
    </ServerGroup>
    <UriGroup Name=”PTCPIK_sampleApp/default_app_URIs”>
    <Uri AffinityCookie=”JSESSIONID” Name=”/servlet/snoop/*”/>
    <Uri AffinityCookie=”JSESSIONID” Name=”/servlet/snoop2/*”/>
    <Uri AffinityCookie=”JSESSIONID” Name=”/servlet/hello”/>
    <Uri AffinityCookie=”JSESSIONID” Name=”/ErrorReporter”/>
    <Uri AffinityCookie=”JSESSIONID” Name=”*.jsp”/>
    <Uri AffinityCookie=”JSESSIONID” Name=”*.jsv”/>
    <Uri AffinityCookie=”JSESSIONID” Name=”*.jsw”/>
    <Uri AffinityCookie=”JSESSIONID” Name=”/j_security_check”/>
    <Uri AffinityCookie=”JSESSIONID” Name=”/servlet/*”/>
    </UriGroup>
    <UriGroup Name=”PTCPIK_sampleApp/examples_URIs”>
    <Uri Name=”/webapp/examples/*”/>
    </UriGroup>
    <ServerGroup Name=”PTCPIK/WebSphere Portal”>
    <Server CloneID=”unu1seri” Name=”WebSphere Portal”>
    <Transport Hostname=”PTCPIK” Port=”9081″ Protocol=”http”/>
    </Server>
    </ServerGroup>
    <UriGroup Name=”Personalization Runtime/PersAdmin_URIs”>
    <Uri Name=”/wps/PersAdmin/*”/>
    </UriGroup>
    <UriGroup Name=”Personalization Email/Personalize Email_URIs”>
    <Uri Name=”/wps/PersEmail/*”/>
    </UriGroup>
    <UriGroup Name=”WPS Enterprise Application/wps.war_URIs”>
    <Uri Name=”/wps/*”/>
    </UriGroup>
    <UriGroup Name=”WS Proxy/wsproxy.war_URIs”>
    <Uri Name=”/wps/wsproxy/*”/>
    </UriGroup>
    <Route ServerGroup=”PTCPIK/Default Server”
    UriGroup=”PTCPIK_sampleApp/default_app_URIs” VirtualHostGroup=”default_host”/>
    <Route ServerGroup=”PTCPIK/Default Server”
    UriGroup=”PTCPIK_sampleApp/examples_URIs” VirtualHostGroup=”default_host”/>
    <Route ServerGroup=”PTCPIK/WebSphere Portal”
    UriGroup=”Personalization Runtime/PersAdmin_URIs” VirtualHostGroup=”default_host”/>
    <Route ServerGroup=”PTCPIK/WebSphere Portal”
    UriGroup=”Personalization Email/Personalize Email_URIs” VirtualHostGroup=”default_host”/>
    <Route ServerGroup=”PTCPIK/WebSphere Portal”
    UriGroup=”WPS Enterprise Application/wps.war_URIs” VirtualHostGroup=”default_host”/>
    <Route ServerGroup=”PTCPIK/WebSphere Portal”
    UriGroup=”WS Proxy/wsproxy.war_URIs” VirtualHostGroup=”default_host”/>
    </Config>

    #196597

    Scott Anderson
    Participant

    The problem you’re seeing is caused by specifying a plugin-cfg.xml file where a server-cfg.xml file is expected. That’s why WebSphere is throwing the NPE. In my WAS 4 config directory I have the following files, which were placed there at installation:
    admin-server-cfg.xml
    plugin-cfg.xml
    resource-provider-templates.xml
    server-cfg.xml
    template-server-cfg.xml

    server-cfg.xml is the main server configuration file. Ah, are you perhaps running the AE version of WebSphere 4, rather than the standard edition?

    –Scott
    MyEclipse Support

    #196598

    dkraus
    Member

    I didn’t actually obtain WebSphere myself. Another person in my group did. They told me it was a trimmed down version.

    When I click on “About” on the administrators console, this is what is displayed…

    Advanced Edition for MultiPlatforms version 4.0.4

    #196599

    Scott Anderson
    Participant

    That explains it. The advanced edition has a completely different launch model and we don’t support debugging with it. Of course, IBM doesn’t either, even in WSAD, if I remember correctly.

    To debug your application you’ll need the “real” trimmed down version which is plain old WebSphere Application Server v4.0 (or 5.0).

    –Scott
    MyEclipse Support

    #196602

    dkraus
    Member

    My cohort thinks that he ordered the WebSphere AE version because AEd and AEs didn’t support portal development.

    Does anyone know anything about this?

    #196603

    Scott Anderson
    Participant

    Unfortunately, I don’t have any experience with IBM’s portal products. However, you might try asking on one of IBM’s websphere user groups. Their NNTP server is news.software.ibm.com

    –Scott
    MyEclipse Support

    #216964

    Roc
    Member

    I meet the same program.

    I find some message at this address.

    http://publib.boulder.ibm.com/infocenter/wsphelp/index.jsp?topic=/com.ibm.websphere.nd.doc/info/ae/ae/rins_portnumber.html

    Could you help me,Scott?

    #216982

    Scott Anderson
    Participant

    Roc,

    We only support WebSphere Application Server Advanced Single Server Edition, Version 4.0.x in MyEclipse, which is configured with
    a server-cfg.xml file. You’re using WebSphere Application Server Advanced Edition, Version 4.0.x which is configured by a database.
    From the link you specified, it might be possible to extract the configuration into a server-cfg.xml file from the database, but I have
    no experience in doing that and it isn’t explicitly supported. If you find a method that works, please post it back here as I’m sure it
    would prove to be of interest to other users.

Viewing 11 posts - 1 through 11 (of 11 total)
Reply To: Problems Starting WebSphere4 from Eclipse

You must be logged in to post in the forum log in