message-passing


How to send large Messages to the WCF Services?


I have one DataContract in the WCF service.In that it has one Array and i am setting that array in the Client code. If I set the array to more than 1000 thousand its throwing up an error saying BadRequest.
System.ServiceModel.ProtocolException : The Remote server returned an unexpected response (400) Bad Request.
How to overcome this? I want to send more data to the service.
You can try to increase the size allowed for a message. You'll need to set both the service and the client endpoint to use the binding configuration.
<bindings>
<netTcpBinding>
<binding name="TcpBindingConfiguration" closeTimeout="00:10:00" openTimeout="00:10:00" receiveTimeout="00:10:00" sendTimeout="00:10:00" maxBufferSize="2147483647" maxReceivedMessageSize="2147483647">
<readerQuotas maxDepth="2147483647" maxStringContentLength="2147483647" maxArrayLength="2147483647" maxBytesPerRead="2147483647" maxNameTableCharCount="2147483647" />
</binding>
</netTcpBinding>
</bindings>
If the data you are trying to send cannot fit within the message size allowed by the above configuration, you'll need to look into ways to either send less data or do it in multiple requests.
You can see this question for related information.

Related Links

How to send large Messages to the WCF Services?

Categories

HOME
api
design-patterns
nvd3.js
pagination
twig
sitecore
solver
opendj
bitbucket-api
cq5
cakephp-3.4
nfs
extjs4.2
spin
drop-down-menu
mel
text-mining
redis-sentinel
frequency-distribution
plink
selectize.js
package-managers
internationalization
aws-sdk
smartclient
xmonad
nim
delphi-xe5
sar
spring-async
systemtime
visual-studio-extensions
easeljs
mount
dapper-extensions
xcode-ui-testing
definitelytyped
siri
custom-post-type
syntax-highlighting
motion-detection
outliers
winexe
sinch
sqsh
testcomplete
scrollview
record
clickjacking
code-snippets
sammy.js
joomla2.5
xcode7.3
demo
tasm
doc
dcmtk
datacachefactory
android-ibeacon
glm-math
http-request
signal-strength
procfile
optimizely
servermanager
automapper-5
sonarlint-eclipse
java-6
janus
jtree
bootstrap-tags-input
testrail
xcode-server
mediametadataretriever
boost-serialization
sklearn-pandas
redis-cluster
libav
jparsec
spring-retry
atan2
flock
poppler
video-player
evolus-pencil
batik
mod-proxy
zscript
rdflib
airbrake
linked-tables
dnssec
mraid
node-serialport
fits
umlgraph
linkedin-jsapi
unix-socket
angular-carousel
rcaller
cancellation
rfc5322
virtual-pc
twisted.web
frameworkelementfactory
iboutlet
pyunit
correlated-subquery
boost-signals
stress
google-maps-mobile
htdocs
twitterizer
presentation-layer
globals
scrollbars
lemmatization
xslcompiledtransform

Resources

Database Users
RDBMS discuss
Database Dev&Adm
javascript
java
csharp
php
android
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App