-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix for #24 #26
Fix for #24 #26
Conversation
String apiIdField = profile.getApiIdField(); | ||
String apiIdValue = null; | ||
if (apiIdField != null && !apiIdField.equals("title")) { | ||
Map<String, Object> result = loadApiConfigFile(profile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@nandoan - Can you add the entry in the apicatalog json. Its missing in the PR
@@ -23,6 +23,7 @@ | |||
<portal.api.doc.format>basic_html</portal.api.doc.format><!-- Format in the portal. Values: basic_html, restricted_html, full_html --> | |||
<portal.directory>./specs</portal.directory> <!-- Directory where OpenAPI specs are accessible. Using ./specs for sample --> | |||
<apigee.smartdocs.config.file>./apicatalog-config.json</apigee.smartdocs.config.file> <!-- Config for fields --> | |||
<portal.api.id.field>title</portal.api.id.field> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@nandoan - Why do I need this entry in the pom file? Why not just get the entry from apicatalog json as you are looking for "title" anyways?
logger.info("Getting API doc for "+ spec.getTitle()); | ||
String apiIdField = profile.getApiIdField(); | ||
String apiIdValue = null; | ||
if (apiIdField != null && !apiIdField.equals("title")) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@nandoan - not sure I prefer the title check being hardcoded, then it doesnt make sense to have this in the pom as a property. The ideal thing would be to just look for the title field in the apicatalog json or else get the value from the pom and see if that matches any key in the apicatalog json and use that value in the code.
Closing this.. Please reopen if you take care of the comments |
Adding a new optional property to configure the API Identification field, as described in #24.