value feed is not a member of io.gatling.http.request.builder

ยอดดู 27 ครั้ง
ข้ามไปที่ข้อความที่ยังไม่อ่านรายการแรก

Toh Lay Mui

ยังไม่อ่าน,
8 ม.ค. 2565 08:48:258/1/65
ถึง Gatling User Group
I try to add feeder to read the value dynamically from the csv
file
but I got the error value feed is not a member of io.gatling.http.request.builder

here is my code snippet

val messageFeeder = csv("message.csv").random

val newMessage = exec(http("Create New Message") // Here's an example of a POST request
.post("/taqelah/messages/")
.feed(messageFeeder)
.body(StringBody("""{ "author": "CB", "message": "Speaking in tongue" }""")))
}

the github repo is at

Stéphane LANDELLE

ยังไม่อ่าน,
8 ม.ค. 2565 10:41:478/1/65
ถึง gat...@googlegroups.com
The compiler is telling you "feed" doesn't go there.
It goes at the same level as "exec".
--

Stéphane Landelle

Chief Technical Officer

   

slan...@gatling.io
gatling.io
   
facebook twitter linkedin 


--
You received this message because you are subscribed to the Google Groups "Gatling User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gatling+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gatling/0a83ca11-04c0-4b8f-b05e-df16a51761ben%40googlegroups.com.

Toh Lay Mui

ยังไม่อ่าน,
10 ม.ค. 2565 00:05:4310/1/65
ถึง gat...@googlegroups.com
Hi 
I have added the feeder to the right level

but in my test report it failed with this error
i.n.h.s.NotSslRecordException: not an SSL/TLS record: 485454502f312e3120343030200d0a436f6e74656e742d547970653a20746578742f68746d6c3b636861727365743d7574662d380d0a436f6e74656e742d4c616e67756167653a20656e0d0a436f6e74656e742d4c656e6774683a20323139330d0a446174653a204d6f6e2c203130204a616e20323032322030343a32393a343220474d540d0a436f6e6e656374696f6e3a20636c6f73650d0a0d0a3c21646f63747970652068746d6c3e3c68746d6c206c616e673d22656e223e3c686561643e3c7469746c653e48545450205374617475732034303020e280932042616420526571756573743c2f7469746c653e3c7374796c6520747970653d22746578742f637373223e626f6479207b666f6e742d66616d696c793a5461686f6d612c417269616c2c73616e732d73657269663b7d2068312c2068322c2068332c2062207b636f6c6f723a77686974653b6261636b67726f756e642d636f6c6f723a233532354437363b7d206831207b666f6e742d73697a653a323270783b7d206832207b666f6e742d73697a653a313670783b7d206833207b666f6e742d73697a653a313470783b7d2070207b666f6e742d73697a653a313270783b7d2061207b636f6c6f723a626c61636b3b7d202e6c696e65207b6865696768743a3170783b6261636b67726f756e642d636f6c6f723a233532354437363b626f726465723a6e6f6e653b7d3c2f7374796c653e3c2f686561643e3c626f64793e3c68313e48545450205374617475732034303020e280932042616420526571756573743c2f68313e3c687220636c6173733d226c696e6522202f3e3c703e3c623e547970653c2f623e20457863657074696f6e205265706f72743c2f703e3c703e3c623e4d6573736167653c2f623e20496e76616c69642063686172616374657220666f756e6420696e206d6574686f64206e616d65205b3078313630783033307830313078303030786531307830313078303030783030307864643078303330783033333078613628307830646d30786436336030783862307861333078316143307861323078663130786137307862622d24413b307862335b307830393078616630786530307866383078306130786633307863317d30783132605d2e2048545450206d6574686f64206e616d6573206d75737420626520746f6b656e733c2f703e3c703e3c623e4465736372697074696f6e3c2f623e20546865207365727665722063616e6e6f74206f722077696c6c206e6f742070726f636573732074686520726571756573742064756520746f20736f6d657468696e6720746861742069732070657263656976656420746f206265206120636c69656e74206572726f722028652e672e2c206d616c666f726d656420726571756573742073796e7461782c20696e76616c69642072657175657374206d657373616765206672616d696e672c206f7220646563657074697665207265717565737420726f7574696e67292e3c2f703e3c703e3c623e457863657074696f6e3c2f623e3c2f703e3c7072653e6a6176612e6c616e672e496c6c6567616c417267756d656e74457863657074696f6e3a20496e76616c69642063686172616374657220666f756e6420696e206d6574686f64206e616d65205b3078313630783033307830313078303030786531307830313078303030783030307864643078303330783033333078613628307830646d30786436336030783862307861333078316143307861323078663130786137307862622d24413b307862335b307830393078616630786530307866383078306130786633307863317d30783132605d2e2048545450206d6574686f64206e616d6573206d75737420626520746f6b656e730a096f72672e6170616368652e636f796f74652e6874747031312e487474703131496e7075744275666665722e7061727365526571756573744c696e6528487474703131496e7075744275666665722e6a6176613a343138290a096f72672e6170616368652e636f796f74652e6874747031312e48747470313150726f636573736f722e736572766963652848747470313150726f636573736f722e6a6176613a323630290a096f72672e6170616368652e636f796f74652e416273747261637450726f636573736f724c696768742e70726f6365737328416273747261637450726f636573736f724c696768742e6a6176613a3635290a096f72672e6170616368652e636f796f74652e416273747261637450726f746f636f6c24436f6e6e656374696f6e48616e646c65722e70726f6365737328416273747261637450726f746f636f6c2e6a6176613a383638290a096f72672e6170616368652e746f6d6361742e7574696c2e6e65742e4e696f456e64706f696e7424536f636b657450726f636573736f722e646f52756e284e696f456e64706f696e742e6a6176613a31353839290a096f72672e6170616368652e746f6d6361742e7574696c2e6e65742e536f636b657450726f636573736f72426173652e72756e28536f636b657450726f636573736f72426173652e6a6176613a3439290a096a6176612e62617365262334373b6a6176612e7574696c2e636f6e63757272656e742e546872656164506f6f6c4578656375746f722e72756e576f726b657228546872656164506f6f6c4578656375746f722e6a6176613a31313238290a096a6176612e62617365262334373b6a6176612e7574696c2e636f6e63757272656e742e546872656164506f6f6c4578656375746f7224576f726b65722e72756e28546872656164506f6f6c4578656375746f722e6a6176611100 %
here is my code snippet

class message extends Simulation{
val config = ConfigFactory.load()
val httpConf = http.baseUrl(config.getString("MESSAGE_BASE_URL"))

object Get {
val getByID = exec(http("Get Single Message")
.get("/taqelah/messages/2"))
}

object Create {

val newMessage = exec(http("Create New Message") // Here's an example of a POST request
.post("/taqelah/messages/")
.body(StringBody("""{ "author": "CB", "message": "Speaking in tongue" }""")))
}
val messageFeeder = csv("message.csv").random
val scn = scenario("CRUD on Message")
.exec(Get.getByID)
val user = scenario("Normal_Users") // For user
.exec(Get.getByID)
// .exec(Create.newMessage)
// .feed(messageFeeder)

setUp(
user.inject(atOnceUsers(1)),
// scn.inject(
// nothingFor(5.seconds),
// atOnceUsers(10),
// rampUsersPerSec(150) to 200 during(1 minutes))
).protocols(httpConf.inferHtmlResources())


}



--
ตอบทุกคน
ตอบกลับผู้สร้าง
ส่งต่อ
ข้อความใหม่ 0 รายการ