Consumer producer

hi
iam learning Threads in java..i know its a simple question but can can anybody please explain me the concept, the flow
of control in the following example of consumer and producer?..as iam not very clear about it....iam interested to know how excatly interthread communication is taking place....
.how does while(true) executes....because for both producer thread and consumer thread the condition is checked with true....
class Queue
     int n;
     boolean valueset=false;
     synchronized public void put(int n)
          if(valueset)
          try{
               wait();
          }catch(InterruptedException e)
               System.out.println("Interrupted");
          this.n=n;
          valueset=true;
          System.out.println("Put: "+n);
          notify();
     synchronized int get()
               if(!valueset)
try
               wait();
          }catch(InterruptedException e)
               System.out.println("Interrupted");
          System.out.println("Got:"+n);
          valueset=false;
          notify();
          return n;
class Producer implements Runnable
     Queue q;
     public Producer(Queue q)
          this.q=q;
          //int i=0;
          new Thread(this,"Producer").start();
     public void run()
          int i=0;
          while(true)
               q.put(i++);
class Consumer implements Runnable
     Queue q;
     public Consumer(Queue q)
          this.q=q;
          new Thread(this,"Consumer").start();
     public void run()
          while(true)
               q.get();
class Conandpro
     public static void main(String args[])
          Queue q=new Queue();
          Producer p=new Producer(q);
          Consumer c=new Consumer(q);
          System.out.println("press control-c to stop");
}

When you post code, please use [code] and [/code] tags as described in Formatting Help on the message entry page. It makes it much easier to read and prevents accidental markup from array indices like [i].
Because your put() method is synchronized, a producer entering that method acquires a lock on Queue - no other threads can get in any synchronized method of Queue.
If the value has not been set, the producer adds a value and notifies any waiting threads that a value is available. If the value is already set, The Queue object calls wait() and releases the lock acquired by the producer, and - of course - waits to be notified. Since the lock has been released, the thread scheduler automagically wakes up another waiting thread; in this case, the consumer, who can then call get() and retrieve the value.
The consumer acts similarly, but with regards to the get() method.

