« Back to Cisco JTAPI Questions

JTAPII integration error help!

Combination View Flat View Tree View
Threads [ Previous | Next ]
We are setting up a Java application (using the JTAPI and the Cisco
implementation) on an iSeries server (IBM mid-range system that is
not in your standard setup routines). When I try to create the
provider, I obtain the following stack trace. I assume that I am
missing something in my setup, is this enough information or should I
send something else?

The Java call (which works on Windows):

Provider jtprovider = JtapiPeerFactory.getJtapiPeer(null).getProvider
(providerstring);

The stack trace:

Exception in thread "Thread-0" com.cisco.jtapi.PlatformExceptionImpl:
Unable to create provider -- java.lang.NullPointerException
at java.lang.Throwable.<init>(Throwable.java:196)
at java.lang.Exception.<init>(Exception.java:41)
at java.lang.RuntimeException.<init>(RuntimeException.java:43)
at javax.telephony.PlatformException.<init>
(PlatformException.java:53
)
at com.cisco.jtapi.PlatformExceptionImpl.<init>(CTQF:0)
at com.cisco.jtapi.CiscoJtapiPeerImpl.getProvider(CTQF:0)
at
com.ibm.i.teleserver.ProviderTest.main(ProviderTest.java:16)

Hi,

What is the providerString that you passing in the API call?

We may need to look into JTAPI logs to see what is going wrong. I will let DevSupport team help you in obtaining the debug level JTAPI logs from proper channel.

Thanks,
Abhishek M.
Cisco JTAPI Development Team

Be sure that your java implementation is a supported one (JDK 1.4.2 or higher - see Ch. 3 of the JTAPI Developer Guide). If you have more than one JVM on the machine, ensure you are launching with the expected version.

I confirmed the Java version is 1.4.2

Can you attach JTAPI logs? You can use the jtprefs application that is installed as apart of the JTAPI client to enable logs. Set for detailed/all-types.

This is running on i5/OS, I don't think jtprefs works there.

I have another question (this time from a Windows test environment). I can connect my provider, but the getTerminals() method only works rarely. I will get 1 terminal and then try again with the same user and not get any.

What could cause the Provider to apparently randomly be OUT_OF_SERVICE most of the time, but come IN_SERVICE intermittently?

Solve the intermittent problem, I needed a delay before using the provider.

Do you have an example of an ini file with the correct strings?

