Topic
  • No replies
Marichamy
Marichamy
1 Post

Pinned topic Create Scoring Object in Jboss

‏2013-08-12T09:38:19Z |

Hi,

I am able to load scoring.dll inside my static block. But I am not able to create scoring object inside the same static block.

static 
{
try
{
System.loadLibrary("scoring"); 
config = "D:/Softwares/GNR_Installed/data/nameworks.config";
scoring = new Scoring(config);
gnrProcess();
}
catch(UnsatisfiedLinkError unsatisfiedError)
{
unsatisfiedError.printStackTrace();
}
catch(Exception ex)
{
ex.printStackTrace();
}
}
private static void gnrProcess()
{
Name name = new Name();
name.setName("Mithun Jay");
queryNameList = scoring.analyzeForSearch(name.getName(), 99);
}

I am able to call and get the response from GNR if I execute this piece of code as Standalone program. But If the same code is executed in Jboss I am getting the below exception.

java.lang.UnsatisfiedLinkError: com.ibm.gnr.nws.scoringSWIGJNI.swig_module_init()V
    at com.ibm.gnr.nws.scoringSWIGJNI.swig_module_init(Native Method)
    at com.ibm.gnr.nws.scoringSWIGJNI.<clinit>(Unknown Source)
    at com.ibm.gnr.nws.ScoringDirector.<init>(Unknown Source)

 

Could you please someone help me to identify the root cause of this issue.