jabref icon indicating copy to clipboard operation
jabref copied to clipboard

Reconnect to a shared database at startup

Open kotecky opened this issue 1 year ago • 16 comments

Improvement suggestion A setting to open last edited libraries at startup exists: image

In the current state the shared database needs to be reopened manually at each startup (File > Shared database > Connect). Instead, the above or a separate setting should include automatic re-connection to a shared database at startup.

kotecky avatar Mar 30 '23 07:03 kotecky

Can I take this ?

NS404 avatar Apr 14 '23 12:04 NS404

Sure :-) Are you a student?

ThiloteE avatar Apr 14 '23 13:04 ThiloteE

No. I am self-taught

NS404 avatar Apr 14 '23 13:04 NS404

@NS404 Yeah ;) Tip: If you don't want to setup mysql/postgres locally, you can quickly get a free postgres db here https://www.elephantsql.com/

Siedlerchr avatar Apr 14 '23 14:04 Siedlerchr

I encountered this while reading the docs Very useful, I appreciate the tip!

NS404 avatar Apr 14 '23 15:04 NS404

Hi @kotecky! You can save the shared database locally in a file so that the open last edited libraries at startup setting can work on your shared databases too. I am trying to understand whether this feature is excessive.

NS404 avatar May 08 '23 08:05 NS404

Hi @NS404 I'm probably missing something ;-) how will saving the DB locally save me time with not reconnecting to the online DB?

kotecky avatar May 08 '23 09:05 kotecky

I mean save it as a local file either by checking the box 'Automatically save the library to' when trying to connect for the first time or using Ctrl + S when the tab is in focus

NS404 avatar May 08 '23 10:05 NS404

Tested and now i see. Indeed, it works for the need described above: Jabref opens the bib file at startup and connects to the online database. I wonder still, whether this process will not create different versions of the bib-file when used by several people at once (which is the goal of the online database).

kotecky avatar May 08 '23 11:05 kotecky

the changes made in the file are passed in the server instantly.

NS404 avatar May 08 '23 11:05 NS404

but changes made to the server are not being pulled automatically, nor does an option exist to pull changes manually. Only closing and reopening the file seems to do the update.

NS404 avatar May 08 '23 12:05 NS404

Another issue I see is the fact that I can open a file that connects to a shared db and also connect to that same database via normal procedure. As a result I get two tabs with the same library. Maybe this shouldn't be allowed?

Screenshot 2023-05-09 093542

NS404 avatar May 08 '23 12:05 NS404

but changes made to the server are not being pulled automatically

Well, this makes it useless, a pity...

kotecky avatar May 08 '23 12:05 kotecky

@NS404 it would be greate if you could check why the changes are not pulled after reconnecting. imho this should always be done to make sure we have the last version

Siedlerchr avatar May 08 '23 12:05 Siedlerchr

Currently there are two ways of connecting to a shared DB: through a file or through the UI. The issue with the first way is that it doesn't let you pull changes without closing and reopening the file (The action to pull changes from shared side is disabled Ctrl+Shift+R).

NS404 avatar May 11 '23 14:05 NS404

Hi @kotecky! You can save the shared database locally in a file so that the open last edited libraries at startup setting can work on your shared databases too. I am trying to understand whether this feature is excessive.

To answer my initial question: I think that currently, using the file opening feature won't do the job as I explained above.

but changes made to the server are not being pulled automatically, nor does an option exist to pull changes manually. Only closing and reopening the file seems to do the update.

NS404 avatar May 30 '23 04:05 NS404