Here is the log data:
Cisco Jtapi version 6.1(1.1000)-1 Release
0: Dec 03 15:23:39.550 CST %JTAPI-MISC-7-UNKemoticonP1-) started preloading classes
1: Dec 03 15:23:39.583 CST %JTAPI-MISC-7-UNKemoticonP1-) finished preloading classes
2: Dec 03 15:23:39.602 CST %JTAPI-CTI-7-UNKemoticonP1-) JVM Field Order is onethreetwo
3: Dec 03 15:23:39.602 CST %JTAPI-CTI-7-UNKemoticonP1-) EventThread wakeups are disabled
4: Dec 03 15:23:39.602 CST %JTAPI-CTI-7-UNKemoticonP1-) EventThread queue statistics are disabled
5: Dec 03 15:23:39.602 CST %JTAPI-CTI-7-UNKemoticonP1-) EventThread queue size threshold is 25
6: Dec 03 15:23:39.602 CST %JTAPI-CTI-7-UNKemoticonP1-) Provider retry interval is set to 30 seconds
7: Dec 03 15:23:39.602 CST %JTAPI-CTI-7-UNKemoticonP1-) Client desired server heartbeat time is set to 30 seconds
8: Dec 03 15:23:39.603 CST %JTAPI-CTI-7-UNKemoticonP1-) CTI request timeout is is set to 30 seconds
9: Dec 03 15:23:39.603 CST %JTAPI-CTI-7-UNKemoticonP1-) Provider open request timeout is set to 200 seconds
10: Dec 03 15:23:39.603 CST %JTAPI-CTI-7-UNKemoticonP1-) Provider priority is set to 2
11: Dec 03 15:23:39.623 CST %JTAPI-CTIIMPL-7-UNKemoticonP1-) Provider.info(CCMEncryption: Constructor)
12: Dec 03 15:23:39.623 CST %JTAPI-CTIIMPL-7-UNKemoticonP1-) Provider.info(Exiting CCMEncryption())
13: Dec 03 15:23:39.630 CST %JTAPI-CTIIMPL-7-UNKemoticonP1-) Provider.info(Entering CCMEncryption::encryptPassword.)
14: Dec 03 15:23:40.023 CST %JTAPI-CTIIMPL-7-UNKemoticonP1-) Provider.info(Exiting CCMEncryption::encryptPassword.success)
15: Dec 03 15:23:40.023 CST %JTAPI-CTIIMPL-7-UNKemoticonP1-) application did not set appinfo, creating default
16: Dec 03 15:23:40.023 CST %JTAPI-JTAPIIMPL-7-UNKemoticonroviderImpl(): calling jtapiProperties.getSecurityPropertyForInstance()
17: Dec 03 15:23:40.030 CST %JTAPI-JTAPIIMPL-7-UNKemoticonP1-joannak) TraceModule: JTAPI version Cisco Jtapi version 6.1(1.1000)-1 Release
18: Dec 03 15:23:40.030 CST %JTAPI-JTAPIIMPL-7-UNKemoticonP1-joannak) Route Select Timeout is 5000 msecs
19: Dec 03 15:23:40.030 CST %JTAPI-JTAPIIMPL-7-UNKemoticonP1-joannak) Jtapi post condition timeout is set to 15 seconds
20: Dec 03 15:23:40.030 CST %JTAPI-JTAPIIMPL-7-UNKemoticonP1-joannak) IgnoreFwdDestination set to false
21: Dec 03 15:23:40.031 CST %JTAPI-CTIIMPL-7-UNKemoticonP1-joannak) Opening server "10.10.1.1" login "joannak"
22: Dec 03 15:23:40.031 CST %JTAPI-CTIIMPL-7-UNKemoticonP1-joannak) ProviderID = P1-joannak
23: Dec 03 15:23:40.063 CST %JTAPI-CTIIMPL-7-UNKemoticonP1-joannak) Trying to create normal socket connection to 10.10.1.1
24: Dec 03 15:23:40.103 CST %JTAPI-CTIIMPL-7-UNKemoticonP1-joannak) connected
25: Dec 03 15:23:40.130 CST %JTAPI-MISC-7-UNKemoticonP1-10.10.1.1) EventThread: created
26: Dec 03 15:23:40.132 CST %JTAPI-MISC-7-UNKemoticonP1-10.10.1.1) EventThread starting up...
27: Dec 03 15:23:40.681 CST %JTAPI-MISC-7-UNKemoticonP1-10.10.1.1) ReceiveThread starting up...

The exception that I receive when I have this level of logging active is:
Exception in thread "Thread-0" java.lang.NullPointerException
at java.lang.Throwable.<init>(Throwable.java:181)
at java.lang.Exception.<init>(Exception.java:29)
at java.lang.RuntimeException.<init>(RuntimeException.java:32)
at java.lang.NullPointerException.<init>(NullPointerException.java:36
)
at com.cisco.cti.protocol.ProtocolElement.class$com$cisco$cti$protoco
l$ClientCallHandle(CTQF:0)
at com.cisco.cti.protocol.ProtocolElement.toString(CTQF:0)
at java.lang.StringBuffer.append(StringBuffer.java:220)
at com.cisco.cti.client.implementation.Provider.handleMessage(CTQF:0)
at com.cisco.cti.client.implementation.ResponseTable.I(CTQF:0)
at com.cisco.cti.client.implementation.Provider.sessionEnded(CTQF:0)
at com.cisco.cti.client.implementation.Provider.tryOpen(CTQF:0)
at com.cisco.cti.client.implementation.Provider.Open(CTQF:0)
at com.cisco.jtapi.ProviderImpl.<init>(CTQF:0)
at com.cisco.jtapi.CiscoJtapiPeerImpl.getProvider(CTQF:0)
at com.ibm.i.teleserver.ProviderTest.main(ProviderTest.java:19)

The code works when I run the same jar file under windows.

Don, did you find a soluiton to this issue?  I am experiencing the same problem.

This looks like possibly a JVM-related issue.  Can you confirm the JVM/version and full OS/version?
 
Check the JTAPI developer guide for a list of tested/supported OS/JVM combinations.