Discuss.FOLIO.org is no longer used. This is a static snapshot of the website as of February 14, 2023.

Starting own module

issam99
16 Jun '17

I have wirte own simple module folio-mymodule and did put it in folder okapi
ModuleDiscriptor.json

{
“id” : “mymodule”,
“name” : “Hello EBSCO”,
“provides” : [ {
“id” : “mymodule”,
“version” : “1.1”,
“handlers” : [ {
“methods” : [ “GET”, “POST” ],
“pathPattern” : “/mymodule”
} ]
} ],
“launchDescriptor” : {
“exec”:“folio-mymodule”
}
}
in purpose to test

  1. started okapi success
  2. in other terminal window curl -i -w ‘\n’ http://localhost:8080/mymodule
    error curl: (7) Failed to connect to localhost port 8080: Connection refused

what could be the issue ??

xley
22 Jun '17

It seems that you need to follow the Okapi Guide and Reference

For example, by default Okapi is running on port 9130, and (apart from the wrong port) that curl command is not complete.