swagger-api / swagger-api/swagger-codegen

[JAVA] library property overrides/removes information

Open
#8,349 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Mustache
Stars
17.8k
Forks
6k
PR merge metrics
No merged PRs in 30d

Description

Description

When using the swagger-codegen-maven-plugin to generate a Java client, I set the regarding information of the developer, scm, description, etc. within the configOptions. Furthermore I set the library to use ('resteasy').

After I generated the client and checked the pom.xml the regarding information (developer, organization, description) were not set.

After removing the <library>resteasy</library> property, the defined information where available again.

Swagger-codegen version
<groupId>io.swagger</groupId>
<artifactId>swagger-codegen-maven-plugin</artifactId>
<version>2.3.1</version>
Configuration

<configOptions>
  <library>resteasy</library>
  <groupId>${project.groupId}</groupId>
  <artifactId>${project.artifactId}</artifactId>
  <artifactVersion>${project.version}</artifactVersion>
  <artifactDescription>A autogenerated ${project.artifactId} client. This client is generated by the produced swagger file of the server.</artifactDescription> <-- MISSING

  <developerName>A Name</developerName> <-- MISSING
  <developerEmail>mail@123.de</developerEmail> <-- MISSING
  <developerOrganization>${project.organization.name}</developerOrganization> <-- MISSING
  <developerOrganizationUrl>${project.organization.url}</developerOrganizationUrl> <-- MISSING

  <scmConnection>${project.scm.connection}</scmConnection>
  <scmDeveloperConnection>${project.scm.developerConnection}</scmDeveloperConnection>
  <scmUrl>${project.scm.url}</scmUrl>

  <java8>true</java8>

  <sourceFolder>src/gen/java/main</sourceFolder>
<configOptions>

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue with the supplied swagger-codegen-maven-plugin configuration, comparing generated pom.xml metadata with and without the resteasy library setting. Trace the Java client generation path and verify that developer, organization, description, and SCM values remain present when resteasy is selected.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
build-system, tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.