Yes, it behaves differently, but for me still in an odd way
With openapi I got only the context path and the value of apiHost option is
lost.
"servers": [
{
"url": "/foo"
}
], ...
Could you take a look at it?
-----Original Message-----
From: Claus Ibsen <[email protected]>
Sent: Wednesday, July 7, 2021 4:31 PM
To: [email protected]
Subject: Re: apiHost for swagger documentation
On 3.x try the openapi component instead of swagger
On Wed, 7 Jul 2021 at 15.20, <[email protected]> wrote:
> Well, I've just checked 3.11.0, result is the same Is apiHost supposed
> to be used this way?
>
> -----Original Message-----
> From: Ivanov, Grigorii <[email protected]>
> Sent: Wednesday, July 7, 2021 3:54 PM
> To: [email protected]
> Subject: RE: apiHost for swagger documentation
>
> Hi Claus,
> We are stuck with 2.23.3, but I have also tried it with 2.25.3, no
> luck Is this a bug of 2.x?
>
> -----Original Message-----
> From: Claus Ibsen <[email protected]>
> Sent: Wednesday, July 7, 2021 3:47 PM
> To: [email protected]
> Subject: Re: apiHost for swagger documentation
>
> What Camel version do you use?
>
> On Wed, Jul 7, 2021 at 2:34 PM <[email protected]> wrote:
> >
> >
> > Hi guys,
> > I found that there is an apiHost option for REST DSL, the
> > documentation states that it "can be used to override the generated
> > host with this configured hostname" -
> > https://camel.apache.org/manual/latest/rest-dsl.html#_configuring_re
> > st
> > _dsl
> > So I tried to use it like
> > <restConfiguration component="jetty" scheme="http"
> > apiHost="mycompany.com " host="localhost" port="8088"
> > contextPath="/foo" apiContextPath="api-doc"/>
> >
> > My intention was to get "mycompany.com" in swagger docs instead of
> "localhost", but it is not working this way, "localhost:8088" is still
> there. Please tell me where I am wrong?
> >
> > Best regards,
> > Grigorii Ivanov
>
>
>
> --
> Claus Ibsen
> -----------------
> http://davsclaus.com @davsclaus
> Camel in Action 2: https://www.manning.com/ibsen2
>
--
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2