Sunday, January 16, 2011

Plugging 3rd party jars into DiffKit

With the 0.8.10 release, you can add third-party jars to DiffKit. DiffKit will recognize JDBC drivers found in those jars, as well as custom Sources, Sinks, and Diffors.
The DiffKit distribution includes a directory "dropin". It’s directly under the DIFFKIT_HOME directory, which is normally the same directory that the diffkit-app.jar is in after you have unzipped the binary download. The directory in the distribution is empty. Any extra jars that you want DiffKit to recognized you can simply copy into the dropin directory. DiffKit will automatically load all jars within dropin each time it runs. Note well that the only archive type that DiffKit recognizes is jar-- it does not recognize zip, war, ear, etc.
All jars within dropin are loaded before any of the third-party jars that are embedded within DiffKit. That means you can override JDBC drivers that are part of the DiffKit binary distribution. You might need to do this in the case of HyperSQL DB, where the version of the JDBC driver must match the version of the DB server. You might also want to add a new JDBC driver in the case where the vendor supplies a newer version of the driver than the one that DiffKit embeds, and that newer version is higher performance.
The principal use for dropins is to allow the user to write custom Source/Sink/Diffor java classes, and then plug those custom implementations into DiffKit. Source/Sink/Diff are documented in the User Guide. Those three key abstractions are represented as Java Interfaces within DiffKit. You can write your own Java classes that implement those Interfaces. You will need to use a PassthroughPlan to reference the custom classes, because MagicPlan does not recognize them. Custom classes are referenced within the Passthrough plan in exactly the same way that DiffKit native classes are.
As a trivial example of a custom Sink, the DiffKit source distribution includes class org.diffkit.contrib.DKSimpleCustomSink. org.diffkit.contrib is a package that is not included in the binary distribution. You can plug that custom Sink into your plan with, for instance, this specification:
...
<bean id="plan" class="org.diffkit.diff.conf.DKPassthroughPlan">
   <property name="lhsSource" ref="lhs.source" />
   <property name="rhsSource" ref="rhs.source" />
   <property name="sink" ref="customSink" />
   <property name="tableComparison" ref="table.comparison" />
</bean>
...
<bean id="customSink" class="org.diffkit.contrib.DKSimpleCustomSink">
   <constructor-arg index="0" value="./custom_report.diff" />
</bean>
...
Having DiffKit recognize your custom Sink is simply a matter of compiling and archiving the org.diffkit.contrib.DKSimpleCustomSink into a jar file, and the dropping that jar file into the dropin directory.

66 comments:

  1. In the particular article You might understand how for getting started building net applications services web design

    ReplyDelete
  2. Thanks for the good words! Really appreciated. Great post. I ve been commenting a lot on a few blogs recently, but I had nt thought about my approach until you brought it up.

    SAP training in Chennai

    ReplyDelete
  3. A nice article here, i think that people who have grown up with the idea of using computers are showing more responsibility towards writing posts that are thoughtful, do not have grammar mistakes and pertinent to the post..

    Online Training in Chennai

    ReplyDelete
  4. Your tips are really wonderful and its ideas are really well good and it makes me to think a very well good ideas. thus it is informative and it is really interesting.

    Online Reputation Management

    ReplyDelete
  5. very useful information provided in this blog. concepts were explained in a detailed manner. Keep giving these types of information.
    SEO company in Chennai

    ReplyDelete
  6. Imagine to browse the map and get the most relevant pictures with a magnifying glass through a tiled view composed of three concentric levels. kakskachatsoftnatelefon.ru Baby Minder is a timer application that has been developed by a mom with a newborn.

    ReplyDelete
  7. IN the forum he tells us to e-mail the developer who is in help. download tv shows New this versionMajor user interface & graphics upgrade.

    ReplyDelete
  8. To get the item needing to travel to the moon that has a much stronger stone than steel, dwarf goes on a various and fantastic puzzle expedition. download music For the past few months, shes been on her own in the yellow house, managing somehow, knowing that her mother will probably never return.

    ReplyDelete
  9. Whenever you launch the app or switch back to the app, you need to authenticate. Try this! Meditation has been a remedy for thousands of years, not only in eastern religions.

    ReplyDelete
  10. Do you want to get out of bed early and be on time for your appointments. download activation codes Compete against your peers or even parents by setting different levels of difficulty.

    ReplyDelete
  11. Category: Productivity Released: January 2010 Version: 1. link for you From Nathan Fennel: Color Springboard provides a simple set of tools for finding the perfect color for your design projects.

    ReplyDelete
  12. As a vague image forms in your mind, sketch it as best as possible in step one. http://novico.ru High contrast colored maps to quickly pinpoint problems on the road.

    ReplyDelete
  13. "This app completely re-invents the round timer, and every. http://uborka-kvartir-krasnodar.ru From DC-Matic: Comic book reader designed to display your purchased or scanned comic books in their proper size.

    ReplyDelete
  14. Great info! I recently came across your blog and have been reading along.
    eCommerce Supply Chain Management

    ReplyDelete
  15. Practice Mode: Hone your skills in this free play mode. neerajanam telugu movie songs This feature is only available on the deluxe version.

    ReplyDelete
  16. Great info! I recently came across your blog and have been reading along.

    Dot Net Training Institute in Chennai

    ReplyDelete
  17. Great info! I recently came across your blog and have been reading along.

    Android Training Institute in Chennai

    ReplyDelete
  18. Click the popover button on the top left to change the image. downlodable games I Saw Mommy Kissing Santa Claus Frosty The Snowman2.

    ReplyDelete
  19. - Windows 7 only: View a currently played Video, jump to a position inside it. downloadsoftwarefromskylar.club Exam Tips: Ideas of what to do before, during and after an exam.

    ReplyDelete
  20. 2 - On With Torchy English, 68,450 words (196 pages) http://bestkeygensarchive.me From Green Mountain Power: Want a fast, easy way to pay your bill and monitor energy usage.

    ReplyDelete
  21. Information, address, near Hotels and ratings of the attraction selected. Web page. Contacts and Carts - View and manage your contacts and listings.

    ReplyDelete
  22. You can even include pictures to show just how good they look, make um hungrier than a woodpecker with a headache. topdownloadsoftwareonline.us With a swipe of the switching arrows you will direct the trains through the train yard to their correct station.

    ReplyDelete
  23. But did you know that you can securely get your files on the go with your iPhone, iPod Touch or iPad. topdownloadwarezcatalog.us Accellion Mobile Apps are a key component of the robust Accellion Secure Collaboration solution for Enterprise organizations.

    ReplyDelete
  24. Homecoming Magazine Pricing: Single Issue Price - USD $3. awesomedownloadyourfiles.ga 0 Add prompt on your input, such as "very close", "close", "space", etc, to make you aware of how much you are getting close to the right answer.

    ReplyDelete
  25. Thanks for sharing. Data entry services are very useful in business firms and organizations as there is a huge demand for entry.
    data entry outsourcing companies

    ReplyDelete
  26. Truly, this article is really one of the very best in the history of articles. I am a antique ’Article’ collector and I sometimes read some new articles if I find them interesting. And I found this one pretty fascinating and it should go into my collection. Very good work!
    data science course in India

    ReplyDelete
  27. Really nice and interesting post. I was looking for this kind of information and enjoyed reading this one. Keep posting. Thanks for sharing.
    Artificial Intelligence Course

    ReplyDelete
  28. It's a very good blog. I'm glad I came across a good blog like this. Update new games. That we got here one place joker slot

    ReplyDelete
  29. here you can get more information about joining pakistan navy
    Join Pak Navy

    ReplyDelete
  30. I was very pleased to find this site. I wanted to thank you for this great read!! I definitely enjoying every little bit of it and I have you bookmarked to check out new stuff you post. drywall installation Chicago

    ReplyDelete
  31. This would really mean a lot. Thanks for sharing this one out. cleaning Bartonville, TX

    ReplyDelete
  32. how to fix a hole in the wall

    This blog post is well written and has a clear message. Thank you for sharing...

    ReplyDelete
  33. Drywall Contractor

    Thank you for sharing this helpful information. ��

    ReplyDelete
  34. Very informative post. Thanks for sharing this. I really appreciate it.
    air conditioning san francisco

    ReplyDelete
  35. I found this is an informative blog and also very useful and knowledgeable. I would like to thank you for the efforts you have made in writing this blog


    Get up To 30% Off buy modalert online

    Get up To 30% Off buy artvigil online
    Get up To 30% Off buy waklert online
    Get up To 30% Off buy modvigil online

    Get up To 30% Off buy vilafinil online

    ReplyDelete
  36. The idea of adding a third party to DiffKit is great but wouldn't this security be compromised? I would be great if you enlighten us about security matters. Essay Writing Services

    ReplyDelete
  37. With over 20years experience in the Pest Control Industry, we control of pest like bed bug, bee & ants in the Sutherland Shire of Sydney.


    Bees Pest control Sutherland Shire
    Bed bugs Pest control Sutherland Shire

    ReplyDelete
  38. Looking for a house removals north London company in the North London area? We can connect you with many verified and reviewed eviction companies in your local area, taking the stress out of you.
    Click here
    Click here

    ReplyDelete
  39. No matter how old your sofa is, you can always make it look beautiful and durable with high quality fabric for upholstery sofa. But, sofa fabric also requires a lot of care and maintenance to ensure its longevity. Do you want to know about cleaning and maintenance tips for your upholstery fabric?
    fabric in floral pattern

    ReplyDelete
  40. We know that there are 101 things you need to do. After showing the clearance team what they can do, they get to work. This allows you to take care of other things you may need to do. The Office clearance London pride on their service and will not leave until they are 100% satisfied with Customs.
    Office clearance London
    Office clearance London
    Click here
    Click here

    ReplyDelete
  41. Water frameworks overall are being undermined by the enormous number of pollutants that represent a wide scope of threats to families. Since you realize that we need water in each reason, like washing, washing, cooking, and drinking, the foreign substances can without much of a stretch influence your wellbeing. These days, the poisons are developing more than ever.
    RO Service Near Me ✅ RO Service in Gurgaon 249/- Only. Call RO Service Centre Number for water purifier service, installation. We cater Kent, Aquaguard, Aquafresh, Livpure, Pureit, Nasaka in Gurgaon & Delhi NCR.
    Pahuja RO Water Solution is an independent Ro Service Centre in Gurgaon, Delhi NCR and All Over India. We undertake job work of Service, AMC, Repair, Installation & Maintenance.

    Your Choice Of Protector: Various Water Purification Technology
    Wide Range of Water Purifiers is Available at Our Store if You Want to Shop Online
    Do you think it’s safe to give your family unfiltered water?
    Water That is Safe and Clean to Drink-RO Filter Service
    Factor You Must Consider Before You Buy Water Purifier For Your Home

    ReplyDelete
  42. Thanks for sharing a useful knowledge-sharing blog.

    It helps in understanding and increase in knowledge.

    Best Regards,

    Man and Van West London
    London House Clearance

    ReplyDelete
  43. review linked here pop over to this site Read Full Article have a peek at this web-site useful content

    ReplyDelete
  44. Spare Parts for Tata Xenon are the parts that are used for the maintenance and repair of Tata vehicles. They are made from high-quality components and engineered to meet exact specifications.

    ReplyDelete
  45. Thanks for sharing this wonderful and very informative blog about Plugging 3rd party jars into DiffKit.
    b&w hitch

    ReplyDelete