Hi Lvc,
I tried 1.7-SNAPSHOT and got the same result. Here's the output.
Note: I regenerated the 10 graphs & used the console.sh from 1.7-SNAPSHOT.
0. Created the 10 OrientGraphNoTx graphs.
1. Start the embedded server
=======================================================================================
[root@test] java -cp target/myjar.jar com.company.Test -test server
------------------------------------------------------------------------
-- this test will start an embedded server to serve the previously
generated graphs
------------------------------------------------------------------------
2014-04-10 16:13:33:135 INFO Loading configuration from input stream
[OServerConfigurationLoaderXml]
2014-04-10 16:13:33:609 INFO OrientDB Server v1.7-SNAPSHOT is starting
up... [OServer]
2014-04-10 16:13:33:625 INFO Databases directory:
/tmp/embedded/orientdb/graphs [OServer]
2014-04-10 16:13:33:713 INFO Listening binary connections on 0.0.0.0:8424
(protocol v.20, socket=default) [OServerNetworkListener]
2014-04-10 16:13:33:716 INFO Listening http connections on 0.0.0.0:8480
(protocol v.10, socket=default) [OServerNetworkListener]
2014-04-10 16:13:33:756 INFO OrientDB Server v1.7-SNAPSHOT is active.
[OServer]
2. Connect to the server instance and list the databases.
=======================================================================================
[root@test] ./console.sh
OrientDB console v.1.7-SNAPSHOT (build UNKNOWN@r; 2014-04-10 14:17:27-0400)
www.orientechnologies.com
Type 'help' to display all the commands supported.
Installing extensions for GREMLIN language v.2.5.0-SNAPSHOT
orientdb> connect remote:localhost:8424 myuser mypass
Connecting to remote Server instance [remote:localhost:8424] with user
'myuser'...OK
orientdb {remote:localhost:8424/}> list databases;
Found 10 databases:
* 1eb60ee7-71bf-4181-84a0-03c182395c6c (plocal)
* 796d8d95-2c4f-4b22-bfaf-066cd8e6a3e5 (plocal)
* 6608331f-f2cf-4e06-976f-25f6cafd8674 (plocal)
* bd063e03-9d9b-4ad1-8d25-16273a12ac35 (plocal)
* a62bcedf-ca9a-4b21-8a52-deba6e05febc (plocal)
* b2e9b2a4-5f48-4c17-8868-a22fad8c4e57 (plocal)
* 8f84c9b9-9222-4838-82b3-289f0a5d2596 (plocal)
* 982edaad-1c01-4f1e-b54c-e6d50c7429cf (plocal)
* 78a12091-70b1-4e66-a444-3885a697af99 (plocal)
* 8678f760-ba9d-4588-98af-27e9f7209c45 (plocal)
=======================================================================================
3. Connect to a graph fails.
=======================================================================================
orientdb {remote:localhost:8424/}> connect
remote:localhost:8424/1eb60ee7-71bf-4181-84a0-03c1823 myuser mypass
Disconnecting from remote server [remote:localhost:8424/]...
OK
Connecting to database
[remote:localhost:8424/1eb60ee7-71bf-4181-84a0-03c182395c6c] with user
'myuser'...
Error:
com.orientechnologies.orient.enterprise.channel.binary.OResponseProcessingException:
Exception during response processing.
Error: com.orientechnologies.orient.core.exception.OConfigurationException:
Database '1eb60ee7-71bf-4181-84a0-03c182395c6c' is not configured on server
=======================================================================================
4. Here is the code that starts the embedded server:
Set<Path> paths = new HashSet<Path>() {{
add(fs.getPath("/tmp/embedded/orientdb/conf"));
add(fs.getPath("/tmp/embedded/orientdb/www"));
add(fs.getPath("/tmp/embedded/orientdb/graphs"));
}};
for (Path p : paths) {
if ( ! Files.exists(p, java.nio.file.LinkOption.NOFOLLOW_LINKS) ) {
Files.createDirectories(p);
}
}
OServer server = OServerMain.create();
server.startup(
"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?>"
+ "<orient-server>"
+ "<network>"
+ "<protocols>"
+ "<protocol name=\"binary\"
implementation=\"com.orientechnologies.orient.server.network.protocol.binary.ONetworkProtocolBinary\"/>"
+ "<protocol name=\"http\"
implementation=\"com.orientechnologies.orient.server.network.protocol.http.ONetworkProtocolHttpDb\"/>"
+ "</protocols>"
+ "<listeners>"
+ "<listener ip-address=\"0.0.0.0\" port-range=\"8424-8430\"
protocol=\"binary\"/>"
+ "<listener ip-address=\"0.0.0.0\" port-range=\"8480-8490\"
protocol=\"http\"/>"
+ "</listeners>"
+ "</network>"
+ "<users>"
+ "<user name=\"fsmon\" password=\"fsm0n\" resources=\"*\"/>"
+ "</users>"
+ "<properties>"
+ "<entry name=\"server.database.path\"
value=\"/tmp/embedded/orientdb/graphs\" />"
+ "<entry name=\"orientdb.www.path\"
value=\"/tmp/embedded/orientdb/www\"/>"
+ "<entry name=\"orientdb.config.file\"
value=\"/tmp/embedded/orientdb/conf/config.xml\"/>"
+ "<entry name=\"server.cache.staticResources\" value=\"false\"/>"
+ "<entry name=\"log.console.level\" value=\"info\"/>"
+ "<entry name=\"log.file.level\" value=\"fine\"/>"
+ "<entry name=\"plugin.dynamic\" value=\"false\"/>"
+ "</properties>"
+ "</orient-server>");
server.activate();
Alan
On Thursday, April 10, 2014 2:43:03 AM UTC-7, Lvc@ wrote:
>
> Hi Alan,
> may you try with 1.7-SNAPSHOT?
>
> Lvc@
>
>
> On 10 April 2014 11:32, Alan Miller <[email protected] <javascript:>>wrote:
>
>> I'm trying to use the embedded server in my application.
>>
>> First I generated some OrientGraphNoTx graphs on disk.
>> Then I started an embedded server as described at
>> https://github.com/orientechnologies/orientdb/wiki/Embedded-Server
>>
>> [root@test] java -cp testing.jar com.company.Class -test server
>> ------------------------------------------------------------------------
>> -- this test starts an embedded server to serve the previously generated
>> graphs
>> ------------------------------------------------------------------------
>>
>> 2014-04-10 02:18:27:519 INFO Loading configuration from input stream
>> [OServerConfigurationLoaderXml]
>> 2014-04-10 02:18:27:872 INFO OrientDB Server v1.7-rc2 is starting up...
>> [OServer]
>> 2014-04-10 02:18:27:880 INFO Databases directory: /tmp/graphs [OServer]
>> 2014-04-10 02:18:27:921 INFO Listening binary connections on
>> 0.0.0.0:8424(protocol v.20) [OServerNetworkListener]
>> 2014-04-10 02:18:27:927 INFO Listening http connections on
>> 0.0.0.0:8480(protocol v.10) [OServerNetworkListener]
>> 2014-04-10 02:18:27:930 INFO OrientDB Server v1.7-rc2 is active. [OServer]
>>
>> I connect to the server instance and list databases shows my databases
>> but I cant connect to them. I used the "embedded config" option in the
>> wiki page.
>>
>> [root@test] ./console.sh
>>
>> OrientDB console v.1.7-rc2 (build UNKNOWN@r; 2014-03-25 15:54:54+0100)
>> www.orientechnologies.com
>> Type 'help' to display all the commands supported.
>> Installing extensions for GREMLIN language v.2.5.0-SNAPSHOT
>>
>> orientdb> connect remote:localhost:8424 root pass
>> Connecting to remote Server instance [remote:localhost:8424] with user
>> 'root'...OK
>> orientdb {remote:localhost:8424/}> list databases
>>
>> Found 10 databases:
>>
>> * dafb189b-5396-4799-bd02-d114d48959aa (plocal)
>> * 99e5147e-a031-47ce-a852-3ad284cb72c2 (plocal)
>> * 7f56f44e-09b6-4744-a789-917d7dd50688 (plocal)
>> * a2b28381-38f6-4bf8-b754-962b9d6a3be0 (plocal)
>> * abab31ba-3413-429c-917e-adabce07fa9f (plocal)
>> * 7f06aff9-db85-4bd1-91dd-32e3db1a72d2 (plocal)
>> * b4590602-fc27-4b2a-8a3e-a54073d087ca (plocal)
>> * a5ab5872-0302-4153-a70b-0b583b41dd16 (plocal)
>> * 526854b7-1787-46d1-979b-f9dae49ed315 (plocal)
>> * 445e7974-ab45-4c35-989d-3cc500ea2201 (plocal)
>>
>> orientdb {remote:localhost:8424/}> connect
>> remote:localhost:8424/dafb189b-5396-4799-bd02-d114d48959aa root pass
>>
>> Disconnecting from remote server [remote:localhost:8424/]...
>> OKConnecting to database
>> [remote:localhost:8424/dafb189b-5396-4799-bd02-d114d48959aa] with user
>> 'root'...
>> Error:
>> com.orientechnologies.orient.enterprise.channel.binary.OResponseProcessingException:
>>
>> Exception during response processing.
>> Error:
>> com.orientechnologies.orient.core.exception.OConfigurationException:
>> Database 'dafb189b-5396-4799-bd02-d114d48959aa' is not configured on server
>>
>> Alan
>>
>> --
>>
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "OrientDB" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to [email protected] <javascript:>.
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
--
---
You received this message because you are subscribed to the Google Groups
"OrientDB" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.