Using ConnectionConfiguration with a romote server Stardog

0 views
Skip to first unread message

Sabino Pariente Juarez

unread,
Feb 24, 2015, 3:07:15 PM2/24/15
to sta...@clarkparsia.com
Hello

I'm trying to connect to remote server with this code lines, that I found in http://docs.stardog.com/#_java_programming 
I'am working with Netbeans IDE with the last Stardog version

        String server = "snarl://"+[ipRemoteServer]+":"+[ipRemoteServer];
        this.aConn = ConnectionConfiguration
            .to("myDB")
            .server(server)
            .credentials(sconfig.getUser(), sconfig.getPassword())              // credentials to use while connecting
            .connect();

 but I get the following exception
       Exception in thread "main" java.util.ServiceConfigurationError: com.complexible.stardog.api.Driver: Provider com.complexible.stardog.protocols.snarl.client.SNARLDriver could not be instantiated
at java.util.ServiceLoader.fail(ServiceLoader.java:232)
at java.util.ServiceLoader.access$100(ServiceLoader.java:185)
at java.util.ServiceLoader$LazyIterator.nextService(ServiceLoader.java:384)
at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:404)
at java.util.ServiceLoader$1.next(ServiceLoader.java:480)
at com.google.common.collect.ImmutableSet.copyOf(ImmutableSet.java:317)
at com.complexible.stardog.api.DriverManager.<init>(DriverManager.java:38)
at com.complexible.stardog.api.DriverManager.<clinit>(DriverManager.java:27)
at com.complexible.stardog.api.ConnectionConfiguration.connect(ConnectionConfiguration.java:137)
at mx.com.inteligenciaaplicada.IARDFStorage.Stardog.StardogConnection.<init>(StardogConnection.java:36)
at mx.com.inteligenciaaplicada.IARDFStorage.IARDFStorage.main(IARDFStorage.java:48)

I already checked if all libraries from Strardog directory are imported on my netbeans project 



regards

Héctor Pérez-Urbina

unread,
Feb 25, 2015, 8:32:22 AM2/25/15
to stardog
Hi Sabino,

This looks like a classpath issue. Could you double check that every single jar contained in the distribution is included in the classpath?

--
-- --
You received this message because you are subscribed to the C&P "Stardog" group.
To post to this group, send email to sta...@clarkparsia.com
To unsubscribe from this group, send email to
stardog+u...@clarkparsia.com
For more options, visit this group at
http://groups.google.com/a/clarkparsia.com/group/stardog?hl=en



--
Best,
Héctor
Reply all
Reply to author
Forward
0 new messages