Re: R: R: R: How to start Connector/MXJ ?
Eric Herman <[email protected]>
| Newsgroups | gmane.comp.db.mysql.java |
|---|---|
| Message-ID | <1158660803.4724.127.camel@localhost> |
Hi Roberto Regazzoni, On Wed, 2006-09-20 at 10:05 +0200, legalmail wrote: > Hi Eric, > > I'm afraid I did not copy and paste properly the CLASSPATH last time. > Actually the three jar files were there. Okay great. No problem. I'm certain we've all botched plenty of pastes and edits in emails. No big deal. > > I attach a new Console output with the full CLASSPATH. > Okay. And I now see the three jars. Perfect. Hmmmm.... But we still see the same class resolution issue. For whatever reason, it seems that Java in that environment isn't finding the class: com.mysql.management.driverlaunched.ServerLauncherSocketFactory which is strange because that /really/ should not be a problem. I have no idea why this would be the case on that system. It might be worth doing a: C:\>jar tvf C:\connector-mxj\connector-mxj\connector-mxj.jar This would simply confirm that ServerLauncherSocketFactory.class is really in the jar. But (provided it's the same one you downloaded) I'm 100% confident it will be. I'd like you to try some things. Perhaps something else in the CLASSPATH is creathing a conflict? I'd like you to remove everything for the CLASSPATH except the three jars. Please get rid of the "." and all the other jars so we just have: C:\connector-mxj\connector-mxj\connector-mxj.jar; C:\connector-mxj\connector-mxj\lib\aspectjrt.jar; C:\Programmi\MySQL\mysql-connector-java-5.0.3 \mysql-connector-java-5.0.3-bin.jar See if that makes a difference. (Seems worth a try, anyway.) Next, (if that still shows the same problem) try using this command: C:\> java ConnectorMXJObjectTestExample The "ConnectorMXJObjectTestExample" does not make use of the the special URL Syntax which Connector/J uses to instantiate a Connector/MXJ SocketFactory. Perhaps *that* will make a difference ... and maybe even shed some light on this issue. As always, please attach the complete console output in a reply. > Maybe is not relevant, but please note that my Java compiler cannot resolve > the import of com.sun.jdmk in the class MysqldTestAgentSunHtmlAdaptor. Ah, wonderful! You're taking an interest in the source! Great to see. It is far from perfect, I know, and I apologize. Be assured it's the best we could do with the time and resources we've had so far. We've struggled with the balance of keeping it (A) well tested (and thus modular for easy test writing, and fast test execution) yet (B) fairly simple to understand. When (A) and (B) have been in conflict, (A) takes priority. Sadly, this means it is not always as simple as would be desired. However back to your question: yes, as it turns out, that isn't at all relevant: MysqldTestAgentSunHtmlAdaptor is for stand alone JMX testing with the Java 1.4 JMX extensions. From the source (reformatted slightly for email): * This Simple JMX Agent is useful for testing. * * This JMX Agent requires the Sun specific tools which come with Sun's * JMX Reference Implementation in the "jmxtools.jar" file. * * If Sun's "jmxtools.jar" is not available (or more specifically * <code>com.sun.jdmk.comm.HtmlAdaptorServer</code> then deploying to * a JMX Agent is required. (I use JBoss --Eric) * * This Agent has exactly two beans: * 1) a MysqldDynamicMBean * 2) a Broswer Interface for management In fact, since we have not had much interest in JMX, especially in being able to do stand-alone JMX testing, that class may be removed entirely in future version. So, it is not at all a problem the compiler on that system cannot resolve the import of com.sun.jdmk.HtmlAdaptor because that class is only used for some specialized testing. If we wish to resolve that class, jmxtools.jar can be downloaded from Sun. Look for the "JMX 1.2.1 Reference Implementation" download at: http://java.sun.com/products/JavaManagement/download.html And download the jmx-1_2_1-ri.zip from sun. Inside that zipcan be found the files: * jmx-1_2_1-bin/lib/jmxri.jar * jmx-1_2_1-bin/lib/jmxtools.jar Or, we may simply ignore MysqldTestAgentSunHtmlAdaptor and its compile issues entirely. Cheers, -Eric > > Thanks > Roberto Regazzoni > > > > -----Messaggio originale----- > Da: Eric Herman [mailto:[email protected]] > Inviato: lunedì 18 settembre 2006 18.37 > A: tech > Cc: [email protected] > Oggetto: Re: R: R: How to start Connector/MXJ ? > > Hello Roberto Regazzoni, > > On Mon, 2006-09-18 at 16:31 +0200, tech wrote: > > > > C:\Documents and Settings\Roberto\IBM\rationalsdp6.0\XML\TextMXJ>SET > > CLASSPATH > > CLASSPATH=.;C:\PROGRA~1\IBM\SQLLIB\java\db2java.zip;C:\PROGRA~1\IBM > > \SQLLIB\java\db2jcc.jar;C:\PROGRA~1\IBM\SQLLIB\java\sqlj.zip;C: > > \PROGRA~1\IBM\SQLLIB\java\db2jcc_license_cu.jar;C:\PROGRA~1\IBM\SQLLIB > > \bin;C:\PROGRA~1\IBM\ > > ector-mxj\connector-mxj\lib\aspectjrt.jar;C:\Programmi\MySQL > > \mysql-connector-java-5.0.3\mysql-connector-java-5.0.3-bin.jar > > > > I do not see "connector-mxj.jar" in the CLASSPATH. > > Let's make extra sure that the CLASSPATH contains: > (1) mysql-connector-java-5.0.3-bin.jar > (2) connector-mxj.jar > (3) aspectjrt.jar > > Cheers, > -Eric > > -- > Eric Herman, Software Developer > MySQL AB, www.mysql.com > VoIP Ext: 6594 US: +1 408 213 6540 Europe: +46 18 174 400 > Mobile: +31 [0]6-20719662 > Are you MySQL certified? www.mysql.com/certification > -- Eric Herman, Software Developer MySQL AB, www.mysql.com VoIP Ext: 6594 US: +1 408 213 6540 Europe: +46 18 174 400 Mobile: +31 [0]6-20719662 Are you MySQL certified? www.mysql.com/certification -- MySQL Java Mailing List For list archives: http://lists.mysql.com/java To unsubscribe: http://lists.mysql.com/[email protected]