views:

247

answers:

3

The way you seem to declare WCF services is to create an interface in C# or VB, and then tag it with ServiceContractAttribute and it's methods with OperationContractAttribute.

The issue is, I'd like to try creating one from IronRuby or IronPython, which (to my knowledge) don't support attributes.

Is this possible?

A: 

Well, while I wouldn't (just preference, no need to flame me), you could use a language like Boo:

http://boo.codehaus.org/

Another alternative is to just build a piece in C# to do this communication for you then call that from IronyRuby or whatever language you want to use.

BobbyShaftoe
Boo seems very cool. Unfortunately I dislike python (just don't like the way the syntax looks, in the same way that some people don't like chocolate icecream), so it's a pity they've based it's syntax on that!
Orion Edwards
+1  A: 

AFAIK you can't yet in IronRuby. It's one of those interop things that are on the back burner while language compatibility is worked on. There's still alot of discussion needed about how to do this... but it is something that those of us working on IronRuby would like to see.

mletterle
+1  A: 

You can just use the object model in the System.ServiceModel.Description namespace (e.g. ContractDescription) to new up the right description objects, poke them in to a service's description's endpoints, and then open the host. But this is very non-trivial.

Brian