Notifications suddenly not working

Hello!

Suddenly over the past week, notifications have stopped working. This is on both Android and iOS. I can’t find any useful logs on my end, but it seems like notifications are just flat out not being delivered.

My application ID is: 4E54F8C8-0A73-E26C-FFCB-5C6E36D78C00

All I know was everything was working 3-4 weeks ago, but now it isn’t. Could someone please help?

Hi @Jeffrey_Sera,

Push notifications stopped working for you? Please try sending a push notification and check the status of the message. What do you get there?

Get Message Status - Backendless REST API Documentation

Regards,
Marina

Push Notifications no longer work, i tried to setup push notifications on my new Android app but this steps don’t seem to work Push Notification Setup (Android) - Backendless SDK for Android/Java API Documentation

Hello @Floyd_Legoana

Welcome to our community and thank you for trying out Backendless.

Could you describe in more detail what steps you are taking and what exactly is not working?

Regards,
Vladimir

Hello thank you for getting back to me. i managed to fix the notification problem by updating to version 7.0.6 but now i have a different problem. after updating to backendless 7.0.6 Files Services are not working on android i am trying to upload a picture to backendless Files by using Backendless.Files.Android.upload(…) the method was working fine before updating to 7.0.6 now i am getting an error on the "Android"part of the method it says “cannot resolve symbol ‘Android’” and the documentation has not changed…

hello @Floyd_Legoana

thank you for your question.

I was able to reproduce the issue, and we will fix it as soon as possible, as workaround create class FilesAndroidExtra

import android.graphics.Bitmap;
import com.backendless.async.callback.AsyncCallback;
import com.backendless.exceptions.BackendlessFault;
import com.backendless.exceptions.ExceptionMessage;
import com.backendless.files.BackendlessFile;
import com.backendless.files.router.BitmapOutputStreamRouter;


public final class FilesAndroidExtra
{
  private static final FilesAndroidExtra instance = new FilesAndroidExtra();
  public final BackendlessInjector injector = BackendlessInjector.getInstance();

  static FilesAndroidExtra getInstance()
  {
    return instance;
  }

  private FilesAndroidExtra()
  {
  }

  public BackendlessFile upload( Bitmap bitmap, Bitmap.CompressFormat compressFormat, int quality, String name,
                                 String path ) throws Exception
  {
    return upload( bitmap, compressFormat, quality, name, path, false );
  }

  public BackendlessFile upload( Bitmap bitmap, Bitmap.CompressFormat compressFormat, int quality, String name, String path,
                                 boolean overwrite ) throws Exception
  {
    checkBitmapAndPath( bitmap, compressFormat, path );
    return injector.getFiles().uploadFromStream( new BitmapOutputStreamRouter( bitmap, compressFormat, quality ), name, path, overwrite );
  }

  public void upload( final Bitmap bitmap, final Bitmap.CompressFormat compressFormat, final int quality, String name, String path,
                      final AsyncCallback<BackendlessFile> responder )
  {
    upload( bitmap, compressFormat, quality, name, path, false, responder );
  }

  public void upload( final Bitmap bitmap, final Bitmap.CompressFormat compressFormat, final int quality, String name, String path,
                      boolean overwrite, final AsyncCallback<BackendlessFile> responder )
  {
    try
    {
      checkBitmapAndPath( bitmap, compressFormat, path );
      new UploadBitmapAsyncTask().executeThis( bitmap, compressFormat, quality, name, path, overwrite, responder );
    }
    catch( Throwable e )
    {
      if( responder != null )
        responder.handleFault( new BackendlessFault( e ) );
    }
  }

  private void checkBitmapAndPath( Bitmap bitmap, Bitmap.CompressFormat compressFormat, String path )
  {
    if( bitmap == null )
      throw new NullPointerException( ExceptionMessage.NULL_BITMAP );

    if( compressFormat == null )
      throw new NullPointerException( ExceptionMessage.NULL_COMPRESS_FORMAT );

    if( path == null || path.equals( "" ) )
      throw new IllegalArgumentException( ExceptionMessage.NULL_PATH );
  }
}

and use in the following way:

AndroidFileHelper.getInstance().upload()

It will be the same as described in the doc.


i get this error “Cannot resolve symbol UploadBitmapAsyncTask()”

Hi. A new version of android-client-sdk will be available in 2-3 hours.
I’ll post about his readiness

1 Like

There is special class for working with Android Bitmap type – FilesAndroidExtra.
Now it is part of android-client-sdk (not the java-client-sdk).
How to use: FilesAndroidExtra.getInstance() and there you’ll see available methods.
The new version is 7.0.7

1 Like

The release was published.

I would recommend to check https://central.sonatype.com/ repository. Аrtifacts appear there within 1-2 hours.

upd: they are already there.

1 Like