Author Topic: Error ARS6009E / Replacing ArsSVTInterface and Updating ArsWWWResult  (Read 4127 times)

mroutlander

  • Jr. Member
  • **
  • Posts: 33
    • View Profile
Hello everyone,
We have a web application running  ODWEK 7.1.x (yeah, I know it's quite old, please don't judge me  :D :P ) connecting to CMOD 7.1.x. Thing is, we are trying to upgrade the setup. CMOD server upgrade was successful and we are able to use it perfectly through the Thick Client.

However, the web application that uses ODWEK for CMOD connectivity, uses classes - ArsSVTInterface and ArsWWWResultand it's there that we are having troubles. Now we could modify the application if we knew what actually these classes entail but we haven't found a single piece of documentation on these. The idea is to remove any references of the former (as IBM suggested) and update the code with correct usage of the latter.

Decompiling the classes doesn't give much of an insight. Could you please help me understand these classes, or suggest a workaround?

EDIT: Forgot to mention, CMOD server is on 9.5 and ODWEK intends to be there.

Warm regards,
Abhinav
« Last Edit: December 27, 2017, 04:27:58 AM by mroutlander »

Justin Derrick

  • IBM Content Manager OnDemand Consultant
  • Administrator
  • Hero Member
  • *****
  • Posts: 2228
  • CMOD Guru for hire...
    • View Profile
    • Tenacious Consulting
Re: Replacing ArsSVTInterface and Updating ArsWWWResult
« Reply #1 on: December 04, 2017, 09:41:18 AM »
Hi Abhinav.

You can review the old documentation for ODWEK 7.1 here: https://cmod.wiki/dox/CMODv7.1/ODApiDoc/index.html

After you review it, let us know if you have more questions.

-JD.
« Last Edit: May 24, 2018, 09:49:35 AM by Justin Derrick »
IBM CMOD Professional Services: http://TenaciousConsulting.com
Call:  +1-866-533-7742  or  eMail:  jd@justinderrick.com
IBM CMOD Wiki:  https://CMOD.wiki/
FREE IBM CMOD Education & Webinars:  https://CMOD.Training/

Interests: #AIX #Linux #Multiplatforms #DB2 #TSM #SP #Performance #Security #Audits #Customizing #Availability #HA #DR

mroutlander

  • Jr. Member
  • **
  • Posts: 33
    • View Profile
Re: Replacing ArsSVTInterface and Updating ArsWWWResult
« Reply #2 on: December 06, 2017, 03:47:18 AM »
Thanks a lot, Justin! I will surely go through the same. Hopefully, I'll get a solution.
EDIT: The documentation doesn't seem to have any info on the Arsxxxxx classes. Would you happen to have anything on that. Our code has numerous references to ArsWWWResult and that's bugging me :D

Thanks again.
« Last Edit: December 06, 2017, 03:50:47 AM by mroutlander »

Justin Derrick

  • IBM Content Manager OnDemand Consultant
  • Administrator
  • Hero Member
  • *****
  • Posts: 2228
  • CMOD Guru for hire...
    • View Profile
    • Tenacious Consulting
Re: Replacing ArsSVTInterface and Updating ArsWWWResult
« Reply #3 on: December 06, 2017, 07:11:05 AM »
Okay, so the reason you're having problems is that your old system used the ODWEK Java Servlet, which was deprecated in CMOD v9.5.  So you're going to have to write your application from scratch using the Java API.  It sounds like you've already made some progress there.

If you want the old documentation (to help you understand what the old code was doing, so that you can write the new code) you can find it here:  https://www.ibm.com/support/knowledgecenter/SSEPCD_9.5.0/com.ibm.ondemand.odwek.doc/dodwekplugin-gentopic1.htm

-JD.
« Last Edit: May 24, 2018, 09:47:52 AM by Justin Derrick »
IBM CMOD Professional Services: http://TenaciousConsulting.com
Call:  +1-866-533-7742  or  eMail:  jd@justinderrick.com
IBM CMOD Wiki:  https://CMOD.wiki/
FREE IBM CMOD Education & Webinars:  https://CMOD.Training/

Interests: #AIX #Linux #Multiplatforms #DB2 #TSM #SP #Performance #Security #Audits #Customizing #Availability #HA #DR

mroutlander

  • Jr. Member
  • **
  • Posts: 33
    • View Profile
Re: Replacing ArsSVTInterface and Updating ArsWWWResult
« Reply #4 on: December 07, 2017, 03:05:49 AM »
Wow! That's great, precisely what we were looking for. Hopefully this solves the issue. Thanks a ton, Justin.
Will let you know how the changes pan out.

Regards
Abhinav

mroutlander

  • Jr. Member
  • **
  • Posts: 33
    • View Profile
Re: Replacing ArsSVTInterface and Updating ArsWWWResult
« Reply #5 on: December 19, 2017, 04:30:14 AM »
Thanks to Justin for the documentation!
The process of updating the old API references was getting too tedious, so we did away with that code and added a crisper version of document retrieval (as prescribed in v9.5)  and thankfully it is working now (well, most of it).

In general, we're able to retrieve almost all the documents. For some documents, somehow, the retrieval from our application fails, citing - ODException: A cancel request was received during a server request and we end up getting null bytes for the document. This, apparently, is error ARS6009E (per manuals). Weirdly though, the retrieval of the very same document happens just fine through a standalone class. And in both cases, the docIDs come up differently.

The failing documents are .DOCX, .PPTX and .MSG files. I am thinking 'no' but would that have any bearing on the retrieval?

The jar used for the standalone class is the same as the one used in the application and the testing environment. Wonder what is missing  :o
Note: ODWEK version is 9.5.0.0, so the docIDs are not pre-encrypted and pre-base64encoded.
« Last Edit: December 19, 2017, 04:47:51 AM by mroutlander »

Justin Derrick

  • IBM Content Manager OnDemand Consultant
  • Administrator
  • Hero Member
  • *****
  • Posts: 2228
  • CMOD Guru for hire...
    • View Profile
    • Tenacious Consulting
Re: Replacing ArsSVTInterface and Updating ArsWWWResult
« Reply #6 on: December 19, 2017, 11:50:15 AM »
Sounds like a mime-type issue, since those are all user-defined data types.

Also, you'll want to update to the latest and greatest ODWEK version.  ODWEK now ships with the IBM CMOD server fixpacks:

https://cmod.wiki/index.php?title=Main_Page#IBM_CMOD_Fixpacks_.26_Security_Bulletins

-JD.
IBM CMOD Professional Services: http://TenaciousConsulting.com
Call:  +1-866-533-7742  or  eMail:  jd@justinderrick.com
IBM CMOD Wiki:  https://CMOD.wiki/
FREE IBM CMOD Education & Webinars:  https://CMOD.Training/

Interests: #AIX #Linux #Multiplatforms #DB2 #TSM #SP #Performance #Security #Audits #Customizing #Availability #HA #DR

mroutlander

  • Jr. Member
  • **
  • Posts: 33
    • View Profile
Re: Replacing ArsSVTInterface and Updating ArsWWWResult
« Reply #7 on: December 20, 2017, 03:03:25 AM »
Thanks a lot, Justin!
Though we could not justify it, but we were also inclined to blame it on the MIME-types. As you advised, we'll go ahead and upgrade to 9.5.0.9. 

Thanks again!
Warm regards,
AP

mroutlander

  • Jr. Member
  • **
  • Posts: 33
    • View Profile
Re: Replacing ArsSVTInterface and Updating ArsWWWResult
« Reply #8 on: December 22, 2017, 03:39:10 AM »
The troubles just don't cease to exist. We upgraded ODWEK to 9.5.0.9 as advised (thanks Justin!) and then loaded a couple more DOCX and MSG files. Now, the strange thing is that, some documents of these types can be retrieved (a somewhat better scenario than before  :) ). E.g.  in a folder containing .MSG (Outlook message files), there are three documents and we can retrieve only two of them successfully. Similarly, in the folder for .DOCX documents (Word documents from Office 2007 onward), one document can be opened and the other can’t.

The [MIMETYPES] are set in arswww.ini as
Code: [Select]
o MSG=text/html
o DOCX=application/ms-word

 - For the failing documents, error is encountered in the
Code: [Select]
ODHit.getDocument() method (it returns null bytes)
 - Exception message for the failing documents is - 
Code: [Select]
com.ibm.edms.od.ODException: A cancel request was received during a server request.
 - Per CMOD message codes, it is error ARS6009E that advises you to look into System Logs in CMOD.
 - We referred to the System Logs in CMOD as well, but there is no corresponding error logged over there.
 - The failing documents can apparently be viewed from the Thick Client

Any assistance will be really appreciated. Thanks in advance,

Warm Regards,
AP
« Last Edit: December 22, 2017, 03:44:47 AM by mroutlander »

mroutlander

  • Jr. Member
  • **
  • Posts: 33
    • View Profile
Re: Replacing ArsSVTInterface and Updating ArsWWWResult / ARS6009E
« Reply #9 on: December 27, 2017, 02:26:24 AM »
We managed to get a trace, in a bid to find the root cause, but that doesn't help much either. Here is what we saw (you can see some error codes, reason codes and status codes - not that they speak much to us):

apiP_RestoreHitFromDocId:Enter
52597:140237026785024 12/26/2017 04:54:35:565822 INFO ars3wapi.C(1771)apiP_RestoreHitFromDocId:Current state byte_buffer=Z27v2UO8TFuS1sR4DV/sNvnh0uQwGDiclxSAWkYP6d.[masked for confidentiality].....nNu

52597:140237026785024 12/26/2017 04:54:35:565826 FLOW arscsvht.c(2717)CsvRestoreHitFromDocId:Enter

52597:140237026785024 12/26/2017 04:54:35:565828 FLOW arscsvht.c(1931)CsvMaxDocIdLength:Enter

52597:140237026785024 12/26/2017 04:54:35:565830 FLOW arscsvht.c(1960)CsvMaxDocIdLength:Return len=3380

52597:140237026785024 12/26/2017 04:54:35:565833 FLOW arscsvht.c(2120)CsvP_ICCDecrypt:Enter

52597:140237026785024 12/26/2017 04:54:35:565843 FLOW arscsvht.c(2163)CsvP_ICCDecrypt:Return arccs return code=0,ARCCS_OKAY
52597:140237026785024 12/26/2017 04:54:35:565854 FLOW arscsvht.c(2926)CsvRestoreHitFromDocId:Return pCsvHit=00007f8b60031d38

52597:140237026785024 12/26/2017 04:54:35:565858 FLOW ars3wapi.C(1796)apiP_RestoreHitFromDocId:Return

52597:140237026785024 12/26/2017 04:54:35:565861 FLOW arscsvdc.c(560)CsOpenDoc:Enter
52597:140237026785024 12/26/2017 04:54:35:582160 FLOW ars3wapi.C(978)JNIDataCallback:Enter
52597:140237026785024 12/26/2017 04:54:35:582375 FLOW ars3wapi.C(1237)JNIDataCallback:Return (ArcI32)pSession->FileError=0
52597:140237026785024 12/26/2017 04:54:35:586724 FLOW ars3wapi.C(978)JNIDataCallback:Enter
52597:140237026785024 12/26/2017 04:54:35:586912 FLOW ars3wapi.C(1237)JNIDataCallback:Return (ArcI32)pSession->FileError=0
52597:140237026785024 12/26/2017 04:54:35:591277 FLOW ars3wapi.C(978)JNIDataCallback:Enter
52597:140237026785024 12/26/2017 04:54:35:591456 FLOW ars3wapi.C(1237)JNIDataCallback:Return (ArcI32)pSession->FileError=0
52597:140237026785024 12/26/2017 04:54:35:596109 FLOW ars3wapi.C(978)JNIDataCallback:Enter
52597:140237026785024 12/26/2017 04:54:35:596293 FLOW ars3wapi.C(1237)JNIDataCallback:Return (ArcI32)pSession->FileError=0
52597:140237026785024 12/26/2017 04:54:35:601007 FLOW ars3wapi.C(978)JNIDataCallback:Enter
52597:140237026785024 12/26/2017 04:54:35:601320 ERROR ars3wapi.C(1127)JNIDataCallback:ArcOS_tempnam failed pSession->szTempDir=/tmp pSession->szTempPrefix=52597-00007F8B7A2A7700
52597:140237026785024 12/26/2017 04:54:35:601328 FLOW ars3wapi.C(1129)JNIDataCallback:Return 3=3
52597:140237026785024 12/26/2017 04:54:35:631136 FLOW arscsvdc.c(836)CsOpenDoc:Return csv_rc=2,CSV_RC_CANCEL csv_msgid=0,CSV_MSG_NO_MESSAGE
52597:140237026785024 12/26/2017 04:54:35:631147 FLOW ars3wapi.C(515)apiP_setReturnCodeAndMessage:Enter
52597:140237026785024 12/26/2017 04:54:35:631175 FLOW ars3wcom.C(1174)CmGuiGetString:Enter

52597:140237026785024 12/26/2017 04:54:35:631210 ERROR ars3wapi.C(10957)Java_com_ibm_edms_od_ArsWWWInterface_apiGetDocument:Current state rtn.RC=2 extId=6009 pMsg=A cancel request was received during a server request.

52597:140237026785024 12/26/2017 04:54:35:631215 FLOW ars3wapi.C(591)apiP_setReturnCodeAndMessage:Return
52597:140237026785024 12/26/2017 04:54:35:631218 FLOW ars3wapi.C(11138)Java_com_ibm_edms_od_ArsWWWInterface_apiGetDocument:Return session id=140236591238320 (irc)=1
52597:140237026785024 12/26/2017 04:54:35:636788 FLOW ars3wapi.C(5859)Java_com_ibm_edms_od_ArsWWWInterface_apiLogoff:Enter session id=140236591238320
52597:140237026785024 12/26/2017 04:54:35:636795 FLOW arscsvlg.c(650)CsvLogoff:Enter
52597:140237026785024 12/26/2017 04:54:35:636813 FLOW arscsvfl.c(2146)CsvCloseFolder:Enter
52597:140237026785024 12/26/2017 04:54:35:636835 FLOW arscsvfl.c(2250)CsvCloseFolder:Return
52597:140237026785024 12/26/2017 04:54:35:638166 FLOW arscsvlg.c(790)CsvLogoff:Return
52597:140237026785024 12/26/2017 04:54:35:638178 FLOW ars3wapi.C(5896)Java_com_ibm_edms_od_ArsWWWInterface_apiLogoff:Return session id=140236591238320 (0)=0

Does anyone have an idea what it means? In my 10+ years of using ODWEK, I've never encountered this  :-\ Any help will be much appreciated.

Warm regards,
AP
« Last Edit: December 27, 2017, 04:26:20 AM by mroutlander »