Skip to content
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

refactor: normalize database structure #1376

Merged
merged 2 commits into from
Sep 4, 2018

Conversation

XadillaX
Copy link
Member

@XadillaX XadillaX commented Sep 4, 2018

Some points:

  • let module name be 214. (refer)
  • indexes (docs/db.sql only):
    • let uniq indexes starts with uk_;
    • let other indexes starts with idx_;

Because sqlite's index namespace is the whole database, two tables can't have the same index name. I didn't add the index names to models/*.js.

@codecov-io
Copy link

codecov-io commented Sep 4, 2018

Codecov Report

❗ No coverage uploaded for pull request base (master@3141437). Click here to learn what that means.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##             master    #1376   +/-   ##
=========================================
  Coverage          ?   86.88%           
=========================================
  Files             ?       88           
  Lines             ?     3759           
  Branches          ?      723           
=========================================
  Hits              ?     3266           
  Misses            ?      493           
  Partials          ?        0
Impacted Files Coverage Δ
models/download_total.js 100% <ø> (ø)
models/module_deps.js 100% <ø> (ø)
models/module_unpublished.js 100% <ø> (ø)
models/module.js 100% <ø> (ø)
models/total.js 16.66% <ø> (ø)
models/tag.js 100% <ø> (ø)
models/module_maintainer.js 100% <ø> (ø)
models/user.js 91.66% <ø> (ø)
models/module_keyword.js 100% <ø> (ø)
models/module_log.js 100% <ø> (ø)
... and 4 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3141437...2b54748. Read the comment docs.

@fengmk2
Copy link
Member

fengmk2 commented Sep 4, 2018

+1

@fengmk2 fengmk2 merged commit 26d7147 into cnpm:master Sep 4, 2018
PRIMARY KEY (`id`),
UNIQUE KEY `module_maintainer_user_name` (`user`,`name`),

Choose a reason for hiding this comment

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

Magdi _ail_alhad

Mg303030 added a commit to Mg303030/cnpmjs.org that referenced this pull request Jul 15, 2019
liuweifeng pushed a commit to liuweifeng/cnpmjs.org that referenced this pull request Jul 27, 2021
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.

None yet

4 participants