11 Replies Latest reply on Jun 10, 2011 1:15 PM by Clebert Suconic

    Error: java.lang.UnsatisfiedLinkError: org.hornetq.core.asyncio.impl.AsynchronousFileImpl.init(Ljava/lang/String;ILorg/hornetq/core/logging/Logger;)Ljava/nio/ByteBuffer;

    Karl Hennig Newbie

      I am getting an error when trying to run an in-vm broker for my unit tests.  I followed nearly exactly the example in the user manual.

       

      I saw a similar message between developers but I don't understand what the solution is.  What do I need to do to successfully run this embedded server within my unit tests?  Thank you.

       

       

      The code:

              Configuration config = new ConfigurationImpl();

              HashSet<TransportConfiguration> transports = new HashSet<TransportConfiguration>();
              transports.add(new TransportConfiguration(InVMAcceptorFactory.class.getName()));

              config.setAcceptorConfigurations(transports);
              HornetQServer server = new HornetQServerImpl(config);
              server.start();

       

      Error is:

      java.lang.UnsatisfiedLinkError: org.hornetq.core.asyncio.impl.AsynchronousFileImpl.init(Ljava/lang/String;ILorg/hornetq/core/logging/Logger;)Ljava/nio/ByteBuffer;
          at org.hornetq.core.asyncio.impl.AsynchronousFileImpl.init(Native Method)
          at org.hornetq.core.asyncio.impl.AsynchronousFileImpl.open(AsynchronousFileImpl.java:206)
          at org.hornetq.core.journal.impl.AIOSequentialFile.open(AIOSequentialFile.java:190)
          at org.hornetq.core.journal.impl.JournalImpl.createFile(JournalImpl.java:3037)
          at org.hornetq.core.journal.impl.JournalImpl.load(JournalImpl.java:2004)
          at org.hornetq.core.journal.impl.JournalImpl.load(JournalImpl.java:1374)
          at org.hornetq.core.persistence.impl.journal.JournalStorageManager.loadMessageJournal(JournalStorageManager.java:772)
          at org.hornetq.core.server.impl.HornetQServerImpl.loadJournals(HornetQServerImpl.java:1206)
          at org.hornetq.core.server.impl.HornetQServerImpl.initialisePart2(HornetQServerImpl.java:1056)
          at org.hornetq.core.server.impl.HornetQServerImpl.start(HornetQServerImpl.java:310)
          at com.mycompany.util.messaging.MessagingTest.setUp(MessagingTest.java:33)
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
          at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:44)
          at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
          at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:41)
          at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:27)
          at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:31)
          at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:76)
          at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50)
          at org.junit.runners.ParentRunner$3.run(ParentRunner.java:193)
          at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:52)
          at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:191)
          at org.junit.runners.ParentRunner.access$000(ParentRunner.java:42)
          at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:184)
          at org.junit.runners.ParentRunner.run(ParentRunner.java:236)
          at org.junit.runner.JUnitCore.run(JUnitCore.java:157)
          at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:64)