hunk.code_window:                 });
       }
       @Override
       public Mono<Datasource> update(String id, Datasource datasource) {
           if (id == null) {
               return Mono.error(new AppsmithException(AppsmithError.INVALID_PARAMETER, FieldName.ID));
  
hunk.labels: keep keep add keep keep keep keep
hunk.after_edit:     @Override
       public Mono<Datasource> getValidDatasourceFromActionMono(ActionDTO actionDTO, AclPermission aclPermission) {
           // Global datasource requires us to fetch the datasource from DB.
           if (actionDTO.getDatasource() != null && actionDTO.getDatasource().getId() != null) {
               return this.findById(actionDTO.getDatasource().getId(), aclPermission)
                       .switchIfEmpty(Mono.error(new AppsmithException(AppsmithError.NO_RESOURCE_FOUND,
                               FieldName.DATASOURCE,
                               actionDTO.getDatasource().getId())));
           }
           // This is a nested datasource. Return as is.
           return Mono.justOrEmpty(actionDTO.getDatasource());
       }
  
hunk.file_path: app/server/appsmith-server/src/main/java/com/appsmith/server/services/ce/DatasourceServiceCEImpl.java
hunk.type: add
file: package com.appsmith.server.solutions;
  
  import com.appsmith.server.configurations.CommonConfig;
  import com.appsmith.server.configurations.SegmentConfig;
  import com.appsmith.server.repositories.ApplicationRepository;
  import com.appsmith.server.repositories.DatasourceRepository;
  import com.appsmith.server.repositories.NewActionRepository;
  import com.appsmith.server.repositories.NewPageRepository;
  import com.appsmith.server.repositories.WorkspaceRepository;
  import com.appsmith.server.repositories.UserRepository;
  import com.appsmith.server.services.ConfigService;
  import com.appsmith.server.solutions.ce.PingScheduledTaskCEImpl;
  import lombok.extern.slf4j.Slf4j;
  import org.springframework.boot.autoconfigure.condition.ConditionalOnExpression;
  import org.springframework.stereotype.Component;
  
  /**
   * This class represents a scheduled task that pings a data point indicating that this server installation is live.
   * This ping is only invoked if the Appsmith server is NOT running in Appsmith Clouud & the user has given Appsmith
   * permissions to collect anonymized data
   */
  @ConditionalOnExpression("!${is.cloud-hosted:false}")
  @Slf4j
  @Component
  public class PingScheduledTaskImpl extends PingScheduledTaskCEImpl implements PingScheduledTask {
  
      public PingScheduledTaskImpl(
              ConfigService configService,
              SegmentConfig segmentConfig,
              CommonConfig commonConfig,
              WorkspaceRepository workspaceRepository,
              ApplicationRepository applicationRepository,
              NewPageRepository newPageRepository,
              NewActionRepository newActionRepository,
              DatasourceRepository datasourceRepository,
              UserRepository userRepository
      ) {
  
          super(
                  configService,
                  segmentConfig,
                  commonConfig,
                  workspaceRepository,
                  applicationRepository,
                  newPageRepository,
                  newActionRepository,
                  datasourceRepository,
                  userRepository
          );
      }
  }
  