Similar Messages

  • Is it a proper way to use queue for consumer/producer model?

    Hi all,
      I am following the example of consumer/producer model to use the queue to synchronize the following process: The producer is a loop to produce N numbers, I will put every generated number into an array and after every 5 numbers generated, I put the array into the queue and pass it to the consumer. I have to wait the consumer use up the data and it will then remove the element from queue so the producer will get a chance to produce another 5 numbers. Since I set the maximum size of the queue to be ONE, I expect the producer and consumer take turns to produce / consume all five numbers and pass the chance to the other. Here is my code
    when the case box is false, the code will be
    For the first 5 numbers, the produce will generate every thing right and put that into the array, and it will pass the array to the quere so the consumer will get a chance to loop over the array. I except the procude's loop will continue only when the queue is available (i.e. all elements are removed), but it seems that once the consumer start the loop the produce 's loop will continue (so the indicator x+1 and x+2 will show numbers changed). But it is not what I want, I know there must be something wrong but I can't tell what is it.
    Solved!
    Go to Solution.

    dragondriver wrote:
    As you said in 1, the sequency structure enforcing the execution order, that's why I put it there, in this example, to put the issue simple, I replace the complete code with number increase, in the real case, the first +1 and +2 must be executed in that order.
    Mikeporter mentioned:
    1. Get rid of all the sequence structures. None of them are doing anything but enforcing an execution order that would be the same without them.
    So even if you remove the sequence structure, there will be a fixed & defined execution order and that is because LabVIEW follows DATA FLOW MODEL.
    Data Flow Model (specifically in context of LabVIEW): A block diagram node executes when it receives all required inputs. When a node executes, it produces output data and passes the data to the next node in the dataflow path. The movement of data through the nodes determines the execution order of the VIs and functions on the block diagram (Click here for reference).
    Now in your code, just removing the sequence structure will not make sure that the execution order will gonna remain same but you need to do few very small modifications (like pass the error wire through For loop, before it goes to 'Dequeue Element' node).
    Coming to the main topic: is it a proper way to use queue for consumer/producer model?
    The model you're using (and calling it as consumer/producer model) is way too deviated from the original consumer/producer model model.
    dragondriver wrote:
    For the second one, yes, it is my fault to remove that while. I actually start from the example of Producer/Consumer design pattern template, but I didn't pay attention to the while loop in the consumer part.
    While loops (both Producer & Consumer) are the essential part of this architecture and can't be removed. You may want to start your code again using standard template.
    I am not allergic to Kudos, in fact I love Kudos.
     Make your LabVIEW experience more CONVENIENT.

  • Consumer/producer fast AI and AO.

    I made a routine for fast DAQmx (PXIe-6124) acquisition in two while loop (consumer and producer).
    Currently it can be run by pushing run-button. 
    But, I would like to one more while loop (totally 3) for user-friendly interface and integrating sub-program using event structure.
    Among troubles I thought, these three loops can affect the acquisition speed of DAQmx.
    For example, if I send a "Acquire" signal to producer and consumer of DAQmx from event loop,
    this mean I also have to send "Stop" command.
    This requires more functions in every real-time acquisition iteration.
    -conditional state loop and cluster bundle of 2D(500*500 DBL array) and variant of command enum or data to control consumer loop in producer of DAQmx.
    -conditional state loop for next step and cluster unbundle of data in consumer loop.
    My question is...
    Are there some special or rule-of-thumb techniques for continuous, fast and large data DAQmx acquisition in producer and consumer using three while loops?
    Instead of this, do I had better use call-by-reference under other main program?
    labmaster.
    *)I am sorry I can't post my code because of modifying and hidden subVIs. 

    You will need some logic in your producer loop to execute the stop command sent by the first while loop but won't need one for the consumer loop since it can stop on error when the producer loop is stopped and the queue you are reading from is destroyed.
    Adnan Zafar
    Certified LabVIEW Architect
    Coleman Technologies

  • Consumer producer - Acquisiton image but only producer loop run

    Dear all
    I try acquire and save image from Basler camera L301kc and NI PCe 1427 framegrabber. I create a producer/ consumer loop because the save take more time that the acquisition and if I do both in the same loop I lose frames. But I have problem: only producer loop run.
    I have read all the threads but I didn't manage to solve my problem.
    I have attached a VI code of how I was trying to do it. I am using LabView 2011.
    Please any comments or help is deeply appreciated.
    Thank in advance
    XuanThuy
    Solved!
    Go to Solution.
    Attachments:
    Acquisition Image for Sample 03.vi ‏75 KB

    Dear Kira T,
    The producer and consumer loop has run but the Image Out in consumer loop is empty. Bruce attention to the error wire from the consumer loop wired to the destroy queue vi. But I don't find error.
    I have attached a new VI code.
    Can you help me ?
    Thanks and regards
    XuanThuy
    Attachments:
    Acquisition Image for Sample 03.vi ‏71 KB
    Linescan camera setup Sub VI.vi ‏26 KB

  • WSRP Consumer - producer registration error : (100)continue return code

    I am trying to get an ALI WSRP Consumer working with the ALI WSRP Producer. Whenever I try to register the producer wsdl, the consumer fails with the error :
    Failed to get a service description from WSRP provider!
    Error message from WSRP provider: (100)Continue
    Any clues? I can successfully register this producer with a different portal's consumer. Is there a configuration property that needs to be set to allow the (100) response code? Or perhaps my Producer should avoid that response code in the first place? Has anybody run into this?
    Below is the stack trace generated by my consumer on the back-end (from ALI Logging Spy) :
    Failed to get service description from WSRP provider: http://scollins.sd.defenseweb.net:80/wsrpproducer1.1/1.0/WSRPBaseService.asmx
    AxisFault
    faultCode: {http://xml.apache.org/axis/}HTTP
    faultSubcode:
    faultString: (100)Continue
    faultActor:
    faultNode:
    faultDetail:
         {}string: return code: 100
    HTTP/1.1 200 OK
    Server: Microsoft-IIS/5.1
    Date: Wed, 22 Apr 2009 23:31:53 GMT
    X-Powered-By: ASP.NET
    Connection: close
    X-AspNet-Version: 2.0.50727
    Cache-Control: private, max-age=0
    Content-Type: text/xml; charset=utf-8
    Content-Length: 3084
    <?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:wsa="http://schemas.xmlsoap.org/ws/2004/03/addressing" xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"><soap:Header><wsa:Action>urn:oasis:names:tc:wsrp:v1:getServiceDescriptionResponse</wsa:Action><wsa:MessageID>uuid:dc3a3069-320a-4a6d-a997-45313098bc00</wsa:MessageID><wsa:RelatesTo>uuid:c827c145-c82d-4958-a201-30e7a86c053b</wsa:RelatesTo><wsa:To>http://schemas.xmlsoap.org/ws/2004/03/addressing/role/anonymous</wsa:To><wsse:Security><wsu:Timestamp wsu:Id="Timestamp-18d05f2a-c5dd-4519-8d1d-24b68f27b9e5"><wsu:Created>2009-04-22T23:31:54Z</wsu:Created><wsu:Expires>2009-04-22T23:36:54Z</wsu:Expires></wsu:Timestamp></wsse:Security></soap:Header><soap:Body><getServiceDescriptionResponse xmlns="urn:oasis:names:tc:wsrp:v1:types"><requiresRegistration>false</requiresRegistration><offeredPortlets><portletHandle>simple</portletHandle><markupTypes><mimeType>text/html</mimeType><modes>wsrp:edit</modes><modes>wsrp:help</modes><modes>wsrp:view</modes><windowStates>wsrp:maximized</windowStates><windowStates>wsrp:minimized</windowStates><windowStates>wsrp:normal</windowStates><windowStates>wsrp:solo</windowStates><locales>en</locales></markupTypes><description xml:lang="en"><value>Simple view portlet to test WSRP viewing</value></description><shortTitle xml:lang="en"><value>View</value></shortTitle><title xml:lang="en"><value>View Portlet</value></title><displayName xml:lang="en"><value>SimpleView</value></displayName><userProfileItems>UserProfileName/PropertyName</userProfileItems><templatesStoredInSession>true</templatesStoredInSession><doesUrlTemplateProcessing>true</doesUrlTemplateProcessing></offeredPortlets><offeredPortlets><portletHandle>helloworld</portletHandle><markupTypes><mimeType>text/html</mimeType><modes>wsrp:edit</modes><modes>wsrp:help</modes><modes>wsrp:view</modes><windowStates>wsrp:maximized</windowStates><windowStates>wsrp:minimized</windowStates><windowStates>wsrp:normal</windowStates><windowStates>wsrp:solo</windowStates><locales>en</locales></markupTypes><description xml:lang="en"><value>Hello world portlet to test WSRP viewing</value></description><shortTitle xml:lang="en"><value>View</value></shortTitle><title xml:lang="en"><value>Hello World Portlet</value></title><displayName xml:lang="en"><value>HelloWorld99</value></displayName><userProfileItems>UserProfileName/PropertyName</userProfileItems><templatesStoredInSession>true</templatesStoredInSession><doesUrlTemplateProcessing>true</doesUrlTemplateProcessing></offeredPortlets><registrationPropertyDescription><propertyDescriptions name="ConsumerName" type="xsd:string" /><propertyDescriptions name="BuildDate" type="xsd:dateTime" /></registrationPropertyDescription></getServiceDescriptionResponse></soap:Body></soap:Envelope>
    (100)Continue
         at org.apache.axis.transport.http.HTTPSender.readFromSocket(HTTPSender.java:695)
         at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:129)
         at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:71)
         at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:150)
         at org.apache.axis.SimpleChain.invoke(SimpleChain.java:120)
         at org.apache.axis.client.AxisClient.invoke(AxisClient.java:180)
         at org.apache.axis.client.Call.invokeEngine(Call.java:2575)
         at org.apache.axis.client.Call.invoke(Call.java:2564)
         at org.apache.axis.client.Call.invoke(Call.java:2259)
         at org.apache.axis.client.Call.invoke(Call.java:2182)
         at org.apache.axis.client.Call.invoke(Call.java:1702)
         at com.plumtree.wsrp.base.WSRP_v1_ServiceDescription_Binding_SOAPStub.getServiceDescription(WSRP_v1_ServiceDescription_Binding_SOAPStub.java:857)
         at com.plumtree.wsrp.consumer.impl.ServiceDescriptionManager.getServiceDescription(ServiceDescriptionManager.java:118)
         at com.plumtree.wsrp.consumer.servlet.AdminPreference.renderSetRegistrationPage(AdminPreference.java:992)
         at com.plumtree.wsrp.consumer.servlet.AdminPreference.service(AdminPreference.java:117)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
         at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
         at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
         at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
         at java.lang.Thread.run(Unknown Source)

    This seemed promising, but the proposed solution (adding 'servicePointManager expect100Continue="false"' to Web.config) had no effect.
    My consumer request actually does not include the "Expect: 100-continue" header and receives the 100 response anyways. My understanding now is that this is okay (thought I'm not sure why) and that the client should be expected to handle that response code in any case.
    I am wondering if there is an issue with the combination of products in my environment that is not supported by this product?? I am using
    IIS 5.1,
    .Net 2.0
    AquaLogic WSRP Producer 1.1/WebCenter WSRP Producer 10.3.0 (tried both)
    I am testing this producer in two environments -
    - AquaLogic Consumer running on AL Portal 6.5. When the WSRPConsumer is configured with the producer wsdl, it fails with message "Failed to get service description from WSRP Provider: .... faultString: (100) Continue".
    - Liferay - AFTER successful registration, attempts to deploy my registered .Net portlet (simple hello-world) result in an internal exception thrown in the Producer [Bea.Portlet.Management.PortletManager.LoadPortlet(PortletManager.cs:line 114)] Error loading PortletContainer: Bad PortletState. No request is made to my .Net application.
    It appears from both of these tests that both my producer and consumer are having fundamental problems that do not seem overly exotic (although I have successfully registered other WSRP portlets with the AL Consumer). However, I have not come across much information on these sorts of problems.

  • Consumer Producer and FPN

    I have a layered portal approach, one for internal use, one for external customers and one for vendors. With multiple WD for java apps, and webservices deployed can a portal serve as both producer and comsumer becuase of our approach.
    Thanks Mikie

    can a portal serve as both producer and comsumer
    yes it is, a consumer can produce the content aswell
    jo

  • Change a VI to a more sophisticated pattern (e.g. consumer/producer)

    Hi everybody!
    I have written a VI taking spectra from a triggered flash lamp and spectrometer. The whole systems works in a rotating device. So the triggering and exact timing is quite important. I finally got my Vi to work  but there are still some problems with the spectrometer. I think this is due to the fact that the spectrometer runs into a internal timeout but I don't know why. Furthermore there is still a lot of false triggering when changing to the next sample with a different delay.
    So it's really time to take a deep and think about my program. At the moment I have a flat sequence with some for loops defining the number of measurings as well as the while loops for the triggering...
    Well that's I want to do:
    1. All the necessary data comes in a cluster from a different vi
    2. Initialize: Create folders, calculate positions for the step motor and move it to the initial position, open spectrometer and so on
    3. Start the speed measuring and calculation of delays
    4. Measure the spectrometer dark current
    5. Move step motor to the first position
    6. Start retriggerable task for lamp and spectrometer (the triggering occurs in a subvi, whereas the delays are updated continuously by a reference) 
    7. Measure at step motor position first sample, second sample and so on
    8. Move stepmotor -> 7
    9. Stop retriggerable task for lamp and spectrometer
    10. Save data and wait for a specified time
    11. Back to step 5
    12. In the end: Close the spectrometer, stop the speed measurement and so on
    Furthermore the data has to be displayed:
    1. The actual scan
    2. Step motor position dependent absorption for the actual scan as well as the former scans (by option)
    So much for the theory. I thougt that maybe a produce/consumer patttern would fit but I have no idea how to realize this. Of course I have read a lot but I don't know how to do the triggering stuff and so on.
    I have attached my main vi that you can see how I deal with this at the moment. Of course all the subvis are missing but the working principle should be clear. Please let me know if If you need any more information!
    I want to do two things. First I want to separate the data aquisition from the display and file I/O, second the data aquisition has to be seperated from the lamp and spec triggering.
    Especially the second point seems to be very important because my spectrometer runs into some internal timeout (not because there is no trigger) after some minutes or hours (the exact time is not reproducible, but it does happen) and crashes my whole system  as I mentioned before.
    I don't know why but I hope so much that a more sophisticated vi pattern will solve this problem.
    May you help me with this?
    Thanks!
    Attachments:
    radial_scan_v5.10.vi ‏293 KB

    If the vi runs without user intervention, then simple Enum based state machine architecture can be used.
    1. All the necessary data comes in a cluster from a different vi
    State -1
    2. Initialize: Create folders, calculate positions for the step motor and move it to the initial position, open spectrometer and so on
    State -2 Initialise state
    3. Start the speed measuring and calculation of delays
    This can be a Dynamically launched vi ( and can be launched in State-2) where it waits for the notification from State -2 to start Acquisision.
    This vi will also stop acquisiion based on another notification from the main vi states
    State-3 -> Set start notification for this cont. running sub vi
    4. Measure the spectrometer dark current
    State -4
    5. Move step motor to the first position
    State -5
    6. Start retriggerable task for lamp and spectrometer (the triggering occurs in a subvi, whereas the delays are updated continuously by a reference)
    This can also be another dynamically launched subvi, that is launched in State -2 itself.
    State-6 -> Send Notification to start the Retriggerable task
    7. Measure at step motor position first sample, second sample and so on
    State -7.Measurement
    8. Move stepmotor -> 7
    9. Stop retriggerable task for lamp and spectrometer
    State -8 Send stop notification to stop the Retriggerable task.
    10. Save data and wait for a specified time
    State -9 - Log the Data
    11. Back to step 5
    State 10 .. Check for completion.if required again redirect to state -5
    12. In the end: Close the spectrometer, stop the speed measurement and so on
    State -11 Send stop ACQ notification for all the dynamically launched vis, stop those vis..close  all instrument refs .. stop main vi
    If the states are dependent on user intervention then Event based producer consumer can be used where, the producer will control when to start the whole process and when to stop the process( Using queues).The consumer can be Queue driven Enum based state machine

  • Color pattern match in consumer producer architecture

    The way I currently have my code is as follows:
    If the number of matches in a color pattern match is greater than 0, it sends the information to the consumer loop.
    If it is not greater than 0, it doesn't send anything.
    What I was wondering is, if it finds a match the first time and it sends the information to the consumer loop, will the number of matches in the color pattern match return to 0 or will it be greater than 0 after the first match? If the number of matches in the color pattern match will be greater than 0 after the first match, and it will still be greater than 0, even though it doesn't find a match in the following scenarios, how can I make the number of matches in the color pattern match return to 0?

    Fernan1988 wrote:
    ... will the number of matches in the color pattern match return to 0 or will it be greater than 0 after the first match?...
    it's hard to say unless you can post your code....have you tried probing tool,retain wire value,highlight execution,single stepping into and out, breakpoints?

  • Consumer producer event control button top VI

    I am trying to control the main.vi example that create the “create project wizard” called “Continuous Measurement and logging” from a top lever VI.
    The problem I have is that, I will not start the main.vi unless it’s done by an event created by an operator. How can I control programmatically those buttons from another VI?
    I am attaching the block diagram picture from the wizard and the simple top_level VI to control that VI. Thanks
    Attachments:
    mainVI.png ‏62 KB
    top_level_VI.png ‏16 KB

    That main VI is meant to act as a top level VI.  It is recommended you add on to that VI if you need more capability.
    There are only two ways to tell somebody thanks: Kudos and Marked Solutions
    Unofficial Forum Rules and Guidelines

  • Reg FPN Role assignment in consumer portal

    Hi Team
    We are trying to implement FPN between two portals both are EP7 SP20
    i followed the basic steps like
    1  establishing the trust between portals
    2  regestration of producer portal in consumer portal
    I am able to see the roles created in producer portal in consumer portal with the help of User administration--Identity management tool
    the probelm we are facing is when i assign the role in consumer portal to a user it is not getting assigned but it is getting assigned in the producer portal
    pls let what i need to do inorder for the producer role to be assigned to consumer portal user
    thanks in advance

    Hi,
    already saw this several times. Unfortuantely, it never was a FPN error. It always was human error:
    Confused by the Consumer / Producer concept the Admin created the role assignment in the producer and not in the consumer.
    Just check that you are really using the consumer.
    If so, consider opening up an OSS message.
    br,
    Tobias

  • Federated portal's, cann't see the roles and portal content from producer

    We are configuring a Federated Portal, with a Producer EP7.0 SP13 and a Consumer EP7.0 SP13. The connection test is successful.
    I can see the producer on the consumer and the consumer on the producer.
    The problem is that I can not see the portal content of the producer in the portal content of the consumer.  The producer roles are also not available on the consumer.  I have selected the producer as the data source in the consumer UME,
    then enter * in the role name field, then select "go", but nothing comes up.
    Can anybody help me?

    Hi J De Voijs
    • Following might be the reason:
    1. User should exist in both user store of Consumer and Producer portal otherwise it won’t work.
    2. Incase if the registration is successful then there might be some problem with your servers (Consumer & Producer) clock timings.
    3. ‘Remote Role Assignment’ may get fail perhaps because user to whom remote role assignment is done doesn’t have “End User” role assigned to him/her at Producer Portal. End-user permission enables business users to run content at runtime. Just as end users require end-user permission to run local content on your portal, they also need end-user permission for local content originating from a remote producer.
    4. You should have Owner permission in the objects to which you want to assign permissions otherwise ‘Remote Role Assignment’ wont work.
    5. In the portal content studio, open the producer under 'NetWeaver content producers'. If it does not contain folders in it, the registration is considered to be unsuccessful even though it stated it was successful while registration.
    6. During the process of Registering (Adding) Producer Portal, while entering the connection parameters of the NetWeaver producer portal use appropriate Host name against “Host Name” input field instead of IP address. Perhaps this might create some problem during execution in later stage.
    e.g. Host Name: use “sapProducerportal02” instead of 172.19.144.155
    7. Also go through the following URLs (w.r.t Permissions):
    1) http://help.sap.com/saphelp_nw2004s/helpdata/en/43/2232580bb93fece10000000a11466f/content.htm
    2) http://help.sap.com/saphelp_nw2004s/helpdata/en/f6/2604e505fd11d7b84200047582c9f7/content.htm
    3) http://help.sap.com/saphelp_nw04/helpdata/en/f6/2604e905fd11d7b84200047582c9f7/frameset.htm
    4)http://help.sap.com/saphelp_nw04/helpdata/en/f6/2604e505fd11d7b84200047582c9f7/frameset.htm
    5)http://help.sap.com/saphelp_nw04/helpdata/en/5b/0fab1b76984ed0944d5c732cfad1b2/frameset.htm
    Points pls if you find it useful...
    Thanks and Regards,

  • Can you open an .xls, .pdf or .doc from a Producer over WSRP?

    Has anyone tried to have a Producer create a .xls, .pdf, or a .doc and then try and consume it via a consumer?
    If so is there anything special you had to set up?

    In one of our project, We did consume Producer portlets to generate HTML report and send to printer for print out.
    One another project we generated reports using Jasper and consume that portlets in remote.
    When consumer send request to Producer, please make sure your URL is send correctly.
    You can monitor WSRP traffic by http://consumer:port/consumerWeb/monitor
    There is no special things to handle. As long as if you generate PDF, DOC in Producer, then you can consume.
    For better performance, if both Producer & Consumer on same box, please enable LOCAL PROXY, if you are using WLPortal 8.1.4 above.

  • Remote Delta link setup problem with Bean / Access Service

    Hello,
    I am trying to setup Remote Delta Link (RDL) between two portals. (Both portals same version - EP 7.0 EHP1 SP 05 - are in the same domain)
    I already have the Remote Role Assignment working without any issues.
    The following have been done successfully:
    1. Same user repository has been setup for both the portals
    2. Setup trust between producer and consumer (SSO working fine)
    3. Producer added and registered succesfully on consumer
    4. Permissions setup on producer and consumer
    4. pcd_service user with required UME actions setup
    I am able to see all the remote content in the Consumer portal.
    When I try to copy the remote content and paste it as local content, I am getting the following error:
    Could not create remote delta link to object 'page id'. Could not connect to the remote portal. The remote portal may be down, there may be a network problem, or your connection settings to the remote portal may be configured incorrectly.
    After increasing the log severity, I am able to see the following in Default Trace:
    com.sap.portal.fpn.transport.Trying to lookup access service (P4-RMI) for connecting to producer 'ess_int' with information: com.sap.portal.fpn.remote.AccessServiceInformation@31c92207[connectionURL=hostname.mycompany.com:50004, shouldUseSSL=false, RemoteName=AccessService]
    com.sap.portal.fpn.transport.Unable to lookup access service (P4-RMI) with information: com.sap.portal.fpn.remote.AccessServiceInformation@31c92207[connectionURL=hostname.mycompany.com:50004, shouldUseSSL=false, RemoteName=AccessService]
    AbstractAdvancedOperation.handleDirOperationException
    [EXCEPTION]
    com.sap.portal.pcm.admin.exceptions.DirOperationFailedException: Could not retrieve the bean / access service to connect with producer
    Could not retrieve the bean / access service to connect with producer
    Like you can see above, there is some bean / access service which is not retrieved successfully. I am not sure if this is a permission problem on the consumer.
    I have checked that the P4 ports are configured correctly (standard - not changed) and I am able to telnet from producer to consumer (and vice versa) on the P4 port.
    I am stuck at this point and am not able to find any information on this.
    I would really appreciate if some one can point me in the right direction.
    Thank you for reading.
    - Raj

    Hi Raj,
    Please check your config of the P4 port on the producer.  Is it really 50004 (check SystemInfo of the producer)?
    I do think there's a problem with the P4 communication since RDL requires P4 connection.
    Do you have load balanced consumer-producer connection? Please refer to this blog for further details
    Little known ways to create a load balanced Consumer – Producer connection in a FPN scenario
    Regards,
    Dao

  • Difference between Federated single sign on  and just Single sign on

    Can anyone please give a clear definition of what is
    1. Federated Single sign on?
    2. Just Single Sign on ?
    As a security expert if you were to Architect security what will you suggest ?
    Lets take an example Landscape
    NW1(ABAP + JAVA)- system, NW-2(ABAP+JAVA)  system and EP( java only), LDAP
    I am having a hard time convincing the customer to have both CONSUMER AND PRODUCER PORTAL for Federated single sign on? is this a bad idea. Customer says just give me SSO(with just one portal acting as CONSUMER/PRODUCER).
    initial GOLIVE user load will be 700+ users.
    Edited by: Franklin Jayasim on Jul 16, 2010 7:52 PM
    Edited by: Franklin Jayasim on Jul 16, 2010 7:53 PM
    Edited by: Franklin Jayasim on Jul 16, 2010 7:57 PM
    Edited by: Franklin Jayasim on Jul 17, 2010 12:17 AM

    Hi  Denny Liao
    The project is going to have BI(NW) and ECC/SRM/HR(NW) and sepparate  portal ( EP - Java only )
    I thought that normal SSO will help in the intranetwork, what happens if the employee(user)  needs to work from home.
    What about the external vendors suppliers etc...?

  • Data acquisition synchronisation Arduino/LabView

    Hello,
    I'm trying to acquire force sensor values using an Arduino board (reading the data and controlling a motor) and LabView. The data acquisition rate is tunable according to the motor condition, meaning a high acquisition rate (short delay) during the ON state of the motor and a low acquisition rate (long delay) during the OFF state of the motor.
    I managed to acquire the data, but till now I always find some "0" values though I'm applying a continuous force on the sensor. I guess the main problem is the synchronisation of the "datarate" on the Arduino board and the acquisition time point in LabView.
    I hope that you could halp me, since I'm trying since weeks to overcome this problem. You will find both the LabView and the Arduino source codes in the attachment.
    Attachments:
    CBR control_opti.vi ‏206 KB
    CBR_Arduino.docx ‏15 KB

    Dear all,
    last week I had some limited time, which I could dedicate to my work with Labview. Unfortunately I'm not able to solve the problem with the Consumer/Producer architecture. It seems to be the appropiate solution, but due to my limited knowledge I'm not capable of doing that.
    I will add my modifications (CBR control_Prod-Cons.vi) to give you an idea about what I've achieved so far. I appriciate any help of you, since this story is driving me crazy. Additionally, I attach a JPG showing the readout I'm obtaining with the old version (CBR control.vi), where the red circles indicate the problem with the "0" values.
    Thank you again,
    Cheers 
    Attachments:
    CBR control_Prod-Cons.vi ‏203 KB
    sensor read out.JPG ‏164 KB
    CBR control.vi ‏206 KB

Maybe you are looking for

  • Is there a way to find out how much time an Upgrade took with DBUA?

    Hello! I've performed a successful upgrade from 10g to 11g using dbua. The thing is that I made that upgrade last friday, I know when it started but I can't manage to find any log that tells me when It was finished exactly. I tried to search in the .

  • Charge adaptor for 3G

    so the 3g has been out a while now and i still cant find an adapter so my CD player in my car will charge my iphone 3g. i see cablejive has made one that will be on sale soon, does anybody know if there is any other adapters already fro sale? http://

  • MIRO - FieldExit

    Hello, Our requirement is to enable a field exit in MIRO to change the field Doc. Type in Details screen according of Transaction Field, automatically. For example: If Transaction = Invoice, then Doc. Type = Invoice-net Is it possible? Thanks Michel

  • Update TVARV table entries using a Function Module or Program

    Hi Gurus, My requirement is that I have a entry in TVARV table which has a 'low'. We would like to change this value whenever we desire. We are unable to do it via sm30 and se16 as table maintenance access is not permitted in Production environment.

  • Kill session and process

    Hi, There are many answers in this forum related with my question but could not complete answer. I have problem with process count in db. Firstly I killed sessions alter system kill session 'xxx,yyyy'; and then queried v$session. The status of sessio