Illegal state Exception when running the code at startup

Here's my main method:

    public static void main(String[] args)
    {
        if (args.length == 1 && args[0].equals("startup"))
        {
            Criteria locationCriteria = new Criteria();
            locationCriteria.setCostAllowed(false);
            LocationProvider mlocationProvider;
            Location mLocation = null;
            try
            {
                mlocationProvider = LocationProvider
                        .getInstance(locationCriteria);
                mLocation = mlocationProvider.getLocation(-1);
            }
            catch (LocationException e) {
            }
            catch (InterruptedException e) {
            }
            QualifiedCoordinates mQC = mLocation.getQualifiedCoordinates();
        }
        else
        {
            MyApp theApp = new MyApp();
            theApp.enterEventDispatcher();
        }
    }

The method

 mlocationProvider = LocationProvider.getInstance(locationCriteria); 

throws the illegal state exception

When I check the debug information, I found this exception are thrown to the line when he calls Application.getApplication ();

When I move this code to run in a normal life to screen it works fine. !

Any help?

There may be a number of issues here:

(1) until your Application is actually running, you can't really do any processing.  Your Application does not start running until you

'enterEventDispatcher() '.

Hand, all you should do is instantiate your Application.  Manufacturer of your Application should not do anything complicated either, since it works as part of main().

You can do some activities, for example to add listeners, in main() code that is, in some respects, unfortunate because it lulls people into thinking they can do anything.  ,

(2) get the location as you do, is a blocking call.  If you need to do it on a background Thread.  You c a get away with that on the Simulator because GPS simulated returns immediately with a location.  So it does not actually block.  But on a real device, code as you can force your application to break.

(3) you seem to try to do something in the commissioning.  You must be aware, this start-up up is called as part of the start-up of the device and before the unit is fully active.  In fact, I think on a real device that this code will fail because the device is not ready to provide a location in the beginning upward.

You will find find article, informative and useful for (1) and (3).

http://supportforums.BlackBerry.com/T5/Java-development/write-safe-initialization-code/Ta-p/444795

I suspect you want to start and get a location at first upward, in which case you might find this useful:

http://supportforums.BlackBerry.com/T5/Java-development/create-a-background-application/Ta-p/445226

Tags: BlackBerry Developers

