Questions tagged [processbuilder]
Processbuilder is Java wrapper around an Operating System Process. This class is used to create operating system processes.
processbuilder
1,519
questions
-1
votes
0
answers
52
views
Non blocking Processbuilder output
When using ProcessBuilder, is there a true non blocking reactive way to consume the output? By true non blocking i mean not creating a thread that is blocked waiting to read, but push-based like ...
0
votes
1
answer
59
views
Open a Visible Cmd Window In Java
I currently have some code that executes a task:
this.cmds = new String[] { "cmd.exe", "/c", customCmd };
ProcessBuilder pb = new ProcessBuilder(cmds);
try {
pb.start();
} ...
0
votes
0
answers
74
views
Interact with openconnect in java processbuilder
I am attempting to establish a VPN connection using a ProcessBuilder in Java. However, the process seems to block, and entering my password has no effect.
I am unable to include my username and ...
1
vote
0
answers
41
views
Running a Python program in Java Spring Boot backend [closed]
My server (on AWS) is in Java Spring Boot, and I'm trying to integrate a Python program that uses LangChain, takes JSON input, generates JSON output.
I have found two solutions:
Use ProcessBuilder ...
1
vote
0
answers
74
views
Weird behaviour of X11 window opened via ProcessBuilder [closed]
I am on Ubuntu 20.04 and java se 17. I have a java application that uses a ProcessBuilder to start a subprocess. The subprocess (running R code) launches a X11 window and plots things in it. This X11 ...
0
votes
0
answers
70
views
Execute a jar file from Java Spring-boot Application as a Window Service
I've been trying to launch a JAR file within a Java Spring Boot application as a Windows service. Initially, I attempted to execute the JAR file using a batch file and the Process Builder, but it ...
0
votes
1
answer
45
views
How to optimize BufferedReader reading?
I have a code written in Java that shows all installed programs on a PC. But for some reason after this line, the program runs 25 seconds longer than usual.
sb.append(reader.lines().collect(Collectors....
2
votes
0
answers
70
views
How to run a Python script hosted on a different server remotely from a Java application hosted on another server?
Before going throw the explanation of my problem, I want to give you a short introduction about my app idea, basically there is a python library that I need to use, and there is no alternatives ...
0
votes
2
answers
59
views
my Java command Process builder never exit
I'm trying to run a command in my java program that allows me to use the external software ffmpeg to extract subtitles from a video file.
On my cmd the command works fine, but when I run it from my ...
0
votes
0
answers
24
views
Getting CreateProcess error=5, Access is denied while trying to launch the emulator programmatically from Java Appium code
I am running a Java Appium code where I want to start my emulator programmatically for which I am using the Process builder.
Caused by: java.io.IOException: CreateProcess error=5, Access is denied
...
0
votes
1
answer
65
views
Should an open source library with a blocking method offer an asynchronous option for execution? [closed]
Background:
I am creating library that I want to make open source.
This library is designed for use in backend processes.
The service I will make available utilizes Java's ProcessBuilder, to execute ...
0
votes
1
answer
30
views
using process builder to get the stream of this process
I'm using a common solution which is using the BufferedReader class in order to get the the input stream but it seems that if I can see the command console opening with the application running, I ...
-2
votes
3
answers
167
views
Open Url in given browser using process builder
My use case is to use process builder in java springboot to open a test url in google chrome. I have explored various commands to do the same but not able to achieve a desired result. I have explored ...
1
vote
0
answers
28
views
Java ProcessBuilder not immediately terminating mysql import command with process.destroyForcibly()
I am using the following Java code to execute a MySQL command that imports data from a source file:
String command = String.format("%s -h %s -P%s -u%s -p%s -D %s < %s", mysqlCommand, ip, ...
0
votes
1
answer
279
views
Checkmarx command line injection
We are using ProcessBuilder in Java to execute Python program on a Linux machine.
We added all validation suggested by Checkmarx and then we tried to execute the below sample provided by Checkmarx.
...