Getting platform parameters when its deprecated

What product/components do you use and which version/fix level are you on?

Version of cumulocity 1015

Is your question related to the free trial, or to a production (customer) instance?


What are you trying to achieve? Please describe it in detail.

I want to subscribe to all operations within a microservice using the following code:

	Subscriber subscriber = SubscriberBuilder.<String, OperationRepresentation>anSubscriber()
						.withSubscriptionNameResolver(new Identity()).withDataType(OperationRepresentation.class)
				Subscription<String> subscription = subscriber.subscribe("/operations/*",
						new OperationDispatcherSubscriptionListener());

Do you get any error messages? Please provide a full error message screenshot and log file.

The log says that platform params have now been depracated. How can i get these in order to substitute it in the variable. The parameters var is mandatory.


Field platform in required a bean of type ‘com.cumulocity.sdk.client.PlatformImpl’ that could not be found.


Bean of this type is no longer available.
Instead inject platform APIs directly or inject com.cumulocity.sdk.client.Platform and get the same platform APIs instances with getters.
Use relative URL’s starting with ‘/’ with RestConnector bean to have them resolved automatically against the host defined in PlatformParameters#getHost().

Have you installed all the latest fixes for the products and systems you are using?

       private RestConnector restConnector;

InventoryRealtimeDeleteAwareNotificationsSubscriber subscriber = new InventoryRealtimeDeleteAwareNotificationsSubscriber(restConnector.getPlatformParameters());

                           new SubscriptionListener<String, ManagedObjectDeleteAwareNotification>() {
                    public void onNotification(Subscription<String> arg0, ManagedObjectDeleteAwareNotification notification) {


            PlatformParameters platform = new PlatformParameters(
                                                        new ClientConfiguration());

InventoryRealtimeDeleteAwareNotificationsSubscriber subscriber = new InventoryRealtimeDeleteAwareNotificationsSubscriber(platform);

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.