New Posts New Posts RSS Feed: gzipMessageEncoding
  FAQ FAQ  Forum Search   Calendar   Register Register  Login Login

gzipMessageEncoding

 Post Reply Post Reply
Author
yafei View Drop Down
Newbie
Newbie


Joined: 25-Aug-2010
Location: los Angeles
Posts: 21
Post Options Post Options   Quote yafei Quote  Post ReplyReply Direct Link To This Post Topic: gzipMessageEncoding
    Posted: 26-Aug-2010 at 11:47am
I got the following error message when I use the customBinding in my BOS:
The type 'IdeaBlade.Core.Wcf.Extensions.GZipMessageEncodingElement, IdeaBlade.Core' registered for extension 'gzipMessageEncoding' could not be loaded. (C:\Docs\WPF\WpfApplication1\bin\Debug\WpfApplication1.vshost.exe.Config line 66)
 
I have IdeaBlade.Core.dll referenced for the runtime.
 
Server Side configuraiton ServerConsole.exe.config:
 
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
  <configSections>
    <section name="ideablade.configuration" type="IdeaBlade.Core.Configuration.IdeaBladeSection, IdeaBlade.Core" />
  </configSections>
  <connectionStrings>
    <add name="NorthwindIBEntityManager" connectionString="metadata=res://*/NorthwindIBModel.csdl|res://*/NorthwindIBModel.ssdl|res://*/NorthwindIBModel.msl;provider=System.Data.SqlClient;provider connection string=&quot;Data Source=JAY-WS\SQLEXPRESS;Initial Catalog=NorthwindIB;User Id=localdev;Password=anotherhotday;MultipleActiveResultSets=True&quot;" providerName="System.Data.EntityClient" />
  </connectionStrings>
 
  <ideablade.configuration version="6.00" xmlns="http://schemas.ideablade.com/2010/IdeaBladeConfig">
 
    <logging
        logFile="DebugLog.xml"
        archiveLogs="false"
        port="9922"
        serviceName="TracePublisher"
        usesSeparateAppDomain="false" />

    <objectServer remoteBaseURL="http://192.168.0.109"
                  serverPort="9009"
    serviceName="EntityService"
                  useDCS="true" >

      <serverSettings allowAnonymousLogin="true"
                       loginManagerRequired="false"
                       sessionEncryptionKey=""
                       supportedClientApplicationType="UseLicense"
                       testMode="false"
                       useAspNetSecurityServices="false"
                       useDTC="false"
                       userSessionTimeout="30"
                      />
    </objectServer>
    <probeAssemblyNames>
      <probeAssemblyName name="MyAssembly" />
    </probeAssemblyNames>
 
   <notificationService enabled="false" clientPort="1001" />
 
    <verifiers />
  </ideablade.configuration>
  <system.serviceModel>
    <services>
      <!--<service name="EntityService">
        <endpoint
          address="http://localhost:9009/EntityService"
         binding="wsHttpBinding" bindingConfiguration="wsHttpDefault"
         contract="IdeaBlade.EntityModel.IEntityServiceContract" />
      </service>
      <service name="EntityServer">
        <endpoint
          address="http://localhost:9009/EntityServer"
         binding="wsHttpBinding" bindingConfiguration="wsHttpDefault"
         contract="IdeaBlade.EntityModel.IEntityServerContract" />
      </service>-->

      <service name="EntityService">
        <endpoint address="http://localhost:9009/EntityService"
                  binding="customBinding" bindingConfiguration="compressedBinaryBinding"
                  contract="IdeaBlade.EntityModel.IEntityServiceContract"
                  />
      </service>
      <service name="EntityServer">
        <endpoint address="http://localhost:9009/EntityServer"
                  binding="customBinding" bindingConfiguration="compressedBinaryBinding"
                  contract="IdeaBlade.EntityModel.IEntityServerContract"
                  />
      </service>
    </services>
    <bindings>
      <wsHttpBinding>
        <binding name="wsHttpDefault" maxReceivedMessageSize="2147483647" />
      </wsHttpBinding>

      <customBinding>
        <binding name="compressedBinaryBinding"
                 closeTimeout="00:01:00"
                 openTimeout="00:01:00"
                 receiveTimeout="00:10:00"
                 sendTimeout="00:01:00">
          <gzipMessageEncoding>
            <readerQuotas
              maxDepth="2147483647"
              maxStringContentLength="2147483647"
              maxArrayLength="2147483647" />
          </gzipMessageEncoding>
          <httpTransport maxReceivedMessageSize="2147483647" />
        </binding>
      </customBinding>

     
    </bindings>
    <!-- gzipMessageEncoding is used by the custom binding above to provide GZip compression. -->
    <extensions>
      <bindingElementExtensions>
        <add name="gzipMessageEncoding"
             type="IdeaBlade.Core.Wcf.Extensions.GZipMessageEncodingElement, IdeaBlade.Core"/>
      </bindingElementExtensions>
    </extensions>
 
  </system.serviceModel>