Similar Questions

  • JavaFX binding throws illegal state Exception: not on the thread of Application FX

    Hi all

    I am updating a label of a task using bindings.

    However, when I 'Bind' the label text property with a property of the task, Illegal state exception string is thrown. Saying: this is not not on the thread of JavaFX.

    The Exception occurs whenever I try to set the property of the task of the Interior string.

    Please do not suggest to use the platform. RunLater(). I want to do this through links as the values I am trying to display in the label (later on) could change too frequently, and I don't want to flood the queue of the thread of the user interface with executable objects.

    Please let me know what I'm doing wrong and what I need to change to make it work properly with links. (I'm new to links and concurrency JavaFx API)

    Here is my Code.

    public class MyTask extends Task<String>{
    
        MyTask(){
           System.out.println("Task Constructor on Thread "+Thread.currentThread().getName());
    
    
        }
        private StringProperty myStringProperty = new SimpleStringProperty(){
            {
                System.out.println("Creating stringProperty on Thread "+Thread.currentThread().getName());
            }
        };
        private final void setFileString(String value) {
            System.out.println("Setting On Thread"+Thread.currentThread().getName());
            myStringProperty.set(value); }
        public final String getFileString() { return myStringProperty.get(); }
        public final StringProperty fileStringProperty() {
            System.out.println("Fetching property On Thread"+Thread.currentThread().getName());
            return myStringProperty; }
        
        @Override
        public String call() throws Exception{
            System.out.println("Task Called on thread "+Thread.currentThread().getName());
    
    
           for(int counter=0;counter<100;counter++){
               try{
               setFileString(""+counter);
               }catch(Exception e){
                   e.printStackTrace();
               }
               Thread.sleep(100);
               System.out.println("Counter "+counter);
           }
           return "COMPLETED";
        }
    }
    
    
    public class MyService extends Service<String> {
    
    
        MyTask myTask;
    
        public MyService(){
            System.out.println("Service Constructor on Thread "+Thread.currentThread().getName());
            myTask=new MyTask();
        }
    
        @Override
        public Task createTask(){
            System.out.println("Creating task on Thread "+Thread.currentThread().getName());
            return myTask;
        }
    
    }
    
    
    public class ServiceAndTaskExperiment extends Application {
        @Override
        public void start(Stage stage) throws Exception {
            Parent root = FXMLLoader.load(getClass().getResource("Sample.fxml"));
            Scene scene = new Scene(root);
            stage.setScene(scene);
            stage.show();
        }
        public static void main(String[] args) {
            launch(args);
        }
    }
    
    
    public class SampleController implements Initializable {
        @FXML
        private Label label;
    
        @FXML
        private void handleButtonAction(ActionEvent event) {
            System.out.println("You clicked me!");
            myTestService.start(); //This will throw out exceptions when the button is clicked again, it does not matter
        }
    
        MyService myTestService=new MyService();
        @Override
        public void initialize(URL url, ResourceBundle rb) {
            label.setText("Hello World!");
            //adding the below Line causes the exception
            label.textProperty().bind(myTestService.myTask.fileStringProperty()); //removing this line removes the exception, ofcourse the label wont update.
        } 
    }
    //sample.fxml
    <?xml version="1.0" encoding="UTF-8"?>
    <?import java.lang.*?>
    <?import java.util.*?>
    <?import javafx.scene.*?>
    <?import javafx.scene.control.*?>
    <?import javafx.scene.layout.*?>
    
    
    <AnchorPane id="AnchorPane" prefHeight="200" prefWidth="320" xmlns:fx="http://javafx.com/fxml" fx:controller="serviceandtaskexperiment.SampleController">
        <children>
            <Button layoutX="126" layoutY="90" text="Click Me!" onAction="#handleButtonAction" fx:id="button" />
            <Label layoutX="126" layoutY="120" minHeight="16" minWidth="69" fx:id="label" />
        </children>
    </AnchorPane>
    
    
    
    

    And it is the output with links on:

    Output: when the link is activated label.textProperty () .bind (myTestService.myTask.fileStringProperty ());

    Service on JavaFX Application Thread constructor

    Creating string on thread JavaFX Application Thread

    Task, Builder on JavaFX Application Thread

    Get the property on request ThreadJavaFX wire

    You clicked me!

    Creating a task on a thread Thread Application JavaFX

    Task called threadThread-4

    Setting on ThreadThread-4

    java.lang.IllegalStateException: not on the application thread FX; currentThread = Thread-4

    at com.sun.javafx.tk.Toolkit.checkFxUserThread(Toolkit.java:237)

    at com.sun.javafx.tk.quantum.QuantumToolkit.checkFxUserThread(QuantumToolkit.java:398)

    to javafx.scene.Parent$ 1.onProposedChange(Parent.java:245)

    at com.sun.javafx.collections.VetoableObservableList.setAll(VetoableObservableList.java:90)

    at com.sun.javafx.collections.ObservableListWrapper.setAll(ObservableListWrapper.java:314)

    at com.sun.javafx.scene.control.skin.LabeledSkinBase.updateChildren(LabeledSkinBase.java:602)

    at com.sun.javafx.scene.control.skin.LabeledSkinBase.handleControlPropertyChanged(LabeledSkinBase.java:209)

    to com.sun.javafx.scene.control.skin.SkinBase$ 3.changed(SkinBase.java:282)

    at javafx.beans.value.WeakChangeListener.changed(WeakChangeListener.java:107)

    to com.sun.javafx.binding.ExpressionHelper$ SingleChange.fireValueChangedEvent (ExpressionHelper.java:196)

    at com.sun.javafx.binding.ExpressionHelper.fireValueChangedEvent(ExpressionHelper.java:100)

    at javafx.beans.property.StringPropertyBase.fireValueChangedEvent(StringPropertyBase.java:121)

    at javafx.beans.property.StringPropertyBase.markInvalid(StringPropertyBase.java:128)

    in javafx.beans.property.StringPropertyBase.access$ 100 (StringPropertyBase.java:67)

    to javafx.beans.property.StringPropertyBase$ Listener.invalidated (StringPropertyBase.java:236)

    to com.sun.javafx.binding.ExpressionHelper$ SingleInvalidation.fireValueChangedEvent (ExpressionHelper.java:155)

    at com.sun.javafx.binding.ExpressionHelper.fireValueChangedEvent(ExpressionHelper.java:100)

    at javafx.beans.property.StringPropertyBase.fireValueChangedEvent(StringPropertyBase.java:121)

    at javafx.beans.property.StringPropertyBase.markInvalid(StringPropertyBase.java:128)

    at javafx.beans.property.StringPropertyBase.set(StringPropertyBase.java:161)

    at javafx.beans.property.StringPropertyBase.set(StringPropertyBase.java:67)

    to serviceandtaskexperiment. MyTask.setFileString (MyTask.java:24)

    to serviceandtaskexperiment. MyTask.call (MyTask.java:36)

    to serviceandtaskexperiment. MyTask.call (MyTask.java:11)

    to javafx.concurrent.Task$ TaskCallable.call (Task.java:1259)

    at java.util.concurrent.FutureTask.run(FutureTask.java:262)

    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)

    to java.util.concurrent.ThreadPoolExecutor$ Worker.run (ThreadPoolExecutor.java:615)

    at java.lang.Thread.run(Thread.java:724)

    Output with links removed: (label will not be updated)

    Service on JavaFX Application Thread constructor

    Creating string on thread JavaFX Application Thread

    Task, Builder on JavaFX Application Thread

    You clicked me!

    Creating a task on a thread Thread Application JavaFX

    Task called threadThread-4

    Setting on ThreadThread-4

    Counter 0

    Setting on ThreadThread-4

    1 meter

    Setting on ThreadThread-4

    2 meter

    Setting on ThreadThread-4

    If myStringProperty is bound to the textProperty of etiquette, you can only change it on the Thread of the JavaFX Application. The reason is that change its value will result in a change of the label, and changes of live parts of the graphic scene cannot be performed on the Thread of the JavaFX Application.

    Task and Service classes expose a messageProperty you could use here. The Task class has a updateMessage (...) method that changes the value of the message on the Thread of the JavaFX Application property. It also merges calls in order to prevent the flooding of this thread. If you could do the following in your MyTask.call () method:

    updateMessage(""+counter);
    

    and then in your controller just do

    label.textProperty().bind(myTestService.messageProperty());
    

    If you don't want to use the messageProperty for some reason any (for example you are already using it for something else, or you want to make something similar to a property that is not a string), you must merge the updates yourself. What follows is based on the source code of the task:

    public class MyTask extends Task {
    
         // add in the following:
        private final AtomicReference fileString = new AtomicReference<>();
    
        private void updateFileString(String text) {
            if (Platform.isFxApplicationThread()) {
                setFileString(text);
            } else {
                if (fileString.getAndSet(text) == null) {
                    Platform.runLater(new Runnable() {
                        @Override
                        public void run() {
                            final String text = fileString.getAndSet(null);
                            MyTask.this.setFileString(text);
                        }
                    });
                }
            }
        }
    
       // Now just call updateFileString(...) from your call() method
    }
    
  • HPC for Excel - get the exception when running the diagnostics

    I was wondering if anyone would be able to provide assistance with the issue I am dealing with the help of HPC (2012 R2) for Excel (2016).

    I started a new Setup and all made in the paper, as shown here on the Microsoft Web site: start with HPC server (this site is not allow me to paste the link here). I have a test cluster consisting of 1 head node, 1 compute node. The domain controller is on a separate server. All have Windows Server 2012 R2 64-bit installed and installed using the deployment of Excel 2016 32-bit Office tool. I have installed HPC Pack 2012 R2 Update 3 on the head node and compute node. The problem is when I run the Test of the Excel of Diagnostics of HPC Cluster Manager Configuration, the test fails for the two nodes (i.e. the head and calculation). For the head node, I get an exception with a long error message that ends with some problem with "ExcelClient.Dispose". On the compute node, the error is that she could not invoke service 'Excel '.

    I think I have done everything exactly according to the instructions and followed other steps that have helped me in a successful test deployment. Any help to understand what I am doing wrong will be greatly appreciated!

    Hello

    I suggest you post your query on the TechNet forums to get help. Consult the following link:

    https://social.technet.Microsoft.com/forums/WindowsServer/en-us/home?Forum=winserver8gen

    It will be useful.

  • Exception when running the application deployed on WLS

    Hello everyone.

    I developed an application. When I ran the JDeveloper (jspx page) application, it worked very well. Now, I have another instance WLS in my pc (new_domain). When I deploy my application in this area and of the race, I am getting following error.

    java.security.PrivilegedActionException: weblogic.common.ResourceException: java.security.PrivilegedActionException: weblogic.common.ResourceException: no entry credential Mapper found for user password indirection = shipping_assignment for the data source Connection1

    Should I change to anything\?

    Hello

    Check out this thread.

    What does this message mean?

    Arun-

  • By clicking on the button "return" gives illegal state exception

    Hello

    In my app, when I'm clicking on I show a dialog box. and when I am pressing Yes in the dialog box, it gives me the illegal state exception. But I want to return to the previous screen. If I'm clicking on menu and then clicking Close, and then it goes back to the previous screen. Here is my code:

    public boolean keyDown(int keycode, int time) {
    
            if (Keypad.KEY_ESCAPE == Keypad.key(keycode)) {
                int result = Dialog.ask(Dialog.D_YES_NO, "Do you want to edit the list?");
                if (result == Dialog.YES)
                {
                    try
                    {
                        UiApplication.getUiApplication().popScreen(this);
                    }
                    catch (Exception e)
                    {
                        e.printStackTrace();
                    }
    //              onClose();
                }
                else
                {
                    return true;
                }
            } // end if
    
            return false;
        }
    

    Please help me...

    Same question in StackOverFlow:

    Dear arindamhit,

    When you are clicking back into the device and then by default button the onclose() method is called. So try to do like this;

    protected boolean onSavePrompt()
    {
        return true;
    }
    
    public boolean onClose()
    {
        int choose=Dialog.ask(Dialog.D_YES_NO, "Close the screen");
        if(choose==Dialog.YES)
        {
            return super.onClose();
        }
        return true;
    }
    

    It's the best way; If you use like the one above you might get a problem; It is:

    *) If you use this method on the first screen, then according to your code when popup screen then there is no screen in the battery display (because it's the first screen); So you could get this kind of problem;

    Try this one;

  • URGENT::opening multiple files - i have 3 files in my directory... When I run the code I can open a file and read it... but the while loop get blocked after the first iteration... can someone me help or give some indications

    bbmChatDB of public database;

    public static FileConnection fconnRead = null;
    public static String fileReadData = "";
    public static InputStream is = null;
    data Byte [] = null;
    DataInputStream is = null;

    Here is my code...

    I have 3 files in my directory... When I run the code I can open a file and read it... but the while loop get blocked after the first iteration... can someone me help or give some indications

    try {}

    FileConnection fc = Connector.open("file:///store/home/user/documents/BSM/") (FileConnection); "

    If (fc.exists ()) {}

    Enumeration e = fc.list ();

    While (e.hasMoreElements ()) {}

    System.out.println ("files are:" + (String) e.nextElement ());

    play this file
    StringBuffer stringBuff = new StringBuffer();
    try {}
    System.out.println ("opening file")-;
    System.out.println ("file name is:" + (String) e.nextElement ());
    fconnRead = Connector.open("file:///store/home/user/documents/BSM/(String)e.nextElement(),Connector.READ_WRITE) (FileConnection);
    System.out.println ("data length")-;
    If (fconnRead.exists ()) {}
    is = fconnRead.openDataInputStream ();
    data = IOUtilities.streamToBytes (is);
    Ddd = new String string (data);
    fileReadData = ddd.toString ();
    System.out.println ("length of data:" + fileReadData.length ());
    System.out.println ("read data :" + fileReadData);

    }

    } catch (IOException ee) {}
    ee.printStackTrace ();
    System.out.println ("Exception in the read data :")
    + ee.getMessage ());
    }

    }
    }

    } catch (IOException e) {}

    e.printStackTrace ();
    }

    {Finally

    try {}
    If (is! = null) {}
    is. Close();
    }
    System.out.println ("is closed...");
    } catch (IOException e1) {}

    E1. PrintStackTrace();
    }

    If (fconnRead! = null) {}
    try {}
    fconnRead.close ();
    } catch (Exception e) {}
    System.out.println (try ());
    }

    }

    }

    You can recode this treatment so that it uses only:

    e.nextElement ())

    Once a loop iteration.

    Directly at the start saying something like:

    String fileName = e.nextElement ());

    and use fileName everywhere in your loop.

    Also be aware that printStackTrace() will do nothing in your situation, it only works if you catch Throwable.  So make sure you something output all your catches exception and also have a catch (Throwable t) to catch the things you miss, as follows:

    {} catch (Throwable t)

    t.printStackTrace ();

    System.out.println ("Eception exception:" + t.toString ());

    }

    I think your code is thrown an exception and you don't see it.

  • Run the code once when loading the form

    Hi guys,.

    I have a text field (TextField1), which fills with a value (1-100)

    During the initial loading of the form, this value will be the highest.

    When the user navigates around the shape, this number will change (lower than initial load)

    I have another text field (TextField2) on the form I want to keep the original value to the loading of the form.

    something like: TextField2.rawValue = TextField1.rawValue

    But any event that I put in it always updates TextField2 with TextField1 value (not does not run the code once when loading the form)

    Can someone tell how can I do this?

    If the form is loaded with the number 70 as a value in TextField1 - TextField2 has 70 as a value and maintains this value regardless of what TextField1 goes to...

    Thanks a lot for any help

    try putting in the TextField2 docReady event:

    $ = TextField1.rawValue

  • see URLEncodedPostData.getBytes () and illegal state Exception

    Hi, expert,

    recently when I tried to understand the device encryption, I discovered my starts http grave failed when the device is locked and the encryption is enabled. After the addition of debugging information more, I finally discovered that the exception is thrown to the URLEncodedPostData.getBytes () with IllegalStateException, here is a part of the stack trace:

      IllegalStateException
        No detail message
        net_rim_cldc-11(4DE8751A)
         PersistentContent
         decode
         0x8E80
        net_rim_cldc-11(4DE8751A)
         PersistentContent
         decode
         0xB1FC
        net_rim_cldc-11(4DE8751A)
         PersistentContent
         decode
         0xB18A
        net_rim_bb_browser_lib(4DE8802C)
         URLEncodedFormData
         toString
         0xB6C9
        net_rim_bb_browser_lib(4DE8802C)
         URLEncodedFormData
         getBytes
         0xB6B2
        net_rim_bbapi_browser(4DE88041)
         URLEncodedPostData
         getBytes
         0x411
    

    Then I did some search on the forum, I found this link, and that is exactly the same as what I saw: http://supportforums.blackberry.com/t5/Java-Development/URLEncodedPostData-getBytes-and-Illegal-Stat... As I saw no explanation on this thread, I just open this post to see if there is any explanation about it.  I guess that fi that we can't work around this problem, we would have to write code ourselves url code.

    This proximity. Work of my own URL encoding code which is pretty easy to code.

  • Run the code from the jar java fixed pitch

    Hello

    based on article

    https://supportforums.Cisco.com/document/98986/UCCX-quick-Java-recipes

    I copied the code of 1). and they changed a bit for my daysx24hours. The only type is, give the script a parameter (here the number of credit card and return the result of UCCX (perhaps the last type is missing).)

    The following code:

    ###############################################################################

    public class ClassCheckCC {}

    Public Shared Sub main (String [] args) {}
    TODO self-generating method stub
    String ccnumber = args [0];
    String ccnumber = "66666666666666666";
    int isValid = 99;
    isValid = verifyCC (ccnumber);
    System.out.println (IsValid);
    }
            
            
            
            
    private static int verifyCC (String ccnumber) {}
    int sum = 0;
    Boolean alternate = false;
    Boolean isValid = false;
    try {}
    int i = 0;
    for (I = ccnumber.length () - 1; i > = 0; i--) {}
    int n = Integer.parseInt (ccnumber.substring (i, i + 1));
    If {(acting)
    n = n * 2;
    If (n > 9) {}
    n = (% n 10) + 1;
    }
    }
    sum += n;
    Alternate =! alternate;
    }
    isValid = (sum %10 == 0);

    } catch (Exception e) {}

    Returns - 1;

    }

    return (isValid == true? 1: 0);
    }
    }

    ###############################################################################

    In Eclipse, I create a new java project named "CheckCreditCardNumber" and insert this code into the new project. The name of the new class is 'ClassCheckCC '. I created a "CheckCCNumber1.jar" executable jar file This will work as expected in a DOS window.
    I call it this way: java-jar CheckCCNumber1.jar 1234567890123456

    The number represents a credit card number.

    In my opinion, always ready to implement in UCCX.

    JAR file downloaded on UCCX (you can find it in an attachment here), moved to the right side (to the Classpath entries. selected :) Some service restarted. Do some tests to access the file and can be seen in UCCX Editor.

    Then, I created a new script file and inserted a defined step

    takes it place the following errors:

    But the result expected from the byte type (-1.0 or 1) java code. Shit, I declared the variable isValid as string occurs:

    We try to call java code:

    Next, the error message is different:

    Yes, here are my questions. What wrong? Where can I call this java code little success.

    I know, it s possible to run code without additional jar files. I am interested to implement more than java classes in a jar file for future needs, and this is a first step.

    Greetings Naatz Maic

    Hello

    UH... Let's get a few things right if you don't mind.

    Your class is valid, as you say, you tested with Eclipse, which is a fair way to go. You have two methods, 'main' and a private static "verifyCC" returning an int value. Good. Now, if I take a quick glance at your UCCX script I see some interesting things there. First, you create a new variable of type ClassCheckCC, with the name CheckCC and with null as default. Cool, that's like saying JRE of UCCX for "Hey, let's use a new variable of type ClassCheckCC", or more precisely:

    ClassCheckCC CheckCC = null;

    Alrighty. Then, you kind of try to value of isValid saying CheckCC (ccnumber). Why it's wrong: in Java, it does:

    isValid = CheckCC (ccnumber);

    You see already? The above code actually means:

    isValid = null (ccnumber); Not valid!

    CheckCC is null.

    Let's try a slightly different approach:

    public class CheckCC {}
    Public Shared Sub main (String [] args) {}
    System.out.println ("Move along, nothing to see here, call verifyCC (String s) instead. ');
    }
    public static int verifyCC (String ccnumber) {}
    int sum = 0;
    Boolean alternate = false;
    Boolean isValid = false;
    try {}
    int i = 0;
    for (I = ccnumber.length () - 1; i > = 0; i--) {}
    int n = Integer.parseInt (ccnumber.substring (i, i + 1));
    If {(acting)
    n = n * 2;
    If (n > 9) {}
    n = (% n 10) + 1;
    }
    }
    sum += n;
    Alternate =! alternate;
    }
    isValid = (sum %10 == 0);
    } catch (Exception e) {}
    Returns - 1;
    }
    return (isValid == true? 1: 0);
    }
    }

    You may have noticed that I made a few adjustments. I renamed ClassCheckCC to the simpler CheckCC, I changed the method of verifyCC to the public modifier. It's actually a great example of a utility class where you have not all instances, so we should let JDK code optimization.

    Using this approach, we don't need to create instances of the object - that they are unnecessary in this case. Simply call CheckCC.verifyCC (String aString) is quite sufficient. We can, as I will demonstrate, but then again, why should create us instances of the class each time a script is run.

    The following three constructs are valid (assuming that I have created the necessary variables: val, validCCNumber, and invalidCCNumber):

    Valid value = CheckCC.verifyCC (validCCNumber)

    Pure and simple. I simply call the static verifyCC method on the CheckCC class with a parameter.

    The valid value = {return CheckCC.verifyCC (invalidCCNumber) ;}

    I just padded the single line above with braces, creating a block of code, point comma and the return keyword became necessary.

    The valid value = {CheckCC instance = new CheckCC(); return instance.verifyCC (validCCNumber) ;}

    Now, it's quite redundant but functional example. I created an instance of the CheckCC class, named instance and then ran the method verifyCC on the newly created class instance. Once again, it is a situation when a developer is boring and has nothing better to do than to create instances of the class and sending them to the eternal bytefields.

    G.

    Here is a screenshot:

  • NULL point Exception when obtaining the user name

    Hello

    I'm getting NULL pointer exception when trying to get the user name when the page load.

    My code is as follows:

    I had imported the oracle.apps.fnd.framework.webui.beans.message.OAMessageStyledTextBean package

    In the controller under the proceesrequest, I wrote the following code

    String uname = pageContext.getUsername ();
    OAMessageStyledTextBean UN = (OAMessageStyledTextBean) webbean.findChildRecursive ("name");
    one. SetValue (pagecontext, uname);

    After doing that when I run the page I'm getting NULL pointer exception.

    Can someone correct me where I had gone wrong.

    Thank you.

    The error is on line 39 of your controller. First thing you should do to avoid this must include an audit non-zero.
    String uname = pageContext.getUsername ();
    OAMessageStyledTextBean UN = (OAMessageStyledTextBean) webbean.findChildRecursive ("name");
    if(un!=null)
    {
    one. SetValue (pagecontext, uname);
    }

  • Run the Code in a Java Applet

    I'm calling a Java to Javascript applet. The Java code must run in privileged mode.  Eventually it will display a file selector that allows you to view files on the local hard drive, but for now, she simply returns a dummy value simple.  The problem I have is that the JavaScript to Java call return PrivilegedActionException. The applet is in a signed Jar file.  I'm under 8u25.

    This is the Java class:

        // Java code
        public class OHLib extends Applet {
    
            public String getFile() {
                String result;
                try {
                    result = (String) AccessController.doPrivileged(new PrivilegedAction() {
                        public String run() {
                            // JFileChooser code will go here
                            return "xxx";
                       }
                    });
                } catch (Exception e) {
                    e.printStackTrace();
                }
                return result;
            }
    
        }
    
    

    Can someone tell me what's wrong with this code?  I would also be interested to know why the try/catch block above does not catch the exception.  The only place where I see the exception is in browser F12 developer tools.

    Here's the JavaScript code:

        function BrowseForFile() {
            var x;
            try {
                 // this code generates PrivilegedActionException
                 x = ohApplet.getFile();
            } catch (e) {
                 console.log(e);
            }
    
        }
    
    

    The applet is deployed on my web page as follows:

    <script src="/plugins/deployJava.js"></script>
    <script>
         var attributes = { 
             id:'ohApplet',
             code:'OHLib',
             codebase: 'java',
             archive: 'OHLib.jar', 
             width:1, 
             height:1,
         } ;
         var parameters = { 
          jnlp_href: 'OHLib.jnlp',
          classloader_cache: 'false',
         } ;
         deployJava.runApplet(attributes, parameters, '1.8');
    <script>
    
    
    

    The applet is in a jar signed with the following manifest file:

    Application name: < appname >

    Permissions: permissions everything

    CodeBase: < domain > .dev < domain > ".com"

    The appellant eligible Codebase: < domain > .dev < domain > ".com"

    Application library eligible Codebase: < domain > .dev < domain > ".com"

    The JNLP file is as follows:

        <?xml version="1.0" encoding="UTF-8"?>
        <jnlp spec="1.0+" codebase="" href="">
    
            <information>
                <title>title</title>
                <vendor>vendor</vendor>
            </information>
    
            <security>
                <all-permissions />
            </security>
    
            <resources>
                <j2se version="1.8+" href="http://java.sun.com/products/autodl/j2se" />
                <jar href="OHLib.jar" main="true" />
            </resources>
    
            <applet-desc 
                 main-class="OHLib"
                 name="OHLib"
                 width="1"
                 height="1">
             </applet-desc>
        </jnlp>        
    
    

    The problem was that I was not including the anonymous inner class (OHLib$ 1.class) in the jar file. My original CD jar command looks like this:

    jar cfmv OHLib.jar "../../jar_manifest.txt" OHLib.class
    

    Change to below solved the problem:

    jar cfmv OHLib.jar "../../jar_manifest.txt" OHLib.class OHLib$1.class
    

    Credits go to this page for the solution.

  • Running a Seq file when running the GUI (command line option) return an error

    Hello

    I use a LabVIEW based UI to run/execute a file in sequence by using the command line option. My command line is "Test DUT' D:\QF\GUI-test-Sequential.seq D:\QF\GUI-Test.exe - runEntryPoint

    When I ran the get 3 popup saying that some of the perameters 'is not a valid file of LabVIEW"(see attachments). No idea how to avoid these messages? (The user interface works very well and runs the entrypoint of the USE Test)

    LabVIEW 8.5

    TestStand 4.1

    Thank you.

    Hi Tom,

    When you create a new application to your specification to Build, you must set the 'Pass all arguments for application command line' in the Advanced tab.

    Once you do that it should all work.

    Concerning

    Ray Farmer

  • Why can't I just run the code developed in Lookout Lookout 6.5 6.2?

    Our client has developed the code in point 6.2 Lookout. Now that they have purchased Lookout Run Time 6.5 and they are unable to run their code. Is there a limitation that could cause this kind of behavior?

    Thank you...

    They should be able to run the .lks file.

    The .l4p file is not compatible.

    What is the error, they got?

  • Run the Code Labview program on VN8970 vector material

    I would like to ask if anyone has ever tried to run the Labview Code on the material vector in Standaone Mode,

    The VN8970 have a PC as material and I would use as my hardware target.

    Labview programming would go toward, creating / establishing a controller which output is POSSIBLE only.

    Necessary sensor data is on the BUS CAN even output going to the CAN-BUS network.

    The vector hardware box 8970 should run with the Labview code inside and be just like a car engine controller, just a BOX knot...

    Can anyone shade some light on this topic because it is very difficult to collect all the required bits.

    Vector support won't help with that because that intends it to sell their own software, which does not fit this need.

    Far as I can tell the VN8970 has an ATOM processor or a core-i7 on board and running something called vector CANoeRT.

    From the VN89xx Manual:

    "The family of interface VN8900 offers a stand-alone mode that allows you to measure without any other PC user.

    To this end that a request can be configured in the canoe, which is then written to the NVM of the VN8900. After a reboot, the configura-tion is loaded and the measure began independently. »

    Canoe uses a programming language called CAPL. My understanding is that the code of the CAPL is downloaded on the series VN89xx materials and run directly on the device without the need to be connected to a PC.

    In other words, I don't think there is a way to get a LabVIEW code to run on a VN8970.

    The vxlapi.dll that is used here is intended to be used on a Windows operating system. You can use it to control the VN8970 similar to the other vector material, but not in standalone mode.   I don't know what OS runs on the material of VN89xx but I doubt you'd be able to install a LabVIEW run-time engine on it.

    I think your only option to run a VN8970 in stand-alone mode is to buy a canoe license that allows you to do and learn how to write the CAPL.

  • Exception when opening the portal "" java.lang.ClassCastException: oracle.mds.core.MetadataObject cannot be cast to oracle.webcenter.framework.view.support.jaxb.DevicesMDMO ""

    Dear,

    I created a new portal application and run it... It has worked well. Then, I created a new page template and deployed the application in order to add these files appear in the War file.

    then deploy the application. After running the application, I got this exception of non-performance

    java.lang.ClassCastException: oracle.mds.core.MetadataObject cannot be cast to oracle.webcenter.framework.view.support.jaxb.DevicesMDMO

    I use jdev 11.1.1.7 with 11.1.1.8 extension.

    Also, I followed these discussions without hope

    Error in the webCenter portal deployment

    Re: java.lang.ClassCastException: oracle.mds.core.MetadataObject cannot be cast to oracle.webcenter.framework.view.support.jaxb.DevicesMDMO

    java.lang.ClassCastException: oracle.webcenter.framework.service.WebCenterConfig cannot be cast to oracle.webcenter.framework.service.WebCenterConfig

    at oracle.webcenter.framework.service.WebCenterConfig.instance(WebCenterConfig.java:146)

    at oracle.webcenter.framework.service.config.analytics.ConfigUtils.getADFConfig(ConfigUtils.java:77)

    at oracle.webcenter.framework.service.config.analytics.ConfigUtils.instance(ConfigUtils.java:145)

    at oracle.webcenter.framework.service.config.analytics.OpenUsageHelper.initialize(OpenUsageHelper.java:118)

    to oracle.webcenter.framework.service.AnalyticsUtil. < clinit > (AnalyticsUtil.java:105)

    at oracle.webcenter.framework.service.WebCenterLoginCountFilter.doFilter(WebCenterLoginCountFilter.java:87)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.adf.library.webapp.LibraryFilter.doFilter(LibraryFilter.java:180)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    to oracle.security.jps.ee.http.JpsAbsFilter$ 1.run(JpsAbsFilter.java:119)

    at java.security.AccessController.doPrivileged (Native Method)

    at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:324)

    at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:460)

    at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:103)

    at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:171)

    at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:163)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    to weblogic.servlet.internal.WebAppServletContext$ ServletInvocationAction.wrapRun (WebAppServletContext.java:3715)

    to weblogic.servlet.internal.WebAppServletContext$ ServletInvocationAction.run (WebAppServletContext.java:3681)

    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)

    at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)

    at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2277)

    at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2183)

    at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1454)

    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)

    at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)

    < ConfigUtils > < getADFConfig > oracle.webcenter.framework.service.WebCenterConfig cannot be cast to oracle.webcenter.framework.service.WebCenterConfig

    < DeviceSupportUtils > < getAllDevices >

    java.lang.ClassCastException: oracle.mds.core.MetadataObject cannot be cast to oracle.webcenter.framework.view.support.jaxb.DevicesMDMO

    at oracle.webcenter.framework.view.support.impl.DeviceSupportUtils.getAllDevices(DeviceSupportUtils.java:2235)

    at oracle.webcenter.framework.view.support.impl.DeviceSupportImpl.getAllDevices(DeviceSupportImpl.java:97)

    at oracle.webcenter.framework.view.support.impl.DeviceSupportImpl.getDeviceByUserAgent(DeviceSupportImpl.java:397)

    at oracle.webcenter.framework.view.support.DeviceAgent.getDevice(DeviceAgent.java:286)

    at oracle.webcenter.framework.view.support.DeviceAgent.getDeviceGroups(DeviceAgent.java:313)

    at oracle.webcenter.framework.view.support.DeviceAgent.getCurrentScopeDeviceGroup(DeviceAgent.java:417)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.qualifySessionScopeId(SiteStructureContext.java:759)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.generateCacheKey(SiteStructureContext.java:1070)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.getSiteStructure(SiteStructureContext.java:318)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.getSiteStructure(SiteStructureContext.java:281)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.getDefaultSiteStructure(SiteStructureContext.java:363)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.getCurrentModel(SiteStructureContext.java:1002)

    at oracle.webcenter.portalframework.sitestructure.handler.CustomViewHandler.getCurrentSiteStructure(CustomViewHandler.java:349)

    at oracle.webcenter.portalframework.sitestructure.handler.CustomViewHandler.findNavigationViewId(CustomViewHandler.java:315)

    at oracle.webcenter.portalframework.sitestructure.handler.CustomViewHandler.createView(CustomViewHandler.java:115)

    at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._restoreView(LifecycleImpl.java:831)

    at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._executePhase(LifecycleImpl.java:422)

    at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:207)

    at javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)

    to weblogic.servlet.internal.StubSecurityHelper$ ServletServiceAction.run (StubSecurityHelper.java:227)

    at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)

    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)

    at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.portlet.client.adapter.adf.ADFPortletFilter.doFilter(ADFPortletFilter.java:32)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.webcenter.framework.events.dispatcher.EventDispatcherFilter.doFilter(EventDispatcherFilter.java:44)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:205)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.adfinternal.view.faces.webapp.rich.RegistrationFilter.doFilter(RegistrationFilter.java:128)

    to org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$ FilterListChain.doFilter (TrinidadFilterImpl.java:446)

    at oracle.adfinternal.view.faces.activedata.AdsFilter.doFilter(AdsFilter.java:60)

    to org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$ FilterListChain.doFilter (TrinidadFilterImpl.java:446)

    at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:271)

    at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:177)

    at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.wcps.client.PersonalizationFilter.doFilter(PersonalizationFilter.java:74)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.webcenter.content.integration.servlets.ContentServletFilter.doFilter(ContentServletFilter.java:168)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.webcenter.lifecycle.filter.LifecycleLockFilter.doFilter(LifecycleLockFilter.java:151)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.adf.library.webapp.LibraryFilter.doFilter(LibraryFilter.java:180)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    to oracle.security.jps.ee.http.JpsAbsFilter$ 1.run(JpsAbsFilter.java:119)

    at java.security.AccessController.doPrivileged (Native Method)

    at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:324)

    at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:460)

    at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:103)

    at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:171)

    at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:163)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    to weblogic.servlet.internal.WebAppServletContext$ ServletInvocationAction.wrapRun (WebAppServletContext.java:3715)

    to weblogic.servlet.internal.WebAppServletContext$ ServletInvocationAction.run (WebAppServletContext.java:3681)

    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)

    at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)

    at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2277)

    at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2183)

    at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1454)

    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)

    at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)

    < DeviceSupportUtils > < getAllDeviceGroups >

    java.lang.ClassCastException: oracle.mds.core.MetadataObject cannot be cast to oracle.webcenter.framework.view.support.jaxb.DevicesMDMO

    at oracle.webcenter.framework.view.support.impl.DeviceSupportUtils.getAllDeviceGroups(DeviceSupportUtils.java:3308)

    at oracle.webcenter.framework.view.support.impl.DeviceSupportUtils.getEnabledDeviceGroups(DeviceSupportUtils.java:3418)

    at oracle.webcenter.framework.view.support.impl.DeviceSupportImpl.getEnabledDeviceGroups(DeviceSupportImpl.java:168)

    at oracle.webcenter.framework.view.support.DeviceAgent.getCurrentScopeDeviceGroup(DeviceAgent.java:418)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.qualifySessionScopeId(SiteStructureContext.java:759)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.generateCacheKey(SiteStructureContext.java:1070)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.getSiteStructure(SiteStructureContext.java:318)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.getSiteStructure(SiteStructureContext.java:281)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.getDefaultSiteStructure(SiteStructureContext.java:363)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.getCurrentModel(SiteStructureContext.java:1002)

    at oracle.webcenter.portalframework.sitestructure.handler.CustomViewHandler.getCurrentSiteStructure(CustomViewHandler.java:349)

    at oracle.webcenter.portalframework.sitestructure.handler.CustomViewHandler.findNavigationViewId(CustomViewHandler.java:315)

    at oracle.webcenter.portalframework.sitestructure.handler.CustomViewHandler.createView(CustomViewHandler.java:115)

    at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._restoreView(LifecycleImpl.java:831)

    at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._executePhase(LifecycleImpl.java:422)

    at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:207)

    at javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)

    to weblogic.servlet.internal.StubSecurityHelper$ ServletServiceAction.run (StubSecurityHelper.java:227)

    at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)

    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)

    at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.portlet.client.adapter.adf.ADFPortletFilter.doFilter(ADFPortletFilter.java:32)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.webcenter.framework.events.dispatcher.EventDispatcherFilter.doFilter(EventDispatcherFilter.java:44)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:205)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.adfinternal.view.faces.webapp.rich.RegistrationFilter.doFilter(RegistrationFilter.java:128)

    to org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$ FilterListChain.doFilter (TrinidadFilterImpl.java:446)

    at oracle.adfinternal.view.faces.activedata.AdsFilter.doFilter(AdsFilter.java:60)

    to org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$ FilterListChain.doFilter (TrinidadFilterImpl.java:446)

    at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:271)

    at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:177)

    at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.wcps.client.PersonalizationFilter.doFilter(PersonalizationFilter.java:74)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.webcenter.content.integration.servlets.ContentServletFilter.doFilter(ContentServletFilter.java:168)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.webcenter.lifecycle.filter.LifecycleLockFilter.doFilter(LifecycleLockFilter.java:151)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.adf.library.webapp.LibraryFilter.doFilter(LibraryFilter.java:180)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    to oracle.security.jps.ee.http.JpsAbsFilter$ 1.run(JpsAbsFilter.java:119)

    at java.security.AccessController.doPrivileged (Native Method)

    at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:324)

    at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:460)

    at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:103)

    at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:171)

    at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:163)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    to weblogic.servlet.internal.WebAppServletContext$ ServletInvocationAction.wrapRun (WebAppServletContext.java:3715)

    to weblogic.servlet.internal.WebAppServletContext$ ServletInvocationAction.run (WebAppServletContext.java:3681)

    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)

    at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)

    at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2277)

    at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2183)

    at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1454)

    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)

    at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)

    < DeviceSupportUtils > < getAllDeviceGroups >

    java.lang.ClassCastException: oracle.mds.core.MetadataObject cannot be cast to oracle.webcenter.framework.view.support.jaxb.DevicesMDMO

    at oracle.webcenter.framework.view.support.impl.DeviceSupportUtils.getAllDeviceGroups(DeviceSupportUtils.java:3308)

    at oracle.webcenter.framework.view.support.impl.DeviceSupportImpl.getAllDeviceGroups(DeviceSupportImpl.java:134)

    at oracle.webcenter.framework.view.support.impl.DeviceSupportImpl.getDefaultDeviceGroup(DeviceSupportImpl.java:298)

    at oracle.webcenter.framework.view.support.DeviceAgent.getCurrentScopeDeviceGroup(DeviceAgent.java:456)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.qualifySessionScopeId(SiteStructureContext.java:759)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.generateCacheKey(SiteStructureContext.java:1070)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.getSiteStructure(SiteStructureContext.java:318)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.getSiteStructure(SiteStructureContext.java:281)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.getDefaultSiteStructure(SiteStructureContext.java:363)

    at oracle.webcenter.portalframework.sitestructure.SiteStructureContext.getCurrentModel(SiteStructureContext.java:1002)

    at oracle.webcenter.portalframework.sitestructure.handler.CustomViewHandler.getCurrentSiteStructure(CustomViewHandler.java:349)

    at oracle.webcenter.portalframework.sitestructure.handler.CustomViewHandler.findNavigationViewId(CustomViewHandler.java:315)

    at oracle.webcenter.portalframework.sitestructure.handler.CustomViewHandler.createView(CustomViewHandler.java:115)

    at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._restoreView(LifecycleImpl.java:831)

    at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._executePhase(LifecycleImpl.java:422)

    at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:207)

    at javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)

    to weblogic.servlet.internal.StubSecurityHelper$ ServletServiceAction.run (StubSecurityHelper.java:227)

    at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)

    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)

    at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.portlet.client.adapter.adf.ADFPortletFilter.doFilter(ADFPortletFilter.java:32)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.webcenter.framework.events.dispatcher.EventDispatcherFilter.doFilter(EventDispatcherFilter.java:44)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:205)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.adfinternal.view.faces.webapp.rich.RegistrationFilter.doFilter(RegistrationFilter.java:128)

    to org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$ FilterListChain.doFilter (TrinidadFilterImpl.java:446)

    at oracle.adfinternal.view.faces.activedata.AdsFilter.doFilter(AdsFilter.java:60)

    to org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$ FilterListChain.doFilter (TrinidadFilterImpl.java:446)

    at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:271)

    at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:177)

    at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.wcps.client.PersonalizationFilter.doFilter(PersonalizationFilter.java:74)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.webcenter.content.integration.servlets.ContentServletFilter.doFilter(ContentServletFilter.java:168)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.webcenter.lifecycle.filter.LifecycleLockFilter.doFilter(LifecycleLockFilter.java:151)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.adf.library.webapp.LibraryFilter.doFilter(LibraryFilter.java:180)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    to oracle.security.jps.ee.http.JpsAbsFilter$ 1.run(JpsAbsFilter.java:119)

    at java.security.AccessController.doPrivileged (Native Method)

    at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:324)

    at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:460)

    at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:103)

    at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:171)

    at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:163)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    to weblogic.servlet.internal.WebAppServletContext$ ServletInvocationAction.wrapRun (WebAppServletContext.java:3715)

    to weblogic.servlet.internal.WebAppServletContext$ ServletInvocationAction.run (WebAppServletContext.java:3681)

    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)

    at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)

    at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2277)

    at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2183)

    at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1454)

    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)

    at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)

    < SkinFactoryImpl > < getSkin > cannot find a skin that fits the family portal and version v1. We will use the portal.desktop of the skin.

    You must install the latest patch bundle for WebCenter portal.

    I believe that this error is a bug caused by certain features that are available in the portal Builder, but not in a framework application.

    Basically, WebCenter is throwing items of metadata to specific models of devices. In the portal Builder, you can create different templates depending on the device, but this feature is not available in the framework where the error.

    Just install the latest patch bundle and your problem should be solved.

    Also... Note that Oracle recommendation is to use the portal generator and not to develop any new application with the framework.

Maybe you are looking for