{"action":"opened","issue":{"url":"https://api.github.com/repos/swagger-api/swagger-codegen/issues/4298","repository_url":"https://api.github.com/repos/swagger-api/swagger-codegen","labels_url":"https://api.github.com/repos/swagger-api/swagger-codegen/issues/4298/labels{/name}","comments_url":"https://api.github.com/repos/swagger-api/swagger-codegen/issues/4298/comments","events_url":"https://api.github.com/repos/swagger-api/swagger-codegen/issues/4298/events","html_url":"https://github.com/swagger-api/swagger-codegen/issues/4298","id":192645373,"number":4298,"title":"[Java] Cannot build code generated by Maven plugin","user":{"login":"tadhgpearson","id":1496586,"avatar_url":"https://avatars.githubusercontent.com/u/1496586?v=3","gravatar_id":"","url":"https://api.github.com/users/tadhgpearson","html_url":"https://github.com/tadhgpearson","followers_url":"https://api.github.com/users/tadhgpearson/followers","following_url":"https://api.github.com/users/tadhgpearson/following{/other_user}","gists_url":"https://api.github.com/users/tadhgpearson/gists{/gist_id}","starred_url":"https://api.github.com/users/tadhgpearson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tadhgpearson/subscriptions","organizations_url":"https://api.github.com/users/tadhgpearson/orgs","repos_url":"https://api.github.com/users/tadhgpearson/repos","events_url":"https://api.github.com/users/tadhgpearson/events{/privacy}","received_events_url":"https://api.github.com/users/tadhgpearson/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-11-30T18:41:00Z","updated_at":"2016-11-30T18:41:00Z","closed_at":null,"body":"##### Description\r\n\r\nI'm using the Maven plugin to generate Java code. Following the generation, I get errors compiling the generated code such as:\r\n```\r\npackage com.google.gson.annotations does not exist\r\npackage okio does not exist\r\n```\r\nI'm surprised because I expect _Jersey client 1.18. JSON processing: Jackson 2.4.2_ to be used, as documented in the readme - why do I need GSON or OKIO. If I do, I can't find which dependencies I would need to add to resolve this issue - I am using the examples in the swagger-maven-plugin documentation,  but the build is still failing\r\n\r\n##### Swagger-codegen version\r\n2.2.1 - it was working in 2.1.6\r\n\r\n##### Swagger declaration file content or url\r\nhttps://github.com/amadeus-travel-innovation-sandbox/sandbox-content/blob/master/swagger.yml\r\n\r\n##### Command line used for generation\r\nCodegen config\r\n\r\n```\r\n\t\t\t\t\t\t<configuration>\r\n\t\t\t\t\t\t\t<inputSpec>https://raw.githubusercontent.com/amadeus-travel-innovation-sandbox/sandbox-content/master/swagger.yml</inputSpec>\r\n\t\t\t\t\t\t\t<language>java</language>\r\n\t\t\t\t\t\t\t<configOptions>\r\n\t\t\t\t\t\t\t   <dateLibrary>joda</dateLibrary>\r\n\t\t\t\t\t\t\t</configOptions>\r\n\t\t\t\t\t\t\t<output>${project.build.directory}/generated-sources/swagger</output>\r\n\t\t\t\t\t\t</configuration>\r\n```\r\n\r\nDependencies and properties\r\n\t```\r\n<dependencies>\r\n        <!-- dependencies are needed for the client being generated -->\r\n        <dependency>\r\n            <groupId>io.swagger</groupId>\r\n            <artifactId>swagger-annotations</artifactId>\r\n            <version>${swagger-annotations-version}</version>\r\n        </dependency>\r\n\r\n        <!-- HTTP client: jersey-client -->\r\n        <dependency>\r\n            <groupId>org.glassfish.jersey.core</groupId>\r\n            <artifactId>jersey-client</artifactId>\r\n            <version>${jersey-version}</version>\r\n        </dependency>\r\n        <dependency>\r\n            <groupId>org.glassfish.jersey.media</groupId>\r\n            <artifactId>jersey-media-multipart</artifactId>\r\n            <version>${jersey-version}</version>\r\n        </dependency>\r\n        <dependency>\r\n            <groupId>org.glassfish.jersey.media</groupId>\r\n            <artifactId>jersey-media-json-jackson</artifactId>\r\n            <version>2.22.1</version>\r\n        </dependency>\r\n\r\n        <!-- JSON processing: jackson -->\r\n        <dependency>\r\n            <groupId>com.fasterxml.jackson.core</groupId>\r\n            <artifactId>jackson-core</artifactId>\r\n            <version>${jackson-version}</version>\r\n        </dependency>\r\n        <dependency>\r\n            <groupId>com.fasterxml.jackson.core</groupId>\r\n            <artifactId>jackson-annotations</artifactId>\r\n            <version>${jackson-version}</version>\r\n        </dependency>\r\n        <dependency>\r\n            <groupId>com.fasterxml.jackson.core</groupId>\r\n            <artifactId>jackson-databind</artifactId>\r\n            <version>${jackson-version}</version>\r\n        </dependency>\r\n        <dependency>\r\n            <groupId>com.fasterxml.jackson.datatype</groupId>\r\n            <artifactId>jackson-datatype-joda</artifactId>\r\n            <version>2.1.5</version>\r\n        </dependency>\r\n        <dependency>\r\n            <groupId>joda-time</groupId>\r\n            <artifactId>joda-time</artifactId>\r\n            <version>${jodatime-version}</version>\r\n        </dependency>\r\n\r\n        <!-- Base64 encoding that works in both JVM and Android -->\r\n        <dependency>\r\n            <groupId>com.brsanthu</groupId>\r\n            <artifactId>migbase64</artifactId>\r\n            <version>2.2</version>\r\n        </dependency>\r\n        <!-- test dependencies -->\r\n        <dependency>\r\n            <groupId>junit</groupId>\r\n            <artifactId>junit</artifactId>\r\n            <version>${junit-version}</version>\r\n            <scope>test</scope>\r\n        </dependency>\r\n    </dependencies>\r\n\r\n    <properties>\r\n\t<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>\r\n\r\n        <swagger-annotations-version>1.5.0</swagger-annotations-version>\r\n        <jersey-version>2.12</jersey-version>\r\n        <jackson-version>2.4.2</jackson-version>\r\n        <jodatime-version>2.3</jodatime-version>\r\n        <maven-plugin-version>1.0.0</maven-plugin-version>\r\n        <junit-version>4.8.1</junit-version>\r\n    </properties>\r\n\r\n```\r\n\r\n##### Steps to reproduce\r\n\r\nClone and build https://github.com/tadhgpearson/swagger-maven-plugin-dependencies\r\nI'm using Java 8 & Maven 3.3\r\n\r\n##### Related issues\r\n\r\nPerhaps #3261 ? \r\n\r\n##### Suggest a Fix\r\n\r\nBehaviour suggests the default is now using GSON + OK HTTP - maybe that's where the bug is?\r\n\r\n"}}
{"actor":{"display_login":"tadhgpearson"}}