dbviewer 0.5.4 → 0.5.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5f0218efe5ea6bc79f61ca87472b6b413916b82e3aedf28e6030c37f302b2ca3
|
4
|
+
data.tar.gz: 65c58c041d85f80f0ad609e54225ec9c5bf3707bc36954ea07c36b95eb69a23c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 15b2f9f0cf3543c59bc0230ef23070b93d64c7038387e8d384aa2613ef0f28badec97957c2b3d48ab991da86f22f48e9fd71a41844d9247d4cf3d8c015f46331
|
7
|
+
data.tar.gz: 05a6f0cfdd61f901a6dd17edbcd2a93c5244f461a4bfe61b350c2ed864af7e83ed1afa6489a8d2d0e81a66b307d0aa65ea8b81c080a4dc3cca896cec4ee20598
|
data/README.md
CHANGED
@@ -111,7 +111,7 @@ This is necessary because API-only Rails applications don't include the Flash mi
|
|
111
111
|
You can configure DBViewer by using our generator to create an initializer in your application:
|
112
112
|
|
113
113
|
```bash
|
114
|
-
rails generate dbviewer:
|
114
|
+
rails generate dbviewer:install
|
115
115
|
```
|
116
116
|
|
117
117
|
This will create a file at `config/initializers/dbviewer.rb` with the default configuration:
|
@@ -172,7 +172,7 @@ config.query_logging_mode = :file # Store queries in a log file
|
|
172
172
|
config.query_log_path = "log/dbviewer.log" # Path where query log file will be stored
|
173
173
|
```
|
174
174
|
|
175
|
-
The file format uses one JSON entry per line, making it easy to analyze with standard tools.
|
175
|
+
The file format uses one JSON entry per line, making it easy to analyze with standard tools. Query Log collector are disabled by default on non development environtment.
|
176
176
|
|
177
177
|
## 🔒 Security Features
|
178
178
|
|
@@ -226,7 +226,7 @@ With the addition of Basic Authentication, DBViewer can now be used in any envir
|
|
226
226
|
3. Access the tool through your regular application URL:
|
227
227
|
|
228
228
|
```
|
229
|
-
https://yourdomain.com/dbviewer
|
229
|
+
https://yourdomain.com/dbviewer
|
230
230
|
```
|
231
231
|
|
232
232
|
## 📝 Security Note
|
@@ -334,6 +334,7 @@ gem build dbviewer.gemspec
|
|
334
334
|
3. The dummy app includes sample data across multiple tables to test various DBViewer features
|
335
335
|
|
336
336
|
### Architecture Diagram
|
337
|
+
|
337
338
|
```mermaid
|
338
339
|
graph TB
|
339
340
|
subgraph "DBViewer Engine"
|
data/lib/dbviewer/version.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
module Dbviewer
|
2
2
|
module Generators
|
3
|
-
class
|
3
|
+
class InstallGenerator < Rails::Generators::Base
|
4
4
|
source_root File.expand_path("../templates", __FILE__)
|
5
5
|
desc "Creates a DBViewer initializer file at config/initializers/dbviewer.rb"
|
6
6
|
|
@@ -1,21 +1,21 @@
|
|
1
1
|
Dbviewer.configure do |config|
|
2
|
-
config.per_page_options = [ 10, 20, 50, 100, 250 ]
|
3
|
-
config.default_per_page =
|
4
|
-
config.max_query_length = 10000
|
5
|
-
config.cache_expiry = 300
|
6
|
-
config.max_records = 10000
|
7
|
-
config.enable_data_export = false
|
8
|
-
config.query_timeout = 30
|
2
|
+
config.per_page_options = [ 10, 20, 50, 100, 250 ] # Default pagination options
|
3
|
+
config.default_per_page = 50 # Default records per page
|
4
|
+
config.max_query_length = 10000 # Maximum SQL query length
|
5
|
+
config.cache_expiry = 300 # Cache expiration in seconds
|
6
|
+
config.max_records = 10000 # Maximum records to return in any query
|
7
|
+
config.enable_data_export = false # Whether to allow data exporting
|
8
|
+
config.query_timeout = 30 # SQL query timeout in seconds
|
9
9
|
|
10
10
|
# Query logging options
|
11
|
-
config.enable_query_logging =
|
12
|
-
config.query_logging_mode = :memory
|
13
|
-
config.query_log_path = "log/dbviewer.log"
|
14
|
-
config.max_memory_queries = 1000
|
11
|
+
config.enable_query_logging = true # Enable or disable query logging completely (default: true)
|
12
|
+
config.query_logging_mode = :file # Storage mode for SQL queries (:memory or :file)
|
13
|
+
config.query_log_path = "log/dbviewer.log" # Path for query log file when in :file mode
|
14
|
+
config.max_memory_queries = 1000 # Maximum number of queries to store in memory
|
15
15
|
|
16
|
-
# Authentication options
|
17
|
-
# config.admin_credentials = {
|
18
|
-
|
19
|
-
#
|
20
|
-
|
16
|
+
# Authentication options (Basic Auth)
|
17
|
+
# config.admin_credentials = {
|
18
|
+
# username: "admin",
|
19
|
+
# password: "your_secure_password"
|
20
|
+
# }
|
21
21
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dbviewer
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Wailan Tirajoh
|
@@ -99,7 +99,7 @@ files:
|
|
99
99
|
- lib/dbviewer/storage/file_storage.rb
|
100
100
|
- lib/dbviewer/storage/in_memory_storage.rb
|
101
101
|
- lib/dbviewer/version.rb
|
102
|
-
- lib/generators/dbviewer/
|
102
|
+
- lib/generators/dbviewer/install_generator.rb
|
103
103
|
- lib/generators/dbviewer/templates/initializer.rb
|
104
104
|
- lib/tasks/dbviewer_tasks.rake
|
105
105
|
homepage: https://github.com/wailantirajoh/dbviewer
|