2

I use jrebel as a standalone version, not as eclipse plugin, so i made all the rebel.xml files by myself...

with this rebel.xml i got in eclipse the following error at the <configuration> tag

cvc-complex-type.2.4.a: Invalid content was found starting with element 'configuration'. One of '{name, module, deployment, version, "http://www.zeroturnaround.com":classpath, "http:// www.zeroturnaround.com":web, "http://www.zeroturnaround.com":war}' is expected.

<?xml version="1.0" encoding="UTF-8"?>
<application xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.zeroturnaround.com" xsi:schemaLocation="http://www.zeroturnaround.com http://www.zeroturnaround.com/alderaan/rebel-2_0.xsd">

    <configuration>
      <!--
        root is 2 directoris away from jar/war modules
      -->
      <relativePath>../../</relativePath>

      <rootPath>$${project_name.root}</rootPath>
    </configuration>

    <classpath>
        <dir name="${project_name.root}/datamodel/target/classes" />
    </classpath>

</application>

jRebel is already working, but eclipse shows me errors and this is a little bit annoying! Anyone see the error, or knows how to fix this?

I use: Eclipse Indigo Service Release 2 and jrebel 5.0.1 standalone (jar version)

Joergi
  • 1,527
  • 3
  • 39
  • 82

1 Answers1

2

You're mixing maven plugin elements with JRebel elements. rebel.xml should only contain JRebel information otherwise JRebel will ignore elements is does not understand at runtime. The configuration tag is a maven plugin element and should be removed. The eclipse error states the JRebel elements which the schema accepts are name, module, deployment, version, "http://www.zeroturnaround.com":classpath, "http:// www.zeroturnaround.com":web and "http://www.zeroturnaround.com":war. These are the only elements you can use under the root application tag.

HTH -- Simon (ZeroTurnaround Tech Evangelist) @sjmaple

Simon
  • 36
  • 3
  • 1
    hi Simon, i was looking at http://zeroturnaround.com/software/jrebel/maven/ and i found this in the `STEP 3: Use relative paths in generated configuration` - for me it sounds like it HAS TO BE in the `rebel.xml`? `Now you will have c:/projects/my-maven-project1/my-jar1/target/classes as ${rebel.root}/my-maven-project1/my-jar1/target/classes in the rebel.xml.` Or did i get i totally wrong? – Joergi Dec 21 '12 at 10:04
  • 1
    Hi Joerg, it should go in the pom.xml just underneath the tag. I'll update the doc to make it clearer. Thanks for your feedback! Simon – Simon Dec 21 '12 at 15:22