I have a schema that works. It validates correctly, it validates the instance flat file correctly, and all is well. I then decide to try some of the schema properties settings like, "Allow Early Termination," and the schema no longer validates, nut instead results in the: "error BEC2004: Unexpected end of stream while looking for:" error. I then set the setting back to No and save my files, but I get the same setting. I then tried rebuilding the solution and get the same issue. The only way that I have found to "fix" my schema is to replace it with an original working version (I am glad I made the copy) or to rebuild it from scratch.
This has happened with a few schemas and resulted in my search for answers to the "error BEC2004: Unexpected end of stream while looking for:" error (for schemas that otherwise worked before changing a setting or two, and then turning them back). The schema settings seem to change back to their original state in the actual XML file when opened from notepad++ or sublime-text, but just wont validate anymore.
Has anyone else had this problem? --Know what causes this problem? -- or have any suggestions for how to prevent this issue from bothering me anymore?
I am unsure if this is a BizTalk issue, IDE, or some other cause.
Side note: I have BizTalk Server and Services SDK's installed and was wondering if they are known to interfere?
I seem to have figured it out. I have two fields for "Input Instance Filename," as you can see above. I think that one is for BizTalk services and the other for BizTalk server, but they are not labeled as so. Not knowing which field to use, I had both filled in. After only filling in the two seen above (for input and output) and setting the "Validate Instance Input Type" to Native, the schema validated perfectly.
I had Native set before, but the BizTalk Services "Input Instance Filename" seemed to have been overriding the "Validate Instance Input Type" for the BizTalk Server field.
To sum it up: If you are validating a schema for BizTalk Server and Services, make sure you set the "Validate Instance Input Type" to native after entering one "Input Instance Filename". Then add the other "Input Instance Filename", and then make sure that Native is still set.
Note: This is for Flat File schema validation
I hope this helps anyone else with this issue.
Update: After restructuring my solution, I ran into this issue again. I found that simply removing all of the paths to instances (input and output), rebuilding the solution, re-entering the paths and instance type, and then validating worked. When I rebuilt with no paths entered, the duplicate fields disappeared, allowing me to set the correct paths and type.