I meant just randomly running the method from the same class before taking the JAR export. Let's say if I have to take the below code as JAR export, the steps are -
Original Message:
Sent: Wed March 06, 2024 07:17 AM
From: jhon wick
Subject: methods do not appear when importing jar
Atanu, hi. i created an interface for the method and a new class to run the method from. when running the interface and the method i get this error:
<error type="java.lang.NoSuchMethodError" description="NoSuchMethodError"> <cause type="java.lang.Throwable" description="cause"></cause> <localizedMessage type="java.lang.String" description="String">org/example/FileToSQL.<init>(Ljava/lang/String;)V (loaded from managedasset:61.6d8885d5-6887-41d5-96c3-125570ae46ae by com.lombardisoftware.server.core.ManagedAssetClassLoader@e011f1e2 [current classloaderMap size=129, initial classloaderMap size=1000]) called from interface org.example.InterfaceFileToSQL (loaded from managedasset:61.1f25586c-c326-45d4-8007-0f6ecf42bf05 by com.lombardisoftware.server.core.ManagedAssetClassLoader@e011f1e2 [current classloaderMap size=129, initial classloaderMap size=1000]).</localizedMessage> <message type="java.lang.String" description="String">org/example/FileToSQL.<init>(Ljava/lang/String;)V (loaded from managedasset:61.6d8885d5-6887-41d5-96c3-125570ae46ae by com.lombardisoftware.server.core.ManagedAssetClassLoader@e011f1e2 [current classloaderMap size=129, initial classloaderMap size=1000]) called from interface org.example.InterfaceFileToSQL (loaded from managedasset:61.1f25586c-c326-45d4-8007-0f6ecf42bf05 by com.lombardisoftware.server.core.ManagedAssetClassLoader@e011f1e2 [current classloaderMap size=129, initial classloaderMap size=1000]).</message> <stackTrace type="[Ljava.lang.StackTraceElement;" description="StackTraceElement;">
when tested in my ide both methods work fine
------------------------------
jhon wick
Original Message:
Sent: Tue March 05, 2024 08:21 AM
From: Atanu Roy
Subject: methods do not appear when importing jar
Hi John,
Can you try running the methods from the main method in the same class before exporting the JAR, sometimes I also face this issue, this works for me.
Please let me know if this works.
Thanks!
------------------------------
Atanu Roy
Lead Engineer
London Stock Exchange Group
Original Message:
Sent: Tue March 05, 2024 07:51 AM
From: jhon wick
Subject: methods do not appear when importing jar
Im having the following issue on ibm bpm 8.5.6. ive developed a jar with a class with public methods. some of these methods appear when i import the jar on ibm but some wont. the weird thing is that both methods that do appear and dont have the same signature
heres the signature for the 3 methods:
public static List<String> generateInsertStatementsFromFile(String filePath, String tableName, String[] selectedAttributes) throws UnknownHostException { ----------------------------- } public static String generateInsertStatementsFromFileString(String filePath, String tableName, String selectedAttributes) throws UnknownHostException { ------------------------------ } public static String generateInsertStatementsFromFileObjectJSON(String filePath, String selectedAttributes) throws UnknownHostException { ------------------------------ }
method generateInsertStatementsFromFile and generateInsertStatementsFromFileString appear when importing the jar, generateInsertStatementsFromFileObjectJSON doesnt. what could be going on?
------------------------------
jhon wick
------------------------------