상세 컨텐츠

본문 제목

Svcutil With Wsdl File

카테고리 없음

by bilperedoc1976 2020. 2. 29. 17:27

본문

When answering a question please:. Read the question carefully. Understand that English isn't everyone's first language so be lenient of badspelling and grammar. If a question is poorly phrased then either ask for clarification, ignore it, oredit the question and fix the problem. Insults are not welcome. Don't tell someone to read the manual. Chances are they have and don't get it.Provide an answer or move on to the next question.Let's work to help developers, not make them feel stupid.

Hello,If you have control over the whole system you don't have to use any wsdl generation tool. You can have the interface and commons type in a common dll, which must be included in all the projects that uses indigo, and call the service in this way:Dim cf As New ChannelFactory( Of IWSServiciosInfoca)( 'ep' )Dim isic As IWSServiciosInfoca = cf.CreateChannelisic.CargarArbolUOPorTrabajador( )This way you don't create new types.

You can use svcutil with /r command, this have the same effect, but i prefer my first option.Hope this help. Tell me if this is your scenario:1.

Svcutil Download

Svcutil With Wsdl File

Both services use the same enum type, from the same assembly reference. They don't both implement a 'copy' of the same enum in their own namespace.2.

ClassFile

Wsdl File Example

Each service has their own separate WSDL contract.3. The client is consuming both services by adding a service reference (or, svcutil command) to generate proxy/config.If this is the case, what you should be getting is two copies of the same enum because by default the generated proxy/config will generate all of the types found in its WSDL. It doesn't check to see if you have already generated the type from another WSDL.What's throwing me off is this statement: 'until I add a new service and include it in the wsdl generation'. What do you mean by that? It implies more than one service in the WSDL, but each service gets its own WSDL.

My scenario is that I have several services, each with its own contract interface, and each with its own service host.2. The enum is contained in a server-side assembly that is referenced by each of the services. The enums all live under the same namespace, not a copy.3. When I create the proxy via svcutil/wsdl, I reference each service contract together and create just one proxy file that contains references to each service, as well as the shared types.e.g.: svcutil All of this has worked fine until the latest service contract was added to the wsdl. Funny thing is, only shared enums get duplicated, and only a few of them.

Svcutil Vs Wsdl

I can't seem to find a pattern of why some do and some do not get duped.