Solved

JXM Command Line

Posted on 2011-02-17
10
443 Views
Last Modified: 2013-11-24

 JAVA APPLICATION
I have to access a Java application as shown in the figure.  Ovals depict a click.  Last oval is a double click.  It is on a Windows server.  I am running my Bash script on Linux server.  From my Linux box, I need to access this Java application so that I don't have to log onto the Windows box every time and do those few clicks.  I heard that JMX can do it but I have no idea.  If not terribly complicated, could you please show me how to code this?
0
Comment
Question by:farzanj
  • 5
  • 5
10 Comments
 
LVL 92

Expert Comment

by:objects
ID: 34920080
jmx won't do it, and you're not going to find a way to easily do that
0
 
LVL 31

Author Comment

by:farzanj
ID: 34920137
http://download.oracle.com/javase/1.5.0/docs/guide/management/agent.html#jconsole_remote
Says you can do it programmatically by using URL.  That is the kind of thing I am looking for.  Why can't you do it?
0
 
LVL 92

Expert Comment

by:objects
ID: 34920698
you can access jmx programatically, but you cannot use it to automate clicks
0
 
LVL 31

Author Comment

by:farzanj
ID: 34921313
Well, that is what I meant.  There is an object that I need to call, basically.  Forget about clicks.  By clicks I meant to show the object in the tree I am calling.  I have to invoke a procedure of a particular object as shown in the figure.  I don't care how it is done, but the procedure should be called.

And I know it can be done, there are people in my company who do it but they are too hard to reach.
0
 
LVL 92

Expert Comment

by:objects
ID: 34921338
0
Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

 
LVL 92

Expert Comment

by:objects
ID: 34921347
0
 
LVL 31

Author Comment

by:farzanj
ID: 34926313
It has a steep learning curve.  Could you please answer the following?


Will I need a compile a Java program on the client side, right?
How would I know if the server is running that JMX server?
How would I authenticate to it? Will it have the same password as of Windows server?  When I manually access the server and open the Java application, I don't need to provide any further credentials.
0
 
LVL 92

Expert Comment

by:objects
ID: 34929807
> Will I need a compile a Java program on the client side, right?

to provide custom acces yes

> How would I know if the server is running that JMX server?

you won't be able to connect if it isn't

> How would I authenticate to it? Will it have the same password as of Windows server?  When I manually access the server and open the Java application, I don't need to provide any further credentials.

If the server is setup to require authentication then yes
it does not use the same password as windows
http://download.oracle.com/javase/6/docs/technotes/guides/management/agent.html
0
 
LVL 31

Accepted Solution

by:
farzanj earned 0 total points
ID: 35016619
I think my description was pretty accurate as to what I wanted to do.  No, it was not difficult.  It was easy and I did it.  All I needed to know was "jmxsh-R4.jar" utility.  It is provided under Apache license.  It is also available under JBoss.
http://www.ohloh.net/p/jmxsh
It provides shell capability to access jmx by using TCL language.  If you know the sequence of clicks I had given at the beginning, it takes just a few minutes to write the command for it, which is a one liner.  If you want to do further processing, you need to know TCL.

Personally, I help a lot of people on EE in my zones.  I programmed in Java till early 2000s but then left it for good.  But on EE I expected the same quality of help that I provide.  If I don't know about certain thing, I would never say it cannot be done.
0
 
LVL 31

Author Closing Comment

by:farzanj
ID: 35067628
I appreciate your time and I value it.  However non of the answers you provided gave me not even a clue.  And the solution was very easy to accomplish, only you had to know that there is already a compiled application available to call jmx from shell, which is what I had requested.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
scoreUp challenge 14 48
computer science syllabus 3 53
for i loop in grovy 1 32
Problem to start Neon 20 54
For beginner Java programmers or at least those new to the Eclipse IDE, the following tutorial will show some (four) ways in which you can import your Java projects to your Eclipse workbench. Introduction While learning Java can be done with…
Java functions are among the best things for programmers to work with as Java sites can be very easy to read and prepare. Java especially simplifies many processes in the coding industry as it helps integrate many forms of technology and different d…
Video by: Michael
Viewers learn about how to reduce the potential repetitiveness of coding in main by developing methods to perform specific tasks for their program. Additionally, objects are introduced for the purpose of learning how to call methods in Java. Define …
This tutorial explains how to use the VisualVM tool for the Java platform application. This video goes into detail on the Threads, Sampler, and Profiler tabs.

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now