</configuration>
 
 
 
 
And client side WPF configuration app.config:
<?xml version="1.0"?>
<configuration>
<configSections>
<section name="ideablade.configuration" type="IdeaBlade.Core.Configuration.IdeaBladeSection, IdeaBlade.Core"/>
</configSections>
<ideablade.configuration version="6.00" xmlns="http://schemas.ideablade.com/2010/IdeaBladeConfig">
<logging logFile="DebugLog.xml"/>
<!--<objectServer>
<objectServer remoteBaseURL="http://192.168.0.109" serverPort="9009" serviceName="EntityService" >
<clientSettings isDistributed="true" />
</objectServer>-->
<objectServer>
<clientSettings isDistributed="true" />
</objectServer>
<!-- Additional configuration can be added to override defaults.
See the sample config files in the Learning Resources for more information.
-->
</ideablade.configuration>
<system.serviceModel>
<client>
<!--<endpoint name="EntityService"
address="http://192.168.0.109:9009/EntityService"
binding="wsHttpBinding" bindingConfiguration="wsHttpDefault"
contract="IdeaBlade.EntityModel.IEntityServiceContract"
/>
<endpoint name="EntityServer"
address="http://192.168.0.109:9009/EntityServer"
binding="wsHttpBinding" bindingConfiguration="wsHttpDefault"
contract="IdeaBlade.EntityModel.IEntityServerContract"
/>-->
<endpoint name="EntityService"
address="http://192.168.0.109:9009/EntityService"
binding="customBinding" bindingConfiguration="compressedBinaryBinding"
contract="IdeaBlade.EntityModel.IEntityServiceContract"
/>
<endpoint name="EntityServer"
address="http://192.168.0.109:9009/EntityServer"
binding="customBinding" bindingConfiguration="compressedBinaryBinding"
contract="IdeaBlade.EntityModel.IEntityServerContract"
/>

</client>
<extensions>
<bindingElementExtensions>
<add name="gzipMessageEncoding"
type="IdeaBlade.Core.Wcf.Extensions.GZipMessageEncodingElement, IdeaBlade.Core"/>
</bindingElementExtensions>
</extensions>
<bindings>
<customBinding>
<binding name="compressedBinaryBinding" closeTimeout="00:01:00" openTimeout="00:01:00" receiveTimeout="00:10:00"
sendTimeout="00:01:00">
<gzipMessageEncoding>
<readerQuotas maxDepth="2147483647" maxStringContentLength="2147483647" maxArrayLength="2147483647" />
</gzipMessageEncoding>
<httpTransport maxReceivedMessageSize="2147483647" />
</binding>
</customBinding>
<wsHttpBinding>
<!-- Standard wsHttp binding - uses Windows auth and message security by default.
To use, on the endpoint definitions above,
change the bindingConfiguration name to "wsHttpDefault"
and the binding to "wsHttpBinding". -->
<binding name="wsHttpDefault" maxReceivedMessageSize="2147483647" />
</wsHttpBinding>
</bindings>
</system.serviceModel>
</configuration>
 
 
Back to Top
kimj View Drop Down
IdeaBlade
IdeaBlade
Avatar

Joined: 09-May-2007
Posts: 1391
Post Options Post Options   Quote kimj Quote  Post ReplyReply Direct Link To This Post Posted: 26-Aug-2010 at 12:32pm
Are you getting this error message when editing the config file in Visual Studio or using the WCF Configuration Editor?  If so, then the error is innocuous, since it's just Intellisense complaining that it doesn't know that the IdeaBlade.Core assembly is in the GAC.  If you set Copy Local = true for the IdeaBlade.Core reference in your project the error may go away, since Intellisense should then find the assembly in your bin folder.
Back to Top
yafei View Drop Down
Newbie
Newbie


Joined: 25-Aug-2010
Location: los Angeles
Posts: 21
Post Options Post Options   Quote yafei Quote  Post ReplyReply Direct Link To This Post Posted: 26-Aug-2010 at 12:43pm

I got this error when I ran the WPF app. When I set Copy Local = true and the error goes away. It seems that WPF app doesn't use the IdeaBlade.Core.dll properly from GAC.

Back to Top
kimj View Drop Down
IdeaBlade
IdeaBlade
Avatar

Joined: 09-May-2007
Posts: 1391
Post Options Post Options   Quote kimj Quote  Post ReplyReply Direct Link To This Post Posted: 26-Aug-2010 at 1:51pm
Possibly.
 
For completeness I should add that you don't really need to use the system.serviceModel configuration information in a DevForce 2010 application.  In your case since you're currently using all DevForce defaults, you could instead remove the serviceModel section from both config files and allow DevForce to programmatically determine the configuration needed based on information in the <objectServer> element.
Back to Top
yafei View Drop Down
Newbie
Newbie


Joined: 25-Aug-2010
Location: los Angeles
Posts: 21
Post Options Post Options   Quote yafei Quote  Post ReplyReply Direct Link To This Post Posted: 26-Aug-2010 at 3:28pm
thank you very much.
 
Yafei
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down