Retry an http request

Hi,
          Is there a way to instruct an http client (browser) to re-issue the same
          http request it issued for this request ?
          The scenario is as follows :
          I have a client sending a "heavy" http post request, now when it arrives to
          the app.server
          I have a case in which I want to tell the client to try the request again in
          a delay of one minute,
          without the user of the browser being aware of this ?
          I tried the "Retry-After" header in http (according to the RFC) on the
          response object
          but it didnt work, (More then possible I didnt do it correct).
          The environment is : jsp pages with weblogic as http and app erver (5.1sp4
          on Win2000).
          Any thought or solution will be appreciated.
          Thanks.
          

Thanks for the link!
          Cameron Purdy
          [email protected]
          http://www.tangosol.com
          WebLogic Consulting Available
          "Marius" <[email protected]> wrote in message
          news:[email protected]...
          > Go to http://vancouver-webpages.com/META/ and study the HTTP META TAG
          > 'Refresh'.
          >
          > Cheers,
          > Marius
          >
          >
          >
          > "Asher Bitton" <[email protected]> wrote in message
          > news:[email protected]...> This is not good for me since
          > > I'm using weblogic's session management via the URL I cant perform
          > > GET operations, the encoding destroys the get parameters (unless they
          > > are manually put there, when building the url by code, which is not the
          > > case).
          > > I was looking for a programmatic way or if you know what is the HTTP
          meta
          > > tag I can study it and see maybe in some way it can help me.
          > >
          > > thanks in advance.
          > >
          > >
          > > "Alexandre POLOZOFF" <[email protected]> wrote in message
          > > news:[email protected]...
          > > > There is an HTML meta-tag that will allow you to do a GET and then use
          a
          > > > query string in the URL.
          > > >
          > > > --
          > > > -Alexandre POLOZOFF
          > > > [email protected]
          > > >
          > > >
          > > > "Asher Bitton" <[email protected]> wrote in message
          > > > news:[email protected]...
          > > > > Hi,
          > > > >
          > > > > Is there a way to instruct an http client (browser) to re-issue the
          > same
          > > > > http request it issued for this request ?
          > > > > The scenario is as follows :
          > > > > I have a client sending a "heavy" http post request, now when it
          > arrives
          > > > to
          > > > > the app.server
          > > > > I have a case in which I want to tell the client to try the request
          > > again
          > > > in
          > > > > a delay of one minute,
          > > > > without the user of the browser being aware of this ?
          > > > > I tried the "Retry-After" header in http (according to the RFC) on
          the
          > > > > response object
          > > > > but it didnt work, (More then possible I didnt do it correct).
          > > > > The environment is : jsp pages with weblogic as http and app erver
          > > (5.1sp4
          > > > > on Win2000).
          > > > >
          > > > > Any thought or solution will be appreciated.
          > > > >
          > > > > Thanks.
          > > > >
          > > > >
          > > > >
          > > > >
          > > >
          > > >
          > >
          > >
          >
          >
          

