diff --git a/Documentation/UserManual/FirstStepsArangoDB.md b/Documentation/UserManual/FirstStepsArangoDB.md index 1ac8cd8407..b7be0e6a81 100644 --- a/Documentation/UserManual/FirstStepsArangoDB.md +++ b/Documentation/UserManual/FirstStepsArangoDB.md @@ -176,19 +176,26 @@ advantage that you can use auto-completion. ------------------------------------- Help ------------------------------------- Predefined objects: - arango: ArangoConnection - db: ArangoDatabase + arango: ArangoConnection + db: ArangoDatabase + fm: FoxxManager Example: - > db._collections(); list all collections - > db._create(); create a new collection - > db._drop(); drop a collection - > db..all(); list all documents - > id = db..save({ ... }); save a document - > db..remove(<_id>); delete a document - > db..document(<_id>); get a document - > help show help pages - > helpQueries query help - > exit + > db._collections(); list all collections + > db._create() create a new collection + > db._drop() drop a collection + > db..toArray() list all documents + > id = db..save({ ... }) save a document + > db..remove(<_id>) delete a document + > db..document(<_id>) retrieve a document + > db..replace(<_id>, {...}) overwrite a document + > db..update(<_id>, {...}) partially update a document + > db..exists(<_id>) check if document exists + > db._query().toArray() execute an AQL query + > db._useDatabase() switch database + > db._createDatabase() create a new database + > db._listDatabases() list existing databases + > help show help pages + > exit arangosh> This gives you a prompt, where you can issue JavaScript commands. @@ -273,10 +280,7 @@ Querying For Documents {#FirstStepsArangoDBQuerying} ---------------------------------------------------- All documents are stored in collections. All collections are stored in a -database. The database object is accessible there the variable `db` from -the module - - arangosh> var db = require("org/arangodb").db; +database. The database object is accessible via the variable `db`. Creating a collection is simple. You can use the `_create` method of the `db` variable. diff --git a/UnitTests/Basics/EndpointTest.cpp b/UnitTests/Basics/EndpointTest.cpp index 9a08fcafff..04b5d507ba 100644 --- a/UnitTests/Basics/EndpointTest.cpp +++ b/UnitTests/Basics/EndpointTest.cpp @@ -55,6 +55,11 @@ using namespace std; BOOST_CHECK_EQUAL(expected, e->FEATURE_NAME(feature)()); \ DELETE_ENDPOINT(e); +#define CHECK_ENDPOINT_SERVER_FEATURE(type, specification, feature, expected) \ + e = Endpoint::serverFactory(specification, 1, true); \ + BOOST_CHECK_EQUAL(expected, e->FEATURE_NAME(feature)()); \ + DELETE_ENDPOINT(e); + // ----------------------------------------------------------------------------- // --SECTION-- setup / tear-down // ----------------------------------------------------------------------------- @@ -121,8 +126,9 @@ BOOST_AUTO_TEST_CASE (EndpointSpecification) { CHECK_ENDPOINT_FEATURE(client, "tcp://localhost", Specification, "tcp://localhost"); CHECK_ENDPOINT_FEATURE(client, "SSL://127.0.0.5", Specification, "SSL://127.0.0.5"); CHECK_ENDPOINT_FEATURE(client, "httP@ssl://localhost:4635", Specification, "httP@ssl://localhost:4635"); - CHECK_ENDPOINT_FEATURE(server, "unix:///path/to/socket", Specification, "unix:///path/to/socket"); - CHECK_ENDPOINT_FEATURE(server, "htTp@UNIx:///a/b/c/d/e/f.s", Specification, "htTp@UNIx:///a/b/c/d/e/f.s"); + + CHECK_ENDPOINT_SERVER_FEATURE(server, "unix:///path/to/socket", Specification, "unix:///path/to/socket"); + CHECK_ENDPOINT_SERVER_FEATURE(server, "htTp@UNIx:///a/b/c/d/e/f.s", Specification, "htTp@UNIx:///a/b/c/d/e/f.s"); } //////////////////////////////////////////////////////////////////////////////// @@ -138,11 +144,11 @@ BOOST_AUTO_TEST_CASE (EndpointTypes) { CHECK_ENDPOINT_FEATURE(client, "ssl://localhost", Type, Endpoint::ENDPOINT_CLIENT); CHECK_ENDPOINT_FEATURE(client, "unix:///path/to/socket", Type, Endpoint::ENDPOINT_CLIENT); - CHECK_ENDPOINT_FEATURE(server, "tcp://127.0.0.1", Type, Endpoint::ENDPOINT_SERVER); - CHECK_ENDPOINT_FEATURE(server, "tcp://localhost", Type, Endpoint::ENDPOINT_SERVER); - CHECK_ENDPOINT_FEATURE(server, "ssl://127.0.0.1", Type, Endpoint::ENDPOINT_SERVER); - CHECK_ENDPOINT_FEATURE(server, "ssl://localhost", Type, Endpoint::ENDPOINT_SERVER); - CHECK_ENDPOINT_FEATURE(server, "unix:///path/to/socket", Type, Endpoint::ENDPOINT_SERVER); + CHECK_ENDPOINT_SERVER_FEATURE(server, "tcp://127.0.0.1", Type, Endpoint::ENDPOINT_SERVER); + CHECK_ENDPOINT_SERVER_FEATURE(server, "tcp://localhost", Type, Endpoint::ENDPOINT_SERVER); + CHECK_ENDPOINT_SERVER_FEATURE(server, "ssl://127.0.0.1", Type, Endpoint::ENDPOINT_SERVER); + CHECK_ENDPOINT_SERVER_FEATURE(server, "ssl://localhost", Type, Endpoint::ENDPOINT_SERVER); + CHECK_ENDPOINT_SERVER_FEATURE(server, "unix:///path/to/socket", Type, Endpoint::ENDPOINT_SERVER); } //////////////////////////////////////////////////////////////////////////////// @@ -460,7 +466,7 @@ BOOST_AUTO_TEST_CASE (EndpointHostString) { BOOST_AUTO_TEST_CASE (EndpointIsConnectedServer1) { Endpoint* e; - e = Endpoint::serverFactory("tcp://127.0.0.1"); + e = Endpoint::serverFactory("tcp://127.0.0.1", 1, true); BOOST_CHECK_EQUAL(false, e->isConnected()); DELETE_ENDPOINT(e); } @@ -472,7 +478,7 @@ BOOST_AUTO_TEST_CASE (EndpointIsConnectedServer1) { BOOST_AUTO_TEST_CASE (EndpointIsConnectedServer2) { Endpoint* e; - e = Endpoint::serverFactory("ssl://127.0.0.1"); + e = Endpoint::serverFactory("ssl://127.0.0.1", 1, true); BOOST_CHECK_EQUAL(false, e->isConnected()); DELETE_ENDPOINT(e); } @@ -484,7 +490,7 @@ BOOST_AUTO_TEST_CASE (EndpointIsConnectedServer2) { BOOST_AUTO_TEST_CASE (EndpointIsConnectedServer3) { Endpoint* e; - e = Endpoint::serverFactory("unix:///tmp/socket"); + e = Endpoint::serverFactory("unix:///tmp/socket", 1, true); BOOST_CHECK_EQUAL(false, e->isConnected()); DELETE_ENDPOINT(e); } @@ -532,7 +538,7 @@ BOOST_AUTO_TEST_CASE (EndpointIsConnectedClient3) { BOOST_AUTO_TEST_CASE (EndpointServerTcpIpv4WithPort) { Endpoint* e; - e = Endpoint::serverFactory("tcp://127.0.0.1:667"); + e = Endpoint::serverFactory("tcp://127.0.0.1:667", 1, true); BOOST_CHECK_EQUAL("tcp://127.0.0.1:667", e->getSpecification()); BOOST_CHECK_EQUAL(Endpoint::ENDPOINT_SERVER, e->getType()); BOOST_CHECK_EQUAL(Endpoint::DOMAIN_IPV4, e->getDomainType()); @@ -552,7 +558,7 @@ BOOST_AUTO_TEST_CASE (EndpointServerTcpIpv4WithPort) { BOOST_AUTO_TEST_CASE (EndpointServerUnix) { Endpoint* e; - e = Endpoint::serverFactory("unix:///path/to/arango.sock"); + e = Endpoint::serverFactory("unix:///path/to/arango.sock", 1, true); BOOST_CHECK_EQUAL("unix:///path/to/arango.sock", e->getSpecification()); BOOST_CHECK_EQUAL(Endpoint::ENDPOINT_SERVER, e->getType()); BOOST_CHECK_EQUAL(Endpoint::DOMAIN_UNIX, e->getDomainType()); diff --git a/arangod/V8Server/v8-actions.cpp b/arangod/V8Server/v8-actions.cpp index 6bc3ef7dea..088b3d2267 100644 --- a/arangod/V8Server/v8-actions.cpp +++ b/arangod/V8Server/v8-actions.cpp @@ -893,14 +893,8 @@ static v8::Handle JS_ExecuteGlobalContextFunction (v8::Arguments cons //////////////////////////////////////////////////////////////////////////////// static v8::Handle JS_DefinePeriodic (v8::Arguments const& argv) { - v8::Isolate* isolate; - - TRI_v8_global_t* v8g; v8::HandleScope scope; - isolate = v8::Isolate::GetCurrent(); - v8g = (TRI_v8_global_t*) isolate->GetData(); - if (argv.Length() != 5) { TRI_V8_EXCEPTION_USAGE(scope, "definePeriodic(, , , , )"); } diff --git a/etc/arangodb/arangod.conf.in b/etc/arangodb/arangod.conf.in index 15150d4b13..a94a210c7a 100644 --- a/etc/arangodb/arangod.conf.in +++ b/etc/arangodb/arangod.conf.in @@ -1,4 +1,4 @@ -# AragoDB configuration file +# ArangoDB configuration file # # Documentation: # http://www.arangodb.org/manuals/current/CommandLine.html diff --git a/etc/relative/arangod.conf b/etc/relative/arangod.conf index 374c49c930..12859e8b52 100644 --- a/etc/relative/arangod.conf +++ b/etc/relative/arangod.conf @@ -7,6 +7,7 @@ disable-authentication = true endpoint = tcp://localhost:8529 threads = 5 +reuse-address = true [scheduler] threads = 3 diff --git a/js/apps/system/aardvark/frontend/css/documentView.css b/js/apps/system/aardvark/frontend/css/documentView.css index 6276420c76..4f591232e8 100644 --- a/js/apps/system/aardvark/frontend/css/documentView.css +++ b/js/apps/system/aardvark/frontend/css/documentView.css @@ -151,3 +151,11 @@ table.dataTable thead th { #saveDocumentButton { margin-top: 5px; } + +#showSaveState { + display:none; + color: green; + float:right; + margin-top: 10px; + font-weight: 300; +} diff --git a/js/apps/system/aardvark/frontend/html/body.html.part b/js/apps/system/aardvark/frontend/html/body.html.part index 82ad661fc9..09660cbc66 100644 --- a/js/apps/system/aardvark/frontend/html/body.html.part +++ b/js/apps/system/aardvark/frontend/html/body.html.part @@ -9,6 +9,8 @@
+
+
diff --git a/js/apps/system/aardvark/frontend/js/routers/router.js b/js/apps/system/aardvark/frontend/js/routers/router.js index 1c5e8624cf..1ce7aecac5 100644 --- a/js/apps/system/aardvark/frontend/js/routers/router.js +++ b/js/apps/system/aardvark/frontend/js/routers/router.js @@ -72,7 +72,8 @@ this.footerView = new window.FooterView(); this.naviView = new window.NavigationView({ - notificationCollection: this.notificationList + notificationCollection: this.notificationList, + userCollection: window.userCollection }); this.footerView.render(); this.naviView.render(); diff --git a/js/apps/system/aardvark/frontend/js/templates/addNewGraphView.ejs b/js/apps/system/aardvark/frontend/js/templates/addNewGraphView.ejs index 7cd19375fc..194b32e5c7 100644 --- a/js/apps/system/aardvark/frontend/js/templates/addNewGraphView.ejs +++ b/js/apps/system/aardvark/frontend/js/templates/addNewGraphView.ejs @@ -1,4 +1,4 @@ - diff --git a/js/apps/system/aardvark/frontend/js/templates/documentView.ejs b/js/apps/system/aardvark/frontend/js/templates/documentView.ejs index c5bb22531e..19bad37246 100644 --- a/js/apps/system/aardvark/frontend/js/templates/documentView.ejs +++ b/js/apps/system/aardvark/frontend/js/templates/documentView.ejs @@ -8,6 +8,7 @@
+
Saved...
diff --git a/js/apps/system/aardvark/frontend/js/templates/navigationView.ejs b/js/apps/system/aardvark/frontend/js/templates/navigationView.ejs index 87a8213a2f..98662a439c 100644 --- a/js/apps/system/aardvark/frontend/js/templates/navigationView.ejs +++ b/js/apps/system/aardvark/frontend/js/templates/navigationView.ejs @@ -5,10 +5,12 @@
  • Collections
  • Graphs
  • - + +
  • + Applications +
  • AQL Editor
  • - - +