Skip to content
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

[Functions] Remove strong dependency on azure-functions-java-library #456

Closed
pragnagopa opened this issue Oct 31, 2018 · 2 comments
Closed

Comments

@pragnagopa
Copy link
Member

cc @soninaren
Right now any updates to annotations even adding new properties to existing annotations require updating maven plugin
For example, CosmosDBBinding.java is a copy of
CosmosDBTrigger.java.

Need to decouple library and plugin dependency. All the information needed for plugin should be coming from azure-functions-java-library

@pragnagopa
Copy link
Member Author

@jdneo / @Flanker32 Lets discuss this post GA.

@Flanker32
Copy link
Member

@pragnagopa @jdneo Refactor done in pr #508, please have a review.

In this pr, i remove other binding classes except BaseBinding, attributes was get by java reflect and save to the map of Basebinding, i will get all attributes defined in annotation and save attributes which is different with its default value, besides, a serializer was created to keep the format of generated function.json.

For now adding new properties to existing annotations will not affect maven plugin, but remove an existing annotations will still not work. I store the type and direction of annotations in BindingEnum and save the relevance in BindingFactory, which import all annotations from java lib.

@pragnagopa

  1. Is there any other way for us to get the type and direction of each annotation? If so, we could decouping the dependency between function lib and maven plugin.
  2. Could you please update the function.json scheme? Schema could be much helpful in local validation and users could verify and update their code according to schema as well

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants