Coder Social home page Coder Social logo

Comments (5)

mhjort avatar mhjort commented on September 23, 2024

Apparently there is an issue. However, I was unable to reproduce this. It is probably related to the scenario structure you had. Could you pass the details of the simulation you were running?

For example with this simulation defined in here: https://github.com/mhjort/clj-gatling-example/blob/master/src/clj_gatling_example/simulations.clj I was able to start it with concurrency 10000 (with my machine it is not possible to run properly with that kind of an concurrency but it does not crash)

from trombi.

ivos avatar ivos commented on September 23, 2024

There it is:

(ns net.company.project.load.simulations
  (:require [clojure.core.async :refer [chan go >!]]
            [org.httpkit.client :as http]
            ))

(defn create-pairing
  []
  {:name    "Customer: Create pairing"
   :request (fn [_]
              (let [response (chan)
                    process-result (fn [{:keys [status]}]
                                     (go
                                       (>! response [(and status (<= 200 status 299))])
                                       ))]
                (http/request {:method :post
                               :url    "http://localhost:8080/api/v1/pairings"}
                              process-result)
                response))})

(def purchase-simulation
  {:name      "Purchase simulation"
   :scenarios [
               {:name   "Happy purchase"
                :weight 100
                :steps  [
                         (create-pairing)
                         ]}
               {:name   "Canceled purchase"
                :weight 1
                :steps  [
                         (create-pairing)
                         ]}
               {:name   "Customer rejected purchase"
                :weight 1
                :steps  [
                         (create-pairing)
                         ]}
               {:name   "Balance rejected purchase"
                :weight 1
                :steps  [
                         (create-pairing)
                         ]}
               ]})

(def simulations
  {
   :purchase purchase-simulation
   })

I tried to cut down irrelevant things as much as possible. So e.g. those four "different" scenarios are meaningful, when I cut one out, the error goes away.

from trombi.

mhjort avatar mhjort commented on September 23, 2024

Thanks. I can now also reproduce the problem. I will investigate this one.

from trombi.

mhjort avatar mhjort commented on September 23, 2024

Found a root cause and managed to fix the bug. This is now fixed in 0.10.2

from trombi.

ivos avatar ivos commented on September 23, 2024

I confirm it is resolved. Thank you.

from trombi.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.