Commit Graph
165 Commits
Author SHA1 Message Date
Alexander Köplinger c4692001a9 [bcl] Fix method parameter names to match .NET
The names were fixed only for the subset of methods that are included in netstandard,
and in cases where netstandard differs from Desktop .NET we match with .NET.
2016-08-26 17:49:03 +02:00
Ludovic Henry 249daf43de [mcs] Replace NET_2_1 by MOBILE
NET_2_1 is also defined whenever we define MOBILE, so they have the same effect. Silverlight was 2.1 but it's been dead for a while now, and we do not even support it.
2016-08-18 16:34:36 +02:00
Marcos Henrich c1d81649cc Merge pull request #2323 from esdrubal/servicemodel
[System.ServiceModel] Fixes missing xsi xsd attributes
2016-02-15 12:08:21 +00:00
Alexander Köplinger b03e606287 Remove ChangeLog files from the repo
They weren't updated in the last 6 years and aren't helpful anymore (e.g. by causing unrelated matches during git grep searches).
2016-01-29 19:17:06 +01:00
Marcos Henrich fdb5cadefb [ServiceModel] Fixes missing xsi xsd attributes
While serializing operations with XmlSerializerFormatAttribute,
attributes xmlns:xsi and xmlns:xsd were not added to the message body.

XmlBodyWriter now adds the missing attributes.

Fixes #34413.
2016-01-04 15:42:26 +00:00
Miguel de Icaza 28f473c41d Merge pull request #1225 from strawd/bug22307
Fix for bug 22307 - Intermittent IndexOutOfRangeException on closing connection
2015-09-23 15:34:55 -04:00
Zoltan Varga e71bf630bc [bcl] Fix test failures in the System.ServiceModel tests after 9ffb681d06. 2015-08-15 22:26:59 -04:00
Chris Hamons b044a27fe0 Create xammac_net_4_5 profile for XM 4.5 Unified to remove references to unshippable assmblies 2015-06-18 13:31:04 -05:00
Miguel de Icaza 5715cdc582 [System.ServiceModel] Prevent server crash when client disconnect
This patch is an updated version of a pull request (377) from Rob
Wilkens to fix #5926
2015-02-16 10:01:22 -05:00
Zoltan Varga c1b4366932 [bcl] Remove NET_4_5 defines from class libs. 2015-01-13 16:34:23 -05:00
Zoltan Varga 032f313d5f [bcl] Remove NET_4_0 defines from class libs. 2015-01-13 16:06:31 -05:00
Martin Baulig 87622fc711 [WCF]: Update to my last fix for bug #22129.
The problem already starts when creating the OperationDescription; we need
to also look at the End* method here to correctly parse the reply parameters.

Then ClientRuntimeChannel.Process needs to distinguish between sync/async
and copy the out/byref parameters when needed.
2014-09-16 21:34:20 +02:00
David Straw 5b6c684d26 Fix for bug 22307 - Intermittent IndexOutOfRangeException on closing connection 2014-08-22 11:50:08 -06:00
Martin Baulig 1ae87e9ee9 [WCF]: Add stubs for some missing .NET 4.0/4.5 APIs. 2013-09-02 21:52:13 +02:00
Rodrigo Kumpera a0d28b2587 Kill the MOONLIGHT define in System.ServiceModel. 2013-02-11 13:01:11 -05:00
Martin Baulig 37b26ae4a0 [#7177][WCF]: Correctly handle derived FaultExceptions. 2012-09-19 06:01:11 +02:00
Rolf Bjarne Kvinge 9ab872cb69 System.ServiceModel: Make FaultContractInfos available (and therefore deserialized correctly) in mobile profiles. Fixes #1437 and 2859. 2012-02-04 03:04:34 +01:00
Jonathan Pryor 00e29089c7 [System.ServiceModel] Don't try to deserialize void messages.
Fixes: http://bugzilla.xamarin.com/show_bug.cgi?id=1164

The breakage reported in #1164 was caused by commit 106fdeb4, which
fixed bxc206. The problem is that in fixing bxc206, response messages
of a type having a MessageContractAttribute custom attribute were
changed to have a `void` return type, according to the
MessageDescription's Body.ReturnValue.Type property.

This fix is correct, in that it's what .NET does, but it broke XML
deserialization which expected the "actual" return type to exist, not
`void`.

Case in point: the added IService1.EndJSMGetDatabases() method will
have a MessageDescription with a Body.ReturnValue.Type=typeof(void).
The problem is that deserializing this message will fail:

	System.Runtime.Serialization.SerializationException: Deserializing
	type 'System.Void'. Expecting state 'EndElement'. Encountered state
	'Text' with name '' with namespace ''.

Obviously this is not good. ;-)

