Skip to content

Instantly share code, notes, and snippets.

View hackmajoris's full-sized avatar

Alex Ilies hackmajoris

  • Cluj-Napoca
View GitHub Profile
@hackmajoris
hackmajoris / amplify-prod-ready.md
Last active March 20, 2024 14:35
# Amplify Gen 1 CLI bugs and production ready wishes from @hackmajoris

Will add more references for already existing open issues at the amplify/cli

The below bugs are present in CLI version 11.0.5. Due to the breaking changes introduced in newer versions, we have chosen to stick with this version. Additionally, I did attempt to upgrade to another version, specifically version 12 or higher. Although there were bugs that I addressed directly with AWS Support, they were subsequently fixed in newer versions. However, we decided not to proceed with future upgrades due to concerns about the stability of Amplify.

1. @Searchable on nested fields

  • Either fix query generation on the Amplify side.
  • Provide documentation and use cases for custom JS resolvers.(Will provide an example)
  • Include an advanced filtering example based on multiple relations (one-to-one, many-to-many).
  • Don't forget about pagination. Note that the 'filter after' feature of OpenSearch causes issues.
@hackmajoris
hackmajoris / start-stop-rds-lambda.ts
Last active February 6, 2024 10:31
Start and Stop RDS Scheduler with Lambda and CDK TypeScript Stack
import { Handler } from 'aws-lambda';
import * as AWS from 'aws-sdk';
const rds = new AWS.RDS();
enum InstanceStatus {
STOPPED = 'stopped',
AVAILABLE = 'available',
}
@hackmajoris
hackmajoris / Fastfile
Created October 1, 2018 13:16 — forked from polbins/Fastfile
Fastlane script for Uploading to Slack and Play Store Alpha
default_platform :android
platform :android do
before_all do
ENV["SLACK_URL"] = "https://hooks.slack.com/services/ABC/123/XYZ"
end
######################### PUBLIC LANES #########################
desc "Deploy a new Prod APK version to Play Store Alpha"
public static class GenericBinaryTree {
public static void main(String[] args) {
Tree t = new EmptyBST();
t = t.add(4);
t = t.add(3);
t = t.add(5);
System.out.println(t.member(0));
@hackmajoris
hackmajoris / UdacityDownload.py
Created October 24, 2016 11:14 — forked from vinovator/UdacityDownload.py
Python program to download course content for multiple Udacity courses neatly arranged within a folder structure
# UdacityDownload.py
# Python 2.7.6
"""
Python script to download course content from udacity courses
- Creates folders as per course names
- Downloads all the zip files
- Extract content from zip file
- Finally delete the zip file
Multiple course content can be downloaded from list
@hackmajoris
hackmajoris / App.java
Last active September 22, 2016 13:42
More complex lambda examples
import java.util.*;
import java.util.function.Predicate;
/**
* Created by iliesa on 22.09.2016.
*/
public class App {
private ArrayList<User> users;
public App() {
@hackmajoris
hackmajoris / App.java
Last active September 29, 2016 14:06
Lambda Expression Example. Java 8
import com.sun.xml.internal.messaging.saaj.packaging.mime.util.BEncoderStream;
import java.util.ArrayList;
import java.util.List;
/**
* Created by iliesa on 22.09.2016.
*/
public class App {
private List<Integer> numbers = new ArrayList<>();
@hackmajoris
hackmajoris / Training.java
Last active September 5, 2016 12:41
Exception Handling
/**
* Created by viplord on 05.09.2016.
*/
import org.omg.CORBA.portable.InputStream;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.io.IOException;
import java.io.InputStreamReader;
@hackmajoris
hackmajoris / Comparator.java
Created September 5, 2016 11:30
Comparable interface implementation
package me.ilies;
/**
* Created by iliesa on 05.09.2016.
*/
public class Apple implements Comparable<Apple> {
private String variety;
private String color;
private int weight;