headless

java.awt.HeadlessException thrown from HeadlessGraphicsEnvironment.getDefaultScreenDevice

牧云@^-^@ 提交于 2019-12-04 04:05:55
问题 I need to do some image processing on a java server (Debian with java version "1.6.0_12"), and I am receiving java.awt.HeadlessException from my code: java.awt.HeadlessException at sun.java2d.HeadlessGraphicsEnvironment.getDefaultScreenDevice(HeadlessGraphicsEnvironment.java:64) at WaxOn.getDefaultConfiguration(WaxOn.java:341) Even when java.awt.headless is set to true (as evident by this code printing so): if (!java.awt.GraphicsEnvironment.isHeadless()) { logger.warn("Headless mode is not

How to setup Android sdk from command-line on headless server? [duplicate]

情到浓时终转凉″ 提交于 2019-12-04 02:01:02
This question already has an answer here: “android update sdk” on headless linux 5 answers So far Ive managed to download and install the SDK and its in my PATH. Problem now is that I can't run "android update sdk" since it expects to be connected to a display and Im connected to a remote headless server through ssh (its a build server so there's no desktop env). Is there a command-line option for the android tool that tells it to run without X ? There is a --no-ui flag for the update. Typical linux setup: cd android-sdk-linux_86/tools ./android update sdk -u This will run it headless. To note

Selenium-Chrome-Headless : Unable to receive message from renderer

和自甴很熟 提交于 2019-12-03 22:15:13
I am using Chrome-latest stable version 61.0.3163.79 Chomedriver 2.31 Selenium 3.4.0 Jenkins and docker My first run over Jenkins getting error as below: 1.732][INFO]: Done waiting for pending navigations. Status: disconnected: Unable to receive message from renderer [1.732][DEBUG]: DevTools request: http://localhost:12059/json [1.733][DEBUG]: DevTools request failed Can someone please assist me how can I solve this? chromeOptions.addArguments(dimension); chromeOptions.addArguments("--disable-gpu"); chromeOptions.addArguments("--no-sandbox"); chromeOptions.setBinary("/usr/bin/google-chrome");

headless xml generation from xsd with eclipse

[亡魂溺海] 提交于 2019-12-03 20:43:26
In recent versions of the free and open source Eclipse IDE you can generate XML documents from DTD and XSD files. Right-click on a given *.dtd or *.xsd file and select "Generate -> XML File...". You can choose which root element to generate and whether optional attributes and elements should be generated. Can i use this headless (without starting eclipse)? You can create a headless RCP application that contains only those plugins needed to do the actual generation. These are largely WTP plugins with a couple of the core plugins needed for managing extension points and such. The RCP app can be

Using a http proxy with headless firefox in Selenium webdriver in Python

久未见 提交于 2019-12-03 16:29:23
问题 I'm using Firefox headless like this: from selenium.webdriver.firefox.firefox_binary import FirefoxBinary from selenium import webdriver import os import sys # Set the MOZ_HEADLESS environment variable which casues Firefox to # start in headless mode. os.environ['MOZ_HEADLESS'] = '1' # Select your Firefox binary. binary = FirefoxBinary('/usr/bin/firefox', log_file=sys.stdout) # Start selenium with the configured binary. driver = webdriver.Firefox(firefox_binary=binary) But now I want to add a

Easiest way to unit test SWT and Swing apps in a headless environment?

只愿长相守 提交于 2019-12-03 16:17:12
问题 I'm looking to unit test some SWT and Swing code for a project I'm working on and the tests run fine as long as I'm running them from eclipse. As soon as I run them in my hudson environment it fails since hudson runs the tests in headless mode. What's the best way of doing this? Open source solutions only please (since the project is open source). 回答1: You could run Xvfb (X virtual framebuffer, an X11 server that performs all graphical operations in memory) and this works fine. But there is

Spring Boot - infinite loop service

时光怂恿深爱的人放手 提交于 2019-12-03 15:44:23
I want to build a headless application which will query the DB in infinite loop and perform some operations in certain conditions (e.g. fetch records with specific values and when found launch e-mail sending procedure for each message). I want to use Spring Boot as a base (especially because of Actuator to allow expose health-checks), but for now I used Spring Boot for building REST web-services. Is there any best practices or patterns to follow when building infinite loop applications ? Does anyone tried to build it based on Spring Boot and can share with me his architecture for this case ?

Selenium Pyvirtualdisplay Hangs on starting

我只是一个虾纸丫 提交于 2019-12-03 14:38:46
I have a selenium test which I am trying to run Headlessly on my ubuntu server. It uses pyvirtualdisplay and xephyr. Though the script is running fine in my local system, it hangs when I run it in the server. I have tried to clear memory and restarting the server. But no luck. The script looks something like this : from selenium import webdriver from pyvirtualdisplay import Display display = Display(visible=0, size=(1366, 768)) display.start() driver = webdriver.Firefox() driver.set_window_size(1366, 768) driver.get ("http://www.google.com/") Any help? Okay, finally I got through it. sudo apt

(转载)Selenium + Chrome headless 报ERROR:gpu_process_transport_factory.cc(1007)]

萝らか妹 提交于 2019-12-03 11:48:28
Selenium不再推荐使用PhantomJS,会报如下警告 UserWarning: Selenium support for PhantomJS has been deprecated, please use headless versions of Chrome or Firefox instead warnings.warn('Selenium support for PhantomJS has been deprecated, please use headless ' 于是从PhantomJS转移到Chrome,使用headless versions of Chrome时,首先要安装Chrome,然后下载chromedriver,再把chromedriver的地址配置到系统环境变量path中,方便调用。如果不把chromedriver的地址配置到系统环境变量的话,也可以在使用时指定chromedriver的地址。 注意Chrome和chromedriver有版本对应的要求,系统中安装了某一版本的chrome要使用对应版本的chromedriver,其实下载最新版本的Chrome和chromedriver就行了,一般都是对应的。 Chrome下载地址:https://chrome.en.softonic.com/ chromedriver下载地址:http://npm

Running Selenium headless without using xvfb

邮差的信 提交于 2019-12-03 07:44:10
问题 I'm trying to run Selenium headless (without the browser appearing). Other questions have pointed to xvfb as the tool to do this. However, it appears highly unstable, crashing all the time, so I'm looking for another alternative. Is there a non-xvfb way of running Selenium headless? 回答1: I don't think you'll be able to run a browser without running an X server. If you don't like Xvfb, then as Pascal said, your best bet might be to run a VNC server -- I personally like Xtightvnc. This means