Wrapper task missing from Java-library build

I have build file that applies the plugin java-library.
When I run gradle wrapper I get this error

FAILURE: Build failed with an exception.
* What went wrong:
Task 'wrapper' not found in project ':DBConnection'.

I thought that all builds in gradle had the wrapper task.
Is the wrapper task missing or have I misunderstud something.

Regards Klaus

Problem no longer exist. Not sure why.