• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

how to Monitor Registry

 
Ranch Hand
Posts: 72
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey Guys,

So here's what I am trying to do. I have two separate web applications on one machine. I have a registry setting which I change in Application A, which will need to be picked up by Application B. I would like to set up a listener to monitor the Registry and pick up any changes. From what I can tell the C++ equivalent would be RegNotifyChangesKeyValue. Can someone point me toward the appropriate library or documentation to accomplish this? Is it even possible? Or am I going to have to right a plugin?

Thanks,
 
Java Cowboy
Posts: 16084
88
Android Scala IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The registry is a very Windows-specific thing. Java is a platform-independent language, meant to work on many different operating systems. Therefore it does not contain classes and methods in the standard Java API for functionality that is very specific to a particular operating system.

There are libraries that you can get to work with the Windows registry from Java; Google for example for "java windows registry" to find them. I don't know if there's one that will support the functionality that you need, you'll have to check that out.
 
John Lark
Ranch Hand
Posts: 72
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for the response! I think I am going to write a dll, then I can just start a thread in the java that will make a call to the said dll and just wait for a response.
 
Jesper de Jong
Java Cowboy
Posts: 16084
88
Android Scala IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
That's one thing you could do. You'd have to use JNI (Java Native Interface) to call your DLL from Java.
 
A sonic boom would certainly ruin a giant souffle. But this tiny ad would protect it:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic