[SPRNET-1499] WebService Exported produces "Duplicate type name within an assembly" exception Created: 16/Apr/12  Updated: 25/May/12  Resolved: 03/May/12

Status: Resolved
Project: Spring.NET
Component/s: Spring-NET-SERVICES
Affects Version/s: 1.3.2
Fix Version/s: 2.0 M1

Type: Bug Priority: Major
Reporter: Steve Bohlen Assignee: Steve Bohlen
Resolution: Cannot Reproduce Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Reference URL: http://forum.springframework.net/showthread.php?7048-Duplicate-type-name-within-an-assembly

 Comments   
Comment by Steve Bohlen [ 03/May/12 ]

We are unable to reproduce this error on our end. We will re-open this issue in the future if we are provided a sample repro case that can be used to better support our attempts to resolve this issue.

Comment by Wayne He [ 25/May/12 ]

I encounter the same problem today. It occurs when using AOP proxy with WebServiceExporter.
My config looks like this
<objects xmlns="http://www.springframework.net" xmlns:aop="http://www.springframework.net/aop"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.net http://www.springframework.net/xsd/spring-objects.xsd">

<!-- Web Services -->
<object id="WcfCalcService" type="WcfService.CalcService, WcfService" singleton="false">
<property name="Format" value="[(

{0} + {1}i)]" />
</object>

<object id="CalcService" type="Spring.Web.Services.WebServiceExporter, Spring.Web">
<property name="TargetName" value="WcfServiceProxy"/>
<property name="Name" value="WcfCalcService" />
<property name="Description" value="My exported CalcService web service"/>
<property name="TypeAttributes">
<list>
<object type="System.Web.Services.WebServiceAttribute, System.Web.Services">
<property name="Description" value="My Spring-configured CalcService method."/>
</object>
</list>
</property>
</object>

<object id="DebugAdvice" type="Spring.Aop.Advice.DebugAdvice, Spring.Aop"/>

<object id="WcfServiceProxy" type="Spring.Aop.Framework.ProxyFactoryObject, Spring.Aop">
<property name="TargetName" value="WcfCalcService"/>
<property name="IsSingleton" value="true"/>
<property name="InterceptorNames">
<list>
<value>DebugAdvice</value>
</list>
</property>
</object>
</objects>

If I take out the AOP proxy, the problem goes away.
<objects xmlns="http://www.springframework.net"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.net http://www.springframework.net/xsd/spring-objects.xsd">

<!-- Web Services -->
<object id="WcfService.CalcService" type="WcfService.CalcService, WcfService" singleton="false">
<property name="Format" value="[({0}

+

{1}

i)]" />
</object>

<object id="CalcService" type="Spring.Web.Services.WebServiceExporter, Spring.Web">
<property name="TargetName" value="WcfService.CalcService"/>
<property name="Description" value="My exported CalcService web service"/>
<property name="TypeAttributes">
<list>
<object type="System.Web.Services.WebServiceAttribute, System.Web.Services">
<property name="Description" value="My Spring-configured CalcService method."/>
<property name="Namespace" value="http://wswhe.genomichealth.com/WcfService"/>
</object>
</list>
</property>
</object>
</objects>

Generated at Mon Jul 15 22:42:05 UTC 2019 using JIRA 7.9.2#79002-sha1:3bb15b68ecd99a30eb364c4c1a393359bcad6278.