Similar Messages

  • Safe to retry Flex Web Service calls on HTTP request failures?

    I'm using Flex's web services layer to make SOAP calls to a back-end server. Once in a while, those calls fail with a generic RPC fault that looks like this:
    faultString="HTTP request error"
    faultCode="Server.Error.Request"
    faultDetail="Error #2032: Stream Error..."
    When this happens, is it safe to assume that the server didn't get the message and retry an otherwise non-idempotent request?

    Anyone have any ideas?

  • About the read from http request, I think it is a bug in weblogic

    Hi guys,
    sorry for the previous post, I press the wrong button, I didn't finished yet.
    I have experienced a problem when I try to read from http request in a web application.
    the following is my code:
    InputStreamReader isr = new InputStreamReader(new URL("www.myhost.com").openStream(),"8859_1");
    BufferedReader bfr = new BufferedReader(isr);
    String request = "";
    while((request = bfr.readLine()) != null)
    stringGotFromServer += request;
    the problem is it always hang in there when BufferdReader reach the end.
    but in java specification, BufferedReader should reture null if reaching the
    end.
    Does anyone have any good idea for that?
    Thanks in advance.

    Hi,
    I think if you follow the instructions as given in the example you will not have any problems.
    here are the instructions below
    "This example code demonstrates one technique of handling test failures.
    If this step fails, a dialog will be displayed giving options to Break, Terminate, or Retry.
    The On Fail Post Action calls the HandleTestFailure sequence which is
    another sequence in this sequence file.
    The sequence file has the SequenceFilePreStep Callback overridden where
    the initial statue of Runstate.SequenceFailed is stored in a local variable. Create a local variable in your sequence called SequenceAlreadyFailed which is a boolen.
    To use this in your sequence file:
    1. Copy the HandleTestFailure sequence to your sequence file.
    2. For a step to use this, you
    must set the On Fail Post Action to call the
    HandleTestFailure sequence.
    3. Override the PreStepCallback.
    4. Copy the step from this example's PreStepCallback to yours.
    5. Copy the TestFailureDialog.* files to the same directory as your sequence file.

  • How to test HTTP request for Sender SOAP Channel

    Hi all,
    We are testing Soap requests from SOAP UI tool.
    We are able to call HTTPS calls from SOAPUI tool, but unable to call HTTP request.
    we eanbles ssl and able to post https requests.
    please advice .
    Thanks
    RGDASARI

    Hi Stefan, I configured the way you have put it, but I get the error "no receiver could be determined"
    Here are my settings:
    Sender service - HTTP_SEND
    sender o/b interface - PROD_MSG_INT_OB_ASYNC
    receiver service - FILE_RECEIVE
    receiver i/b interface - PROD_MSG_INT_IB_ASYNC
    receiver communication channel - FILE adapter
    JAVA script:
    String Party       = "MFC";
    String Service     = "HTTP_SEND";
    String XINameSpace = "mfc%3Anamespace1";
    String Interface   = "PROD_MSG_INT_OB_ASYNC";
    String Url   = "http://nemo:8000/sap/xi/adapter_plain?";
    XML DATA File:
    <?xml version="1.0" encoding="UTF-8"?>
    <ns0:PRODUCT xmlns:ns0="mfc:namespace1">
    <ID>E</ID>
    <NAME>thank god</NAME>
    <BRAND>SOME BRAND</BRAND>
    </ns0:PRODUCT>
    Stefan Am I missing anything?
    XML error message:
    <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!--  Receiver Identification
      -->
    - <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">
      <SAP:Category>XIServer</SAP:Category>
      <SAP:Code area="RCVR_DETERMINATION">NO_RECEIVER_CASE_BE</SAP:Code>
      <SAP:P1 />
      <SAP:P2 />
      <SAP:P3 />
      <SAP:P4 />
      <SAP:AdditionalText />
      <SAP:ApplicationFaultMessage namespace="" />
      <SAP:Stack>No receiver could be determined</SAP:Stack>
      <SAP:Retry>N</SAP:Retry>
      </SAP:Error>
    It would be great if you have solution for this.
    Regards
    felix

  • Empty HTTP request received in SAP RFC test connection type G

    Hi all,
      While checking the RFC connection i am getting error,
    response_line               HTTP/1.0 500 Empty HTTP request received
    server_protocol             HTTP/1.0
    status_code                 500
    status_reason               Empty HTTP request received
    Please let me know if this is right.

    Hi,
      We are trying to connect to an external server. So, we are using Connection Type as G.
    RFC connection Test status is 500.
    But in our case, Idoc is getting generated but it is in the XI Box, throwing the below error,
    <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!-- Call Adapter
    -->
    - <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">
    <SAP:Category>XIServer</SAP:Category>
    <SAP:Code area="SECURITY">SECURITY_VERIFY_ERROR</SAP:Code>
    <SAP:P1>Check Signature</SAP:P1>
    <SAP:P2 />
    <SAP:P3 />
    <SAP:P4 />
    <SAP:AdditionalText>Signature error Error while valdiating the digital signature. Theerror was com.sap.security.core.ws.wss.NoSecurityHeaderException No wsse:Security header has been defined for role soap:finalActor. Please verify the</SAP:AdditionalText>
    <SAP:ApplicationFaultMessage namespace="" />
    <SAP:Stack>Error during message security handling in inbound channel: Security profile 'Check Signature'</SAP:Stack>
    <SAP:Retry>M</SAP:Retry>
    </SAP:Error>
    Since the RFC is working now, we were not able to find what is the issue. Even SSL certificates are valid.

  • Null values in Weblogic 7 HTTP Request Parameters

    It appears weblogic 7 handles nulls passed from the request object
              differently than the previous versions. In my jsp's, if a parameter
              was not passed, I used to get a java null value:
              String s = request.getParameter("something_not_passed");
              if(s == null) {
              //do stuff
              Now, weblogic seems to return the string literal "null" so I would
              have to use:
              if(s.equals("null")) {
              //do stuff
              Is this a bug or am I missing something?
              Thanks,
              Paul
              

    HI, Thanks for the reply. I am using getString() to fetch values.
    DO u think its due to driver incompatibility?? Because, BEA claims WL7.0 supports
    Oracle 8.1.7 onwards!
    Thanks,
    Yogesh
    Joseph Weinstein <[email protected]> wrote:
    >
    >
    Yogesh wrote:
    Hi, I have ported my web application from weblogic 5.1 to weblogic 7.Set up is weblogic
    7 with database Oracle 8.1.6 and i am using OCI driver for DB connectionpool. I
    am facing some problems like, the values that were retrieved as blanksin weblogic
    5.1 are being retrieved as null(string literal value) in 7. The same thinghappens
    when parameters were passed through HTTP request object. Any idea aboutthis?
    Thanks,
    YogeshHi. This sounds like a driver bug. Let's isolate it to a simple standalone
    program
    that uses our driver to select null data. How are you asking for the object?
    GetString(),
    GetObject()?
    Joe

  • Problem in sending HTTP request to the server.

    Hi,
    i dveloped an ant script for sar deployment.
    i deployed a sar to my local soa server with ant script. it got deployed succesfully..
    but when i try to deploy to a remote server, getting the below error..
    "Problem in sending HTTP request to the server. Please make sure the server is up and/or check standard HTTP response code for 404"
    but the server is up and runnig and i am able to ping it from my machine and also access the console...
    below is my script
    build.properties
    wn.bea.home=C:/Oracle/Middleware
    all.needed.jars.path=D:/SourceCode/neededJAR
    oracle.soa.home=C:/Oracle/Middleware/Oracle_SOA1
    java.passed.home=C:/Oracle/Middleware/jdk160_24
    #Deployment environment
    deployment.plan.environment=DEV
    #Deploy Action
    deployAction =redeploy
    #credentials
    user=weblogic
    password=welcome1
    #For Composite deployment
    serverURL=http://10.177.154.6:7001
    forceDefault=true
    server=10.177.154.6
    port=7001
    sarLocation=D:/SourceCode/JAR
    build.xml
    <?xml version="1.0" encoding="iso-8859-1"?>
    <project name="soaDeployAll" default="deployAll">
         <echo>basedir ${basedir}</echo>
         <property environment="env"/>
    <echo>current folder ${basedir}</echo>
         <property file="${basedir}/build.properties"/>
         <taskdef resource="net/sf/antcontrib/antlib.xml">
         <classpath>
              <pathelement location="${all.needed.jars.path}/ant-contrib.jar"/>           
         </classpath>
         </taskdef>
         <target name="init">
              <tstamp>
                   <format property="timestamp" pattern="yyyy-MM-dd_HH-mm-ss"/>
              </tstamp>
              <property name="build.log.dir" location="${basedir}/buildlogs"/>
              <mkdir dir="${build.log.dir}"/> <property name="build.log.filename" value="build_${timestamp}.log"/>
              <record name="${build.log.dir}/${build.log.filename}" loglevel="verbose" append="false"/>
              <echo message="Build logged to ${build.log.filename}"/>
         </target>
         <target name="deployAll" depends="init">
         <echo>Deploy for environment ${deployment.plan.environment}</echo>
         <antcall target="deployAllComposites"/>
    </target>
    <!-- Following Actions are performed for Composite files in Managed Server - Deploy,Redeploy -->
         <target name="deployAllComposites" depends="init">
         <foreach target="deployComposites" param="Files">
              <fileset dir="${sarLocation}" casesensitive="no" includes="*.jar"/>
         </foreach>
         </target>
         <target name="deployComposites" depends="init">
         <basename file="${Files}" property="basename"/>
    <echo>Deploy Project ${basename} for environment ${deployment.plan.environment}</echo>
              <if>
                   <equals arg1="${deployAction}" arg2="deploy" />
                   <then>
                        <echo message="Deploying composites in Managed server........." />
                        <ant antfile="${oracle.soa.home}/bin/ant-sca-deploy.xml" inheritAll="true" target="deploy">
                             <property name="serverURL" value="${serverURL}"/>
                             <property name="user" value="${user}"/>
                             <property name="password" value="${password}"/>
                             <property name="overwrite" value="false"/>
                             <property name="forceDefault" value="${forceDefault}"/>
                             <property name="sarLocation" value="${sarLocation}/${basename}"/>
                        </ant>
                   </then>
                   <else>
                        <echo message="ReDeploying composites in Managed server........." />
                        <ant antfile="${oracle.soa.home}/bin/ant-sca-deploy.xml" inheritAll="true" target="deploy">
                             <property name="serverURL" value="${serverURL}"/>
                             <property name="user" value="${user}"/>
                             <property name="password" value="${password}"/>
                             <property name="overwrite" value="true"/>
                             <property name="forceDefault" value="${forceDefault}"/>
                             <property name="sarLocation" value="${sarLocation}/${basename}"/>                         
                        </ant>
                   </else>
              </if>
    </target>
    </project>
    please help....

    Hi,
    Give the serverURL as http://<host>:<managed.server.port>/soa-infra/deployer and try.
    e.g . http://10.177.154.6:8001/soa-infra/deployer
    Regards,
    Neeraj Sehgal

  • How to send a http-request from abap?

    I want to send a xml file through a http-request ,what should i do?

    Welcome to SDN
    you can use cl_http_client class to do that. search the abap general forum with key word cl_http_client and you will find lot of examples.
    Regards
    Raja

  • How to construct a faces request from a http request?

    I wonder how FacesServlet.service determines whether it should be calling LifecycleImpl.execute in oppose to calling LifecycleImpl.render?
    Basically, I'm trying to construct a http request that would go through the decode method of my UIComponent. However, it seems that my request has always been treated as a non-faces request, where it goes to the render face directly.
    Does anyone know how do I need to construct my http request so that it'll be recgonized as a faces request?
    Anyone knows where i can download the source code for FacesServlet?
    thanks!

    Sorry, are you saying that FacesServlet ALWAYS call execute before render even if it's the first request?
    What I experienced is that for the first request, execute isn't called, and it goes directly to render.
    And if I use the html form submit on the 2nd request, it does go to execute, then render.
    However, if i construct another http request, it'll act like a first request, where it doesn't go through the execute, but striaght to render.
    This is what I set in web.xml:
    <servlet>
    <servlet-name>Faces Servlet</servlet-name>
    <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
    <load-on-startup> 1 </load-on-startup>
    </servlet>
    <!-- Faces Servlet Mapping -->
    <servlet-mapping>
    <servlet-name>Faces Servlet</servlet-name>
    <url-pattern>/faces/*</url-pattern>
    </servlet-mapping>
    I call my jsp using http://server:8080/faces/my.jsp, and I'm using tomcat 5. Any help would be appreciated.

  • How to pass a HTTP request from a simple java class

    Is it possible to pass an HTTP request from a simple java class.if yes how?

    Is it possible to pass an HTTP request from a simple
    java class.if yes how?If you're talking about creating a HttpRequest object and passing it to a servlet, that would be a red flag to me that your design is flawed. You shouldn't have to do that - the application server (Tomcat, Weblogic, etc) should be the only thing that has to worry about creating that kind of object and passing it to you.

  • How to make a http request from a pl/sql procedure(URGENT)

    I need to make a http request from a pl/sql procedure, can any one tell me which built-in package and which procedure/function we serve my need?
    Thanks in advance.
    Ram Prasad.

    You should use UTL_HTTP package, but before it install the JVM into DB

  • Application Web Service Control Manager detected AWEBSVC is not responding to HTTP requests

    Hi,
    We are using SCCM 2012 sp1 cu5 with one primary in the datacenter and a number of local DP's which are presently servicing 200 users, but will rise to 12,000. The Application Catalogue is installed on the primary server.
    Once a day we get the above error and the message id is 8101, and sometimes a user will have to click on install twice, with the first one failing (the ones that fail are normally with dependencies which are quite large in size around 250MB)
    I'm just wondering if this is something I should be concerned about, especially since we will be ramping up user numbers in the next few weeks, and if it could be down to volume of traffic, although the apps are downloaded to the users local DP.
    Also, does this design look suitable to service this amount of users, or should I have local application catalogues? The WAN bandwith between the datacenter and the user sites has recently been upgraded and is pretty fast.
    Thanks
    Jaz

    Hi Torsten,
    Message ID is in the SMS_AWEBSVC_CONTROL_MANAGER status log and equates to "Application Web Service Manager detected AWEBSVC is not responding to HTTP requests. The http error is 12002.
    Then, about 1 hr later in the same monitoring log I get Message ID 8102 "Application Web Service Control Manger detected AWEBSVC is responding to HTTP requests.
    At the moment it isn't doing this very often, just once a day at different times normally, but it has also logged this a couple of times as well. I guess it may correspond to multiple users accessing the web portal at multiple times, but wondered if
    anyone else has seen this behaviour and how it was fixed.
    Thanks
    Jaz

  • Application Web Service Control Manager detected AWEBSVC is not responding to HTTP requests. The http status code and text is 400, Bad Request.

    Hi All,
    I am seeing the following error for SMS_AWEBSVC_CONTROL_MANAGER component with Message ID: 8100
    Application Web Service Control Manager detected AWEBSVC is not responding to HTTP requests.  The http status code and text is 400, Bad Request.
    awebsctl.log file has below errors:
    Call to HttpSendRequestSync failed for port 80 with status code 400, text: Bad Request
    SMS_AWEBSVC_CONTROL_MANAGER 12/22/2014 3:37:55 PM
    13920 (0x3660)
    AWEBSVCs http check returned hr=0, bFailed=1
    SMS_AWEBSVC_CONTROL_MANAGER 12/22/2014 3:37:55 PM
    13920 (0x3660)
    AWEBSVC's previous status was 1 (0 = Online, 1 = Failed, 4 = Undefined)
    SMS_AWEBSVC_CONTROL_MANAGER 12/22/2014 3:37:55 PM
    13920 (0x3660)
    Health check request failed, status code is 400, 'Bad Request'.
    SMS_AWEBSVC_CONTROL_MANAGER 12/22/2014 3:37:55 PM
    13920 (0x3660)
    Management point and Application Catalog Website Point are installed on the same Server where I am seeing the error for Application Catalog Web Service Point role. Management Point and Application Catalog Website Point are functioning properly. Application
    Catalog Website is working.
    Thanks & Regards, Kedar

    Hi Jason,
    Application Catalog Web Service Point and Application Catalog Website Point; both are installed as per below configuration on same Server:
    IIS Website: Default Web Site
    Port Number: 80
    with default value for Web Application Name configured.
    For SMS_AWEBSVC_CONTROL_MANAGER component, I am getting below error in Component Status:
    Application Web Service Control Manager detected AWEBSVC is not responding to HTTP requests.  The http status code and text is 400, Bad Request.
    Possible cause: Internet Information Services (IIS) isn't configured to listen on the ports over which AWEBSVC is configured to communicate. 
    Solution: Verify that the designated Web Site is configured to use the same ports which AWEBSVC is configured to use.
    Possible cause: The designated Web Site is disabled in IIS. 
    Solution: Verify that the designated Web Site is enabled, and functioning properly.
    For more information, refer to Microsoft Knowledge Base.
    And awebsctl.log has the below error lines:
    Call to HttpSendRequestSync failed for port 80 with status code 400, text: Bad Request
    SMS_AWEBSVC_CONTROL_MANAGER
    12/23/2014 11:04:36 AM 16388 (0x4004)
    AWEBSVCs http check returned hr=0, bFailed=1
    SMS_AWEBSVC_CONTROL_MANAGER
    12/23/2014 11:04:36 AM 16388 (0x4004)
    AWEBSVC's previous status was 1 (0 = Online, 1 = Failed, 4 = Undefined)
    SMS_AWEBSVC_CONTROL_MANAGER
    12/23/2014 11:04:36 AM 16388 (0x4004)
    Health check request failed, status code is 400, 'Bad Request'.
    SMS_AWEBSVC_CONTROL_MANAGER
    12/23/2014 11:04:36 AM 16388 (0x4004)
    STATMSG: ID=8100
    What should I check from IIS side?
    Application Catalog Website is functioning properly.
    Thanks & regards,
    Kedar
    Thanks & Regards, Kedar

  • Multiple HTTP Requests in for loop response handling

    i am working on stock market portfolio. a user saves his stock name , buy price ,etc .i've added this details in database.but while viewing his portfolio he should even get the current price of d stocks he has added. while retrieving i fetch all data from database set them in a bean and for each stock i make a HTTP Request. in result handler i event set the current price into the bean. Problem is my entire application is displayed with all the CurrentPrice fields with null.
    private function selectContacts():void
        trace("select before");
        stmt.sqlConnection = this.isDbConnected(conn);
        stmt.text = "SELECT * FROM stocks_t";
        stmt.addEventListener(SQLErrorEvent.ERROR, sqlError);
        stmt.addEventListener(SQLEvent.RESULT, sqlResult);
        stmt.execute();
        trace("select after");
    private function sqlResult(res:SQLEvent):void{
        httpServ = new HTTPService();
        data1 = stmt.getResult().data;
        stockList = new ArrayCollection();   
        for(var d:int=0;d<=data1.length-1;d++)
            myPortfolioBean = new MyProtfolioBean();
            httpServ.url = 'http://quote.yahoo.com/d/quotes.csv?s='+data1[d].stockName+'&f=snl1a';
            httpServ.method = 'GET';
            httpServ.addEventListener(ResultEvent.RESULT,yDataResult);
            httpServ.addEventListener(FaultEvent.FAULT,yDataFault);
            httpServ.showBusyCursor= true;
            httpServ.send();
            myPortfolioBean.stockNameB = data1[d].stockName;
            myPortfolioBean.buyB = data1[d].buy;
            myPortfolioBean.quantityB = data1[d].quantity;
            myPortfolioBean.totalQuantityAmountB = data1[d].totalQuantityAmount;
            myPortfolioBean.profitB = data1[d].profit;
            stockList.addItem(myPortfolioBean);
    public function yDataResult(evt:ResultEvent):void
        var s:String = evt.result as String;
        var a:Array = s.split(",");
        //To add to a form or individual fields
        lastTraded =  a[2].toString();
        lastTradedFloat = parseFloat(lastTraded);
        myPortfolioBean.currentB = lastTradedFloat;
        stockList.addItem(myPortfolioBean);
        //stockList.addItem({current:lastTradedFloat});
    the yDataResult() is called after the entire datagrid is displayed on screen as a result of which the CurrentPrice in datagrid column in null. Eg: user has added google ,yahoo,apple( CurrentPrice  is null for all three values) after some time three more rows (as a result of call to yDataResult) with CurrentPrice xx.xx displayed. I want merged results.

    hello ,
    "CurrentPrice" is "lastTradedFloat" sorry for the ambiguity.
    and u got my problem but there is an issue ..
    all the results are set using "sqlResult" except the "lastTradedFloat" which is set in "ydataResult".
    but i confused with HTTP ResultEvent Execution.
    first "sqlResult" method is called arrayCollection is populated. then result is displayed on screen.( lastTraded value is null then)
    then "ydataResult" executes again manipulating data in arraycollection.
    what i want is data in "sqlResult" and "ydataResult" to be set sequentially then callin my display page . such that display is correct.

  • The MAC signature found in the HTTP request '***' is not the same as any computed signature. Server used following string to sign: 'POST

    Hi,
    When trying with Postman sending a REST call to Azure Storage Queues I get:
    The MAC signature found in the HTTP request '***' is not the same as any computed signature. Server used following string to sign: 'POST.
    The code I have for creating the Authorization Header:
    var accountName = "my_account";
    string key = ConfigurationManager.AppSettings["my_access_key"];
    DateTime dt = DateTime.Now;
    string formattedDate = String.Format("{0:r}", dt);
    var canonicalizedHeaders = "x-ms-date:" + formattedDate + "\n" + "x-ms-version:2009-09-19" + "\n" ;
    var canonicalizedResource = "/my_account/myqueue/messages";
    var stringToSign = String.Format("POST,\n\n\n\n\n\n\n\n\n\n\n{0}{1}", canonicalizedHeaders, canonicalizedResource);
    stringToSign = HttpUtility.UrlEncode(stringToSign);
    HMACSHA256 hmac = new HMACSHA256(Encoding.UTF8.GetBytes(key));
    var signature = Convert.ToBase64String(hmac.ComputeHash(Encoding.UTF8.GetBytes(stringToSign)));
    var authorizationHeader = String.Format(CultureInfo.InvariantCulture, "SharedKey {0}:{1}", accountName, signature);
    return authorizationHeader;
    Anyone any idea what I'm missing/doing wrong?
    Additional question: do i have to create for every message I want to send a new Authorization header? Or is there an option (as with Service Bus Topics) to create a header that can be used for a certain timeframe?
    Thanks.

    One issue is with this line of code:
    HMACSHA256 hmac = new HMACSHA256(Encoding.UTF8.GetBytes(key));
    Please use the following:
    HMACSHA256 hmac = new HMACSHA256(Convert.FromBase64String(key));
    and that should take care of the problem.
    Regarding your question, "do i have to create for every message I want to send a new Authorization header? Or is there an option (as with Service Bus Topics) to create a header that can be used for a certain timeframe?"
    With your current approach, the answer is yes. What you can do is create a Shared Access Signature on the queue which will be valid for certain duration and then use that for posting messages to a queue using simple HttpWebRequest/HttpWebResponse.
    Hope this helps.

Maybe you are looking for

  • Cannot Update any CS3 programs on Leopard??

    I recently upgraded to leopard 10.5.6 and i reinstalled CS3 with no problems but i can't update them without the installer freezing. I sometimes even need to force the computer to shut down. Has anyone else come across this problem. it's incredibly a

  • HT204053 Changed Apple ID names and no Apps will not use those changes

    Hello I was cleaning up a bunch of old history and renamed 4 of 5 apple accounts cleaning up family chaos over the last years.  Now my Apps updates ask for old Apple IDs and will not use renamed ones for same accounts or old passwords.  Please help.

  • Export Flash to .mov file

    I work with Flash CS5.5 on a MacPro with OS 10.7.5 with a 2 x 2.4 GHz Quad Core Intel Xeon processor and 32 GB 1066 MHz DDR3 memory with an ATI Radeon HD 5870 1024 MB graphics card. When I export my Flash to a .mov file the results are cluttered with

  • Firewire Recording Interface recommendations

    I'm looking for a Firewire interface to input about 8 to 12 channels from a band into Logic Pro. This Presonus Firestudio Project (8 channels for about $450 after rebate) looks reasonable but nowhere does it explicitly mention being compatible with L

  • Powershell NTFS Script

    Hi everybody! I've got some troubles with axiomatization of creating folders and NTFS sharing. I am using powershell to do it. But I am new with it. Could you please help with it? Get-ADUser -filter * -SearchBase "OU=users,DC=constro,DC=com" -propert