Applet: repaint() causing infinite loop

I'm developing an applet that draws a linegraph. The user can select which lines of points will be drawn in the applet using checkboxes. I have a separate function as an Itemlistener for the checkboxes, and I call repaint at the end of the itemStateChanged function. For some reason, once the itemlistener has seen one event, the applet gets stuck in a loop, and paint is continually run over and over again. This makes the applet useless as the user can't enter any input since the applet is continually being redrawn. I only want paint to be called once from a repaint() call. I'm not using any loops anywere in my program. Any suggestions?

ItemListeners tend to throw lots of events when actually only one has happened.
The solution i use:
remember the old satus. when an event happens first check if the status has changed, if not do nothing.

Similar Messages

  • [svn] 4870: TextView with textAlign="justify" causes infinite loop and eventual RTE.

    Revision: 4870
    Author: [email protected]
    Date: 2009-02-05 15:33:52 -0800 (Thu, 05 Feb 2009)
    Log Message:
    TextView with textAlign="justify" causes infinite loop and eventual RTE. Vellum sometimes returns width and/or height larger than the request width/height due to rounding error. This triggers a contentWidth/Height change event which triggers the scroller which comes back in to TextView updateDisplayList, etc.
    QE Notes:
    Doc Notes:
    Bugs: SDK-19144
    Reviewers: Gordon
    Ticket Links:
    http://bugs.adobe.com/jira/browse/SDK-19144
    Modified Paths:
    flex/sdk/branches/i10/frameworks/projects/flex4/src/mx/components/TextView.as

  • FBL5N - BSEG-REBZG values cause infinite loop FDM_COLL_INVOICE_GET_BY_REF

    Hello,
    We have a problem where function FDM_COLL_INVOICE_GET_BY_REF looks at BSEG records in a loop. It finds the next BSEG record by using the contents of BSEG-REBZG.
    Unfortunately, some of our BSEG records point back to each other. We have the situation where BSEG "A" points to BSEG "B", and BSEG "B" points back to BSEG "A".
    For example:
    BSEG-BELNR   9100011111  ->  REBZG = 9111122222
    BSEG-BELNR   9111122222  ->  REBZG = 9100011111
    This data is causing the loop to execute infinitely as the exit conditions are never met.
    I cannot find a SAP Note that addresses this issue. It looks like the code involved is related to items in Dispute and Part Payments.
    Has anyone out there experienced this issue?
    Many thanks,
    Stuart.

    What release are you on?
    There is note 1105687 addressing the scenario when a credit memo is entered as an invoice reference in an invoice item which can cause such an infinite loop, but that note is only valid up to rel. 6.03
    There is also note 919415 but it is for even older systems.
    If you are on a current release, then creating an OSS message is your best bet.
    It would be theoretically possible to have a recent release with some already posted documents that were entered before the patch fixing such endless loops were applied... how likely is to have such old documents is another question. SAP support should help you to clean up the problematic records if this is the case.

  • Using the back button causes infinite loop between articles

    Hi i have a folio that has a series of projects, and i wanted to use the back option as various access points to each project
    goto://FolioNavigation/lastview
    but each project has an image article associated with it, and this has a button on it back specifically to the project main article. But when u click the back button now on that main artcile, it takes  u to the image article, not back to where the person wud have wanted to be.
    I cannot think of a work around other than going back to using specific page navto but that means determining the access point which is not possible. Or duplicated the articles entirely.
    Any help appreciated.
    Rob

    found solution. you have to use the goto://FolioNavigation/lastview
    in the back option on the image page as wel. then it knows not to cause infinite loop

  • Alert Component with OnKillFocus Causes Infinite Loop

    I have this script...
    txtPPM.onKillFocus = function(txtPPM)
    import mx.controls.Alert;
    Alert.show("blah blah");
    When my focus shifts away from the txtPPM textfield I get an
    infinite loop error. I haven't been able to find a successful
    method to fix this. Any suggetions?

    Probably related to the FocusManager (V2 components). There
    may be other
    ways to work around it, but here's something quick:
    import mx.controls.Alert;
    var alertClickHandler:Function = function (evt_obj:Object) {
    switch (evt_obj.detail) {
    case Alert.OK :
    trace("You clicked: " + Alert.okLabel);
    break;
    case Alert.CANCEL :
    trace("You clicked: " + Alert.cancelLabel);
    break;
    txtPPM.onKillFocus = txtFocusHandler;
    function showAlert(){
    Alert.show("blah blah blah", "", undefined, this,
    alertClickHandler);
    function txtFocusHandler(newFocus:Object){
    this.onKillFocus = undefined;
    showAlert();
    txtPPM.onKillFocus = txtFocusHandler;

  • URGENT: executeQuery after setWhereClause causes infinite loop

    Hi,
    - I'm using jdev 9.0.3.2.
    - I have a JTable bound to a ViewObject.
    - I set the vo's whereClause, the where clause has some syntax error.
    - I call executeQuery
    - The JBO exception is shown.
    - I press ok.
    BUT:
    - The JBO exception is called again and again, the reason is getEstimatedRowCount called again and again by the repaint event.
    I noticed the following code in JUIteratorBinding :
    public void executeQuery()
    synchronized(getSyncLock())
    if (mIsAlive && mIsBound)
    try
    getRowSetIterator().getRowSet().executeQuery();
    catch(Exception ex)
    reportException(false /*markDead*/, ex);
    reportException(false -> means do not markDead
    is this OK?
    Please help.
    Thanks Ognian

    You're hitting a reported bug 3090348
    A known workaround is to reset the erring clause after execute and exception like:
    private void setWhereClause_actionPerformed(ActionEvent e)
    //here it starts
    JUIteratorBinding ib=panelBinding.findIterBinding("EmpView1Iter");
    try {
    ib.getApplication().setErrorHandlerActive(false);
    ib.getViewObject().setMaxFetchSize(100);
    ib.getViewObject().setWhereClause("empno = xxx"); //the where clause
    is intentional wrong!!
    ib.executeQuery(); //one JBO exception is OK, but not an endless loop
    until a stack overflow happens!
    catch (JboException je)
    ib.getViewObject().setWhereClause(null);
    ib.getApplication().setErrorHandlerActive(true);
    panelBinding.reportException(je);
    ib.executeQuery();
    //set a breakpoint here and go inside execute query
    - this reports the exception once...

  • CommandButton linked to same page causes infinite loop

    I'm working on an jsf application with a quite complex interface. I used to deploy it with the MyFaces implementation of jsf. Because of some irratic behavior I want to test Sun's reference implementation. Everything works just fine except when my commandButtons are linked back to the same jsp, configured as a navigation-rule in my faces-config.xml. When I click the button the configured handler-method gets called infinitely(the method works fine, no exception thrown). Any ideas why this is happening?
    /Dan
    From "bolagsstammoAktiebok.jspx"
    <h:commandButton action="#{bolagsstammoAktiebokHandler.berakna}" styleClass="styleinput" immediate="true"
                                                     value="Ber&#228;kna"/>From faces-config.xml
    <navigation-case>           <from-action>#{bolagsstammoAktiebokHandler.berakna}</from-action>
                <from-outcome>success</from-outcome>
                <to-view-id>bolagsstammoAktiebok.jspx</to-view-id>
            </navigation-case>

    Why make a navigation rule that navigates to the same
    page ?
    Just return "" from the
    bolagsstammoAktiebokHandler.berakna method.That helps in that particular case. The problem persists when I try to navigate to another jsp, though. In that case I must use a navigation-rule.

  • A cycle is detected in the object graph.  This will cause an infinite loop.

    People,
    Looking for a little guidance.  Please point me in the correct direction if I am mistaken.  I am using Jersey 2.11 and generating JAXB definitions from XSD.
    I have a periodic exception that seems to be timing based.  If I change the timing of the message sent in anyway the error does not occur.  The other issue is that the cycle reported in the error changes some times, however, the cycles reported can not occur based on the XSD definition.  I have also dumped the message before sending and it definitely does not contain the cycle reported.
    In this specific scenario, I am sending a message of NotificationType which contains a list of DocumentType, however, DocumentType can never contain NotificationType so the following cycle is not possible:
    net.es.nsi.pce.discovery.jaxb.DocumentType@24d793f3 -> net.es.nsi.pce.discovery.jaxb.NotificationType@7f06bc07 -> net.es.nsi.pce.discovery.jaxb.DocumentType@24d793f3]
    I am wondering if there could be a different reason for receiving the following exception?
    Thank you for the help,
    John
    [code]
    [ERROR] [08/22/2014 11:16:22.307] [NSI-DISCOVERY-akka.actor.default-dispatcher-4] [akka://NSI-DISCOVERY/user/discovery-notificationRouter/$c] HTTP 500 Internal Server Error
    javax.ws.rs.ProcessingException: HTTP 500 Internal Server Error
            at org.glassfish.jersey.client.ClientRuntime.invoke(ClientRuntime.java:255)
            at org.glassfish.jersey.client.JerseyInvocation$1.call(JerseyInvocation.java:667)
            at org.glassfish.jersey.client.JerseyInvocation$1.call(JerseyInvocation.java:664)
            at org.glassfish.jersey.internal.Errors.process(Errors.java:315)
            at org.glassfish.jersey.internal.Errors.process(Errors.java:297)
            at org.glassfish.jersey.internal.Errors.process(Errors.java:228)        at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:424)
            at org.glassfish.jersey.client.JerseyInvocation.invoke(JerseyInvocation.java:664)
            at org.glassfish.jersey.client.JerseyInvocation$Builder.method(JerseyInvocation.java:424)
            at org.glassfish.jersey.client.JerseyInvocation$Builder.post(JerseyInvocation.java:333)
            at net.es.nsi.pce.discovery.actors.NotificationActor.onReceive(NotificationActor.java:100)
            at akka.actor.UntypedActor$$anonfun$receive$1.applyOrElse(UntypedActor.scala:167)
            at akka.actor.Actor$class.aroundReceive(Actor.scala:465)
            at akka.actor.UntypedActor.aroundReceive(UntypedActor.scala:97)        at akka.actor.ActorCell.receiveMessage(ActorCell.scala:516)
            at akka.actor.ActorCell.invoke(ActorCell.scala:487)
            at akka.dispatch.Mailbox.processMailbox(Mailbox.scala:238)
            at akka.dispatch.Mailbox.run(Mailbox.scala:220)
            at akka.dispatch.ForkJoinExecutorConfigurator$AkkaForkJoinTask.exec(AbstractDispatcher.scala:393)
            at scala.concurrent.forkjoin.ForkJoinTask.doExec(ForkJoinTask.java:260)
            at scala.concurrent.forkjoin.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1339)
            at scala.concurrent.forkjoin.ForkJoinPool.runWorker(ForkJoinPool.java:1979)
            at scala.concurrent.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:107)
    Caused by: javax.ws.rs.InternalServerErrorException: HTTP 500 Internal Server Error
            at org.glassfish.jersey.message.internal.AbstractJaxbElementProvider.writeTo(AbstractJaxbElementProvider.java:152)
            at org.glassfish.jersey.message.internal.AbstractJaxbElementProvider.writeTo(AbstractJaxbElementProvider.java:85)
            at org.glassfish.jersey.message.internal.WriterInterceptorExecutor$TerminalWriterInterceptor.invokeWriteTo(WriterInterceptorExecutor.java:265)
            at org.glassfish.jersey.message.internal.WriterInterceptorExecutor$TerminalWriterInterceptor.aroundWriteTo(WriterInterceptorExecutor.java:250)
            at org.glassfish.jersey.message.internal.WriterInterceptorExecutor.proceed(WriterInterceptorExecutor.java:162)
            at org.glassfish.jersey.filter.LoggingFilter.aroundWriteTo(LoggingFilter.java:293)
            at org.glassfish.jersey.message.internal.WriterInterceptorExecutor.proceed(WriterInterceptorExecutor.java:162)
            at org.glassfish.jersey.message.internal.MessageBodyFactory.writeTo(MessageBodyFactory.java:1154)
            at org.glassfish.jersey.client.ClientRequest.writeEntity(ClientRequest.java:503)
            at org.glassfish.jersey.client.HttpUrlConnector._apply(HttpUrlConnector.java:315)
            at org.glassfish.jersey.client.HttpUrlConnector.apply(HttpUrlConnector.java:227)
            at org.glassfish.jersey.client.ClientRuntime.invoke(ClientRuntime.java:246)
            ... 22 more
    Caused by: javax.xml.bind.MarshalException
    - with linked exception:
    [Exception [EclipseLink-25003] (Eclipse Persistence Services - 2.5.0.v20130507-3faac2b): org.eclipse.persistence.exceptions.XMLMarshalException
    Exception Description: An error occurred marshalling the object
    Internal Exception: Exception [EclipseLink-25037] (Eclipse Persistence Services - 2.5.0.v20130507-3faac2b): org.eclipse.persistence.exceptions.XMLMarshalException
    Exception Description: A cycle is detected in the object graph.  This will cause an infinite loop: net.es.nsi.pce.discovery.jaxb.DocumentType@24d793f3 -> net.es.nsi.pce.discovery.jaxb.NotificationType@7f06bc07 -> net.es.nsi.pce.discovery.jaxb.DocumentType@24d793f3]
            at org.eclipse.persistence.jaxb.JAXBMarshaller.marshal(JAXBMarshaller.java:403)
            at org.glassfish.jersey.message.internal.XmlJaxbElementProvider.writeTo(XmlJaxbElementProvider.java:139)
            at org.glassfish.jersey.message.internal.AbstractJaxbElementProvider.writeTo(AbstractJaxbElementProvider.java:150)
            ... 33 more
    Caused by: Exception [EclipseLink-25003] (Eclipse Persistence Services - 2.5.0.v20130507-3faac2b): org.eclipse.persistence.exceptions.XMLMarshalException
    Exception Description: An error occurred marshalling the object
    Internal Exception: Exception [EclipseLink-25037] (Eclipse Persistence Services - 2.5.0.v20130507-3faac2b): org.eclipse.persistence.exceptions.XMLMarshalException
    Exception Description: A cycle is detected in the object graph.  This will cause an infinite loop: net.es.nsi.pce.discovery.jaxb.DocumentType@24d793f3 -> net.es.nsi.pce.discovery.jaxb.NotificationType@7f06bc07 -> net.es.nsi.pce.discovery.jaxb.DocumentType@24d793f3
            at org.eclipse.persistence.exceptions.XMLMarshalException.marshalException(XMLMarshalException.java:97)
            at org.eclipse.persistence.internal.oxm.XMLMarshaller.marshal(XMLMarshaller.java:911)
            at org.eclipse.persistence.internal.oxm.XMLMarshaller.marshal(XMLMarshaller.java:848)
            at org.eclipse.persistence.jaxb.JAXBMarshaller.marshal(JAXBMarshaller.java:401)
            ... 35 more
    Caused by: Exception [EclipseLink-25037] (Eclipse Persistence Services - 2.5.0.v20130507-3faac2b): org.eclipse.persistence.exceptions.XMLMarshalException
    Exception Description: A cycle is detected in the object graph.  This will cause an infinite loop: net.es.nsi.pce.discovery.jaxb.DocumentType@24d793f3 -> net.es.nsi.pce.discovery.jaxb.NotificationType@7f06bc07 -> net.es.nsi.pce.discovery.jaxb.DocumentType@24d793f3
            at org.eclipse.persistence.exceptions.XMLMarshalException.objectCycleDetected(XMLMarshalException.java:400)
            at org.eclipse.persistence.internal.oxm.XPathObjectBuilder.buildRow(XPathObjectBuilder.java:207)
            at org.eclipse.persistence.internal.oxm.TreeObjectBuilder.buildRow(TreeObjectBuilder.java:118)
            at org.eclipse.persistence.internal.oxm.TreeObjectBuilder.buildRow(TreeObjectBuilder.java:1)
            at org.eclipse.persistence.internal.oxm.XMLCompositeObjectMappingNodeValue.marshalSingleValue(XMLCompositeObjectMappingNodeValue.java:237)
            at org.eclipse.persistence.internal.oxm.XMLCompositeObjectMappingNodeValue.marshal(XMLCompositeObjectMappingNodeValue.java:149)
            at org.eclipse.persistence.internal.oxm.NodeValue.marshal(NodeValue.java:102)
            at org.eclipse.persistence.internal.oxm.record.ObjectMarshalContext.marshal(ObjectMarshalContext.java:59)
            at org.eclipse.persistence.internal.oxm.XPathNode.marshal(XPathNode.java:393)
            at org.eclipse.persistence.internal.oxm.XPathObjectBuilder.buildRow(XPathObjectBuilder.java:238)
            at org.eclipse.persistence.internal.oxm.TreeObjectBuilder.buildRow(TreeObjectBuilder.java:118)
            at org.eclipse.persistence.internal.oxm.TreeObjectBuilder.buildRow(TreeObjectBuilder.java:1)
            at org.eclipse.persistence.internal.oxm.XMLCompositeCollectionMappingNodeValue.marshalSingleValue(XMLCompositeCollectionMappingNodeValue.java:321)
            at org.eclipse.persistence.internal.oxm.XMLCompositeCollectionMappingNodeValue.marshal(XMLCompositeCollectionMappingNodeValue.java:104)
            at org.eclipse.persistence.internal.oxm.NodeValue.marshal(NodeValue.java:149)
            at org.eclipse.persistence.internal.oxm.NodeValue.marshal(NodeValue.java:102)
            at org.eclipse.persistence.internal.oxm.record.ObjectMarshalContext.marshal(ObjectMarshalContext.java:59)
            at org.eclipse.persistence.internal.oxm.XPathNode.marshal(XPathNode.java:393)
            at org.eclipse.persistence.internal.oxm.XPathObjectBuilder.buildRow(XPathObjectBuilder.java:238)
            at org.eclipse.persistence.internal.oxm.TreeObjectBuilder.buildRow(TreeObjectBuilder.java:118)
            at org.eclipse.persistence.internal.oxm.TreeObjectBuilder.buildRow(TreeObjectBuilder.java:1)
            at org.eclipse.persistence.internal.oxm.XMLMarshaller.marshal(XMLMarshaller.java:743)
            at org.eclipse.persistence.internal.oxm.XMLMarshaller.marshal(XMLMarshaller.java:901)
            ... 37 more
    [/code]

    Unfortunately, even this thread is unanswered, i am closing the thread.as it it creating problems for further posting

  • How do i disable audio out timeout on a macbook pro causing noise on external amplifier, without having a silent .wav playing in infinite loop?

    After updating to Mavericks I have this problem. From what I guess, my audio out (either the signal, or the entire soundcard) cuts power after being idle for about 30 seconds. This results in a static noise when connected to my external amplifier. From various forums, dating back to 2007/8 I can see this is not a new problem. The only workaround is playing an empty .wav sound on infinite loop (either by using a terminal command, or by a third-pary app which does this for you), preventing the audio out from timing out and cutting power. This seems to me to be an undisirable proceeding. Even if minimal, it uses extra power and memory. Is there any way to prevent the sound card from timing out like this?

    Ok. I tried disconnecting the charger from my macbook and that actually helped. The noise is now so low it is hardly audible, so I guess it has to do with a ground loop. But still, even when hardly audible it still only happens after 30 seconds of idle time. Is that because my theory about a timeout is correct, or is there some other reason for this? This used to just happen when my macbook went on standby (sleep), but now it happens allready after 30 seconds, so even though it may be a loop, it wasn't like this before. I'd love to understand what is different now.

  • Throws infinite-loop error after cycline through Vector - HELP!!!

    public void paint(Graphics g) {
    FontMetrics fm = g.getFontMetrics();
    xpos = (getSize().width - fm.stringWidth(((String[])parseVector.elementAt(kount))[1])) / 2;
    if (ypos >= getSize().height || ypos <= 0) {
    g.drawString("", 0, 0); // CLEAR THE APPLET
    ypos = getSize().height;
    if (kount <= parseVector.size()) {
    kount++;
    } else {
    kount = 0;
    g.drawString(((String[])parseVector.elementAt(kount))[1], xpos, ypos);
    class ScrollNews implements Runnable {
    public void run() {
    while (true) {
    ypos = ypos - 1;
    ParseNews.this.repaint();
    try {
    Thread.sleep(50);
    } catch (InterruptedException e) {}
    I don't know why this breaks after working one time through the Vector parseVector, what am I missing????
    Phil

    public void paint(Graphics g) {
    FontMetrics fm = g.getFontMetrics();
    xpos = (getSize().width -
    fm.stringWidth(((String[])parseVector.elementAt(kount))
    1])) / 2;
    if (ypos >= getSize().height || ypos <= 0) {
    g.drawString("", 0, 0); // CLEAR THE APPLET
    ypos = getSize().height;
    if (kount <= parseVector.size()) {
    kount++;
    } else {
    kount = 0;
    g.drawString(((String[])parseVector.elementAt(kount))[
    ], xpos, ypos);
    class ScrollNews implements Runnable {
    public void run() {
    while (true) {
    ypos = ypos - 1;
    ParseNews.this.repaint();
    try {
    Thread.sleep(50);
    } catch (InterruptedException e) {}
    I don't know why this breaks after working one time
    through the Vector parseVector, what am I missing????
    PhilI think your problem is here:
    while (true) {You have an infinite loop - how will the while loop ever be false?

  • Odd behaviour in Graphics2D.drawImage - infinite loop?

    Hi,
    I have the following code inside an overriden paintComponent (JPanel):
    g2.drawImage(fc.getImage(),(int)fc.getSignificantPoint().getX(),
                                    (int)fc.getSignificantPoint().getY(), vioPanel);fc is just an object that is a wrapper for an image and vioPanel is the JPanel class that has been overriden (it's not this because the drawing on g2 is done outside the jpanel class)
    I'm getting some really strange behaviour that i can't explain: when the images are drawn i noticed they were flashing. so i put a system.out.println into the paintComponent method and it seems that calling the g2.drawImage method is causing the panel to be repainted constantly as if it is stuck in an infinite loop. Has anyone else experienced this? if so, do you know the solution?
    If it helps, if you replace the vioPanel variable with new JPanel() the looping stops.
    Cheers,
    jj

    hi,
    VioPanel is a simple class that overrides JPanel with some extra functionality. Essentially tho, it overrides the paintComponent method as shown below and calls a method of a different object that draws the shapes and images. I tried putting all the code in that method into paintComponent (i.e. classic overriding of paintComponent), but still get the same problem.
    public void paintComponent(Graphics g)
            super.paintComponent(g);
            dm.fireGraphics2DSequence();
        }The fireGraphics2DSequence method does all the drawing:
    public void fireGraphics2DSequence()
            Graphics2D g2 = getPanelGraphics();
            g2.scale(magniFactor, magniFactor);
            //separate entities out
            ArrayList features = getFeatures();
            ArrayList lines = getLines();
            //draw map entities (lines and hubs first)
            for(int i = 0; i < lines.size(); i++)
                //draws shapes, which works fine
            //draw nodes
            g2.setColor(Color.black);
            for(int i = 0; i < features.size(); i++)
                FeatureCircle fc = (FeatureCircle)features.get(i);
                if (fc.isTagged()) continue;
                g2.drawImage(fc.getImage(),(int)fc.getSignificantPoint().getX(),
                                    (int)fc.getSignificantPoint().getY(), vioPanel);
                //System.out.println("drawing "+i);
                if(entLabels) g2.drawString(fc.getName(),(float)fc.getSignificantPoint().getX(),
                                           (float)fc.getSignificantPoint().getY());
        }

  • SQL stored procedure Staging.GroomDwStagingData stuck in infinite loop, consuming excessive CPU

    Hello
    I'm hoping that someone here might be able to help or point me in the right direction. Apologies for the long post.
    Just to set the scene, I am a SQL Server DBA and have very limited experience with System Centre so please go easy on me.
    At the company I am currently working they are complaining about very poor performance when running reports (any).
    Quick look at the database server and CPU utilisation being a constant 90-95%, meant that you dont have to be Sherlock Holmes to realise there is a problem. The instance consuming the majority of the CPU is the instance hosting the datawarehouse and in particular
    a stored procedure in the DWStagingAndConfig database called Staging.GroomDwStagingData.
    This stored procedure executes continually for 2 hours performing 500,000,000 reads per execution before "timing out". It is then executed again for another 2 hours etc etc.
    After a bit of diagnosis it seems that the issue is either a bug or that there is something wrong with our data in that a stored procedure is stuck in an infinite loop
    System Center 2012 SP1 CU2 (5.0.7804.1300)
    Diagnosis details
    SQL connection details
    program name = SC DAL--GroomingWriteModule
    set quoted_identifier on
    set arithabort off
    set numeric_roundabort off
    set ansi_warnings on
    set ansi_padding on
    set ansi_nulls on
    set concat_null_yields_null on
    set cursor_close_on_commit off
    set implicit_transactions off
    set language us_english
    set dateformat mdy
    set datefirst 7
    set transaction isolation level read committed
    Store procedures executed
    1. dbo.p_GetDwStagingGroomingConfig (executes immediately)
    2. Staging.GroomDwStagingData (this is the procedure that executes in 2 hours before being cancelled)
    The 1st stored procedure seems to return a table with the "xml" / required parameters to execute Staging.GroomDwStagingData
    Sample xml below (cut right down)
    <Config>
    <Target>
    <ModuleName>TransformActivityDim</ModuleName>
    <WarehouseEntityName>ActivityDim</WarehouseEntityName>
    <RequiredWarehouseEntityName>MTV_System$WorkItem$Activity</RequiredWarehouseEntityName>
    <Watermark>2015-01-30T08:59:14.397</Watermark>
    </Target>
    <Target>
    <ModuleName>TransformActivityDim</ModuleName>
    <WarehouseEntityName>ActivityDim</WarehouseEntityName>
    <RequiredWarehouseEntityName>MTV_System$WorkItem$Activity</RequiredWarehouseEntityName>
    <ManagedTypeViewName>MTV_Microsoft$SystemCenter$Orchestrator$RunbookAutomationActivity</ManagedTypeViewName>
    <Watermark>2015-01-30T08:59:14.397</Watermark>
    </Target>
    </Config>
    If you look carefully you will see that the 1st <target> is missing the ManagedTypeViewName, which when "shredded" by the Staging.GroomDwStagingData returns the following result set
    Example
    DECLARE @Config xml
    DECLARE @GroomingCriteria NVARCHAR(MAX)
    SET @GroomingCriteria = '<Config><Target><ModuleName>TransformActivityDim</ModuleName><WarehouseEntityName>ActivityDim</WarehouseEntityName><RequiredWarehouseEntityName>MTV_System$WorkItem$Activity</RequiredWarehouseEntityName><Watermark>2015-01-30T08:59:14.397</Watermark></Target><Target><ModuleName>TransformActivityDim</ModuleName><WarehouseEntityName>ActivityDim</WarehouseEntityName><RequiredWarehouseEntityName>MTV_System$WorkItem$Activity</RequiredWarehouseEntityName><ManagedTypeViewName>MTV_Microsoft$SystemCenter$Orchestrator$RunbookAutomationActivity</ManagedTypeViewName><Watermark>2015-01-30T08:59:14.397</Watermark></Target></Config>'
    SET @Config = CONVERT(xml, @GroomingCriteria)
    SELECT
    ModuleName = p.value(N'child::ModuleName[1]', N'nvarchar(255)')
    ,WarehouseEntityName = p.value(N'child::WarehouseEntityName[1]', N'nvarchar(255)')
    ,RequiredWarehouseEntityName =p.value(N'child::RequiredWarehouseEntityName[1]', N'nvarchar(255)')
    ,ManagedTypeViewName = p.value(N'child::ManagedTypeViewName[1]', N'nvarchar(255)')
    ,Watermark = p.value(N'child::Watermark[1]', N'datetime')
    FROM @Config.nodes(N'/Config/*') Elem(p)
    /* RESULTS - NOTE THE NULL VALUE FOR ManagedTypeViewName
    ModuleName WarehouseEntityName RequiredWarehouseEntityName ManagedTypeViewName Watermark
    TransformActivityDim ActivityDim MTV_System$WorkItem$Activity NULL 2015-01-30 08:59:14.397
    TransformActivityDim ActivityDim MTV_System$WorkItem$Activity MTV_Microsoft$SystemCenter$Orchestrator$RunbookAutomationActivity 2015-01-30 08:59:14.397
    When the procedure enters the loop to build its dynamic SQL to delete relevant rows from the inbound schema tables it concatenates various options / variables into an executable string. However when adding a NULL value to a string the entire string becomes
    NULL which then gets executed.
    Whilst executing "EXEC(NULL)" would cause SQL to throw an error and be caught, executing the following doesnt
    DECLARE @null_string VARCHAR(100)
    SET @null_string = 'hello world ' + NULL
    EXEC(@null_string)
    SELECT @null_string
    So as it hasnt caused an error the next part of the procedure is to move to the next record and this is why its caught in an infinite loop
    DELETE @items WHERE ManagedTypeViewName = @View
    The value for the variable @View is the ManagedTypeViewName which is NULL, as ANSI_NULLS are set to ON in the connection and not overridded in the procedure then the above statement wont delete anything as it needs to handle NULL values differently (IS NULL),
    so we are now stuck in an infinite loop executing NULL for 2 hours until cancelled.
    I amended the stored procedure and added the following line before the loop statement which had the desired effect and "fixed" the performance issue for the time being
    DELETE @items WHERE ManagedTypeViewName IS NULL
    I also noticed that the following line in dbo.p_GetDwStagingGroomingConfig is commented out (no idea why as no notes in the procedure)
    --AND COALESCE(i.ManagedTypeViewName, j.RelationshipTypeViewName) IS NOT NULL
    There are obviously other ways to mitigate the dynamic SQL string being NULL, there's more than one way to skin a cat and thats not why I am asking this question, but what I am concerned about is that is there a reason that the xml / @GroomingCriteria is incomplete
    and / or that the procedures dont handle potential NULL values.
    I cant find any documentation, KBs, forum posts of anyone else having this issue which somewhat surprises me.
    Would be grateful of any help / advice that anyone can provide or if someone can look at their 2 stored procedures on a later version to see if it has already been fixed. Or is it simply that we have orphaned data, this is the bit that concerns most as I dont
    really want to be deleting / updating data when I have no idea what the knock on effect might be
    Many many thanks
    Andy

    First thing I would do is upgrade to 2012 R2 UR5. If you are running non-US dates you need the UR5 hotfix also.
    Rob Ford scsmnz.net
    Cireson www.cireson.com
    For a free SCSM 2012 Notify Analyst app click
    here

  • Infinite loop/afrLoop when deploying ADF application to standalone weblogic

    Working with Oracle ADF / JDeveloper 11.1.2.2
    I have enabled ADF security in my application and am using JAAS combined with Oracle EBS users and roles to provide security to the application. Testing on my local integrated weblogic server works fine.
    When deploying my Oracle ADF application to a standalone Weblogic server through an EAR file, requesting a JSF page causes the server to go into an infinite loop on both IE and firefox.
    GET /test-app/faces/login.jsf HTTP/1.1     200
    GET /test-app/faces/login.jsf?_afrLoop=346001033248597&_afrWindowMode=0&Adf-Window-Id=w0 HTTP/1.1     302
    GET /test-app/adfAuthentication HTTP/1.1     302
    GET /test-app/faces/login.jsf HTTP/1.1     200
    GET /test-app/faces/login.jsf?_afrLoop=346001340281597&_afrWindowMode=0&Adf-Window-Id=w0 HTTP/1.1     302
    GET /test-app/adfAuthentication HTTP/1.1     302
    GET /test-app/faces/login.jsf;jsessionid=syWvP1nMY1L87BySh2JbTd1tb4SY0HzDw6T3LvLctvkbMWKmqqJv!1800986117 HTTP/1.1     200
    GET /test-app/adfAuthentication HTTP/1.1
    Reviewing some of the suggestions from the forum and from the link below, I have tried fixing the issue through updates to my web.xml - but am still having the same issue.
    https://blogs.oracle.com/jdevotnharvest/entry/solving_jdeveloper_11gr2_issue_with
    Updated web.xml:
    <security-constraint>
    <web-resource-collection>
    <web-resource-name>Allowed ADF Resources</web-resource-name>
    <url-pattern>/adf/*</url-pattern>
    <url-pattern>/afr/*</url-pattern>
    <url-pattern>/bi/*</url-pattern>
    <url-pattern>/servlet/GraphServlet/*</url-pattern>
    <url-pattern>/servlet/GaugeServlet/*</url-pattern>
    <url-pattern>/mapproxy/*</url-pattern>
    <url-pattern>/adflib/</url-pattern>
    </web-resource-collection>
    <web-resource-collection>
    <web-resource-name>allPages</web-resource-name>
    <url-pattern>/*</url-pattern>
    </web-resource-collection>
    <web-resource-collection>
    <web-resource-name>adfAuthentication</web-resource-name>
    <url-pattern>/adfAuthentication</url-pattern>
    </web-resource-collection>
    <auth-constraint>
    <role-name>valid-users</role-name>
    </auth-constraint>
    </security-constraint>
    <login-config>
    <auth-method>FORM</auth-method>
    <form-login-config>
    <form-login-page>/faces/login.jsf</form-login-page>
    <form-error-page>/faces/login-error.jsf</form-error-page>
    </form-login-config>
    </login-config>
    <security-role>
    <role-name>valid-users</role-name>
    </security-role>
    weblogic.xml
    <security-role-assignment>
    <role-name>valid-users</role-name>
    <principal-name>users</principal-name>
    </security-role-assignment>
    I know other users have experienced similar issues - but I am having trouble debugging or troubleshooting why this is happening.
    Any suggestions on how to further troubleshoot or resolve this issue would be appreciated!
    Dan

    I was able to resolve the login page looping issue.
    The issue is related to the login page being a JSF page based on a page template.
    When I created the JSF login page as a page template - the template contains a binding:
    <af:pageTemplate viewId="/test-template.jsf" value="#{bindings.ptb1}" id="pt1">
    When I deploy my application to the test weblogic server, the anonymous-role grants are not being respected. So even though I grant view access to the login JSF page to anonymous-role -- it appears that weblogic is trying to request a login for any page with a pageDef (including the login page). By re-creating the login page with no pageDef (a JSF page that does not use a page template) -- the login page is displayed (rather than entering into a loop).
    There is still a seperate issue with the anonymous-role grant not working as I would expect it to work that I will need to troubleshoot further.

  • Satellite A100-998: Blue Screen error - nv4_disp.dll infinite loop

    I bought this laptop a month ago and I have a serious problem with 3d applications, 3ds max and video games. I receive a blue screen saying
    Error message: STOP 0x000000EA THREAD_STUCK_IN_DEVICE_DRIVER
    nv4_disp.dll
    STOP: 0x000000EA (0x8408E6B8, 0x88D33F60, 0xBAF7BCBC, 0x00000001)
    (hope i noted down correctly) and it says something about "that this device caught in an infinite loop)
    I downloaded the latest drivers for my nvidia display Forceware 84.68 (GeForce Go 7300, 512ram)from Toshiba but nothing changed. Any suggestions ? What is the problem? the performance is really good until the blue screen appears, so i don't see why this happens...
    The laptop came with windows xp media center edition.
    Thanks in advance.

    > Yes, i think so, the problem is that it is not easy
    > to be separated with my laptop ... especially when
    > you have deadlines! I will call them tomorrow maybe
    > there is a hardware problem. It happens in all 3d
    > applications, and i have the most recent drivers.
    Did you ever get an answer? When i took my laptop home, the first thing i did once it was setup was test various 3d programs, because i bought it to do my 3d work on as well as having something mobile for work. I got that stop error, called toshiba and was told to uninstall and reinstall the graphics driver. Sounded like a fob but i did it anyway, and it had no effect. It seems like there's nothing i can do as Nvidia says they don't support it, it's a toshiba problem, and toshiba swears it can't be their fault.
    I used to see it on my desktop (before it went to computer heaven) until i updated the driver (a new one came out), and then i never got it again. From what toshiba tech support told me, it sounds like they won't be updating the driver for the go 7300 as it's regarded as too old? I'm pretty disappointed as my search of reviews of the product never revealed this flaw.
    One person who i talked to advised me to disable Hardware Acceleration, but wihout that i might as well saved money and gotten a cheapy graphics card. The price difference between a notebook with this card and one with the onboard intel type was huge.
    The first notebook i bought had a faulty dvd drive and i returned it for this one. I cringe at the thought of calling toshiba again and having them tell me to return it to them as if it was a hardware failure, when it sounds like a poorly written driver is causing the STOP.

  • Apple TV 1st gen stuck in infinite loop

    Hi
    This has probably been covered a few times but the only answers I could find was from an archived discussion.
    The other day I was given an Apple TV 1st gen, it had not been used for quite some time, and decided to upgrade the software, when I noticed it still had old pictures and music on from the previous user, not wanting to keep these pictures, I decided to reset the machine to factory settings, which it did, but on the restart it was stuck at a loop giving me a code to enter into iTunes, and then resetting and giving me a different code.
    i've tried several resets of the settings, holding menu and - together, but still having no joy.
    Its never been tampered with, but its really annoying me.
    Can anyone help? this is a very old product so figure something might have been done during this time
    Cheers
    Dave

    sounddave,
    I have been in the middle of the same problem for months.
    I think the problem is with the software version that the older 40GB Apple TV's revert to after the factory restore.  Mine reverted to version 1.0, and that is when the loop started happening.  Since when did a factory restore become a factory paper weight creator!
    I read somewhere that the Apple TV looks at an Apple server and the older software doesn't play well with the updated server causing it to keep rebooting.  I'll try to find a link about this if I can find it again.  I remember reading that it happened to a bunch of people with older Apple TV software on a particular day that Apple upgraded their server.
    If you don't let your Apple TV connect to the internet, it will stop the infinite loop, but it also means you can't upgrade your software.  I haven't tried it yet, but it also might be an issue with newer versions of iTunes.
    I tested this by unplugging my router, and the Apple TV stopped looping.
    I tried to fix this before without success, but I am really determined this time.

Maybe you are looking for

  • What just happened? HD password suddenly doesn't work...

    Alright this is a tricky one.  W520 w/ Intel SSD. I've got a Supervisor (SPV) password set for my BIOS as well as a HD password set.  I don't think I had a Power-on password set but I'm not sure. No problems, my password has always worked.  I'm worki

  • What do I do if my phone wont connect to my phone number for imessage?

    so my phone is acting up and wont let me use my phone number for iMessage! what do i do?!!?!?!??!?!???!??!?!?!?!??!?!?!?!?!?!?!?

  • Licence for Photoshop v 9  as part of CS2

    I have a licence code for the above and have tried downloading  Photoshop Elements v9  package However  I have noticed that CS2 isn't downloadable and when I try and enter the licence code it says its not valid  Any suggestions ?  Any help much appre

  • How to manually recover user state data saved to a State Migration Point

    Hi, In SCCM 2012, how would you recover the User State saved to the State Migration Point manually? In SCCM 2007 you could do what was outlined here: http://social.technet.microsoft.com/Forums/en-US/configmgrosd/thread/159affd3-1726-4829-a0f4-0c87548

  • CUP 5.3 issue

    Dear Experts, I have an issue with CUP 5.3. I have 3 systems say ECC, SEM, SCM. I need to configure in such a way that If user requests for a new account in all these systems, the system should do Mandatory Riskanalysis for ECC and it should not perf