# PlatformImpl()

**URL:** <https://community.cumulocity.com/t/platformimpl/7345>\
**Category:** Forum\
**Tags:** cumulocity\
**Created:** [August 23, 2023, 10:46am UTC](https://community.cumulocity.com/t/platformimpl/7345 "2023-08-23T10:46:42Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![Kai\_Sieben](https://dub1.discourse-cdn.com/flex005/user_avatar/community.cumulocity.com/kai_sieben/32/5541_2.png) [@Kai\_Sieben](https://community.cumulocity.com/u/Kai_Sieben)\
**Post date:** [August 23, 2023, 11:14am UTC](https://community.cumulocity.com/t/platformimpl/7345/2 "2023-08-23T11:14:32Z")

</div>

Hi @vaibhavi_ghumare ,

I would strongly suggest to not use the code this way, as you would hardcode credentials into the code and do not use the SDK properly, hence loosing all the convenience and benefits the SDK provides for microservice development.  
Please follow e.g. the knowledge base article on starting a microservice project:

> [@Jump-Start your next Cumulocity microservice project in java](https://community.cumulocity.com/t/jump-start-your-next-cumulocity-microservice-project-in-java/3976):
>
> Introduction Setting up a microservice for Cumulocity using [Microservice SDK](https://cumulocity.com/guides/microservice-sdk/java/) project is easy. However, a few manual steps must be taken before you have a successfully running microservice locally configured to your Cumulocity instance. To speed this process up, use a maven archetype instead: [cumulocity-microservice-archetype](https://github.com/Cumulocity-IoT/cumulocity-microservice-archetype) This open-source maven archetype helps you to setup your maven project in less than 5 minutes!!! It is not just faster; it is also a good template which are based on be…

This also includes using the microservice bootstrap user ([Cumulocity documentation](https://cumulocity.com/guides/microservice-sdk/java/#running-the-microservice-locally)) and using a dev profile like “application-dev.properties” and use the bootstrap user credentials within this file.

P.S.: In latest versions the PlatformImpl class cannot be used directly anyway anymore, hence you should follow the Spring Boot Bean injection principles to use the SDK and its beans, e.g. just inject “InventoryApi” instead of using the “PlatformImpl” class.

Regards Kai

  

* * *

Kai Sieben

[Software AG Professional Services](https://www.softwareag.com/en_corporate/resources/services/professional-services.html)

[![](https://europe1.discourse-cdn.com/flex005/uploads/cumulocity/original/3X/c/3/c3a93a2618e4708f51be40fe2e142061f7c4edc7.jpeg)](https://www.softwareag.com/en_corporate/resources/services/fast-track-services.html)

---

_[View the full topic](https://community.cumulocity.com/t/platformimpl/7345)._
