BMSearch introduction
更新日期:
Introduction
One side, I love chrome’s bookmark because it’s so convenient to manage all the web resource I cherished. But on the other side, I can’t help complaining its simplicity. Here is what bother me most:
With several year’s accumulation, it becomes extremely hard to find what I want from such a messy url collection. How many times I have to go through each of bookmark folders to find the target. What was worse, it’s very likely you have no idea to your bookmark until you open the url and see the resource.
Considering the network condition of China, it’s a great pain to re-open the bookmark since some request is hard to retrieve back, especially those resource whose server is outside of mainland. Re-opening bookmark is time-consuming.
You have no idea when your bookmark is no longer available. Maybe author deletes their article or maybe the website is blocked according to some policy.
Since chrome has been driven out of China, we can’t sync its bookmarks between different platform. I always worry about one day I may loss all of my bookmarks since it’s not portable.
All in all, chrome’s bookmarks can’t fully support my requirement. So I decide to maintain and extend the bookmarks all by myself.
In order to maintain bookmark and achieve the functionality that I ask for, I plan to design and implement ‘Bookmark Search Manager’ project. Let’s call it ‘BSM’ for short.
Here is brief list of its features.
Manage bookmarks by user
BSM is basing on membership. User need to register as its member at first and all the functionality are not available until he has logged in.
Branch-based management
User can create/update bookmark repository by uploading chrome’s bookmark to BSM. Each update will only merge the diff to the branch and all the commit will be recorded so that it’s possible for user to switch to any version he wants. Actually, we call it go forward and back mechanism just as browser’s go back/forward button.
Offline bookmarks
BSM will do crawling for each of the bookmark automatically so that user can access the resource behind the bookmark offline without being scared of resource unavailable.
Show summary for bookmark
User can add summary for each of bookmark and BSM will show title and summary of bookmark to user. This will help user have a better understanding of the resource and focus on what they are truly interested in.
Filter bookmarks by its organization
Currently, chrome’s bookmark is organized by folder. So it’s reasonable to provide a folder-based filter mechanism that user can choose a folder to see the bookmark under that folder. Maybe we can provide multiple selection.
Provide search functionality for bookmark
Ideally, I want to provide search functionality for the whole website. User can search the specific bookmark according to the keywords he inputs.
Support for multiple bookmarks
Where the idea come from?
To be frank, a well constructed bookmark manager is really something that I desired but it doesn’t worth my so much leisure time to solve such kind of a simple bothering.
Two years has past since I graduated from college. In my past two years, I learned a lot of new technologies, including: ruby on rails, restful api, elasticsearch, angularjs, dojo, easyui.
I’m always wondering do I really make any progress? do I fully understand those technologies? their usage? the mechanism behind them? are they still separated technologies for me or I can consider them as an integrated solution? With those confusion, I decide to take some action and do something with those new skill.
Architecture
Here is the architecture for Bookmark Search Manager
Front-end: AngularJS + Bootstrap
BSM is a single page application.
Web Server: ruby on rails
Currently, I adopt webrick as BSM’s web server
Web API: Grape
Database: ElasticSearch
I use ElasticSearch to replace DB.
Index Engine: Tika + ElastiSearch
when and how to index resource is not decided yet
If everything goes well, I’d like to rebuild BSM with the technologies that I’m fond of.
Front-end: AngularJS + Bootstrap
BSM is a single page application.
Web Server: Nodejs + Express
Database: MongoDB
Index Engine: Tika + ElastiSearch
when and how to index resource is not decided yet
Detail Design
Detail Design for Front End
GUI should contains the following page:
Login
User can log in
Dashboard
User can see all the bookmarks on this page
User can filter the bookmarks
User can add summary for bookmark
User can preview bookmark
Search
User can search specific markbooks by keywords
Config
User can create new repository
User can update the repository
User can view the commit history
User can switch branch
CUI should contains the following modules (I have implemented them in my daily work):
Authorization (access controll)
Browser Check
Localization (i18n/L10)
Route control
Error Handling
Detail Design for Web Service
Web Service should contains four controllers:
Application_Controller
Check for authentication and session timeout
Auth_Controller
Responsible for authentication
Bookmark_Controller
Serve for dashboard page
Config_Controller
Serve for config page
Search_Controller
Serve for search page