简体   繁体   中英

Why is Orleans not recognized in 'Orleans Grains Class Collection' project?

I'm trying to write a simple Orleans demo solution:

  1. I've installed Orleans v1.0.0 via the .msi from github .
  2. I've created a new Visual Studio 2013 solution.
  3. I've created a new Orleans Grains Interface Collection type project.
  4. I've created a new Orleans Grains Class Collection type project

In the interface collection project, I can type Orleans and VS2013 Intellisense recognizes the namespace and its contents:

在此处输入图片说明

In the class collection project I can't:

在此处输入图片说明

Why is this happening and how can I fix it?

I've been able to resolve my issue with generous help from Sergey Bikov from the Microsoft Orleans team.

What I did was:

  1. I add the missing reference from my grain project to my interface project, and added using MyGrainInterfaces1; to Grain1.cs . (Just so my solution would build without errors)

  2. I removed the references to the Orleans.dll from both my projects and then re-added them manually. (Path to Orleans.dll for me is C:\\Microsoft Project Orleans SDK v1.0\\SDK\\Binaries\\OrleansClient\\Orleans.dll

Now the Orleans namespace is recognized in both projects correctly.

Side note: Not sure why this did not work for me when I tried it several days ago.

  1. Add reference from grain project to interface project, add using MyGrainInterfaces1; to Grain1.cs and build.
  2. Unload/reload grain project. - This seems to be an IntelliSense "feature".

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM