Toggle DEBUG_LOGGING On/Off on the fly

Hi Alex,

Just tried your application and it works brilliantly. I will move your post to the download
section in due course.

Can you tell me if the application is along the same lines as described in the Tips and
traps section (Toggle Debug logging on the fly). If this is so, I will make a reference in that post.

Again thank you very much for your contribution.

Rgds,
 
I've just given it a try and it works like a dream. Well done!

What would be useful is if it deleted the jdedebug.log when you click Off.
 
Alex-

Thanks for the utility. Can it direct the output to a different file?

I like to point logging and debugging messages to the same file:

[DebugFile=c:\jde.log; JobFile=c:\jde.log]

so they are merged in real time and you don't have to look back and forth
between the files.

Regards,
David
 
Thanks, Sef.

Yes, I'm using the function call from that old article, the trick is that it has to be executed from
within the OneWorld process to have any effect and it's not a trivial task to do it from an
external program: it's a rather advanced technic mostly used in some more complex virus
programs...

I have just re-programmed some bits in it and re-released it as a single file, plus it is now
supposed to work under Windows NT 4.0 - check it out, it's on the same URL.

As for the suggestion (from a reply to your message) that it should also delete the log file
while turning the logging OFF, I have serious doubts: you would normally turn it ON just before
and OFF - immediately after something you wanted to capture the logs for and you would
expect
the log file to still be there after you have finished, wouldn't you?

Regards,
Alex.

PS: I would rather people downloaded it from my site to keep the counter going and to make sure
the latest version is there, so, please, just publish the URL in your Downloads section.
 
Yes you're right.

I was just thinking that some way of refreshing the log would be useful because it fills up so quickly. Perhaps some way of inserting a marker at appropriate points would be useful?
 
Hi Alex,

That's nice work, thanks. Would you also post your source code? I don't think many sites would allow deployment of an exe they cannot validate and build themselves.

As for building an external app to do this, then that's really very straight-forward. Just build a c program per the interoperability/c api method that calls the BSFN that toggles the log, or if you don't want to deply a bsfn to your servers, just code all the API calls in the BSFN directly in the C application.

One advantage of a standalone app is the ability to run it while OW is stopped in the C debugger. However the disadvantage is that in a production environment, you might not be permitted to deploy a standalone exe onto your citrix servers. OTOH, you can probably get a OW interactive app that does the toggle and log presentation deployed more easily. YMMV.

Cheers,
JohnO
 
Hello Alex,
A very nice tool!
Will you accept my 2¢ suggestions?
Firstly, is there a way to have a feedback from clicking the On or Off? I see only Success (which could mean A LOT OF positive things, EXCEPT for the DebugLog_On/Off status :)
And lastly, as JohnO was putting it (and YOU say it so nicely, about complex virus programs ...), would it be a big deal to have the application properly disected on this Forum?
Thanks,
Adrian Chimirel
PS Or do you intend to sell it?
 
This works great.

I can think of two improvements (not that I think they would be easy to
implement)
1) Make it possible for an admin to specify a user on a WTS to turn logging
on for, without having to give the user the app and admin rights.
2) Get the utility to function on a logic server.

Now THAT would be indispensable.

(I'm not complaining)

Steve Lehner
Global Systems Administrator
Global Information Systems
Westcon.Net
email: [email protected]
phone: 914 829 7457




Alex_Pastuhov
<Alex_Pastuhov@jde To: [email protected]
dwards.com> cc:
Sent by: Subject: Toggle DEBUG_LOGGING On/Off on the fly
owner-jdelist@jdel
ist.com


04/23/2002 10:54
PM
Please respond to
jdelist





Enjoy:

http://members.optushome.com.au/apastuhov/OWDebugLogCommander.htm
--------------------------
 
John,

Frankly, I find it hard to believe: calling this BSFN in your own process (as in "LoadLibrary", "GetProcAddress" and then call) won't change a thing in the O/W process. It needs to be called from within OneWorld.

Not being familiar with the "interop/c api method" you are refering to, I might be wrong, but unless this "method" does what I had to do in the "Commander" transparently to the caller, I would not believe it can be used.

Can you elaborate a bit on this "interop" thing or try to follow your suggestions yourself to see if it works?

Regards,
Alex.
 
Steve,

I will look at the #1 and
#2 - this you can do with SAW as it is - you can toggle the logging for any kernel at any time...

Regards,
Alex.
 
Hi Alex,

Nah, no need for dynamic dll loading... unless you want to do all that.

If you want to learn about OneWorld Interoperability then I recommend you go to the Knowledge Garden and search for "OneWorld Interoperability Guide". Its a rather large pdf document, but full of good stuff. In particular, chapter 10 covers the API functions concerned with connecting to Oneworld, the exposed API's and how to call business functions.

As you will see, it is straighforward to write an app that connects to OneWorld and executes it's APIs and business functions. All you need in this case are the API's JDB_InitEnv(), JDB_InitUser(), JDE_CreateBusinessFunctionParms(), then jdeCallObject() to call the BSFN posted in the Tips and Traps forum to toggle logging..

Of course, JDE are pushing XML, Corba, COM and Java for interoperability rather than the C API's now, bit that's another story...

Have fun,
JohnO
 
Hi again,

I just hacked together a sample standalone app to call my log toggle bsfn. It also does log viewing and clearing. To grab it, look in the downloads section of this forum...

Cheers,
JohnO
 
John,

Thanks, I'll have a look.

Not being a O/W developer as such, does this mean that you have to develop a
BSFN in O/W to be able to call the "changeLogSettings" function? I expect,
it is not associated with an object name itself then, right?

Would your approach work for calling a BSFN in an instance of OneWorld
running by a different user on the same WTS?

Regards,
Alex.
 
Hi John,

I already tried the same thing, It worked !!!! But the problem is, it is not logging the OW process it's logging the my external C program process.

1) I am wondering how do you manage to execute the application with single signon ?. (I assume each signon is a seperate process)
2) How do you access the OW cached information in to your program ?

By the way i couldn't find it in downloads section .....

Regards

Zakeer
 
Hi Zakeer,

I think the moderator has to approve it before it's visible in the downloads area. In the meantime, I'll attach it here as well:

Cheers,
JohnI
 

Attachments

  • 33424-ToggleJDELogging.zip
    54.2 KB · Views: 83
Jolly,

I've checked a minute ago and it was already available(for everybody) in the download section

Christian Audet
 
Hello JohnO,
Just started to implement your BSFN and I noticed that the CCUSTOM.dll is missing; the manual says it should be the default (and OMW filled it in, and, then, invalidated it).
Wat is your advice:
- should I create it (thru OMW), OR do I have to find the reason why it's missing, fix its missing, AND finally add the B5500013 to it? OR
- should I just create another custom one, say CCUSTMFP.dll?
Cheers,
Adrian Chimirel
PS Thanks for YOUR patience!
 
Back
Top