Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/coderberry/appmap-test-app-fiber-graphql
Test app for https://github.com/getappmap/appmap-ruby/issues/349
https://github.com/coderberry/appmap-test-app-fiber-graphql
Last synced: 12 days ago
JSON representation
Test app for https://github.com/getappmap/appmap-ruby/issues/349
- Host: GitHub
- URL: https://github.com/coderberry/appmap-test-app-fiber-graphql
- Owner: coderberry
- Created: 2024-03-05T21:29:11.000Z (11 months ago)
- Default Branch: main
- Last Pushed: 2024-03-11T16:03:40.000Z (11 months ago)
- Last Synced: 2025-01-02T16:22:22.961Z (20 days ago)
- Language: Ruby
- Size: 40 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# AppMap + GraphQL + Fiber Bug
This app replicates the bug reported at https://github.com/getappmap/appmap-ruby/issues/349.
## Conditions
- Using the appmap gem
- Using the latest graphql gem
- `config.active_support.isolation_level = :fiber` in application.rb## Steps to reproduce
### 1. Prepare app
```bash
git clone [email protected]:coderberry/appmap-test-app-fiber-graphql.git
cd appmap-test-app-fiber-graphql
bin/setup
bin/rails db:migrate
bin/rails db:seed
```### 2. Run the app
```bash
bin/rails s
```### 3. Execute a query via GraphiQL
Open [http://locahost:3000/graphiql](http://localhost:3000/graphiql)) and execute the following query 5 times:
```graphql
query {
localCounts
}
```### 4. Observe the hung fibers
Ensure you are viewing the Rails server logs and sumbmit the request a 6th time. The request will hang and you will see that the connection pool was not cleaned up.
Example:
![CleanShot 2024-03-05 at 16 17 57](https://github.com/coderberry/appmap-test-app-fiber-graphql/assets/12481/c3287d73-fb38-47cd-ab44-c202e0a6507a)