can only call or exec a service

by eliasen 17. oktober 2009 20:59

Hi all

The other day I ran into a strange error when compiling my BizTalk solution. It was a simple solution, which I was fairly sure there was nothing wrong with. I had two projects. In the first I had a public orchestration and in the second I had a schema and an orchestration that calls the orchestration in the first project.

So the project structure looks like this:

project_structure

So not something that would normally go wrong. Anyway, the “customer.biztalk.sendmail” project compiles just fine. But when I compile the “eliasen.customer.test” project it fails with these three errors:

  1. identifier 'biztalk' does not exist in 'eliasen.customer'; are you missing an assembly reference?
  2. cannot find symbol 'customer.biztalk.sendmail.Send_Receipt'
  3. 'biztalk.sendmail.Send_Receipt': can only call or exec a service

This was weird. Apparently the called orchestration (customer.biztalk.sendmail.Send_Receipt) could not be found. Now since there has been a lot of issues with the copy local functionality being broken, that was my first thought. But since my solution had never been deployed and using Reflector on the customer.biztalk.sendmail assembly that was copied to the bin folder of the eliasen.customer.test project had all the right classes, I skipped that idea.

Then, just to be sure, I checked that “biztalk”, “customer” and “sendmail” aren’t reserved words in XLANG/s here: http://msdn.microsoft.com/en-us/library/aa547020(BTS.10).aspx – they weren’t.

Then I googled the “can only call or exec a service” error and found a couple of hits, but none that I could directly relate to my issue.

Then, as if struck by divine intervention, I thought of changing the namespace of the orchestration that was being called. Maybe in hindsight it makes sense, since one of the errors is telling me that it is looking for “biztalk” in the “eliasen.customer” namespace, which really doesn’t make sense at all.

Anyway, I opened up the properties of the called orchestration and changed the namespace:

new_namespace

and then it compiled… after re-choosing the called orchestration in my “Call Orchestration” shape. This, of course, is not acceptable – I want to be able to have any namespace I want. It seems that somehow the compiler matches the “customer” in “customer.biztalk.sendmail” to the “customer” in “eliasen.customer.test” with each other.

I have tried looking deeper into this, but I can’t seem to find the exact reason it is failing, so I will probably just report it to Microsoft and then let them deal with it :-)

Hope this helps someone…

--
eliasen

Tags:

Add comment

  Country flag

biuquote
  • Comment
  • Preview
Loading

About the author

Jan Eliasen is 37 years old, divorced and has 2 sons, Andreas (July 2004) and Emil (July 2006).

Jan has a masters degree in computer science and is currently employed at Logica Denmark as an IT architect.

Jan is a 6 times Microsoft MVP in BizTalk Server (not currently an MVP) and proud co-author of the BizTalk 2010 Unleashed book.

BizTalk Server 2010 Unleashed


Buy from Amazon

Microsoft MVP


6 times: July 2004, July 2008, July 2009, July 2010, July 2011, and July 2012. Not currently an MVP.

MCTS

Image to show

Month List

Page List