Skip to content

Updates necessary for the Heroku deployment #9

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 40 commits into
base: master
Choose a base branch
from

Conversation

berezovskyi
Copy link
Member

@berezovskyi berezovskyi commented May 10, 2019

Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
Signed-off-by: Andrew Berezovskyi <[email protected]>
@berezovskyi berezovskyi requested a review from jamsden May 10, 2019 14:39
@berezovskyi berezovskyi self-assigned this May 10, 2019
@berezovskyi
Copy link
Member Author

POST is now fixed but GET returns an empty response

@@ -1,7 +1,8 @@
{
"scheme": "http",
"host": "localhost",
"protocol": "http",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

scheme and host are the w3c names used in https://www.w3.org/Addressing/URL/url-spec.txt. These should be named using standard terms in the config.json file to avoid confusion. scheme is the name of the protocol to use, host is the name of the node to bind to.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have made this change so that the JSON keys match the attributes in the https://nodejs.org/docs/latest-v10.x/api/url.html

@@ -67,13 +67,13 @@ function ensureIndex() {
}

exports.init = function(env, callback) {
require('mongodb').connect(env.mongoURL, function(err, conn) {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have:

	const MongoClient = require('mongodb').MongoClient;
	const client = new MongoClient(env.mongoURL, { useNewUrlParser: true });
	client.connect(function(err, client) {
		if (err) {
			callback(err);
			return;
		}

		db = client.db(env.dbName);
		exports.graphs = graphs();
		console.log("Connected to MongoDB at: "+env.mongoURL);
		ensureIndex();

Here.

Copy link

@jamsden jamsden left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

n3 1.1.1 is the latest and requires significant changes in the Mongo db. Not sure this is worth doing in this sample app. ldp-service uses rdflib instead. Perhaps we should leave LDPjs alone and do new development in ldp-app, ldp-services.

@berezovskyi
Copy link
Member Author

Thanks Jim. Very likely I will abandon this patch. Let me try the ldp-app first.

@jamsden
Copy link

jamsden commented May 22, 2019

Note viz.js doesn't yet work on ldp-app because it had a hard dependency on the MongoDB representations of triples.

@berezovskyi berezovskyi removed their assignment Jul 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants