See this gold record right here. It's not from being a rock star. I wish it was when I got started on this I had zero dollars. So this week we've been talking about how to create digital assets how to create your passive income for this Here and become what's called a digital landlord today. We're gonna talk about how to create that passive income with zero dollars out of pocket Let's get into it Hey, it's Christian the work from anywhere guy We're back with the digital landlord series because if we want passive income We have to have an asset that creates that income and the real-world houses throw off rent checks online We have to own something that produces that income for us So we actually have to create a digital asset now if you haven't seen the other videos in the series Please go check back the last one We showed you four ways to come up with your idea for passive income this year That's really important because this video we're gonna talk about how to actually Create that asset with zero dollars out of pocket now like I said when I started on this gold record From day one when I had zero sales I knew that I wanted it and I knew how many sales it took so the last video we talked about Calculating how many sales to make a million dollars But I started creating my digital asset and I sold the very first one and I walked in the room Just like a proud father my baby had just taken his first steps And I was ecstatic and I told my girlfriend about this and I was jumping up and down Now I ran upstairs to brush my teeth after breakfast and while I was in the bathroom another sale came through On my phone Now needless to say I just thought that I had like completely made it and I ran down stairs I was jumping up and down and I remember that day my girlfriend came back with a Number two balloon because she was celebrating two sales because we both knew the target was a thousand sales And so we go okay. We got two sales today. We have 998 to go and at that time, you know, I had a business But I was putting everything back into the business and I didn't have any money to be spending on Creating things so this I started by first selling the asset and then after it was sold I started creating things now Let's walk through this real quick because people get really weird around this topic like immediately So let's think about Tesla Look in the screen right here about how many cyber trucks Tesla has sold already now that truck is not out yet I actually placed a pre-order for it. I think it's an awesome looking truck And we're going to talk about the importance of that in a minute But the truck has not been manufactured and yet Tesla has collected this much money already So we can do the same thing with our assets where we can actually go out there And we can pitch it to the world in a media event just like Elon Musk does we want to pre-sell like Elon Musk We'll talk about that means and we can actually collect cash for our asset before we've ever created it Now I've done this for software for iPhone apps for courses for coaching for all sorts of things And it works over and over again And if you think about it, this is the way the world works right if you go to university and you sign it for a class You actually pay your tuition before you attend to the class So it's not an abnormal thing to pay for service before you get it So whatever your digital asset is whether it's a course a coaching program and iPhone apps software Whatever we want to hold a pre-sale event now if you think about the way that Tesla pre-sales They put on this big media event right are they the only car company to do that? What do you think would happen if you know Toyota or Hyundai? Put on an event like Elon Musk and they tried to sell their new car Do you think they would get as many pre-orders? No, they wouldn't would they because there is hype around Tesla That's why it works because people are seeing something they've never seen before And this is how we have to pre-sell our assets no matter what they are we have to give people information That is important to them now Modern civilization is just like this tiny blip on the timeline of how long humans have been alive So our brains are largely I don't I don't know a better word prehistoric. They're functioning based on instinct Now what that means is if we've already heard information before or for aware of it If we're familiar with it if we understand it, we'll just completely tune it out Right, we don't have enough attention to pay attention to every single piece of information that comes across our desk That's why if Toyota puts out a new Civic, you know We're probably not gonna rush to watch the pre-order ceremony like we would Tesla Now why do we pay attention to Tesla when they pre-order? It's because the Cybertruck is like nothing we've ever seen before it makes you stop and say wait what and Some people love it. Some people hate it. It's polarizing You cannot help but stop and pay attention Now Elon Musk is a genius and he doesn't stop there So they have these indestructible windows and I don't know if this was a media stunt or it was really an accent But he's taking these lead balls He's throwing them against the window of the Cybertruck and he's telling us how the window is not going to break And what happens the window breaks and So this just throws the media For a complete loop. They're publishing the new Cybertruck Everywhere you look and everyone in the world has heard about these windows breaking That's billions of dollars in free publicity So what's happening with Tesla and the Cybertruck and the products they release is our brain is seeing new information We've never seen before and it thinks it's important to notice it for our survival Because if we've seen Honda Civic before our brain takes that piece of information It puts us in a folder called Honda Civic that folder is already established if the Cybertruck comes out And we try to put that information in the Cybertruck folder. There's no folder for that So humans greatly overvalue what is new so in order to sell our digital asset We have to create something new about it Now it doesn't you don't have to be Elon Musk You don't have to be creating something that is the newest thing in the world You know one example I love to give about this is the Marina Bay Sands Hotel in Singapore It's just three skyscrapers with a little bit of magic on top So you can see the foundations are exactly the same as any other skyscraper if it didn't have the top section It wouldn't be notable at all But what do they do they put a little bit of magic on top and we're gonna do the same thing with our digital assets And the way we do that is we warn our audience about something good or something bad So if we're talking about if I'm selling a snowboarding course I can warn the audience about a new way to learn snowboarding that helps them get better faster And if I can position that as something new and they have no file to put that in Then they're gonna stop and pay attention So that's how we create our passive income Digital asset with zero dollars out of pocket and become digital landlords even if we have no money right now is Number one we figure out our digital asset idea check out the last video for the four ways to do that And number two is we pre-sell that with a hype event now on the internet We're usually just gonna use a landing page and a sales page to pre-sell it And then we can create the product once the sales start coming in Now this makes sure that there's demand so if test someone out there and they sold the cyber truck at this event And nobody signed up for pre-orders they probably canceled production of that truck because it would be a big waste of money So we're gonna do the same thing with our digital asset We're gonna we're gonna take orders and as long as we have orders We'll use that money to create the asset if there's not enough orders We'll just refund them and we won't create it So that's snowboarding product to put out and again you can see here some days this thing does seven or eight hundred bucks Just on a normal day the very first person who bought it. There was no product. There was zero and the welcome email says Hey, welcome to the snowboard school You're gonna be getting two new videos every single week for the next three months, right? And so then I can just create those videos every single week and space them out over three months after that The product is done and new people to buy they get the whole product at once But everybody who bought in the first three months they got two videos at a time now I've done that in every business. I've ever created the first person who bought the first sale from this gold record Guess what was in the members area? There was zero And it's not unethical if I know I can deliver it and expectations are clear with the customer So I tell them hey, this is the release schedule This is when week one starts it starts next Monday and then I have the weekend to go ahead and create that video For them so they know that it's gonna be dripped out Just like a college course would just like the Cybertruck has a release date in the future So that is how you pre-sell your digital asset Again sell it then start creating the product use a media hype event by giving people new information They've never heard before so they have to create a new folder on their brain to put that in that is what gets us What's called attention which is an instinct for our survival if it's something we've never heard before and we think It's important. We're gonna stop and we're gonna pay attention That's the only way if it's a Honda Civic. We're looking at put it in the Honda Civic folder. We're not paying attention So we got to create that marketing hook that is something new and different by just putting a little bit of magic on top Just like this skyscraper again. We usually just do that with explaining things in a new way So let me know in the comments. How do you feel about pre-selling your digital asset this year? Do you believe that you can create passive income by building assets and becoming a digital landlord if you have hesitations What are they throw them in the comments and I'll help you out it's Christian They worked money where guy don't forget subscribe to the channel because we're doing a whole series on digital assets right now In the next video, we're gonna talk about how to scale your digital asset to a million dollars So go ahead and subscribe to the channel if you want to see that hit notifications right now And I'll see you on the next one


There you go Okay, today. I'm talking about modularity and dependence injection at scale So this is mostly based on the Twitter Android app Like I I'll try to elaborate anything that goes into detail about Android But mostly it's about dependence injection and the things that we've dealt with over the years So to start off This isn't me. This is like nacho and Cesar who's been working on it for the last two years I'm sound. I'm Software engineer at Twitter working on Android mostly focused on performance right now So I work closely with Cesar and nacho for any architectural changes Okay, so to start off. Let's dive in a little bit and like see like what we were doing over the last few years So Twitter is a really old app. So Because there isn't that many audience and sort of guessing let me just show you this is our first commit So as you can see we've been at it for about a decade This is just the Android app and we've started before this happen first initial commit, obviously So during that time a lot of the things were different. I Believe Android Froyo was out. Everybody was using Eclipse for Android. It was an ant build platform Usually everybody had one module. So did we there was a simpler app. It wasn't that many features But as we went forward we extended we you know switch to great Oh, we started dividing up the UI and the business logic and The more we worked on it the more we realized that it provided more benefit. So we started splitting it up even further So we split up The UI from the features itself right like so we went feature wise Then we even started splitting up what we had under the covers for the business logic to be more generic versus anything That was Twitter related We went even further and the started splitting up each one of the features says we As new teams on boarded we were getting more and more engineers working on different features They wanted to maintain their own module. They didn't want to go forward, right? Then we realized the benefits of that and we started splitting up all the lower-level business logic I'm going by this fast just to because it's a brief history, but Stop me if you guys have questions We split up even further we decided to split up our business logic that Twitter related into like subsystems that makes sense and like the infrastructure and Essentially we ended up with an app There was a lot of different modules that support each other to build then to our app at the very top We had the big module which was the app itself and then the features then the infrastructure subsystems and finally the corollaging as all of this was happening we acquired periscope and As we welcome the periscope team, we wanted to give them what we have learned over the years and we wanted to build Help them build their Android app with the same features that we had So let's see what happens. So we started off with the Android app which was this very modular is ab at this point of time and We found that it's actually rather easy at this point right because we could share some of the core logic that was in Twitter related And we can build periscope on top of that we actually took it a slightly further and a team started building basically their sandbox so they can only work on the feature that They want and they don't have to build the entire app. So this Drastically help them with build times right like because you don't have to build every different feature of the app and all of that And it actually it lets you iterate very quickly and like test internally So I know it this was a lot But essentially the core information right here is that we split it up into multiple modules that can be individually tested and all Of that and we essentially built all of this on top of dependence injection Right. So the dependence injection that we used for this was dagger daggers a very common one But before we go down that path, let's just quickly go over why dependence injection really helped us on this, right? So it it's important It helped us we use ability a lot as you saw like that we can use between periscope and Twitter it helped us with testability It helped us with like correctness because we don't have to share like copycode and like could they stick to it And they also helped us a lot with refactoring. We did a lot of refactoring over the years, right? So it's important to have dependency injection for us like and it's actually important for anybody No matter the size of the project that you're working on For us like I mentioned before we use dagger and like it's one of the common ones that's used in the Android world for any mid-sized to large-sized apps and we started using it and we learned a few things along the way right and That's kind of what I want to share today. I was like what we learned and how did we handle some of these things? So in general it helped us a lot with static checks, right? Anything that errors at compile time is way better than seeing it at user level So we want to see something like this more often than like a user complaining to us and even though this annoying It's much better It helps us with code generation it takes care of a lot of the boring code that we're doing right like Here's a walkthrough so we can have Something like this so ignore the code it really doesn't matter, but there's these are modules that depend on each other So each one of them have their own constructor and as the constructor changes we have to update every place that's being used Instead if we could use dependence injection we could have something like this which essentially just Adds this annotation that says hey, this is the constructor that needs to get injected And then we if we change it we don't have to worry about it the generated code kind of takes care of it, right? It also gives us a graph architecture, right? so and this graph architecture allowed us to really scope out and Like figure out like how can we? Split up the object graphs themselves right between the features between all of that One thing that I want to note is that every time I talk about object graph if anybody's familiar with dagger We're basically talking about components and subcomponents There's there's differences between them and I wouldn't go into the details of it, but in general they act similarly So let's see what we had like so I talked a little bit about object graph that we built So in terms of the Android app So we wanted to start at the very top level and like scope out the different graphs that we have So the first one that comes that's the most obvious case is that whole application scope So this is basically singletons that we have in their app That spans across the whole lifetime of the app that as long as it's live following that we have user scope So these are essentially You can think of like like user level databases and like user level logging like stuff like that So these are scoped by the user as a user logs in and logs out and or switches accounts Like we want to go to the correct one from that from there We move forward to like these things that we call retained scopes so in Android what happens is that every screen that you see is essentially an activity and this activity can Be destroyed and recreated as configuration of your phone changes and this could be simple thing as like rotating your screen Right, so we wanted to have some things that are as you're seeing the screen There are things that we need to maintain so we put that in the retained scope and then the Activities themselves. We actually tied them to the view scope So this allowed us to have some some things that can outlive the activities themselves But as long as the screens on view they were Provided and like shared under the retained scope. So This basically maps to these four different scopes that we have throughout our app. So we have application We have user we have retained and we have view Let's dive into a little bit more, right? so if we see Without going full detail, obviously the application scope in the dagger we would define something like this, right? So we This is in Kotlin like we defined that this interface for our object graph. We say this is Application scope and the module that it relates to that will provide the bindings and then from there We basically say that these are the user level Objects that we want to build right the user graph in the user graph. We do the same thing We say this is a user scope and from there we say hey, okay, like from here. We can build anything that's retained scope related, right? so From here like this will be feature level things that we're calling and then same thing in the retained scope as We build it out we have We we build out the view the view graph underneath the covers and then like the view graph is the final one that We have for our four different scopes So these are the four scopes that we had right like the application retained and view scope one thing They will notice that we ended up going with component for the top code for the the top level scope and then subcomponents for the under level scope I mentioned previously there are subtle differences and like one of the reasons for going down this path was essentially the sub graphs need needs access to the the top level graphs right like because it's everything that the application holds even though You're looking at the activity or the view you might need something. That's an application level So we decided to go with subcomponents These are things that a lot of the large companies deal with and they'll build their own set of like Tooling around it to deal with we just decided to use it this way all right, so I've dumped a lot of information about how we're scoping things and all of that This wasn't the main part of it The reason I went through it very quickly is because these are things that you have to deal with as you introduce dagger into your system You have to decide all of these now There are certain things that we ran into and like over time like we decided like we had to like adjust and find things to fix Or not necessarily fixed to basically work around and like get a better at it So I'll start off with a really easy one right so we have a lot of engineers who works on our coast code base and one of the common problems that we have is How dagger like how you instantiate the dagger graph so typically it looks something like this So in this particular case you'll you'll in your application level You're gonna create the main graph right and this particular command is actually the generated code So anybody who's building the application for the very first time Runs into this problem where it doesn't know what this class is because you have to first generate the classes and then the you can You can reference it in like your application So we built a very small helper function and we changed it to something like this right so in this case All we're doing we're just with the helper function that we have for dagger We're just saying hey, this is the application graph that we're generating. Let's look into it Let's see what it looks like so essentially the helper function has the ability to build this graph right and You may be thinking that hey like if you do it this way, it's still fine You're still gonna end up using it so we we use a little bit of reflection I know it's a it's a little costly, but we're doing it only once Right, so we decided to just like use the reflection only in this one method and then the whole graphs presented to us, right? Don't worry about it. This is mostly just checks around reflection and making sure we're doing things, right? The TLDR is essentially like we use a little bit of reflection and we get the graph and once the graph's there We have access to all the objects in the graph Just a note like we will post this so don't worry about pictures it's coming and Shameless plug follows on GitHub. We have a lot of our open source projects right there Anyway, so we basically decided that you know instead of using this generated a reference right like that We have to generate first before we can go forward as new people are onboarding to not have them deal with it We just you know created this little helper. So this was a very easy one and like you really didn't make much of a difference, right? What else so this is this was a big problem for us So we have we've decided on all these graphs and we want to really figure out where should we place them So we started off with like this thought we're like, okay We have this modularized app and we have these scopes that we have defined and what makes sense and we said okay Well, you know it makes sense for the user and application scopes to be at the very low level possible because these are Not really tied to anything and everybody should have access to it Because you from the top you have access to any module that's below you, right? Like you don't have the other way around and similarly for Because the retain graphs and the the retain scope and the view scope is related to the activities It made more sense to be in the feature modules. Let's see how it works. Does it hold up, right? so Let's take an example of tweeting, right? We're gonna tweet out this with an image and you know and like let's walk through what all's involved so essentially to start off our feature is the composer the composer is the one that's gonna take and Let you compose the street so that you can post it So in a very basic sense without diving into a lot of crazy things that's going on We can say that hey at the very least it has an activity Which is the screen it has a view model which defines the logic on the ui logic that we have over there And the delegate is something that we we do which basically Links to the activity so instead of using the activity directly we use this view delegate so that we can unit test that without requiring any of the Android Specifics so it makes sense that hey, these are the feature level components. So it goes to a feature module What next so then we would need the tweet repository because we're basically generating a tweet and we want to put in the repository It makes sense that the treat repository is a user scope, right? Like so as long as the user is logged in in any of the activities you'll get access to it So that this is a subsystem that gets added here and we run into our first problem Which is we wanted the user scope to be at the bottom so that everybody have access to it, but The thing is if you define it that far down you you can't Define the objects at the top right like so all right, but let's move on Let's see what else we run into right so the user scope needs to be at least in the subsystems level Next we have the image right like so we we're adding an image to the street So there's an image uploader now. This is just a Twitter infrastructure thing right like so it's not really tied to the user This is like something that gets kicked off so it's an application scope thing that runs as the image is being uploaded So now it's not really a generic Subsystem so once again, we're in this case where We wanted it to be at the very bottom, but the application scope kind of needs to be a little bit up So one thing that we're noticing is that the application scope needs like to be at the very top, right? Even though like this is something generic that we can have with OK HTTP, which goes at the bottom but the Twitter media image uploader Module that we had is like one level up from that so Let's get even more crazy, right? So if you tweet out in Android, you'll notice that while the tweets being posted There's like a notification that shows up, right? So this notification handler is essentially tied to the application like it's not really related to the activity It's not really happening on the activity. It's just on the app and it's contained there so We want to but we want to put it with the features because it's related to the composer So if we added there what we also ended up doing at that point is like We just move the application scope and the user scope at the very top Because it seems like there's like at any different level like we can have these scopes even though we were really Originally wanting to do it at the bottom Okay, so you know So one thing over here like you know like all the the pentagons right here that I have Are just the different bindings that we were we're having and then like the circles are like the scopes that I've defined So, you know, these are the modules that we talked about so we'll add them right there Right like so so at least that makes sense Like whatever modules we created for the dagger bindings that can stay with the features that that we want, right? So We kind of had to shuffle around a little bit of the ideal location But you know, we can try to deal with it as we go forward. Let's see what else we can do One of the things that we want to look into at this point is like How does how do these graphs then access like from intermediate modules, right? Like so even though originally we said that we wanted one the application scope and the user scope at the bottom And the retain scope and the view scope like further up at the features level But then like, you know now that the application scope and the graphs are defined at the top Which makes sense but we had we run into this case. So imagine this like legacy activity that uploads image I don't know what it does, but let's just assume that it's one of those Now it needs to access the application object, right graph. That's defined at the top to basically get access to this image uploader and That was one of the reasons where we originally was saying that hey it makes sense to have the application scope defined the application graph defined at the very bottom, but We were running into this case. So let's see how we can walk around it Because the module is going to be right there with the feature like as we were talking about So we wrote this another Helper we love helper classes by the way so we wrote this helper class that essentially could be the provider for the application graph and then we Said that instead of doing this where we were storing the application graph At in the application level in like a member variable we instead we change this to basically be Assigning it to the provider. So instead of storing it in the application itself We provide we just store it in the provider and the provider knows how to then get access to the graph The magic part of it is like then we can move the provider all the way to the bottom Like there's no reason for the provider to be at the top even though the graphs get defined at the very top the provider can sit at the very bottom of the of the of the the modules right So in this particular case then like going back to what we had where the legacy application needs access to this media sub graph If if we have the provider then we can just do something like this, right? Like so the provider will give you the graph We know that we are looking at the media sub graph so we can just cast it and access the image uploader Let's clean it up a little bit, right? We can just move it into with a helper method, right? and the helper method can just cast it and Just give you this I'll give you the sub graph We can actually clean it up a little bit more like so you don't even have to think about the provider We can just do it in the graph itself in the graph definition We can write a companion get a getter that essentially does the same thing for you like it will access the provider and like cast it and then The use of it in the legacy module ends up being something very simple You know you want to access the media graph you can just get it and access whatever you need from that graph so This simplicity essentially takes care of this case where we were reaching up and down at this to Basically get down to the lower levels Now we can just reach down like so we can just go to the media sub graph and the media sub graph can reach out To the provider as needed What else did we have? so One thing that you might have noticed from that Example is that the graphs can grow like we were just talking about composers So if we look at just the composer we had at least like the the compose launcher the The notification handler and then like you know with the tweet repositories Whatever related to that and it can keep on growing and that's just like one feature with like a few things at it Right like and then we if we add all the other ones it grows It becomes big So we we thought around and the figure out okay How can we deal with it and one of the thoughts that came about is that we can introduce sub graphs so With sub graphs we can clean it up and we can actually define it So we were already saying that there's the media sub graph But like what if the definitions completely could be used like this way right so Just using a very short version of the application graph. So we had Composer and all of these we can we can just split it up right so we can say hey the composer related It goes to the composer sub graph and we can just basically extend the interface as we need So we can do that for the other ones we can do it for the tweet repository the images and like Whatever granularity that makes sense right and we can build all these sub graphs and make this very simple Object graph definition where you don't have to worry about what all bindings are there right like they're all defined in their own Subgraphs and then like like we were saying before where the media Component modules were right there right, but now we can actually move the sub graphs to that level right and We can actually put them right where they're defined So wherever the bindings are we can put the graphs right next to it Kind of like helps us get rid of this very big graph and distribute it to with all the features that we have all right Question comes up immediately from that is what about testing right? we have all these sub graphs the sub graphs knows how to pull things on their own and The sub graphs is looking at the provider directly. So how do I actually? Take advantage of the testability of dependent in injection and like you replace it So what we did was we added this little thing for the provider So the provider we added a map where it can basically Store some of these overrides that you have and an ability to overwrite it and then in the getter We essentially look at it and see if there was any overrides if there is any overrides will return you that or we can Just return you the real implementation that was already there. So then like you know, that's taking care of now We as we started using this more and more we ran into this problem of decoupling features So I want to dive through it a little bit more and give you a little more detail Because this was a doozy So let me use a example of the app navigation So essentially if we have a very simple Twitter app imagine it has only four modules Imagine it only has the main activity. It has the ability to show tweet details It can do a compose and they have DM for direct messaging, right? Now you can get a tweet link via a DM and if you tap on it you want to be able to open it So now in Android how activities work is that you for To launch that screen you need the activity to create an intent around it and then you basically launch that intent So for in this particular case the DM activity will have to know about the tweet detail activity So that it can launch the intent related to that and then you can go from DM to treat activity However, there's a feature where you can share a tweet through DMs, right? So then the tweet detail activity also has to know about the DM activity So this means that we have this circular dependency and you know that obviously doesn't work So we thought about it and we basically ended up introducing Subsystem called navigation and the net so this is how the navigation subsystem essentially works So we created these intent factories essentially for each one of the features, right? We call them activity args They are related to the features directly and then we moved to these activity args into the navigation subsystem So that way like every activity as you need to do all you need to have access to is to the navigation subsystem And you kind of like take care of this circular dependency Let's dive into a little bit on like what the activity args look like so I mentioned before that they are basically intent factories So essentially the interface looks something simple like this And from there what we want to do is essentially just generate the intent that's required to launch the activity One of the immediate bonuses that we got out of it is we actually had type safety of the arguments because they're just like Bundles that's defined in Android So that was a big bonus, but like it's kind of like something that we just got out of it now it as I mentioned it creates the internet activity, right and then For all of these different ones. So now we have these activities and all these like intent factories spread all around We wanted a easy way to collect them all together So we built the service discovery the service discovery what it does is essentially uses the multi bindings feature for dagger and Pulls in all of these intent factories that we've defined. Let's dive into a little bit. So Even smaller example here But essentially like we have these intent factories defined, right? And we want to basically have them in the object graph somewhere so that we can easily reference to it So we use multi bindings from dagger, which will just essentially collect all of these definitions because they're defined and then put it in for us Dagger can put it in as a set or a map We've decided to use a map and essentially what we said is that for each one of these activity arguments Like map it the values the activity arguments and the key is that the activity class So then we have access to the activity class and we can generate the intent Let's dive into like what we did so taking composer module as an example So we added this tag into map, which comes from dagger Which basically says that pull this binding into a map and then we said use activity arguments as a key and then the value would be the activity class itself This essentially generates this map right that we store in there another helper function Called activity starter. So this isn't a navigation subsystem. So this map is then later accessed So when we want to create something we have this map and we Have this helper method now that can kick out the activity So all you need to know is that this is the activity argument that's required Now Android requires context for a lot of these things. So we take in context for this case But then all it does essentially is that it generates the intent like we said, right and nothing more to it Essentially getting rid of the circular dependency that we had and now we essentially have this module like thanks to dagger We have this map and we can actually relate the different intent factories to the activities themselves All right So we learned a lot about dagger using dagger over the times and over the years And as more and more engineers were onboarding and more and more features that we were writing We started seeing some of these even like starts training So I want to go into it even more details that we ran into So we used it for initializers like is the same features like with the service discovery We used it for all the initializers We used it for like notification handlers and we also use them for deep link handlers like that way We just spread it out wherever they're related, right and like this particular thing like we basically ended up building this Thing right that's on top of dagger so that we can like help Distribute the graph like into the modules themselves, right? So the subgraphs however ran into a problem So we found out that the subgraphs themselves are not atomic So let me let me explain So we have this graph definition that I mentioned right So there's a top level graph and then all the subgraphs to find in the modules that they have But then to use dagger we essentially have to actually define a module next to everything Which defines where the bindings are So you to build a graph at the very top level you have to point it to the modules And then you also have to point it to the subgraphs because of the definition that we have and Then it gets worse because we share code with periscope And we would like to keep on doing it when you have a new definition on that's a shared module You essentially have to define both of them in both the apps and this will just keep on growing right like now We have sandboxes that everybody's using so everywhere you have to remember to do both of them So what can we do? So to start off like so using this broadcast example So that's a subgraph definition which says this is the binding that we're having and then the dagger definition Which actually provides the binding So we started by basically annotating that hey, this is our subgraph So we know what a subgraph is and then we're saying that hey This is the scope for this subgraph and from there we said hey We can actually say that hey This is what's tied to the subgraph right like this is the module that you need for the subgraph and then For the the big graph at the very top Instead of saying that hey, this is this like component with all these modules We can essentially say that hey this part can be replaced with that. This is an object graph That's all like that's all we need to know right we can do the same thing for the user level stuff Because it's a subcomponent, but essentially that's also an object graph. That's defining everything So the big difference between the subgraphs like you said before was just pieces of the object graph the object graph is like the full definition so this annotations then like we basically send it through the annotation processor that we wrote and it can crunch and Generate the dagger compatible components and subcomponents So we define the subgraphs and like just let it generate whatever is dagger This is like fully dagger compatible Right because we are definitely using dagger under the covers It's just like like simplifying the one of the things we ran into What else? Let's see. So subgraphs are not encapsulated right now, right? Let me let me explain that With this example, right? So what I mean is that when you have all these different subgraphs Like you actually don't know how they relate to each other You don't know who needs what it's only when you add it to the object graph that you realize that oh, I have everything that I mean right What we would like is that at a sub grapple at a sub graph level We know that it actually has all the bindings that it requires so what we did is that you know, we took this definition of the modules and like of sorry of the subgraph and We added the dependencies so we know that this subgraphs has other subgraph different dependencies and then You know instead of having this issue when that compile time at the very top level in the graph We say hey, there's a binding missing we can actually get the error at a very lower level So we know that this particular subsystem is actually missing a binding and then fixing that we'll just fix the entire graph right and The bonus from that is that now subgraphs are fully documented right like we have from this definition alone We have what what are the modules that's related to the subgraph? We know what are the dependencies of the subgraphs and we also know what bindings that's being provided So looking at a subgraph, you know what all it means What else we ran into so we ran into the case that subgraphs are not reusable And you're gonna say South I thought that's the whole process of doing it. That's why you're doing it But like there's a little bit that what I mean is a little bit nuanced So we can use this network subgraph right for example in any app that we want But then when Periscope came along they said hey, you know, this doesn't work for us we need to use a special cache and Since it's defined in the subgraph. There's no way for us to reuse it without copying the whole thing So we thought about it and we are like this is a big fail What if we think about it in terms of just what we would do with a class, right? So if you if you were a class, we would say that hey, you this is not a final class It's an open class so you can extend it and then we could say that hey The cache is also an open function and you can overwrite it then for Periscope you can actually Like override that binding even just by extending this and just overriding the special cache right like just saying that it replaced the cache with this special cache and then something like so Would have worked and so we basically Added annotations that basically references the same idea right so we're saying that this particular subgraph is open Which means if you can extend it and then we're saying that this particular bindings are open Which means you can replace it We didn't do it for all we we left the power so that in some cases as you're building the module You know that you cannot replace it so you don't want to do that for everything, right? You want to limit it so we built it in instead of having everything be overwritten. We we allowed it to be defined Right and then like when the periscope comes in it can define its special cache and like said that hey This is a subgraph. This is the override So we can reuse the override annotation and say that it binds to the cash, right? final thing that we ran into is that Subgraphs don't support inversion of dependencies. So this is this was very tricky As we started doing more and more things into the subgraph We ran into this case where we wanted to define this database subgraph and the database subgraph in general like you know We we have this definition of the schema of like what this database holds but a database subgraph is more like an abstract thought right like we have multiple databases and each database will have its Own schema and we want to invert this dependency so that we can Provide the schema for different Databases, but also have like the modules themselves like anything that uses databases to get advantage of this subgraph so just like before Just like open before we added abstract annotations So the abstract annotation says that you cannot instantiate this graph you can extend it you can build something like this for Twitter for example like we and You it if it completes all the bindings then it's a complete graph, right? And it's not going to be an abstract and then you can invert it and you can say that this is the schema that the Twitter Database requires and everything else is provided from the database And so that was all the subgraph stuff and finally for the graphs we ran into this big one is that they are hard to maintain So just like dagger where you have to define all the modules at the top now You have to define all the subgraphs. So something Like this happens even though we are putting all the bindings in their own little graphs, you still have to define the graphs and It gets really insane when you have a lot of features if you haven't seen it trust us we've run into this and so what we decided is like all of these Information is available to us. So can we build an annotation processor that can crunch it, right? and then essentially does automatic discovery and Essentially, all you have to do is say, hey, this is there's this object graph It can find the subgraphs that's required and pull it in So essentially, you know at runtime at when you're writing code You don't have the types available. So you don't really know but at compile time These are all there because of the automatic discovery Right and we did more from there, right? So once we solve that we added support for Factories like in general like just first-class support. We had it improved our build times a lot because of the distribution of the graphs and We are working on an ID integration right now This annotation processor that we created we call it site and You know, it has all these features that I've been talking about for the past 30 or so minutes And we are planning to open source it this year Okay. Thank you very much


There's a reason why Xtrades is currently the fastest growing application on the market for sharing financial ideas. With over $2.5 million paid in the last two years to contributors, users are flocking to see what trades the top traders on the leaderboard are sharing in real time. If you're looking to grow your reputation as a trader on the internet or discuss your trading ideas with other reputable investors, click the link below and get connected with a trading mentor today, completely free of charge. All right, what's up, everybody? This is Alex from Xtrades and welcome back to another weekly trade ideas list. And also Merry Christmas, if that's what you celebrate. It's actually pretty late in the day right now. I was able to get a little bit of charting in today, but I was a little bit busy for Christmas. So I only have a couple of setups this week and also the spy and the QQQ are currently stuck in a range. There's not really too much to see there over that later. So this could be relatively quick video. As you can see, we also really don't have any types of data this week. You can see Christmas and then we got the cashier, their home price index. This is not going to move the market more than likely. We have nothing scheduled for Wednesday and Thursday, just our usual initial jobless claims with also advanced retail inventories, advanced wholesale inventories. And then pending home sales is probably going to be the biggest thing on Thursday. But that's going to be a hit or miss. It just depends on how extreme the reading is. And sometimes the market reacts. Sometimes it doesn't. And then on Friday, just the Chicago business parameter. This usually does not move the market. And then the bond market actually closes early. So I'm not sure if that's going to affect liquidity in the market that day or not. And maybe the market will feel slow. This whole week could feel slow. People are just coming back from holidays, probably. People could still be out on holiday. So there might be really nothing going on this week. So in light of all the inactivity this week and lack of data, I would definitely just take it slow in the market. You don't have to rush or anything. The new year is going to start soon. And you'll probably see a lot of new portfolio rebalancing. A lot of action in the market. Once the new year comes, that's when you start seeing big money investors kind of start to rebalance their portfolios. They start getting in and out of large positions. And you will see that reflect in the price action with volatility and also overall just good volume. And on to the seasonality, which is kind of just proving my point, you can see there's actually from the 26th to the 31st, which is tomorrow to the end of the month. It's basically averaging chop. You don't really see anything major here. You got 47% of winning trades in the last 15 years in this little setup. So there's really not too much going on in terms of seasonality either. It's kind of choppy, which really matches the indexes right now. The spy and the QQQ are both stuck in a range. And you can see we kind of don't start going up until after the first. Once the first comes, you do start to see that kickoff to the upside all the way up into the 12th of January, about midpoint of the month. That's when the action can start picking up. And like I said, it's when you'll start seeing that portfolio rebalancing in the market and you'll probably see a lot more action than you will see right now. That's after all the holidays are done, after everybody gets back, after Wall Street gets back from whatever they're doing, probably some extravagant vacation. Once they get back, you start seeing that activity in the market and you'll probably start to see more of a trend. And obviously the market can still move regardless of volume. The spy and the QQQ melt up on low volume regardless. But if you want to start seeing those bigger moves, you kind of do need a little bit more volume, a little bit more activity, a little bit more participation. And onto the setup. So I just go over them real quick. So this week, I was only able to find three that I like and two of them are probably just going to be day trades. If you weren't going to day trade them, you definitely want to buy time because they are shorts and they're for puts. And with any puts or any shorts right now, it's extremely risky because you get the Fed kind of greenlighting the rate cuts coming up early in 2024 and a lot of people are kind of grasping onto that. And it makes it a little bit more hard to short. It makes volatility a little bit lower. People are more hesitant to ensure their portfolios with puts and overall demand for hedging is just down. So number one, he were to go over UNG real quick. I've actually had this on the list before. It had one really good day. Once the market opened Monday, the last time we looked at it, ripped like 7% and it's been selling off after that ever since. So now that it's made it back on the list, I have a pretty good reason to expect a potential balance in this. You can see that these bull in your bands are flashing multiple signals on the one week. You got one, two, three, four, five arrows. This means these are five arrows going outside two standard deviations, which is two standard deviations away from the median line, which is this 20 SMA might be the 20 EMA, which is the median line for the bull in your bands. So price is two standard deviations away from this median line in the bull in your bands up here. This would be two standard deviations above the median line or 20 SMA. So a lot of times if price starts to get two of these upper bull in your bands or lower bull in your bands, you will kind of see the market try to snap back. People assume that the market gets oversold. It's trading outside two standard deviations and they'll try to bounce or reverse. You can see it right here. Pulled up into two standard deviations above fell. Did it right here as well. Pulled up into two standard deviations fell. Likewise, here to the downside, it's been flashing the signals, but we haven't seen that snap back yet. We are just now starting to see some signs on the one week candles that we could see some type of reversal. So you have a somewhat bullish candle here. I wouldn't say it's the most bullish candle because you don't really have any confirmation of taking out a previous low, reclaiming over a previous high, anything like that. But now you do have this one big lower shadow with candle right here, which looks pretty good. It looks like buyers are trying to put pressure to the upside. And also this is coming off of a bottom. If I saw a candle like this at the top of something at the top of a trend, I'd be a little bit more worried, but this is more at the bottom of the trend. So it could be trying to signal a reversal. I already do have 100 UNG shares, and I also have some clapped options. I spent about $200 on some six and seven calls a while back, and they just were not able to do anything. So I may be willing to put like another 200 bucks in there for options. But overall, I'm kind of just holding my shares right now with a 550 average. So I'm hoping eventually it can snap back, get above our average, maybe run back to 587 and beyond. It needs to get over 587, which is the slow before I can project higher. So if you were to get some calls on UNG and you want to play that seasonality pattern that comes up towards the winter, you will want to buy probably March expiration, maybe even later than that, with a February expiration at minimum. So that's for UNG looking at calls. Max upside I could see over some months. 587 need to see what it does from there. But hopefully this little one week candle with the lower shadow we can turn into a reversal. And next, we're going over CCL. So this is pretty simple. It's pulling up into this 1955 resistance. So I'm watching this actually for a pullback down into 18. 18 is this little wick low right here from when we dumped last Wednesday. We pull back very heavily in the market just for one day and then we snap back. But that is the pretty much max low for right now. I would like to see CCL pullback into that. And I'm going to be looking at puts on this. Probably just day trades, nothing major. And I probably need to see overall, I need to see get back under the nine EMA to even really project any lower. And then you also have this one day MACD going negative as well. Let me turn these bullying your bands off. You can see the one day MACD starting to cross negative. So that's one momentum signal kind of starting to go negative. And then you have this big old resistance. Obviously risk off would be if it starts breaking out kind of like NCLH a couple of weeks ago. NCLH had one decent pullback the first day on Monday. Pullback about 3 percent. And then after that, it just totally ripped. So these little cruise line setups can definitely rip to the upside, especially when markets expecting great cuts. Got to be careful with that. But either way, good risk to reward here. You got the MACD going in your favor. And then overall, I really would need to get under the one day nine EMA team project any lower than $18 right now. So that's for CCL looking at short term puts. Definitely wouldn't swing short term puts overnight. But if you were to do any further outputs to swing, you definitely want to go with probably February minimum for expiration. So that's for CCL risk off over $19.55. If you wanted to be a little bit more aggressive, you could probably do risk off over 20 flat. And like I say, I want to see that pullback down into the 18s, lower 18s that probably give you a nice little pullback to the downside. Maybe pay about 20 to 30 percent on some options, depending on how the premiums are paying. And last but not least, we're going over UPST here. So you can see this is actually a huge drop based drop supply zone. As mentioned right here, it's drop creates a base. Huge drop to the downside. This one candle was down 34 percent. So this is a huge sale imbalance. Something happened in this candle to lead to this sale imbalance. And that's why it's kind of starting to see that resistance right here. Ironically and conveniently, once it got up to this base candle area, you can see there's a hard rejection candle right here from Wednesday.  So one thing I need to see, you need to see it take out 43 33.  Maybe something like that. It's this little wick high right here. It's a little base back test area right there at 3802. Once price broke over that, that's kind of when the momentum started. So watch that 38 base. If this 43 33 breaks down and fills that down candle, that 38 level, probably try to hold up on the short term. But make sure you wait for the signal. So go ahead, mark that 43 33 hit add alert. We'll name it structure low. And then once 43 33 breaks, that's your signal to go lower. You want to wait for that signal like last week. So we had SQ for puts last week, and it wasn't able to give us our signal under the Friday low. And it ended up breaking out of the downtrend. So if you would have paid attention, make sure you didn't go short until it broke under the Friday low. You would have been saved by that. And you wouldn't have entered prematurely because SQ actually did rip. So we never got our signal on that. Unfortunately, I think the only setup that worked good last week was probably CVX and then we also had Uber. I guess I had one 2% down day. My February puts went up to 20%, but I wanted to get more out of it. I want to see it get under that nine EMA. So I'm still holding those February Uber puts. So maybe that'll play out in the next couple of weeks. We'll see. But I would say CVX was the only setup last week that did pretty good. I had two green days. I would say there's a really nice rip off of 150, which is that support or the reclaim zone. We want to see it back over and had a pretty good run off that, made it through almost all the gap, but kind of fell short and had some resistance towards the end of the week. So hopefully this week, it'll be a little bit more consistent on our trade ideas instead of just one kind of playing out. We have had some really good ideas though the past couple of months. I mean, every week there's been one type of banger in there with multiple runners as well, kind of all on the same list, which is pretty rare. It's not always going to happen, but I do like to see that consistency because then I know for a fact if one person just took one of the setups that I know that I worked for them. So that's why I like to see that, but I don't expect anything out of the market like that. It's not just always going to work perfect every single time. So you got to be careful with that. Hopefully this week, UPST will break down this low, kind of give us our signal. CCO, you already have a confirmed rejection at resistance. So I don't think you really need to wait for a signal on that. Just maybe be careful with the nine email if it can get down there. And then UNG just buy time. You want to be patient with that. It's called the Widowmaker for a reason. Natural gas is the most volatile commodity you can trade. So you got to be careful with it. So that's the video guys. Like I said, buying QQQ are stuck in a range this week. There's not really anything I can give you on this other than watch for resistance at 475.90. You can probably try short-term puts off that area if it can get up there. Maybe trade the breakout if it can get over that 475.90, but right now people are just waiting for the highs to get taken out and they kind of trade off of that or waiting for some type of dip into a structure low. That's going to be around 470, a little bit lower than that at this demand zone. So if they can pull into that area down here, you can see it actually pulled into it on Wednesday. So the seasonality actually had us pulling back a little bit last week and we did get that in one day right here.  It was still able to follow that seasonality and then people just bought the dip right away for the Santa rally. So this is a rally base rally zone pulled in one candle, ripped to the upside for two days. So that's basically it guys. I mean, there's not really anything here. You gotta wait for 475, 90 to get taken out. You could probably look for resistance of that area short-term for short-term put trade or wait for it to pull into demand around 470 to 469, 50s. And that's about it. Same for QQQ, basically stuck in a range. So just make sure you're marking your structure high and your structure low from this big red candle. Also this little rally base rally demand zone, you can mark that as well. You can see it had a nice push up candle right here off of it. So we're still bullish, but just haven't broken out yet. So it's the video guys, hope you guys enjoyed. Make sure you like, comment and subscribe to our X-rays YouTube channel. Starts a little bit short this week, but indexes are stuck in a range and it's pretty hard for me to find setups as well as I really didn't get the chart as much as I would like to because I was a little bit busy for the holidays. So hope you guys still enjoyed. I love you guys and I'm out.


Ellie. Hi, I'm Lays from Ellie, formerly known as ESO Library, and we are honored to be the visionary sponsor for the KTESOL 2022 State Conference in Pasadena, California. For the past 20 years, Ellie has been empowering English language teachers with highly engaging content, meaningful assessment tools, and interactive courseware. Today, Ellie is used in hundreds of schools and language programs across California and many more across the United States. Most of Ellie's success has come directly from connecting with teachers like you, so please stop by our booth at the KTESOL State Conference. We'd love to connect and see you there.


TFNN headline news update. Hi everyone, Basel Chapman here. This is the TFNN noontime update and I am the host of the Tiger Technicians Hour coming up straight after the update and the author of the opening called Dating News, led here at TFNN. Dow is down to, yeah, down three points at $26,998. Let me just show you this very quickly. We've been talking about it for some time. Let me get it right here. There it is. Chapman methodology. We look for the lowest low bar, most identifiable low bar, and we merely count each successively higher peak at the fourth highest peak D, optimized sequentially on the way up. That fourth highest peak is where we're looking for something to happen. It could be a sharp pullback. It could be a recycle, but at D, other things can happen. Well, what did we get? We got peak C at 27,123 days ago. I was anticipating today, if it wasn't for IBM, that there would be a move just above 27,120 to start leg D. The futures, the YM actually did that this morning. They went to a leg D. Look at that. Slightly higher high goes to a leg D. And if you look at the S&P, there we are. We're just a fraction away from it. And boom, we got it today right there. You've got your D. You've got the QQQ123, the QQQNDX100 in leg D. So this is where other things can happen. This is where I'm getting a little bit cautious. I haven't done anything yet in the cautious side other than we've raised money for subscribers because this is very important. Look at the dollar. The dollar is pulled back very sharply. It has gone from 99.46 down to today's low. And today's low is the 97.50 area. And that's a big move. Two points just boom, like that. And if you look at the gold, gold is right now trading at up 6 at 1,500. It's trading in back in that rectangle formation that I've been talking about for months, actually. It's just right back in there. If you look at the crude oil, crude oil at this particular point, it's just showing no real signs of strength. I like to see crude oil strength because that means you've got some kind of economic activity there. Down 41 cents at 52.96. And the TLTL has been more time in my show. The Tiger conditions are coming up in a few moments talking about the TLT. Bonds are up. The TLT is up 25 cents at 36 cents at 140.27. Just stuck in a rage, not going anywhere at this particular point. So this is really a very important moment. The volatility index is down at the, actually, it hit the low 13s at the 14.10. It's in a basing area. We'll see what happens over the coming few days. I'm a little cautious right now. I'll be right back. We'll talk about it.