ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Simple mqsicreatebar generator util based on BAR

Post new topic  Reply to topic
 Simple mqsicreatebar generator util based on BAR « View previous topic :: View next topic » 
Author Message
eugenek
PostPosted: Tue Jan 31, 2012 11:26 am    Post subject: Simple mqsicreatebar generator util based on BAR Reply with quote

Newbie

Joined: 03 Jun 2011
Posts: 6

Hi everyone,

I have been thinking about creating a simple utility that can crack the existing bar file open and build the mqsicreatebar script based on the given BAR contents.
So finally found some time to do that and would like to share it in this community.
I think it may be very useful in some situations as it uses only generic Java apis from the JVMs and runs independently from the broker, toolkit and eclipse.

The way it works is in cmd console you launch the JAR file attached:

java -jar <Path>\BARCracker.jar

This brings up a dialog where user needs to specify a BAR file, workspace where the projects are(to be used in -data) and also can set some common flags (the flags may work or not work depending on the toolkit version you have).

When the "Generate" button is clicked the tool will create a mqsicreatebar script based on the BAR file data.
Then if run on Windows the script automatically can be opened in notepad. The script is saved to the same directory where the specified bar is.

If you want to try this utility please reply to this note and let me know the address where to send the jar file to.
My email is: kharlamov.eugene@gmail.com.

Thanks.
Back to top
View user's profile Send private message
lancelotlinc
PostPosted: Tue Jan 31, 2012 12:33 pm    Post subject: Re: Simple mqsicreatebar generator util based on BAR Reply with quote

Jedi Knight

Joined: 22 Mar 2010
Posts: 4941
Location: Bloomington, IL USA

eugenek wrote:
Hi everyone,

I have been thinking about creating a simple utility that can crack the existing bar file open and build the mqsicreatebar script based on the given BAR contents.
So finally found some time to do that and would like to share it in this community.
I think it may be very useful in some situations as it uses only generic Java apis from the JVMs and runs independently from the broker, toolkit and eclipse.

The way it works is in cmd console you launch the JAR file attached:

java -jar <Path>\BARCracker.jar

This brings up a dialog where user needs to specify a BAR file, workspace where the projects are(to be used in -data) and also can set some common flags (the flags may work or not work depending on the toolkit version you have).

When the "Generate" button is clicked the tool will create a mqsicreatebar script based on the BAR file data.
Then if run on Windows the script automatically can be opened in notepad. The script is saved to the same directory where the specified bar is.

If you want to try this utility please reply to this note and let me know the address where to send the jar file to.
My email is: kharlamov.eugene@gmail.com.

Thanks.


Eugene,

Your proposal is technically infeasible. You do not have the generalized workspace name or the source available. Therefore, your attempt to build an mqsicreatebar command line would be inadequate.

There is no replacement for version control. Write source code, then save the source code to a version control system.

This post seems like spam to me, and wonder what actually the Jar does, since it cannot do what you purport it to do. You may be able to derive a command line out of the forensics, but you would not be able to recreate the source code files. What good would a command line do without source code ?

Lance
_________________
http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER
Back to top
View user's profile Send private message Send e-mail
mqjeff
PostPosted: Tue Jan 31, 2012 12:46 pm    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

while you can make some reasonable guesses as to source names based on things like cmf file names and some of the path info, in the general case I agree that you can't make a firm link between the contents of a random bar file and the workspace resources that produced it.

In particular, it's going to be ... complicated at best to guess whether the contents of a JAR file represent workspace source files or project includes or etc. etc. etc.

Now, if the prerequesite is that you provide both the bar file in question AND the workspace that built it - which it seems slightly possible is what is described here, then it's an easier problem.

But then it doesn't seem a terribly useful tool for most purposes.
Back to top
View user's profile Send private message
smdavies99
PostPosted: Tue Jan 31, 2012 12:52 pm    Post subject: Reply with quote

Jedi Council

Joined: 10 Feb 2003
Posts: 6076
Location: Somewhere over the Rainbow this side of Never-never land.

Lancelotlinc,
From his description, you are supplying the location of the workspace where the .bar file was originally built. This possibly would allow the generation of a script as decribed.

Why don't you try it out in a VM and report back? I'm sure we'd all value your feedback...
_________________
WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995

Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions.
Back to top
View user's profile Send private message
lancelotlinc
PostPosted: Tue Jan 31, 2012 12:56 pm    Post subject: Reply with quote

Jedi Knight

Joined: 22 Mar 2010
Posts: 4941
Location: Bloomington, IL USA

I value my bank account and tax return info far more than BarCracker utility. ^^ This smells to me like a Trojan horse.
_________________
http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER
Back to top
View user's profile Send private message Send e-mail
eugenek
PostPosted: Tue Jan 31, 2012 1:18 pm    Post subject: Reply with quote

Newbie

Joined: 03 Jun 2011
Posts: 6

It's interesting how much you can deduce by just looking at the original post info:
"- It's useless;
- It's a Trojan;
- It would not work.

I applaude your deep insight

Now in response to the quesions.
A. It does not care about the workspace. It needs the wokspace parameter just build the script (-data) ( I assume peple can just update th generated script manuallly if the workspace changes);
B. If you don't have anything there of course the script won't work when you try to execute it. But in order to create the script you actually don't need the projects or artefacts on the workspace.
C. It's not intended to replace any source control system.
D. I find it useful in the cases when my mqsicratebar script from the source control sytem does not work for some reason.
Often I saw it does not work because the script may be outdated compared to th source on the workspace.
And in these cases I use this utility to get me the script based on the exisig BAR and it will tell me what projects and artifats are expcted to be on the workspace.

And finally:
If you want to try you can send an e-mail to me. If you don't need it feel free to ignore me
Back to top
View user's profile Send private message
mqjeff
PostPosted: Tue Jan 31, 2012 1:20 pm    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

eugenek wrote:
I applaude your deep insight

It's possible I've considered the problem before.
Back to top
View user's profile Send private message
lancelotlinc
PostPosted: Tue Jan 31, 2012 1:36 pm    Post subject: Reply with quote

Jedi Knight

Joined: 22 Mar 2010
Posts: 4941
Location: Bloomington, IL USA

Eugene, you have not provided enough detail to make even the smallest business case to consider your utility.

People who are smart enough to use Message Broker don't need a GUI tool to create a command line for them.

They should be smart enough to write their own command line and if not, find a new line of work.
_________________
http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER
Back to top
View user's profile Send private message Send e-mail
eugenek
PostPosted: Tue Jan 31, 2012 1:38 pm    Post subject: Reply with quote

Newbie

Joined: 03 Jun 2011
Posts: 6

yeah indeed. Nothing new under the sun.
Well, anyway this thing works for me.
Back to top
View user's profile Send private message
lancelotlinc
PostPosted: Tue Jan 31, 2012 1:44 pm    Post subject: Reply with quote

Jedi Knight

Joined: 22 Mar 2010
Posts: 4941
Location: Bloomington, IL USA

What would really be slick is a Ant generator utility run from Eclipse to create Ant scripts that build bar files.

Maybe what you have is the start of something more towards that end?

What would it take to integrate your utility to Eclipse and rather than create a command line, create an Ant file?
_________________
http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER
Back to top
View user's profile Send private message Send e-mail
eugenek
PostPosted: Tue Jan 31, 2012 1:49 pm    Post subject: Reply with quote

Newbie

Joined: 03 Jun 2011
Posts: 6

Dear Sir Lancelot,
Your point is taken.
Please feel free to read anything else that fits your intelligence level.
Back to top
View user's profile Send private message
eugenek
PostPosted: Tue Jan 31, 2012 1:50 pm    Post subject: Reply with quote

Newbie

Joined: 03 Jun 2011
Posts: 6

It should not be difficult. I can see wht I can do when I have a couple of hours.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Simple mqsicreatebar generator util based on BAR
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.