Sending a request to a servlet without waiting for a response

Hi,
I have a client application that needs to send information to a servlet for processing. I would like to be able to send the information in question without having to wait for a response from the servlet. The reason for this is that I want to speed up the "sending" process. I know that http communication is based on TCP which is a connection-oriented network protocol, but I thought maybe there was a work-around to this.
Thanks in advance for your help,
Chris

There r two ways to do this. First, if you can modify the application simply don't wait for the response do whatever you want and ignore the response. If you need the response in order to continue you will have to wait, but you can do this in a separate thread, while the main thread can do other things.
Second, if you can't modify the application but you can modify the servlet, make the servlet respond as quick as possible, doing the work after having answered. Once again if the application needs the results of the process there is no way, you'll have to wait.

Similar Messages

  • How to make a multiple request without waiting for a response in java ?

    A more specific question:
    how to make a multiple HTTP request without waiting for a HTTP response in java (using httpURLConnection)?
    Thanks

    Thanks for responding.
    But i want to make further request to the same resource URL. I want to reuse the connection, don't want to create a new connection for each of individual request.
    How can i do that using HttpURLConnection ?
    Thanks.

  • Display a message without waiting for user response

    Hi,
    I'm currently trying to find the best way to display a message, and multiple messages to the user, so that he is informed of the processing.
    I've tryied the dialog box but it's waiting for user confirmation so it interrupts the execution of the VI.
    Another precision is that I call the dialog in a case structure, so does it act?
    I'm thinking about using a VI dedicated to the displaying of the message but I may not be able to display multiple message boxes.
    Can anyone help me to use the best way?
    Thank you in advance.
    Bim

    You can build the message display into your vi by using the techniques shown in the attached vi (LV7.1.1)
    It is just a string indicator with large font size, and using property nodes to show/hide when necessary.
    - tbob
    Inventor of the WORM Global
    Attachments:
    MessageDisplay.vi ‏31 KB

  • Unhandled Exception: System.TimeoutException: The request channel timed out while waiting for a reply after 00:01:59.9139778.Increase the timeout value passed to the call to Request or increase the SendTimeout value on the Binding.

    Hi, 
    I created a simple plugin and since i wanted to use Early Binding i added Xrm.cs file to my solution.After i tried registering the plugin (using the Plugin Registration Tool) the plugin does not gets registered and i get the below mentioned Exception.
    Unhandled Exception: System.TimeoutException: The request channel timed out while waiting for a reply after 00:01:59.9139778. Increase the timeout value passed to the call to Request or increase the SendTimeout value on the Binding. The time allotted to this
    operation may have been a portion of a longer timeout.
    Server stack trace: 
       at System.ServiceModel.Channels.RequestChannel.Request(Message message, TimeSpan timeout)
       at System.ServiceModel.Channels.SecurityChannelFactory`1.SecurityRequestChannel.Request(Message message, TimeSpan timeout)
       at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)
       at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)
       at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)
    Exception rethrown at [0]: 
       at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
       at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
       at Microsoft.Xrm.Sdk.IOrganizationService.Update(Entity entity)
       at Microsoft.Xrm.Sdk.Client.OrganizationServiceProxy.UpdateCore(Entity entity)
       at Microsoft.Crm.Tools.PluginRegistration.RegistrationHelper.UpdateAssembly(CrmOrganization org, String pathToAssembly, CrmPluginAssembly assembly, PluginType[] type)
       at Microsoft.Crm.Tools.PluginRegistration.PluginRegistrationForm.btnRegister_Click(Object sender, EventArgs e)
    Inner Exception: System.TimeoutException: The HTTP request to 'https://demoorg172.api.crm.dynamics.com/XRMServices/2011/Organization.svc' has exceeded the allotted timeout of 00:01:59.9430000. The time allotted to this operation may have been a portion of a
    longer timeout.
       at System.ServiceModel.Channels.HttpChannelUtilities.ProcessGetResponseWebException(WebException webException, HttpWebRequest request, HttpAbortReason abortReason)
       at System.ServiceModel.Channels.HttpChannelFactory`1.HttpRequestChannel.HttpChannelRequest.WaitForReply(TimeSpan timeout)
       at System.ServiceModel.Channels.RequestChannel.Request(Message message, TimeSpan timeout)
    Inner Exception: System.Net.WebException: The operation has timed out
       at System.Net.HttpWebRequest.GetResponse()
       at System.ServiceModel.Channels.HttpChannelFactory`1.HttpRequestChannel.HttpChannelRequest.WaitForReply(TimeSpan timeout)
    And to my Surprise after i remove the Xrm.cs file from my solution the Plugin got registered!
    Not understanding what exactly is the issue.
    Any Suggestions are highly appreciated.
    Thanks,
    Shradha
      

    Hello Shardha,
                            I really appreciate that you have faced this issue.This is really very strange issue and basically it occurs because of big size of your early bound class and slow internet
    connection.
                            I would strictly recommend you to reduce the file size of your early bound class and then register.By default early bound class is created for all the entities which are
    present in CRM(System entities as well custom entities).Such kind of early bound classes takes lots of time to register on server and hence timeout exception comes.
                            There is some standard define to reduce the size of early bound class.Please follow the link to get rid from big size of early bound class.
    Create a new C# class library project in Visual Studio called SvcUtilFilter.
    In the project, add references to the following:
    CrmSvcUtil.exe(from sdk)   This exe has the interface we will implement.
    Microsoft.Xrm.Sdk.dll  (found in the CRM SDK).
    System.Runtime.Serialization.
      Add the following class to the project:
    using System;
    using System.Collections.Generic;
    using System.Xml.Linq;
    using Microsoft.Crm.Services.Utility;
    using Microsoft.Xrm.Sdk.Metadata;
    namespace SvcUtilFilter
        /// <summary>
        /// CodeWriterFilter for CrmSvcUtil that reads list of entities from an xml file to
        /// determine whether or not the entity class should be generated.
        /// </summary>
        public class CodeWriterFilter : ICodeWriterFilterService
            //list of entity names to generate classes for.
            private HashSet<string> _validEntities = new HashSet<string>();
            //reference to the default service.
            private ICodeWriterFilterService _defaultService = null;
            /// <summary>
            /// constructor
            /// </summary>
            /// <param name="defaultService">default
    implementation</param>
            public CodeWriterFilter( ICodeWriterFilterService defaultService )
                this._defaultService = defaultService;
                LoadFilterData();
            /// <summary>
            /// loads the entity filter data from the filter.xml file
            /// </summary>
            private void LoadFilterData()
                XElement xml = XElement.Load("filter.xml");
                XElement entitiesElement = xml.Element("entities");
                foreach (XElement entityElement in entitiesElement.Elements("entity"))
                    _validEntities.Add(entityElement.Value.ToLowerInvariant());
            /// <summary>
            /// /Use filter entity list to determine if the entity class should be generated.
            /// </summary>
            public bool GenerateEntity(EntityMetadata entityMetadata, IServiceProvider services)
                return (_validEntities.Contains(entityMetadata.LogicalName.ToLowerInvariant()));
            //All other methods just use default implementation:
            public bool GenerateAttribute(AttributeMetadata attributeMetadata, IServiceProvider services)
                return _defaultService.GenerateAttribute(attributeMetadata, services);
            public bool GenerateOption(OptionMetadata optionMetadata, IServiceProvider services)
                return _defaultService.GenerateOption(optionMetadata, services);
            public bool GenerateOptionSet(OptionSetMetadataBase optionSetMetadata, IServiceProvider services)
                return _defaultService.GenerateOptionSet(optionSetMetadata, services);
            public bool GenerateRelationship(RelationshipMetadataBase relationshipMetadata, EntityMetadata otherEntityMetadata, IServiceProviderservices)
                return _defaultService.GenerateRelationship(relationshipMetadata, otherEntityMetadata, services);
            public bool GenerateServiceContext(IServiceProvider services)
                return _defaultService.GenerateServiceContext(services);
    This class implements the ICodeWriterFilterService interface.  This interface is used by the class generation
    utility to determine which entities, attrributes, etc. should actually be generated.  The interface is very simple and just has seven methods that are passed metadata info and return a boolean indicating whether or not the metadata should be included
    in the generated code file.   
    For now I just want to be able to determine which entities are generated, so in the constructor I read from an XML
    file (filter.xml) that holds the list of entities to generate and put the list in a Hashset.  The format of the xml is this:
    <filter>
      <entities>
        <entity>systemuser</entity>
        <entity>team</entity>
        <entity>role</entity>
        <entity>businessunit</entity>
      </entities>
    </filter>
    Take a look at the methods in the class. In the GenerateEntity method, we can simply check the EntityMetadata parameter
    against our list of valid entities and return true if it's an entity that we want to generate.
    For all of the other methods we want to just do whatever the default implementation of the utility is.  Notice
    how the constructor of the class accepts a defaultService parameter.  We can just save a reference to this default service and use it whenever we want to stick with the default behavior.  All of the other methods in the class just call the default
    service.
    To use our extension when running the utility, we just have to make sure the compiled DLL and the filter.xml file
    are in the same folder as CrmSvcUtil.exe, and set the /codewriterfilter command-line argument when running the utility (as described in the SDK):
    crmsvcutil.exe /url:http://<server>/<org>/XrmServices/2011/Organization.svc /out:sdk.cs  /namespace:<namespace> /codewriterfilter:SvcUtilFilter.CodeWriterFilter,SvcUtilFilter
    /username:[email protected] /password:xxxx
    That's it! You now have a generated sdk.cs file that is only a few hundred kilobytes instead of 5MB. 
    One final note:  There is actually a lot more you can do with extensions to the code generation utility. 
    For example: if you return true in the GenerateOptionSet method, it will actually generated Enums for each CRM picklist (which it doesn't normally do by default).
    Also, the source code for this SvcUtilFilter example can be found here. 
    Use at your own risk, no warranties, etc. etc. 
    Please mark as a answer if this post is useful to you.

  • How can I download a transfer without waiting for it be all transferred?

    How can I download a transfer without waiting for it be all transferred? Thanks.

    Thanks, that now makes sense. Once an item enters the download queue, the user cannot remove it. Either let it complete the download (easiest) or contact the iTunes Store customer support department through the Contact page (select the category and subcategory closest to the issue you're reporting and you'll find either an "Express Lane" button - just follow the instructions to get to the contact form - or an "Email Us" button) and ask them if they'll remove the item(s) from your queue for you.
    Regards.

  • Sync without waiting for backup

    I have looked around in "Preferences" but I cannot seem to be able to find any way to sync my iPad without waiting for a slow backup.  My iPad has been backed up hundreds of times.  I don't feel the need to do it every time I sync.
    iTunes version
    11.2.2 (3)

    I just tried it with my iPhone.
    I don't see a dialogue box.
    Do you mean at the top where I have placed a red arrow?
    That's not an X, it's something else and clicking on it does nothing.

  • Is there a way to passcode lock my iPhone without waiting for the preset idle time?

    Is there a way to passcode lock my iPhone without waiting for the preset time?
    My iPhone is set up to require a passcode after 15 minutes of idle time. Normally, this setting works best for me. However, there are times when I would like to lock it immediately, without waiting for the 15 minutes of idle time to pass. Is there a way to do that easily, without changing my settings? I know that I can click the power button to immediately kill the screen, but that just defaults to "slide to open" with no passcode required.
    Just to clarify, the idea is to leave my 15 minute setting, since this is the way I like it 98% if the time. I'm just wondering if, let's say I am resting my phone down while a curious person is around, I can quickly pass code lock it, much like I could just click the power button to put it to sleep.

    Unfortunately, my phone doesn't ask for the passcode when I do this (just slide-to-open). I've searched settings, but I don't see any way to set it up to require the passcode after the screen is locked with the power button.
    Do you remember how you set your iPhone up to achieve this?

  • Azure Service Bus client: Best way to wait for server response?

    Hi,
    I have a web service that needs to send a request on Azure Service Bus and wait for the response. The web service must operate synchronous as seen from the web service client, that is:
    public Response WebServiceMethod(Request)
    senderQueueClient.Send(Request);
    // wait for response from receiverQueueClient
    // and return to web serviuce client
    return response;
    This can be solved using mutexes that are updated in "receiverClientQueue.OnMessage". But that is hard work and if I Google the matter, I find several options to deal with this - especially when using .NET 4.5.  And there are also some built-in
    stuff in the QueueClient.
    But how to do this best? Can someone point me in the right (easy) direction?
    Werner

    Hi,
    May I know what are you use queue to achieve? can you give us further information for a better help.
    Regards

  • Jakarta HTTPClient , dont wont to wait for a response.

    Hi there.
    I wonder if I can do that , I want to send a post\get request to another server but I don�t want to wait for a response from it.
    Actually, I want to continue with my program regardless to the response and don�t want to be delayed while waiting.
    How can I do it?
    Hope I made myself clear, thanks.
    Shlomi

    spawn a Thread that will send the request. When it's time to process the response, check the Thread to see if any response was returned from the server.
    example
    public class MyThread extends Thread{
        private String response = null;
        private int status = 0;
        private boolean complete = false;
        public void run(){
             // TODO: et the response from the server
             // set the response and status and complete (synchronize all variable when doing this)
        public boolean isComplete(){
            return complete;
        public String getStatus(){ return status; }
        public String getResponse(){ return response; }
    public class Demo(){
        public static void main(String args[]){
            // do some work
            MyThread thread = new MyThread();
            thread.start();
            // do some more work (don't wait for server response
            // now it's time to get the response
            while (!thread.isComplete()){
                try{   Thread.sleep(1000); } // sleep for 1 second
                catch (Exception e){ }
            String response = thread.getResponse();

  • How to call a ALSB Proxy Service and don't wait for his response. Publish M

    Hi,
    I have a Proxy Service called PS1 that will invoke and another Proxy service Called PS_ProcessingNode that invokes 10 differents webservices during the orchestration and takes about 2 minuts.
    I would like that if invoke PS1 that will invokes PS_ProcessingNode (asyncronously) and immediatly PS1 will return "OK" (don't wait for the response of PS_ProcessingNode) .
    For simulate this scenario I am testing with:
    - PS_Processing is a WSDL without response that has a JavaCallout with a Sleeper of 10 seconds.
    - PS invokes with "Publish action" to PS_ProcessingNode but is waiting for PS_Processsing finish. I don't want this beahivour.
    How I can do it for PS doesn't wait for the response of the PS_ProcessingNode?
    Thanks.

    - PS invokes with "Publish action" to PS_ProcessingNode but is waiting for PS_Processsing finish. I don't want this behavior.
    I'm glad you have a solution using JMS. But still Publish action should not wait for response. If you are seeing that behavior, you can contact Support with an SR to get it fixed.
    Manoj

  • CCP related: A timeout occured waiting for a response from the ECU

    Hello All,
                I had just started using ECU Calibration tool kit software. Iam using USB 8473 for my application.When I tried to run the VI after loading the *.A2L file, I see an error message saying "A timeout occured waiting for a response from the ECU ". Does anyone know how to communicate with the ECU through CCP.
            Iam pretty sure that Iam using the right cable. I also checked the address of the parameters using Get property.vi what iam trying to read, wether they are matching with the address in the *.A2L file or not.They are matching. However I was able to communicate with my ECU when I use the same device to read the data over J1939 data link, based on arbitration ID's, with the Vi's from CAN Frame to Channel Conversion Library.
        Can any pls help me out how to communicate with my ECU using CAN Calibration Toolkit software.
    -Lucky.

    Hello,
              I am sending you an attachment of the manual for the ECU Calibration tool kit . Please go through the manual it will clarify your doubt. Moreover , check for can vi's in the example finder in labVIEW. Those will help ....
    I am sending you a link which gives you some insight about the installation of  CCP command set and the use of the toolkit with the USB CAN hardware.
    http://digital.ni.com/softlib.nsf/websearch/D7DE248D07CAD00086256ED3004BAB8A?opendocument&node=13206...
    Drivers and Updates: ECU Measurement and Calibration Toolkit 2.1
    Attachments:
    can manual.pdf ‏1437 KB

  • Firefox freezes about five seconds after I open it, and whenever I use Ctrl+alt+delete to close it I get told that it is waiting for a response from me.

    I am having a problem with Firefox. Whenever I open it, it runs fine for about five seconds and then freezes. A small white rectangle appears in the upper left corner of the browser window. The screen still scrolls fine, but whenever I try clicking on anything (including the menus in the toolbar), it just gives me an unresponsive 'ding' sound. When I try closing the programme with Ctrl+alt+delete, I get a message saying 'The system cannot end this programme as it is waiting for a response from you'. I originally had this problem with an earlier version of Firefox and tried installing Firefox 4 to see if this helped. It worked for two days and began doing it again. I have already tried un- and re-installing Firefox and restarting my computer, and Firefox will not run properly for long enough to let me disable any add-ons or plug-ins. What can I do to fix this?
    I've added a couple of screencaps of the problem. (or tried to)
    [http://i53.tinypic.com/161hvh2.jpg The white rectangle]
    [http://i51.tinypic.com/dwsq1.png Error message]

    Have also since found out that to start FF4 in safe mode you just hold shift whilst double-clicking the icon. We only find these things out after the event, murphy's law!

  • Still waiting for a response from Adobe regarding the post "Printing a pdf from a marked-up pdf".

    Still waiting for a response from Adobe regarding the post "Printing a pdf from a marked-up pdf" dated 15 Dec 2012 9:20 AM.

    Look everyone that comes here with a support problems has gone through all the normal channels, around and  round in circles with no one seeming to be interested. They've called every phone number, every email address they can find. They have been put on hold and bounced fifty times to another operator only to be hung up on. If Adobe would bring back support to main land and have people that know what's going on instead of having people that people can barely understand read from scripts. Scripted information only applies about 10 % of the time. I'm just giving people an alternative. after they have torn their hair out going the normal route.  If they had been able to get a solution they wouldn't be coming here for help.
    There should be a forum set up just for people to air these issues and Adobe employees forced to man it. Then we wouldn't have to have such a Bad attitude. Right now Adobe's Support reputation is worse than Intuit's which did have the absolutely worse on the Planet. Now they are number 2.
    You know it yourself that Adobe's support is absolutely worse than terible. However to prevent me from being banned from the forums I will simply will provide the adobecare email address from now on
    So let's sweep it under the rug.

  • Remote Function module to wait for the response.

    Hi .
    i just created the remote function module to call the webmethod by putting the parameters in tables (tab) for webmethods to pick the data from RFC and parameters in changing (tab) to collect the reponse from webmethods ,i just want to know if this is the right way of creating the RFC for webmethods and the RFC need to wait for certain time until it should get the response from webmethods.
    can any body guide me in this on how i can make the rfc to wait untill it will get the response from webmethods.
    waiting for your response.
    regards.
    Varma

    Hi Jaswanth,
    FM used to upload the data from the non sap system to the SAP sytem is the GUI_UPLOAD ans GUI_DOWLOAD is downloading the data from SAP to the presentation server .This file can be xls,tab or space deliminatior ettxt fiel.
    I think this was your requirement.
    Pooja

  • Ichat "waiting for a response"

    HI,
    I just made an AOL account so i could ichat with my friend. When i try to initiate a call it keeps saying "waiting for a response". When she tries to call me
    it says the same thing for her. What do i do?
    PS: I dont even get a message to accept the call
    I have OS X mavericks

    Hi,
    IF you are sure iChat is set up correctly are you sure your routing device is ?
    There are ways to get AIM or Google Logins to access the servers to see your Buddy List by dropping the login port to 443
    However this will not allow you to Video Chat (Audio Only Chat or Screen Share)
    I am also not sure if you are trying to chat from AIM to AIM or Jabber to Jabber Buddies (you cannot do AIM to Jabber)
    8:18 PM      Sunday; October 30, 2011
    Please, if posting Logs, do not post any Log info after the line "Binary Images for iChat"
     G4/1GhzDual MDD (Leopard 10.5.8)
     MacBookPro 2Gb( 10.6.8)
     Mac OS X (10.6.8),
    "Limit the Logs to the Bits above Binary Images."  No, Seriously

Maybe you are looking for