The fix is simple: don't use the MessageDescription's ReturnValue if
it's `typeof(void)`.

There are two added wrinkles:

 1. Writing a test case for the above.

 2. The test case broke with another error: a NRE within
    BaseMessagesFormatter.MessageObjectToParts(). This is because
    when ContractDescriptionGenerator.GetMessage() sets the
    ReturnValue for a response message, it doesn't set
    MessagePartDescription.MemberInfo.
    BaseMessagesFormatter.MessageObjectToParts(), meanwhile, was
    checking the ReturnValue's MemberInfo...which was null.

    Add a null check here so that the actual bug can be tested.
2012-01-20 00:18:54 -05:00
Martin 5aecac0f33 completes commit 4f3d21e46e 2011-12-29 15:38:58 +01:00
QuickJack 4f3d21e46e Fixes CS0168 in System.ServiceModel.dll 2011-12-29 15:28:26 +01:00
Miguel de Icaza 2852ed0b59 Update copyrights 2011-09-13 18:26:13 -04:00
Sebastien Pouliot 7894348cc8 Add null-check on 'partDesc'. Fix bug #612 (WCF regression) 2011-09-07 11:16:23 -04:00
Atsushi Eno bde305b72c When there is void return, the common message formatter should ignore it.
This case occurs when MessageContract is used and there is no member for
the return value.
2011-08-24 12:10:31 -07:00
Atsushi Eno 2be522da83 This filter should ignore port, and should not filter out anonymous URIs. 2011-08-24 12:00:59 -07:00
Atsushi Eno 5fc5f02c46 Merge pull request #145 from ngraziano/99b87f07af0beed3a887
Fix Service Model Xml Serialization and XMLAttributes
2011-08-03 05:54:54 +09:00
Atsushi Eno 0c7d5fcc14 Fill/reflect ReturnValue to and from corresponding message part.
This may have fixed bug #41.
2011-08-02 09:58:28 -07:00
Atsushi Eno 226c2db9ac Implement support for Stream param with WebHttpBinding raw content format. 2011-06-28 20:43:13 +09:00
Atsushi Eno 0045240824 Enable environment-controled output on non-moon profile too. Add error logging. 2011-04-25 15:35:03 +09:00
Atsushi Eno a316b856d0 Get real fix for bug #687902. Revert request processor IDisposable.
and handle session shutdown when creating InstanceContext.
Also add note on DisposeInstance(), which got me stuck.
2011-04-20 19:11:34 +09:00
Atsushi Eno 5c306c5d04 Ongoing service channel closing fix and session management in ChannelDispatcher.
It is part of bugfix 687902.

To get the bug fixed, the new "using" sections in ChannelDispatcher.cs to
explicitly dispose channels. But this causes regression in PerSession-based
tests. So some new session management code is (likely) required as well.

