Java FX 2.2 WebEngine

Hi everyone,
I'm using WebEngine and WebView classes for manipulating with html pages (JavaFX 2.2).
As far as I know, there is embedded WebKit browser underneath. I would like
to change parameters for WebKit like User-Agent, ... Is there any possibility how
to do that? Today I went throught javadoc and I wasn't able to find something.
Where WebKit embedded JavaFX is looking for configuration, cookies ...? I have checked
implementation of WebKit for Qt, Python, ... and everywhere there was possibility
to take settings from WebKit and change these settings.
Big thanks in advance,
Jan

I have supposed that webkit somewhere should store configurations. In the case I would like to use plugins (adobe, flash, ...) how should I do it without some configuration directory where everything will be stored?WebView does not support plugins and probably never will officially support them (due to the potential increase in the security vulnerability surface).
I don't think it is worthwhile to think of WebView as WebKit (even though it uses a customized WebKit implementation under the cover to achieve a lot of, but not all of, it's current functionality). I'd advise thinking of WebView as an html component for Java for which the only API available is publicly exposed through the WebView and WebEngine classes. That way you won't be under any misconceptions about what it can and cannot do.

Similar Messages

  • WebEngine unexpectly throws java.lang.IllegalArgumentException: Image scanl

    When I use webEngine load below site: http://w133.hg3088.com/ (Need login in), I always get below exception(throw in endless loop). While I do nothing, just load this site, I don't know why throw this exception, and who to fix it.
    java.lang.IllegalArgumentException: Image scanlineStride is too small
         at com.sun.prism.Image.<init>(Unknown Source)
         at com.sun.prism.Image.fromByteBgraPreData(Unknown Source)
         at com.sun.prism.ImageFormatTool.convertImageFrame(Unknown Source)
         at com.sun.webpane.sg.prism.WCImageImpl.<init>(Unknown Source)
         at com.sun.webpane.sg.prism.WCImgDecoderImpl.getPrismImage(Unknown Source)
         at com.sun.webpane.sg.prism.WCImgDecoderImpl.getFrame(Unknown Source)
         at com.sun.webpane.platform.WebPage.twkUpdateContent(Native Method)
         at com.sun.webpane.platform.WebPage.updateDirty(Unknown Source)
         at com.sun.webpane.platform.WebPage.updateContent(Unknown Source)
         at com.sun.javafx.sg.prism.NGWebView.update(Unknown Source)
         at javafx.scene.web.WebView.handleStagePulse(Unknown Source)
         at javafx.scene.web.WebView.access$100(Unknown Source)
         at javafx.scene.web.WebView$2.pulse(Unknown Source)
         at com.sun.javafx.tk.Toolkit.firePulse(Unknown Source)
         at com.sun.javafx.tk.quantum.QuantumToolkit.pulse(Unknown Source)
         at com.sun.javafx.tk.quantum.QuantumToolkit$8.run(Unknown Source)
         at com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
         at com.sun.glass.ui.win.WinApplication.access$100(Unknown Source)
         at com.sun.glass.ui.win.WinApplication$2$1.run(Unknown Source)
         at java.lang.Thread.run(Thread.java:722)Edited by: Owen on Jun 9, 2012 4:14 AM
    Edited by: Owen on Jun 9, 2012 4:14 AM

    I tried JavaFX 2.2(curretly build b13), it throw another exception.
    java.lang.ArrayIndexOutOfBoundsException: 34346
         at com.sun.javafx.image.impl.BaseByteToByteConverter$FourByteReorderer.doConvert(BaseByteToByteConverter.java:236)
         at com.sun.javafx.image.impl.BaseByteToByteConverter.convert(BaseByteToByteConverter.java:97)
         at com.sun.javafx.image.impl.BaseByteToByteConverter$FourByteReorderer.convert(BaseByteToByteConverter.java:212)
         at com.sun.prism.Image.convertImageFrame(Image.java:162)
         at com.sun.webpane.sg.prism.WCImageImpl.<init>(WCImageImpl.java:106)
         at com.sun.webpane.sg.prism.WCImgDecoderImpl.getPrismImage(WCImgDecoderImpl.java:270)
         at com.sun.webpane.sg.prism.WCImgDecoderImpl.getFrame(WCImgDecoderImpl.java:230)
         at com.sun.webpane.platform.WebPage.twkUpdateContent(Native Method)
         at com.sun.webpane.platform.WebPage.updateDirty(WebPage.java:345)
         at com.sun.webpane.platform.WebPage.updateContent(WebPage.java:609)
         at com.sun.javafx.sg.prism.NGWebView.update(NGWebView.java:52)
         at javafx.scene.web.WebView.handleStagePulse(WebView.java:897)
         at javafx.scene.web.WebView.access$200(WebView.java:81)
         at javafx.scene.web.WebView$2.pulse(WebView.java:209)
         at com.sun.javafx.tk.Toolkit.firePulse(Toolkit.java:360)
         at com.sun.javafx.tk.quantum.QuantumToolkit.pulse(QuantumToolkit.java:460)
         at com.sun.javafx.tk.quantum.QuantumToolkit$9.run(QuantumToolkit.java:329)
         at com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
         at com.sun.glass.ui.win.WinApplication.access$100(WinApplication.java:29)
         at com.sun.glass.ui.win.WinApplication$2$1.run(WinApplication.java:62)
         at java.lang.Thread.run(Thread.java:722)Another bug?

  • WebEngine: how to capture the click on a link?

    I need some insight into the inner workings of WebEngine: listeners seem to stop firing under certain conditions.
    Problem description:
    In my application I have to open certain urls in a new tab or in a different pane. Following jsmith's proposal in a different thread (Re: How to cancel page loading in WebView? I do the following:
    - Based on the location of the link clicked, I decide if it has to be opened in place, in a new tab, or in a sort of popup pane (similar to a sheet window in MacOS/X as a fake modal dialog attached to the top of the window).
    - To achieve this, I implement a locationProperty listener using "locationProperty().addListener".
    - Inside the listener I use "getLoadWorker().cancel()" to stop the current engine from loading the url ...
    - ... and load that url in a new tab or the popup pane.
    This works fine, but when I return from the other tab or close the popup pane, the location property listener won't fire any more.
    The same applies if I cancel in a stateProperty change listener.
    Workaround:
    As a workaround I can refresh the page using "getEngine().reload()" in a "Platform.runLater" thread, but the flickering is really ugly.
    Analysis:
    It looks as if the cancel comes too late. The first opportunity to capture the click on a link seems to be "getLoadWorker().stateProperty()" where "Worker.State" is "SCHEDULED"; after that fires the listener on "locationProperty()". In either case "getLoadWorker().cancel()" seems to invalidate the listeners.
    I have experimented with another development platform which also uses Webkit. There it's possible to truely cancel out before a link is loaded. So it should be possible in JavaFX as well...
    Question:
    Does somebody know how I can capture the click on a link without redeveloping the web application (which I can't)?
    Cheers,
    Thomas

    If, after calling getLoadWorker().cancel(), you no longer receive location change notifications upon further clicks on links, it looks like a bug. Feel free to file an issue with Jira.
    However, it is probably too fragile to rely on the location property and the cancel method in your case, due to asynchronous nature of page loads.
    Look at the WebEngine.createPopupHandler property. The popup handler will only be called if the page decides that a new window needs to be created, so it may not be able to help you fully solve your problem, but it may be worth a try.
    Otherwise, consider the approach suggested by irond13. Install DOM event listeners on link objects (<a> tags) and do whatever you want in response to click events. You can do it solely in Java, see Re: Controlling what happens when a user clicks on a hyperlink in a WebView and Re: Communicate from WebView to JavaFX scene for details and example.
    Finally, if you do think a more direct callback on WebEngine is a necessity, consider extending http://javafx-jira.kenai.com/browse/RT-17073 or filing a new feature request.

  • Webview crash WebEngine load method - Win + Mac

    The code below crashes on Win 7 JavaFX 2.0 and Mac OS X 10.6 Java FX 2.0 EA
    On Win 7 32 bits under Java 7 it crashes in WebPane.dll
    On Mac OS X I get: Invalid memory access of location 0x170 rip=0x11e7c0d67
    The culprit is
    eng.load("https://graph.facebook.com/me/friends?access_token="+token); in the change listener.
        public static void main(String[] args) {
            Application.launch(args);
        @Override
        public void start(Stage primaryStage) {
         primaryStage.setTitle("Hello World");
             WebView view = new WebView();
            final WebEngine eng = view.getEngine();
            eng.load("https://graph.facebook.com/oauth/authorize?" + "client_id=" +
                   API_KEY +  "&"
                   + "redirect_uri=http://www.facebook.com/connect/login_success.html&type=user_agent&display=popup);
            final TextField locationField = new TextField("http://www.oracle.com/us/index.html");
            locationField.setMaxHeight(Double.MAX_VALUE);
            Button goButton = new Button("Go");
            goButton.setDefaultButton(true);
            EventHandler<ActionEvent> goAction = new EventHandler<ActionEvent>() {
                @Override public void handle(ActionEvent event) {
                    eng.load(locationField.getText().startsWith("http://") ? locationField.getText() :
                            "http://" + locationField.getText());
            goButton.setOnAction(goAction);
            locationField.setOnAction(goAction);
            eng.locationProperty().addListener(new ChangeListener<String>() {
                @Override public void changed(ObservableValue<? extends String> observable, String oldValue, String newValue) {
                    locationField.setText(newValue);
                        if (newValue.startsWith("http://www.facebook.com/connect/login_success.html")) {
                                           URLCodec codec = new URLCodec();
                            try {
                             String s = codec.decode(newValue);
                              String[] splits = s.split(",");
                             try {
                                 String json = s.substring(s.indexOf('#') + 1, s.length());
                                 System.out.println("JSON = " + json);
                                 String st = URLDecoder.decode(json, "UTF-8");
                                 System.out.println(st);
                                 String params[] = st.split("&");
                                 HashMap<String, String> parmsMap = new HashMap<String, String>();
                                 for (String param : params) {
                                  String temp[] = param.split("=");
                                  parmsMap.put(temp[0], java.net.URLDecoder.decode(temp[1], "UTF-8"));
                                 String token = parmsMap.get("access_token");
                                 System.out.println(token);
                                 eng.load("https://graph.facebook.com/me/friends?access_token="+token);
                             } catch (Exception e) {
                            } catch (DecoderException e) {
                             // TODO Auto-generated catch block
                             e.printStackTrace();
            GridPane grid = new GridPane();
            grid.setVgap(5);
            grid.setHgap(5);
            GridPane.setConstraints(locationField, 0, 0, 1, 1, HPos.CENTER, VPos.CENTER, Priority.ALWAYS, Priority.SOMETIMES);
            GridPane.setConstraints(goButton,1,0);
            GridPane.setConstraints(view, 0, 1, 2, 1, HPos.CENTER, VPos.CENTER, Priority.ALWAYS, Priority.ALWAYS);
            grid.getColumnConstraints().addAll(
                    new ColumnConstraints(100, 100, Double.MAX_VALUE, Priority.ALWAYS, HPos.CENTER, true),
                    new ColumnConstraints(40, 40, 40, Priority.NEVER, HPos.CENTER, true)
            grid.getChildren().addAll(locationField, goButton, view);
            Scene scene = new Scene(grid, 1024, 768);
    {code}
    Edited by: user10787071 on Oct 8, 2011 9:52 PM
    Edited by: user10787071 on Oct 8, 2011 9:53 PM
    Edited by: user10787071 on Oct 8, 2011 9:55 PM                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

    Created the following JIRA http://javafx-jira.kenai.com/browse/RT-17313?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel

  • WebEngine: How to change or catch timeout issue?

    Hello,
    When the execution of a script code takes too much time the WebEngine throws the following exception:
    netscape.javascript.JSException: JavaScript execution exceeded timeout.
           at com.sun.webpane.platform.WebPage.twkExecuteScript(Native Method)
           at com.sun.webpane.platform.WebPage.executeScript(WebPage.java:1438)
           at javafx.scene.web.WebEngine.executeScript(WebEngine.java:811)
    document.generateTimeout= function generateTimeout()
                        var i=3000000000;          // 3 billions iterations = 10 secs on a classical machine
                        while(i>0)
                             i=i-1;
    In my use case, the JavaScript is quite complex because of the generation of a chart and it takes more than 10 seconds to process. The problem is that the timeout event occurs in less than 10 seconds!
    I only would like to catch, disable or increase the timeout value.
    Is it possible? Else, any work around?
    Thanks.

    Seems not to be available yet. [http://javafx-jira.kenai.com/browse/RT-15009]
    Adding a listener on: [http://www.w3.org/wiki/DOM/window.onerror]
    fires some interesting events such as:
    WebEvent [source = javafx.scene.web.WebEngine@2789ea2e, eventType = WEB_ALERT, data = JavaScript execution exceeded timeout. undefined 0]
    Any other workaround would be appreciated!
    Thanks.

  • Using WebEngine + WebView as rich HTML control?

    Has anyone tried using WebEngine/WebView to create (static) content which can mix text with images?
    What I would want is a reflow capable control where I can put in styled text (different styles, sizes, fonts) and some Images to go along with it and have the text nicely reflow around the images. Since HTML has been capable of doing this for ages, and since I donot think even a new RichText control will be able to mix images and text (and certainly not offer all the other features in HTML, like tables, etc..), I think the WebView could fill this gap.
    Getting the HTML page itself inside the control is easy, using the loadContent methods... but what about the Images? I would need some kind of hook to supply Images (directly from a database or from memory, no intermediate URL downloading step) to the WebEngine, but there doesn't seem to be one.
    I suppose I could set up a local webserver and point my 'img src' tags to that to get what I want, but perhaps there is an easier way?
    Let me know.

    Java has so rich capability that you can do anything. To load the images in WebView you need to first must make sure that the image must be in your application package or on other resources.
    I think you problem is to load the images in Webview which is just inside your application. Let's assume you app directory is like this
    <app name>
    +images
         -europa.png
    +mypack
         -Main.java
         -Support.java
         -GUI.javaAnd now to load the image "europa.png" with in the Main.java containing WebView we can do like this
         WebView view = new WebView();
         String url = getClass().getResource("../images/europa.png").toExternalForm();
         view.getEngine().loadContent("<html><body>Hello<img src=\""+url+"\" /></body></html>");Thanks
    Narayan

  • Webengine stuck in RUNNING state - JavaFX 8.0.0

    I am using jdk 1.8 and along with it the latest javaFX 8.0.0. I moved to the latest java FX as i was facing issues with custom fonts loading with the previous version of java FX with JDK 1.7. However with the latest version, my webengine is stuck in RUNNING state and the url page is never getting loaded. Anybody faced the same issue with javaFX. I need this to be fixed for my app to up and running.
    Thanks

    Hi ...
    Restart your router then follow the instructions here >  iOS: Unable to update or restore

  • Use WebEngine to view applet demo of JDK problem

    When I used webEngine to view applet demo of JDK like this:
    WebEngine webEngine = new WebEngine("file:///C:/Program Files/Java/jdk1.6.0_25/demo/applets/BarChart");
    I got message on the page inside JavaFX like this:
    alt="Your browser understands the <APPLET> tag but isn't running the applet, for some reason." Your browser is completely ignoring the <APPLET> tag!
    So, my question is how can I embed applet in webEngine or can webEngine embed applet?
    Thank you very much!

    There are a few known bugs related to webengine:
    • Issue RT-12439: WebView can not be gc-ed (garbage-collected).
    Description: Memory leak causes the application to crash with an out-of-memory error on web sites that have a lot of content, running scripts, and automatic updates.
    Workaround: To be able to reclaim the WebEngine object, call the webView.setEngine(null) method.
    • Issue RT-12440: WebView is updated even when it is invisible.
    Description: Performance is impacted.
    Workaround: Include a call to the webView.setEngine(null) method in your application.
    For more info take a look at http://download.oracle.com/javafx/2.0/release_notes/jfxpub-release_notes.htm

  • Using WebView & WebEnginer

    Hello there,
    I am a total newbie to JavaFX and also in some ways to Java. I am trying to create a user interface in HTML and then able to dynamically change the content of HTML from the Java code.
    As a first step, i have a HTML file in my hard disk that has HTML, JavaScript & CSS in it. I can use the WebEngine.Load() to load this page. The HTML page consists of buttons, text area (paragraph) and some images.
    The goal is, when the user clicks on the HTML buttons i should be able to get the event in Java code, and then send new images and texts to the HTML user interface.
    I see that it's possible to call JavaScript functions in the HTML page. But is it possible to get HTML button clicks inside the Java Code?
    Thanks in advance.

    Please see my code below. It's not formatted, but if you copy that into a editor, it should work fine.
    public class MyClass extends Application {
        WebView webView = null;
        @Override
         public void start(Stage primaryStage) { 
            final BorderPane root = new BorderPane(); 
            webView = new WebView();        
            File f = new File("main.html");
            System.err.println("webView 1st time - "+webView);
            try {
                webView.getEngine().load(f.toURI().toURL().toString());
            catch (MalformedURLException e)
            root.setCenter(webView); 
            webView.getEngine().documentProperty().addListener(new ChangeListener<Document>() { 
                @Override 
                public void changed(ObservableValue<? extends Document> obs, Document oldDocument, Document newDocument) { 
                    if (newDocument != null) { 
                        EventTarget startButton = (EventTarget) newDocument.getElementById("ButtonOk"); 
                        startButton.addEventListener("click",new EventListener() { 
                            @Override 
                            public void handleEvent(Event evt) { 
                                System.out.println("Start Button pressed!"); 
                                getInstance().StartTimer();
                        }, true);                     
            final Scene scene = new Scene(root, 390, 590); 
            primaryStage.setScene(scene); 
            primaryStage.show(); 
        public static void main(String[] args) {
            launch(args);
        public void myTimer ()
      String strP8 = "I am here Now!";
              webView.getEngine().executeScript("changeText('"+strP8+"')"); // Fails here as webView is NULL          
        public class TimerSample extends ProofOfConcept{
            Timer timer = null;
                public void StartTimer() {
                    //1- Taking an instance of Timer class.
                    timer = new Timer("BIO");
                    //2- Taking an instance of class contains your repeated method.
                    MyTask t = new MyTask();
                    timer.schedule(t, 0, 1000);    
                public void StopTimer()
                timer.cancel();
                timer.purge();
            class MyTask extends TimerTask {
                //times member represent calling times.
                private int times = 0;
                public void stop()
                this.cancel();           
                public void run() {
                        myTimer ();
            TimerSample sampleX = null;
            public TimerSample getInstance ()
            if (sampleX == null)
            sampleX = new TimerSample();
            return sampleX;

  • WebEngine WebSockets support

    Hello,
    I'm doing some tests with JavaFX (2.2 beta) and the [vert.x|http://vertx.io/] project, and I succeeded to run some vert.x Groovy examples (SockJS and Eventbus Bridge) using a WebView component as a way to communication with a vert.x server.
    I noticed that WebSocket.OPEN (used in JavaScript code embedded in HTML content) is not recognized by the WebEngine.
    So, my supposition is that WebSocket is not again supported by JavaFX 2.
    Am I wrong? Is there a plan for this support?
    Cheers,
    Bertrand.

    Websockets are enabled in WebView in Java8.
    General availability 2014-3-18
    http://openjdk.java.net/projects/jdk8/milestones
    Early access download
    http://jdk8.java.net/download.html
    There is no in between JavaScript client recommendation.  For Websockets to work in WebView, the function must be enabled in WebView, it can't be enabled by a JavaScript library running in WebView alone.
    You can use Websockets from JavaFX outside of WebView as pointed out by an earlier post in this thread.

  • Return values for WebEngine's ExecuteScript function?

    Hey guys and gals,
    I'm trying to write some code to load a webpage and get some values from the POST header, but unfortunately I'm having trouble with the basics.
    I can't get the executeScript function to return a JSObject! I'm having no luck finding what the executeScript function decides to return based on input. Every time I run the Java code, executeScript returns me the value of the POSTresponses variable as a String. Or it return
    Any suggestions of what could be happening?
    Error message:
    "java.lang.ClassCastException: java.lang.String cannot be cast to netscape.javascript.JSObject"
    Portion of Java file:
    public void changed(ObservableValue ov, State oldState, State newState) {
           Document document;
                                JSObject returnObject;
                                if(newState == State.SUCCEEDED) {
                                    document = webEngine.getDocument();
                                    if(document != null) {
                                        returnObject = (JSObject)webEngine.executeScript(receivedPostJs);
    Entire Javascript file:
    function getPostResponses() {
        var requestHandler = new XMLHttpRequest();
        var POSTresponses;
        if (requestHandler.readyState == 0) {
            POSTresponses = "Nada";
        } else if (requestHandler.readyState == 1) {
            POSTresponses = "Still nuthin";
        } else if (requestHandler.readyState == 2) {
            POSTresponses = requestHandler.getAllResponseHeaders();

    HI,
    I think one good approach could be generate a table API to perform the tasks that you want (insertion, select, update, delete) and put all of these procedures in a package. Each procedure has a return code (0 if succesful for example or the SQLCODE) and a message of the result of the operation ('Success' or the SQLERRM).
    Regards,

  • Getting return value from webengine.executescript when embedded in Swing

    Hi,
    Got a WebView embedded through a JFXPanel in a Swing app. I'm now trying to get some value back from the WebEngine.executeScript method in a synchronous way.
    All examples I can find on Swing embedding use Platform.runLater, which of course doesn't return the value straight away.
    Through some digging I found PlatformImpl.runAndWait(Runnable) and when I use that I do get a synchronous call and thus the return value of Webengine.executeScript immediately.
    Question now is if it's save for me to use PlatformImpl.runAndWait(Runnable) or if I should refrain from using it for some reason. I wasn't able to find anything on the topic, but so far in my tests if seems to work fine.
    Only thing I found were 2 implementations of sort of the same functionality: http://www.guigarage.com/2013/01/invokeandwait-for-javafx/ and https://code.google.com/p/jacp/source/browse/branches/working/JACP.JavaFX/src/main/java/org/jacp/javafx/rcp/worker/AFXComponentWorker.java (invokeOnFXThreadAndWait method)
    TIA,
    K.

    Using the impl method for run and wait is not advised as it may be removed in a future JavaFX version.
    However you can easily copy the source of this simple method to create your own implementation:
    See the following thread for details:
    http://markmail.org/message/kaui2t34ufx3vdwe
    Note that in making what is normally an asynchronous call synchronous, you must be careful to avoid deadlock and UI freezing performance issues.

  • Disabling external content loading in Webengine

    I'm trying to utilize Webengine to load a local file, but do not want to load any other objects references in it (such as images). Looking through several websites, and this forum, I could not find any way for that purpose.
    Regardless of utilizing Load, or LoadContent, my program always tries to load the images.
    I appreciate any leads on how to disable loading the external content.
    Thanks in advance.

    I appreciate any leads on how to disable loading the external content.Two options:
    1. Disconnect the internet.
    2. Implement your own url protocol handler: http://java.sun.com/developer/onlineTraining/protocolhandlers/
    Hint => option 1 is easier . . .

  • Error while running a Java Program

    Can anyone help me,
    I am getting the following error while running a Java program, Below is the exception thrown, please help.
    java.nio.BufferOverflowException
    at java.nio.Buffer.nextPutIndex(Buffer.java:425)
    at java.nio.DirectByteBuffer.putChar(DirectByteBuffer.java:463)
    at org.jetel.data.StringDataField.serialize(StringDataField.java:295)
    at org.jetel.data.DataRecord.serialize(DataRecord.java:283)
    at org.jetel.graph.DirectEdge.writeRecord(DirectEdge.java:216)
    at org.jetel.graph.Edge.writeRecord(Edge.java:288)
    at com.tcs.re.component.RESummer1.run(RESummer1.java:505)
    java.nio.BufferOverflowException
    at java.nio.Buffer.nextPutIndex(Buffer.java:425)
    at java.nio.DirectByteBuffer.putChar(DirectByteBuffer.java:463)
    at org.jetel.data.StringDataField.serialize(StringDataField.java:295)
    at org.jetel.data.DataRecord.serialize(DataRecord.java:283)
    at org.jetel.graph.DirectEdge.writeRecord(DirectEdge.java:216)
    at org.jetel.graph.Edge.writeRecord(Edge.java:288)
    at com.tcs.re.component.RECollectCont.run(RECollectCont.java:304)

    Ok, let's see. Write the following class:
    public class Grunt {
      public static void main(String[] args) {
        System.out.println("Hello Mars");
    }Save it as "C:\Grunt.java", compile by typing:
    javac c:\Grunt.javaRun by typing:
    java -classpath "C:\" GruntDoes it say "Hello Mars"? If yes, go back to your program and compare for differences (maybe you used the "package" statement?).
    Regards

  • Erro de SYSFAIL e Queda do Ambiente JAVA (PI)

    Bom Dia
    Estou num projeto de NFe e atualmente esta acontecendo o seguinte cenário de Erros:
        Na SMQ2 , quando apresenta um aumento nas filas de Mensagens , aparece SYSFAIL em determinadas Filas , todas as outras travam , aumenta o numero de Filas.
       Com essa mensagem de SYSFAIL nas filas , o serve0 (Parte JAVA do PI) cai e após isso estou tendo que efetuar manualmente um STOP/START em todos os canais de comunnicação para que os R/3 voltem a emitir NFe.
        Isso esta ocorrendo com mais frequência após inserir uma nova empresa para emissão de NFe.
        Alguem poderia me ajudar a entender por que ocorre o SYSFAIL as mensagens travam e derruba o ambiente JAVA ?
    Sérgio.

    1º) Erro: Commit Fault: com.sap.aii.af.rfc.afcommunication.RfcAFWException:SenderA
    2º) Foi alterado o numero de Filas O numero de Filas foi alterado , mas não consigo ver esse parametros na RZ10 , tem  3 entradas : X32_DVEBMGS32_NFISAP ; DEFAULT ; START_DVEBMGS32_NFISAP nessa transação ...onde eu vejo isso
    3º) Esse parametro não tem nessa transação (/usr/sap//DVEBMGS00/j2ee/cluster/server0/log/). em qual desses diretórios abaixo eu encontro esse parametro ?
    Existe esses:
    DIR_ATRA      /usr/sap/X32/DVEBMGS32/data
    DIR_BINARY      /usr/sap/X32/DVEBMGS32/exe
    DIR_CCMS      /usr/sap/ccms
    DIR_CT_LOGGIN    /usr/sap/X32/SYS/global
    DIR_CT_RUN              /usr/sap/X32/SYS/exe/run
    DIR_DATA              /usr/sap/X32/DVEBMGS32/data
    DIR_DBMS              /usr/sap/X32/SYS/SAPDB
    DIR_EXECUTABLE /usr/sap/X32/DVEBMGS32/exe
    DIR_EXE_ROOT     /usr/sap/X32/SYS/exe
    DIR_GEN              /usr/sap/X32/SYS/gen/dbg
    DIR_GEN_ROOT    /usr/sap/X32/SYS/gen
    DIR_GLOBAL        /usr/sap/X32/SYS/global
    DIR_GRAPH_EXE  /usr/sap/X32/DVEBMGS32/exe
    DIR_GRAPH_LIB   /usr/sap/X32/DVEBMGS32/exe
    DIR_HOME             /usr/sap/X32/DVEBMGS32/work
    DIR_INSTALL        /usr/sap/X32/SYS
    DIR_INSTANCE     /usr/sap/X32/DVEBMGS32
    DIR_LIBRARY      /usr/sap/X32/DVEBMGS32/exe
    DIR_LOGGING     /usr/sap/X32/DVEBMGS32/log
    DIR_MEMORY_INSPECTOR   /usr/sap/X32/DVEBMGS32/data
    DIR_ORAHOME       /oracle/X32/102_64
    DIR_PAGING                            /usr/sap/X32/DVEBMGS32/data
    DIR_PUT                            /usr/sap/X32/put
    DIR_PERF                            /usr/sap/tmp
    DIR_PROFILE      /usr/sap/X32/SYS/profile
    DIR_PROTOKOLLS     /usr/sap/X32/DVEBMGS32/log
    DIR_REORG                          /usr/sap/X32/DVEBMGS32/data
    DIR_ROLL                          /usr/sap/X32/DVEBMGS32/data
    DIR_RSYN                            /usr/sap/X32/DVEBMGS32/exe
    DIR_SAPHOSTAGENT     /usr/sap/hostctrl
    DIR_SAPUSERS     ./
    DIR_SETUPS                           /usr/sap/X32/SYS/profile
    DIR_SORTTMP     /usr/sap/X32/DVEBMGS32/data
    DIR_SOURCE     /usr/sap/X32/SYS/src
    DIR_TEMP                           /tmp
    DIR_TRANS                           /usr/sap/trans
    DIR_TRFILES                          /usr/sap/trans
    DIR_TRSUB                          /usr/sap/trans

Maybe you are looking for

  • How do I know if my Compressor is installed correctly?

    I get an error message saying to restart, or to insure compressor is installed correctly. I restarted a couple of times, and still get the message. Thisis my first time attempting to use Compressor. I have a project that is 2 hours 13 minutes long, a

  • Help with T61 monitor warning

    Whenever I use Adobe Photoshop Elements 5, or just recently installed Elements 7, I keep getting a warning at the start of the editing option that says "The monitor profile "Lenovo ThinkPad LCD Monitor" appears to be defective.  Please rerun your mon

  • SLD Architeture

    Hi what is SLD Architeture thanks

  • Instance Variables

    Just out of interest : If I have an instance variable that is an object, should I set it equal to null and then instantiate it in the constructor: class MyClassA{    MyClassB b = null;    MyClassA(){         b = new MyClassB(); OR should I just insta

  • Connecting to epson wireless printers

    "upgraded" from linksys-n broadband router to the wrt1900ac, now despite my various attempts, unable to connect my epson workforce545 and workforce 845, these wireless  printers  connected to N w/o any trouble. any ideas towards resolving this issue.