java

Rundeck Node Authentication with domain account

Rundeck Node Authentication with domain account Question: I have installed Rundeck 4.8.0 on Redhat 9. I have a Windows 2022 Server node. I have a local account on the node called rundeck and it’s in the Administrators group. In Rundeck key storage, I made a password key, with the password for the local rundeck account. …

Total answers: 1

How to read bytes type from bigquery in Java?

How to read bytes type from bigquery in Java? Question: We have a legacy dataflow job in Scala which basically reads from Bigquery and then dumps it into Postgres. In Scala we read from bigquery, map it onto a case class and then dump it into Postgres, and it works perfectly for bigquery’s Bytes type …

Total answers: 1

the output in python base64.b64decode doesn't match java's decode Base64

the output in python base64.b64decode doesn't match java's decode Base64 Question: I’m trying to refactor some scala code to python3. Currently stuck at decoding a string in base64. The output from Python’s base64.b64decode does not match the Scala’s output. Scala: import org.apache.commons.codec.binary.Base64.decodeBase64 val coded_str = "UgKgDwhoEAAANAEA1tYAADABABoBABMAAAAAAQAAAAEAAQACAAAAAAD6sT4AO0YAAA==" decodeBase64(coded_str) //Output 1 : res1: Array[Byte] = Array(82, 2, …

Total answers: 2

How to convert an ArrayList<PyObject> to an ArrayList<Scalar>?

How to convert an ArrayList<PyObject> to an ArrayList<Scalar>? Question: I have integrated a java developed app in android studio with python files using chaquopy. The python file returns a List however I am struggling to convert that List to an ArrayList format (In the java file after the list is successfully returned from the Python …

Total answers: 1

Java ByteBuffer similar function in Python

Java ByteBuffer similar function in Python Question: I need to reimplement following function which converts 8 digit List to 32 digit List via ByteBuffer to python. So it can be used a python pipeline. As a data scientist, I have been scratching my head how to do it right. I assume I can try to …

Total answers: 1

Supplying input in subprocess and print the inputs along with the outputs (Python running Java)

Supplying input in subprocess and print the inputs along with the outputs (Python running Java) Question: I want to execute this java program using python import java.util.Scanner; public class Input { public static void main(String[] args) { Scanner sc = new Scanner(System.in); System.out.print("Enter a number = "); int n = sc.nextInt(); System.out.println("Number entered = "+n); …

Total answers: 1

Error "PipeMapRed.waitOutputThreads(): subprocess failed with code 1" when accessing a list of lists by index on hadoop for mapreduce python program

Error "PipeMapRed.waitOutputThreads(): subprocess failed with code 1" when accessing a list of lists by index on hadoop for mapreduce python program Question: I wrote a mapreduce program to resolve matrix operation "X-MN" where M,N,X are matrices with integer values. In order to do that I need to have a list of lists. For instance: M=[[1,2,3],[4,5,6],[7,8,9]] …

Total answers: 1

How to get value based on key for the text file

How to get value based on key for the text file Question: I have below text format in text file ; Generated for TDD [Document] Mainline = PQRS.N – Holdings Corp conference call, Jun. 22, 2006 / 10:00AM ET DocDate = 20060622100000 CtbDocUID = T234567 Action = ADD CtbId = 4567 UserId = ftp_contribution Password …

Total answers: 4

What programing languages does Memgraph support?

What programing languages does Memgraph support? Question: From which programming languages can I connect to Memgraph? Which protocol is used? I know that Python is for sure supported since there is GQLAlchemy (a fully open-source Python library). What about other languages? Asked By: KWriter || Source Answers: f you want to query Memgraph programmatically, you …

Total answers: 1

How do I run Python Scripts in Java with the ScriptEngine?

How do I run Python Scripts in Java with the ScriptEngine? Question: I’m trying to run Python Scripts in my Java Application with Jyton/ScriptEngine but it’s not working. ScriptEngine does not find JythonScriptEngine. public static void main(String[] Args) throws FileNotFoundException, ScriptException { PySystemState engineSys = new PySystemState(); engineSys.path.append(Py.newString("C:/Users/User/AppData/Local/jython2.7.2/jython.jar")); Py.setSystemState(engineSys); StringWriter writer = new StringWriter(); ScriptContext …

Total answers: 2