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

Add API v2 support for admin client in plugins #216

Open
Jotschi opened this issue Sep 11, 2019 · 1 comment
Open

Add API v2 support for admin client in plugins #216

Jotschi opened this issue Sep 11, 2019 · 1 comment
Assignees

Comments

@Jotschi
Copy link
Contributor

Jotschi commented Sep 11, 2019

The admin client will currently only be created with api/v1 - Some plugins may however want to use v2

@deckdom
Copy link
Member

deckdom commented Sep 27, 2019

I think it should be somewhat easy to do.
My idea would be, to specify the version you want to get when you load the client.

// Gets the client in the default Version
MeshRestClient defaultClient = adminClient();

// Gets the client in version 1
MeshRestClient clientV1 = adminClient("v1");

// Gets the client in version 2
MeshRestClient clientV2 = adminClient("v2");

Signature would need to change in here:
https://github.com/gentics/mesh/blob/dev/plugin-api/src/main/java/com/gentics/mesh/plugin/MeshPlugin.java

The same should be added to the PluginContext, to get the User-Client in a certain version:
https://github.com/gentics/mesh/blob/dev/plugin-api/src/main/java/com/gentics/mesh/plugin/PluginContext.java

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

2 participants