15 49.0138 8.38624 1 0 4000 1 https://www.alexmedina.net 300 true 0
WCF

WCF REST, un OperationContract con GET y otro con POST

0 Comments
A veces por motivos de seguridad o eficiencia hay que configurar las llamadas WCF REST por GET o por POST, es altamente recomendable que las peticiones GET al servidor se hagan por GET y las SET por POST, por motivos de seguridad sobretodo. Por eficiencia es siempre mejor el GET. [ServiceContract] public interface IGasPriceService {…

Configurar el tamaño de las peticiones WCF REST del servicio web

0 Comments
Configurar el tamaño de las peticiones WCF REST, esto se realiza en el web.config <bindings> <basicHttpBinding> <binding name="LargeBuffer" ... <readerQuotas  maxDepth="2147483647"  maxStringContentLength="2147483647"  maxArrayLength="2147483647" maxBytesPerRead="2147483647"  maxNameTableCharCount="2147483647" /> .... </binding> </basicHttpBinding> </bindings> <services> <service name="WcfService4.Service1" behaviorConfiguration="WcfService4.Service1Behavior"> <endpoint bindingConfiguration="LargeBuffer" <!-- without this, the default quota of 8192 applies --> address="" binding="basicHttpBinding" contract="WcfService4.IService1"> .... </endpoint> <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange"/> </service> </services>