This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Reproduced in build 060910 (JDK 1.6 Beta 2) To reproduce the bug: - apply Russian Doll design pattern to the flattened OTA schema. java.lang.IllegalArgumentException: Model source is read-only. at org.netbeans.modules.xml.xam.AbstractModel.startTransaction(AbstractModel.java:322) at org.netbeans.modules.xml.xam.AbstractModel.startTransaction(AbstractModel.java:312) at org.netbeans.modules.bpel.model.validation.schema.BPELSchemaValidator.validate(BPELSchemaValidator.java:109) at org.netbeans.modules.xml.xam.spi.Validation.validate(Validation.java:78) at org.netbeans.modules.xml.axi.impl.AXIModelImpl.validate(AXIModelImpl.java:222) at org.netbeans.modules.xml.axi.impl.ModelAccessImpl.sync(ModelAccessImpl.java:75) ...
Assigning to BPEL team as the stack trace is being caused by BPEL validator.
praveen can you look at this?
*** Issue 84617 has been marked as a duplicate of this issue. ***
This particular case is fixed by having the BPELSchemaValidator ignore read-only schema model at the beginning itself rather than later. This is a generic bug in bpel validators that happens when a bpel file is read-only and a validator attempts to start a trasaction before beginning to validate.
which file was read only - the bpel file or the schema file? what are the conditions that led to the read only status? Can you clarify in description of fix, what are the implications for validation. What apsect of validation is being "skipped"?
Updated 'Summary' of the bug to reflect the reason that this issue happens on validating read only models. XAM model does not allow transaction to be started on read-only models. Added check so that before beginning a trasaction, validators will check whether the model is editable. And no transaction will be started for read-only models/files. To answer question on how the readonly models get created: Using windows properties set the bpel file as readonly file. Then the model will be readonly. To answer question "Can you clarify in description of fix, what are the implications for validation. What apsect of validation is being "skipped"? The original bug was reported on a readonly schema model. The BPEL Schema validator was starting a transaction on the schema model and then ignoring it as it was a schema model. Here I only modified it so that the BPELSchemaValidator first checks whether it is a bpel model and then proceeds. That way we do not unnecessarily start and end a transaction on a schema model.
Verified in build 060913.