Test 1 will not work because the xs:schemaLocation does not point to valid location for the schema.<br><br>You can work around this by configuring an XML Catalog in your IDE so it treats "drools-change-set-5.0.xsd" as an alias. <br>
<br>Checkout the widely available xs:schemaLocation documentation for details of its syntax.<br><br><br>Test 2 *should* be OK. The referenced schema does exist and is valid.<br><br>guvnor-examples uses the exact same and works well (or at least for me!)<br>
<br>Can you provide a self-contained unit test to replicate the issue?<br><br><br><br><div class="gmail_quote">On 23 January 2012 20:43, domingo <span dir="ltr"><<a href="mailto:sprabakkar@gmail.com">sprabakkar@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I have some issues using changeset...<br>
<br>
*Test - 1*<br>
<change-set xmlns='<a href="http://drools.org/drools-5.0/change-set" target="_blank">http://drools.org/drools-5.0/change-set</a>'<br>
xmlns:xs='<a href="http://www.w3.org/2001/XMLSchema-instance" target="_blank">http://www.w3.org/2001/XMLSchema-instance</a>'<br>
xs:schemaLocation='<a href="http://drools.org/drools-5.0/change-set" target="_blank">http://drools.org/drools-5.0/change-set</a><br>
drools-change-set-5.0.xsd'><br>
<add><br>
<resource source='classpath:dir1/dir2/filename.drl' type='DRL' /><br>
</add><br>
</change-set><br>
<br>
<br>
when i use the above changeset (thanks to user forum)...the program works<br>
fine no issues but i got the following warning messages...<br>
<br>
<br>
(null: 1, 201): schema_reference.4: Failed to read schema document<br>
'drools-change-set-5.0.xsd', because 1) could not find the document; 2) the<br>
document could not be read; 3) the root element of the document is not<br>
<xsd:schema>.<br>
(null: 1, 201): cvc-elt.1: Cannot find the declaration of element<br>
'change-set'.<br>
(null: 1, 207): schema_reference.4: Failed to read schema document<br>
'drools-change-set-5.0.xsd', because 1) could not find the document; 2) the<br>
document could not be read; 3) the root element of the document is not<br>
<xsd:schema>.<br>
(null: 1, 285): schema_reference.4: Failed to read schema document<br>
'drools-change-set-5.0.xsd', because 1) could not find the document; 2) the<br>
document could not be read; 3) the root element of the document is not<br>
<xsd:schema>.<br>
(null: 1, 374): schema_reference.4: Failed to read schema document<br>
'drools-change-set-5.0.xsd', because 1) could not find the document; 2) the<br>
document could not be read; 3) the root element of the document is not<br>
<xsd:schema>.<br>
(null: 1, 446): schema_reference.4: Failed to read schema document<br>
'drools-change-set-5.0.xsd', because 1) could not find the document; 2) the<br>
document could not be read; 3) the root element of the document is not<br>
<xsd:schema>.<br>
(null: 1, 534): schema_reference.4: Failed to read schema document<br>
'drools-change-set-5.0.xsd', because 1) could not find the document; 2) the<br>
document could not be read; 3) the root element of the document is not<br>
<xsd:schema>.<br>
<br>
<br>
<br>
*Question: how to get rid of this? I completely google the web including<br>
user forum no answer.If it is available in the forum, my apologies for<br>
missing that info...some one could forward me to that info location.*<br>
<br>
*Test - 2*<br>
<change-set xmlns='<a href="http://drools.org/drools-5.0/change-set" target="_blank">http://drools.org/drools-5.0/change-set</a>'<br>
xmlns:xs='<a href="http://www.w3.org/2001/XMLSchema-instance" target="_blank">http://www.w3.org/2001/XMLSchema-instance</a>'<br>
xs:schemaLocation='<a href="http://drools.org/drools-5.0/change-set" target="_blank">http://drools.org/drools-5.0/change-set</a><br>
<a href="http://anonsvn.jboss.org/repos/labs/labs/jbossrules/trunk/drools-api/src/main/resources/change-set-1.0.0.xsd" target="_blank">http://anonsvn.jboss.org/repos/labs/labs/jbossrules/trunk/drools-api/src/main/resources/change-set-1.0.0.xsd</a>'<br>
><br>
<add><br>
<resource source='classpath:dir1/dir2/filename.drl' type='DRL' /><br>
</add><br>
</change-set><br>
<br>
<br>
when i use the above changeset (grepcode drools-compiler 5.2.1<br>
Final)...after 1 minute it gives the following error message and the thread<br>
is open for ever...nothing happen.<br>
<br>
INFO: KnowledgeDefinitionBuilder::::: changeset == <change-set<br>
xmlns='<a href="http://drools.org/drools-5.0/change-set" target="_blank">http://drools.org/drools-5.0/change-set</a>'<br>
xmlns:xs='<a href="http://www.w3.org/2001/XMLSchema-instance" target="_blank">http://www.w3.org/2001/XMLSchema-instance</a>'<br>
xs:schemaLocation='<a href="http://drools.org/drools-5.0/change-set" target="_blank">http://drools.org/drools-5.0/change-set</a><br>
<a href="http://anonsvn.jboss.org/repos/labs/labs/jbossrules/trunk/drools-api/src/main/resources/change-set-1.0.0.xsd" target="_blank">http://anonsvn.jboss.org/repos/labs/labs/jbossrules/trunk/drools-api/src/main/resources/change-set-1.0.0.xsd</a>'<br>
> <add> <resource source='classpath:dir1/dir2/filename.drl' type='DRL' /><br>
</add> </change-set><br>
(null: 1, 285): schema_reference.4:<br>
Failed to read schema document<br>
'<a href="http://anonsvn.jboss.org/repos/labs/labs/jbossrules/trunk/drools-api/src/main/resources/change-set-1.0.0.xsd" target="_blank">http://anonsvn.jboss.org/repos/labs/labs/jbossrules/trunk/drools-api/src/main/resources/change-set-1.0.0.xsd</a>',<br>
because 1) could not find the document; 2) the document could not be read;<br>
3) the root element of the document is not <xsd:schema>.<br>
(null: 1, 285): cvc-elt.1: Cannot find the declaration of element<br>
'change-set'.<br>
<br>
<br>
*Question: I copied the schemaLocation from the src, why it is not working?<br>
please advise me?*<br>
<br>
-----<br>
with kind regards,<br>
<span class="HOEnZb"><font color="#888888"><br>
--<br>
View this message in context: <a href="http://drools.46999.n3.nabble.com/changeset-schema-error-tp3682951p3682951.html" target="_blank">http://drools.46999.n3.nabble.com/changeset-schema-error-tp3682951p3682951.html</a><br>
Sent from the Drools: User forum mailing list archive at Nabble.com.<br>
_______________________________________________<br>
rules-users mailing list<br>
<a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
</font></span></blockquote></div><br>