Skip to content

Commit

Permalink
[#128] added log example to readme and config explanation
Browse files Browse the repository at this point in the history
  • Loading branch information
rpbaltazar committed Dec 17, 2020
1 parent 99ae4d7 commit 0f1c28c
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -338,6 +338,21 @@ Apartment.configure do |config|
end
```

### Additional logging information

Enabling this configuration will output the database that the process is currently connected to as well as which
schemas are in the search path. This can be enabled by setting to true the `active_record_log` configuration.

**Example log output:**

<img src="documentation/images/log_example.png">

```ruby
Apartment.configure do |config|
active_record_log = true
end
```

### Excluding models

If you have some models that should always access the 'public' tenant, you can specify this by configuring Apartment using `Apartment.configure`. This will yield a config object for you. You can set excluded models like so:
Expand Down
Binary file added documentation/images/log_example.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 0f1c28c

Please sign in to comment.