Welcome back to another blog post on this saga of Errors and Warnings, Causes, and Solutions. Sometimes, I think that I’m a magnet that attracts errors, or they feel sad because they are not documented and think… let’s upset Sandro.
This week, while I was trying to deploy through Visual Studio one change on a new BizTalk Server project that I’m working on, I got the following list of errors:
Error: a porttype operation can only contain messagetypes or class types
path\<orchestration-name>.odxError: cannot find symbol ‘<namespace>.Oracle_BIZTALK_Package.INSERT_ORDERS’
path\<orchestration-name>.odxError: identifier ‘INSERT_ORDERSResponse’ does not exist in ‘<namespace>.Oracle_BIZTALK_Package’; are you missing an assembly reference?
path\<orchestration-name>.odx
Needless to say, this was not the first time I had published this solution, and the name of the orchestration presented by coincidence had not changed, which was even more curious.
Cause
In this ORACLE schema, I have two schema definitions, the INSERT_ORDERS and the INSERT_ORDERSResponse, which is quite normal. We often have a schema with several operations defined.
The reason I got this error was by the fact that during the test phase – so the solution was already built, at least part of it – I had the need to generate a dummy instance of the INSERT_ORDERS, and for that, I had the need to:
- Open the schema in the Schema Editor.
- Right-click on the <Schema> node and select properties.
- On the properties panel, on the Root Reference property, define it as INSERT_ORDERS.
- Note that by default, the value of this property is (Default)
After that, I successfully generated the dummy instance of the message type… but I forgot to roll back that Root Reference property to the default value – (Default).
When you try to deploy the solution with the Root Reference changed, it will normally give an error similar to this.
Solution
Once again, the solution to this problem is quite simple. You just need to revert the value of the Root Reference property to the default value – (Default). For that, you need to:
- Once again, open the schema in the Schema Editor.
- Right-click on the <Schema> node and select properties.
- On the properties panel, on the Root Reference property, define it as (Default)
Now, if you try to deploy it, everything will work. At least those errors will disappear.
I hope you find this helpful! If you liked the content or found it useful and want to help me write more, you can buy (or help me buy) my son a Star Wars Lego!