It will also alter "mixed" MaxConcurrentCalls and MaxConcurrentSessions with
correct management code.
2011-04-20 16:52:36 +09:00
Atsushi Eno 549e702365 Add XmlSerializerFormatAttribute support in mobile profiles.
Unlike moonlight, XmlSerializer is in the framework lib (sys.xml), so we don't
have to split them out to Sys.Xml.Serialization.dll.
2011-04-08 15:58:04 +09:00
Atsushi Eno 72f0cd6e5b Split XmlMessagesFormatter out. It is for use in Sys.Xml.Serialization.dll.
XmlMessagesFormatter will be used in Sys.Xml.Serialization.dll and this
type should not be excluded by !NET_2_1 or !MOONLIGHT. It is not doable
if this class is in BaseMessagesFormatter.cs.
2011-04-08 00:19:40 +09:00
Atsushi Eno 852b7fe308 Some XmlSerializerFormatAttribute and XmlSerializerOperationBehavior refactoring. 2011-04-07 19:19:07 +09:00
Rolf Bjarne Kvinge 30443d63dd System.ServiceModel: make it a lot more compatible with Silverlight 2011-03-31 16:01:22 +02:00
Atsushi Eno e60ff5ff90 Add endpoint behavior support in NET_2_1, which involved not a few additions. 2011-03-16 17:20:00 +09:00
Peter Gerbrandt fe6910a0a8 Apply DataContractSerializerOperationBehavior. 2011-03-14 12:16:25 +09:00
Atsushi Eno 1e4407cd84 Replace SRE-based client proxy generator with RealProxy.
Now PE verified workaround should be unnecessary.
2011-03-07 12:29:39 +09:00
Atsushi Eno 1125d54fa3 Another fix to not write null header. Add UniqueId deserialization workaround. 2011-02-24 14:24:44 +09:00
Atsushi Eno 3378ca880c Do not try to serialize null header item. 2011-02-18 16:23:15 +09:00
Atsushi Eno 3aaf87fe84 Message headers are now serialized and deserialized for MessageHeaderDescription. 2011-02-15 23:14:27 +09:00
Atsushi Eno 58a7b75bd8 Support ServiceKnownTypes. Fixed another case on bug #652331. 2011-02-09 15:42:40 +09:00
Atsushi Eno cae51172f8 Open and close client/service runtime channels in chains. Fixed bug #663278. 2011-02-07 23:15:22 +09:00
Atsushi Eno 0351f32bb8 handle IsTerminating. 2011-02-07 23:14:53 +09:00
Atsushi Eno e0a3b79880 Callback contract should be distinguished from others for DispatchOperation. 2011-02-04 12:50:25 +09:00
Atsushi Eno 91074e3475 Fix regression, avoid null key. 2011-01-21 20:24:30 +09:00
Atsushi Eno b2802fa2d5 And rename source file name. 2011-01-21 16:20:23 +09:00
Atsushi Eno 3691992579 Rename InstanceBhavior, too ambiguous among IXxxBehavior interfaces. 2011-01-21 16:18:54 +09:00
Atsushi Eno feec98f870 Sessions should not be keyed by MessageId but be done by channel SessionId. 2011-01-21 16:17:59 +09:00
Marek Habersack d4bb1c86b7 [wcf] make /js and /jsdebug dispatchers work.
There were several issues here:

- The IChannelDispatcherBoundListener was defined twice, in two different namespaces, and it caused code in
  ChannelDispatcher.Attach not to set its associated listener's ChannelDispatcher property to the correct value.
  This, in turn, caused incorrect HttpListenerManagerTable operation, where it would put the "/js" and "/jsdebug"
  dispatchers in separate HttpListenerManagers, instead of in the main (base) service's one.
- After fixing the above, it turned out that SvcHttpHandler selected the manager based on the host's base address,
  when it should first try to find one whose URL matches the current request exactly.
2010-10-20 15:04:37 +02:00
Atsushi Eno 0c7a1a1f5c Fix the issue that callback contract often gets confused by picking unexpected contract type.
The problem is that DispatchRuntime.Type is a service implementation type
that could implement two or more contract interfaces, and it was in random
order how ServiceProxyGenerator picks up the contract type. Now it looks
for correct contract type instead of the service type by exactly looking
for the target contract in the endpoint (dispatcher).
2010-09-29 16:41:59 +09:00