unpredictable behavior

Help
Al Major
2004-11-16
2013-04-17
  • Al Major
    Al Major
    2004-11-16

    i'm using eclipse 3.1M3 with a large list of plugins.

    the plugin is working erratically. most of the time it does nothing. sometimes it generates part of the XMLBean java output.

    i did one run on a freshly started instance of eclipse so i could grab the logfile. schema file was immediately under the source directory. here's the log file

    !ENTRY uk.ltd.grian.eclipse.xmlbeans 1 1 2004-11-16 03:25:23.620
    !MESSAGE Starting EclipseXMLBeansPlugin

    !ENTRY uk.ltd.grian.eclipse.xmlbeans 1 1 2004-11-16 03:25:23.620
    !MESSAGE readStateFrom

    !ENTRY uk.ltd.grian.eclipse.xmlbeans 1 1 2004-11-16 03:25:23.620
    !MESSAGE Info unknown file in .project directory

    !ENTRY org.eclipse.core.runtime 4 2 2004-11-16 03:25:24.972
    !MESSAGE Problems occurred when invoking code from plug-in: "org.eclipse.core.runtime".
    !STACK 0
    java.lang.NullPointerException
        at uk.ltd.grian.eclipse.xmlbeans.XMLBeansSchemaImpl.getName(XMLBeansSchemaImpl.java:191)
        at uk.ltd.grian.eclipse.xmlbeans.XMLBeanBuilder.build(XMLBeanBuilder.java:260)
        at org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:574)
        at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:616)
        at org.eclipse.core.runtime.Platform.run(Platform.java:747)
        at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:158)
        at org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:314)
        at org.eclipse.core.internal.resources.Project.build(Project.java:81)
        at uk.ltd.grian.eclipse.xmlbeans.popup.actions.Generate$1.run(Generate.java:112)
        at org.eclipse.core.internal.jobs.Worker.run(Worker.java:66)

    !ENTRY uk.ltd.grian.eclipse.xmlbeans 4 1 2004-11-16 03:25:25.12
    !MESSAGE Exception in nature->run()
    !STACK 1
    org.eclipse.core.internal.resources.ResourceException: Errors during build.
        at org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:316)
        at org.eclipse.core.internal.resources.Project.build(Project.java:81)
        at uk.ltd.grian.eclipse.xmlbeans.popup.actions.Generate$1.run(Generate.java:112)
        at org.eclipse.core.internal.jobs.Worker.run(Worker.java:66)
    !SUBENTRY 1 org.eclipse.core.resources 2 566 2004-11-16 03:25:25.12
    !MESSAGE Errors during build.
    !SUBENTRY 2 uk.ltd.grian.eclipse.xmlbeans 2 75 2004-11-16 03:25:25.12
    !MESSAGE Errors running builder "XMLBean Builder" on project TradeZone.
    !SUBENTRY 2 uk.ltd.grian.eclipse.xmlbeans 2 75 2004-11-16 03:25:25.12
    !MESSAGE java.lang.NullPointerException encountered while running XMLBean Builder.
    !STACK 0
    java.lang.NullPointerException
        at uk.ltd.grian.eclipse.xmlbeans.XMLBeansSchemaImpl.getName(XMLBeansSchemaImpl.java:191)
        at uk.ltd.grian.eclipse.xmlbeans.XMLBeanBuilder.build(XMLBeanBuilder.java:260)
        at org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:574)
        at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:616)
        at org.eclipse.core.runtime.Platform.run(Platform.java:747)
        at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:158)
        at org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:314)
        at org.eclipse.core.internal.resources.Project.build(Project.java:81)
        at uk.ltd.grian.eclipse.xmlbeans.popup.actions.Generate$1.run(Generate.java:112)
        at org.eclipse.core.internal.jobs.Worker.run(Worker.java:66)

    !ENTRY org.eclipse.core.runtime 4 2 2004-11-16 03:25:27.25
    !MESSAGE Problems occurred when invoking code from plug-in: "org.eclipse.core.runtime".
    !STACK 0
    java.lang.NullPointerException
        at uk.ltd.grian.eclipse.xmlbeans.XMLBeansSchemaImpl.getName(XMLBeansSchemaImpl.java:191)
        at uk.ltd.grian.eclipse.xmlbeans.XMLBeanBuilder.build(XMLBeanBuilder.java:260)
        at org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:574)
        at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:616)
        at org.eclipse.core.runtime.Platform.run(Platform.java:747)
        at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:158)
        at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:192)
        at org.eclipse.core.internal.events.BuildManager$1.run(BuildManager.java:221)
        at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:616)
        at org.eclipse.core.runtime.Platform.run(Platform.java:747)
        at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:224)
        at org.eclipse.core.internal.events.BuildManager.basicBuildLoop(BuildManager.java:243)
        at org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:272)
        at org.eclipse.core.internal.events.AutoBuildJob.doBuild(AutoBuildJob.java:142)
        at org.eclipse.core.internal.events.AutoBuildJob.run(AutoBuildJob.java:203)
        at org.eclipse.core.internal.jobs.Worker.run(Worker.java:66)

    !ENTRY org.eclipse.core.resources 2 75 2004-11-16 03:25:27.276
    !MESSAGE Errors during build.
    !SUBENTRY 1 uk.ltd.grian.eclipse.xmlbeans 2 75 2004-11-16 03:25:27.276
    !MESSAGE Errors running builder "XMLBean Builder" on project TradeZone.
    !SUBENTRY 1 uk.ltd.grian.eclipse.xmlbeans 2 75 2004-11-16 03:25:27.276
    !MESSAGE java.lang.NullPointerException encountered while running XMLBean Builder.
    !STACK 0
    java.lang.NullPointerException
        at uk.ltd.grian.eclipse.xmlbeans.XMLBeansSchemaImpl.getName(XMLBeansSchemaImpl.java:191)
        at uk.ltd.grian.eclipse.xmlbeans.XMLBeanBuilder.build(XMLBeanBuilder.java:260)
        at org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:574)
        at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:616)
        at org.eclipse.core.runtime.Platform.run(Platform.java:747)
        at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:158)
        at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:192)
        at org.eclipse.core.internal.events.BuildManager$1.run(BuildManager.java:221)
        at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:616)
        at org.eclipse.core.runtime.Platform.run(Platform.java:747)
        at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:224)
        at org.eclipse.core.internal.events.BuildManager.basicBuildLoop(BuildManager.java:243)
        at org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:272)
        at org.eclipse.core.internal.events.AutoBuildJob.doBuild(AutoBuildJob.java:142)
        at org.eclipse.core.internal.events.AutoBuildJob.run(AutoBuildJob.java:203)
        at org.eclipse.core.internal.jobs.Worker.run(Worker.java:66)

    !ENTRY uk.ltd.grian.eclipse.xmlbeans 1 1 2004-11-16 03:25:54.204
    !MESSAGE XMLBeanBuilder.prepareToSave()

    !ENTRY org.eclipse.core.runtime 4 2 2004-11-16 03:25:54.214
    !MESSAGE Problems occurred when invoking code from plug-in: "org.eclipse.core.runtime".
    !STACK 0
    java.lang.NullPointerException
        at uk.ltd.grian.eclipse.xmlbeans.XMLBeanBuilder.saving(XMLBeanBuilder.java:214)
        at uk.ltd.grian.eclipse.xmlbeans.EclipseXMLBeansPlugin$WorkspaceSaveParticipant.saving(EclipseXMLBeansPlugin.java:286)
        at org.eclipse.core.internal.resources.SaveManager.executeLifecycle(SaveManager.java:306)
        at org.eclipse.core.internal.resources.SaveManager$1.run(SaveManager.java:129)
        at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:616)
        at org.eclipse.core.runtime.Platform.run(Platform.java:747)
        at org.eclipse.core.internal.resources.SaveManager.broadcastLifecycle(SaveManager.java:141)
        at org.eclipse.core.internal.resources.SaveManager.save(SaveManager.java:1314)
        at org.eclipse.core.internal.resources.Workspace.save(Workspace.java:1710)
        at org.eclipse.ui.internal.ide.IDEWorkbenchAdvisor$5.run(IDEWorkbenchAdvisor.java:513)
        at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:105)

    !ENTRY org.eclipse.ui.ide 4 4 2004-11-16 03:25:56.868
    !MESSAGE Problems saving workspace

    !ENTRY org.eclipse.ui.ide 2 1 2004-11-16 03:25:56.868
    !MESSAGE Problems occurred while trying to save the state of the workbench.
    !SUBENTRY 1 org.eclipse.core.resources 2 566 2004-11-16 03:25:56.868
    !MESSAGE Problems occurred during save.
    !STACK 0
    java.lang.NullPointerException
        at uk.ltd.grian.eclipse.xmlbeans.XMLBeanBuilder.saving(XMLBeanBuilder.java:214)
        at uk.ltd.grian.eclipse.xmlbeans.EclipseXMLBeansPlugin$WorkspaceSaveParticipant.saving(EclipseXMLBeansPlugin.java:286)
        at org.eclipse.core.internal.resources.SaveManager.executeLifecycle(SaveManager.java:306)
        at org.eclipse.core.internal.resources.SaveManager$1.run(SaveManager.java:129)
        at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:616)
        at org.eclipse.core.runtime.Platform.run(Platform.java:747)
        at org.eclipse.core.internal.resources.SaveManager.broadcastLifecycle(SaveManager.java:141)
        at org.eclipse.core.internal.resources.SaveManager.save(SaveManager.java:1314)
        at org.eclipse.core.internal.resources.Workspace.save(Workspace.java:1710)
        at org.eclipse.ui.internal.ide.IDEWorkbenchAdvisor$5.run(IDEWorkbenchAdvisor.java:513)
        at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:105)

    !ENTRY uk.ltd.grian.eclipse.xmlbeans 1 1 2004-11-16 03:25:57.69
    !MESSAGE Stopped EclipseXMLBeansPlugin

    !ENTRY uk.ltd.grian.eclipse.xmlbeans 1 1 2004-11-16 03:25:57.780
    !MESSAGE XMLBeanBuilder.prepareToSave()

    !ENTRY uk.ltd.grian.eclipse.xmlbeans 1 1 2004-11-16 03:25:57.780
    !MESSAGE XMLBeanBuilder.saving()

    !ENTRY uk.ltd.grian.eclipse.xmlbeans 1 1 2004-11-16 03:25:58.10
    !MESSAGE XMLBeanBuilder.doneSaving()

    and here's the schema file

    <?xml version="1.0" encoding="UTF-8"?>
    <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns="http://boxspoon.com/datamodel" targetNamespace="http://boxspoon.com/datamodel" elementFormDefault="qualified">

      <xs:complexType name="A">
        <xs:sequence>
          <xs:element maxOccurs="10" name="B" type="xs:string"/>
        </xs:sequence>
      </xs:complexType>

      <xs:complexType name="C">
        <xs:attribute name="Symbol" type="xs:string"/>
      </xs:complexType>

      <xs:element name="Document">
        <xs:complexType>
          <xs:sequence>
            <xs:element name="D" type="C"/>
          </xs:sequence>
        </xs:complexType>
      </xs:element>

    </xs:schema>

    finally. the contents of the .xst file in the .project /.schemas directory is

    mIJavaProject Handle =xmlbeans-test
    IFile =src/crassus.xsd

    btw, the plug-in is a fantastic idea!

     
    • Don Stewart
      Don Stewart
      2004-11-16

      Hi,

      I am debugging this now along with a couple of other things on the way to 0.0.3. Along with new features :o) The issues seems to have cropped up during some refactoring work.

      I'm still on Eclipse 3.0 but I have had this reported from 3.0 as well.

      Many thanks for the feedback.

      Don

       
    • Don Stewart
      Don Stewart
      2004-11-16

      One more thing you can try for me is:-

      Select the route project and click the Toggle Switch on the toolbar. This should now diable the builder. Now reselect the Toggle Switch, this should cause a re-enablement and build. Do you get the same results or different?

      Regards

      Don

       
    • Don Stewart
      Don Stewart
      2004-11-16

      One more thing you can try for me is:-

      Select the route project and click the Toggle Switch on the toolbar. This should now diable the builder. Now reselect the Toggle Switch, this should cause a re-enablement and build. Do you get the same results or different?

      Regards

      Don