Hi Chryssa

What are the versions of the following Virtuoso components in user:

1. Virtuoso Server by running the command:

          ./virtuoso-t -? 

2. Jena Provider by running the command:

        java -jar virt_jena.jar

3. JDBC Driver by running the command:

        java -jar virtjdbc3.jar

Also, which DBpedia datasets are you using 3.8, 3.9 or other ?
 
Best Regards
Hugh Williams
Professional Services
OpenLink Software, Inc.      //              http://www.openlinksw.com/
Weblog   -- http://www.openlinksw.com/blogs/
LinkedIn -- http://www.linkedin.com/company/openlink-software/
Twitter  -- http://twitter.com/OpenLink
Google+  -- http://plus.google.com/100570109519069333827/
Facebook -- http://www.facebook.com/OpenLinkSoftware
Universal Data Access, Integration, and Management Technology Providers

On 16 Oct 2013, at 08:22, Chryssa Zerva <chryssa....@gmail.com> wrote:

> Hello,
> 
> I have installed virtuoso on my machine and use it to query a dbpedia graph. 
> The code that accesses the server is copied below. The class is called 
> repeatedly in my project, while I am parsing a text. It works in the 
> beginning but if I increase the number of sentences parsed, (and as a result 
> the number of calls to the class and the number of queries) I get the 
> following exception:
> 
> Exception in thread "main" virtuoso.jdbc3.VirtuosoException: Connection 
> failed: Cannot assign requested address
>     at virtuoso.jdbc3.VirtuosoConnection.connect(Unknown Source)
>     at virtuoso.jdbc3.VirtuosoConnection.connect(Unknown Source)
>     at virtuoso.jdbc3.VirtuosoConnection.<init>(Unknown Source)
>     at virtuoso.jdbc3.Driver.connect(Unknown Source)
>     at java.sql.DriverManager.getConnection(DriverManager.java:579)
>     at java.sql.DriverManager.getConnection(DriverManager.java:221)
>     at virtuoso.jena.driver.VirtGraph.<init>(Unknown Source)
>     at virtuoso.jena.driver.VirtGraph.<init>(Unknown Source)
>     at dbpedia.QueryHandler.openGraph(QueryHandler.java:21)
>     at dbpedia.LabelMatchQuery.Matching(LabelMatchQuery.java:30)
>     at dbpedia.DBTagging.findEntity(DBTagging.java:67)
>     at dbpedia.DBTagging.CheckPhrase(DBTagging.java:32)
>     at dbpedia.DBTagging.<init>(DBTagging.java:15)
>     at dbpedia.DBAssignTag.matchNE(DBAssignTag.java:114)
>     at dbpedia.DBAssignTag.assignTags(DBAssignTag.java:84)
>     at dbpedia.DBMatch.main(DBMatch.java:23)
> com.hp.hpl.jena.shared.JenaException: rethrew: 
> virtuoso.jdbc3.VirtuosoException: Connection failed: Cannot assign requested 
> address
>     at virtuoso.jena.driver.VirtGraph.<init>(Unknown Source)
>     at virtuoso.jena.driver.VirtGraph.<init>(Unknown Source)
>     at dbpedia.QueryHandler.openGraph(QueryHandler.java:21)
>     at dbpedia.LabelMatchQuery.Matching(LabelMatchQuery.java:30)
>     at dbpedia.DBTagging.findEntity(DBTagging.java:67)
>     at dbpedia.DBTagging.CheckPhrase(DBTagging.java:32)
>     at dbpedia.DBTagging.<init>(DBTagging.java:15)
>     at dbpedia.DBAssignTag.matchNE(DBAssignTag.java:114)
>     at dbpedia.DBAssignTag.assignTags(DBAssignTag.java:84)
>     at dbpedia.DBMatch.main(DBMatch.java:23)
> Caused by: virtuoso.jdbc3.VirtuosoException: Connection failed: Cannot assign 
> requested address
>     at virtuoso.jdbc3.VirtuosoConnection.connect(Unknown Source)
>     at virtuoso.jdbc3.VirtuosoConnection.connect(Unknown Source)
>     at virtuoso.jdbc3.VirtuosoConnection.<init>(Unknown Source)
>     at virtuoso.jdbc3.Driver.connect(Unknown Source)
>     at java.sql.DriverManager.getConnection(DriverManager.java:579)
>     at java.sql.DriverManager.getConnection(DriverManager.java:221)
>     ... 10 more
> 
> 
> 
> my code: 
> 
> public void Matching(String lang){
>         String uriForm = initial.replace(" ", "_");//expand
>         String resource = "http://dbpedia.org/resource/"; + uriForm;
>         String graph_name = "dbpedia_labels";
>         
>         QueryHandler qh = new QueryHandler();
>         VirtGraph graph = qh.openGraph(graph_name);
>         String query = 
>         "SELECT distinct ?uri " +
>             "WHERE {" +
>             "<" + resource + "> ?tt ?uri }";
> 
>         Pattern p = Pattern.compile("@");
>         
>         try{
>             VirtuosoQueryExecution qe = VirtuosoQueryExecutionFactory.create 
> (query, graph);
>             ResultSet res = qe.execSelect();
>             //ResultSet res = qh.runQuery(query, graph);
>             String pls2;
>             matched = "0";
>             while (res.hasNext()){
>             
>                 QuerySolution qsl1 = res.nextSolution();
>                 pls2 = (qsl1.get("uri")).toString();        
> 
>                 
>                 String sep[] = pls2.split("@");
>                 if (sep[1].equals(lang)){
> 
>                     matched = sep[0];
>                 }
>             }
>             qe.close();
>             graph.close();
> 
>         }catch(Exception e){
>             e.printStackTrace();
>         }
>     }    
> 
> 
> Could someone give me some insight on what might be the problem?
> 
> Thanks in advance,
> 
> Best Regards,
> Chryssa
> ------------------------------------------------------------------------------
> October Webinars: Code for Performance
> Free Intel webinars can help you accelerate application performance.
> Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
> the latest Intel processors and coprocessors. See abstracts and register >
> http://pubads.g.doubleclick.net/gampad/clk?id=60135031&iu=/4140/ostg.clktrk_______________________________________________
> Virtuoso-users mailing list
> Virtuoso-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/virtuoso-users

Attachment: smime.p7s
Description: S/MIME cryptographic signature

------------------------------------------------------------------------------
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register >
http://pubads.g.doubleclick.net/gampad/clk?id=60135031&iu=/4140/ostg.clktrk
_______________________________________________
Virtuoso-users mailing list
Virtuoso-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/virtuoso-users

Reply via email to