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
gridview
string
interface
solaris
sublimetext
appcelerator
access
cq5
nstableheaderview
modal-dialog
google-schemas
minecraft-forge
github-enterprise
filechannel
intercom
magnetic-cards
cumulocity
jersey-1.0
comparator
google-api-client
xcode-ui-testing
data.stackexchange.com
google-cloud-print
userdefaults
quickfixj
android-maps-extensions
getpixel
roblox
timing
hackintosh
signals-slots
numberpicker
wmp
drupal-theming
clang++
vaadin-charts
monkey-testing
optimizely
flask-restful
httrack
openal
mschart
semantic-logging
colorbar
git-flow
arules
polyline
choice
gets
visual-studio-2008-sp1
cudd
stax
seek
dotnetnuke-7
uicolor
dup
delta
pre-build-event
jparsec
character-replacement
pypiserver
page.js
toolkit
jdk1.7
canvg
zxspectrum
phpldapadmin
infosphere-spl
administration
grails-domain-class
reflector
radiant
renderer
multiautocompletetextview
conditionaltagsupport
hibernate-entitymanager
windows-phone-8-sdk
model-driven-development
tlf
intersect
patricia-trie
veracity
apache-whirr
cgimage
presentation-layer
zen
google-wave
product-management
lemmatization
leader

Resources

Encrypt Message