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

fix: uploader panic under db access error #278

Merged
merged 4 commits into from
Apr 6, 2023
Merged

fix: uploader panic under db access error #278

merged 4 commits into from
Apr 6, 2023

Conversation

joeylichang
Copy link
Contributor

Description

  1. Polish uplader code
  2. Add SQLDB params to config, include: ConnMaxLifetime, ConnMaxIdleTime, MaxIdleConns, MaxOpenConns
  3. Add the params default values, if not set the config field will use the default value.
// SQLDB default configuration parmas
const (
	// DefaultConnMaxLifetime defines the default max liveness time of connection
	DefaultConnMaxLifetime = 3600
	// DefaultConnMaxIdleTime defines the default max idle time of connection
	DefaultConnMaxIdleTime = 60
	// DefaultMaxIdleConns defines the default max number of idle connections
	DefaultMaxIdleConns = 128
	// DefaultMaxOpenConns defines the default max number of open connections
	DefaultMaxOpenConns = 1024
)

Rationale

N/A

Example

N/A

Changes

Notable changes:
N/A

@joeylichang joeylichang changed the title Fix up fix: uploader panic under db access error Apr 5, 2023
@joeylichang joeylichang added the r4r Ready for review label Apr 5, 2023
Copy link
Collaborator

@sysvm sysvm left a comment

Choose a reason for hiding this comment

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

LGTM

@joeylichang joeylichang merged commit 55483fd into develop Apr 6, 2023
@joeylichang joeylichang deleted the fix-up branch April 6, 2023 03:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
r4r Ready for review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants