I've felt those things. What's so amazing about fighting, it depends where you're fighting, if you're not in the act of fighting, you won't be humbled or you won't be set back to balance, but if you do these things and you're training in some way that where there is sparring, where people aren't holding back, you will get humbled, you will get stopped. And it's very hard to hold on to a lot of anger. One of the best things you can do for your anger and frustration is get submitted 10 times in 10 minutes or whatever it is. Wrestle with somebody who's far better than you. Spar with somebody that you just can't get inside with. And that's a huge, huge thing. One of the other things we were talking about just before the break is when we are out of touch with these and we decide to act on violence or we decide to act on control, we get into levels of rage and frustration that are almost impossible to control. For instance, somebody was talking about self-defense and knives, and we train like, nobody wants to get in a knife fight.   Same thing I'd say for any sort of weapon. You want to use that last and even your hands, but check this out. If I'm fighting somebody, when we hit those levels of frustration or if we've dealt with some sort of trauma or emergencies in our life, what happens is we black out, okay?   And those types of things, which when we misuse and abuse, it's a fucked up thing. Same thing goes for seduction. When I'm hitting different states, when I'm having sex with a woman, when I'm hitting different planes, I find it like meditation. Meditation, even in action. Whether I'm having sex that's aggressive or fast or slow or just really calm and paced, it doesn't matter, I'm in a different zone. But at some part of that zone, I believe it's so divine that I can't control. If I'm misusing that, if I'm out of touch with my identity, if I'm out of touch with myself, if I'm still afraid of who I am, if I still have anger towards women or if I let that into my exchange so I can perform a technique better, it's gonna get all out of control. I start having sexual experiences with people I don't want to experience with and feeling things I don't want to experience while I'm having sex with them. I get lost when I get lost, I get afraid when I get afraid, I start to control. All right, so these are some of the things when we move into that dysfunction. The key to getting out of this is to get into action on it. Do the functional tool. To push your comfort zone is a great idea, but if it is not serving a result and being let go of once that result is achieved, it's gonna lose its functionality. All right, so what we have here is this is something which I feel is real important. One of the things that I love so much about applied like martial arts or fighting and even when it comes into seduction is moving in this area. A lot of times, and I've spoken about this many times before, but we have technique. A technique defines application. This is like who we talk to, why we talk to them, the situations we talk to them.  Where does that work? Well, our application is allowed in a nightclub, right? And then that serves our identity. We get this lost frustration. Remember, we go into the dysfunctions, we start getting pissed off, mad, whatever. Because people aren't attracted to us, they're attracted to a facade and an image. Now, one of the things that I think is so important is everybody's an individual, you know? I can't practice Brazilian jiu-jitsu like anybody else in this room. I can't practice sparring like anybody else in this room. I couldn't practice diet like anybody else in this room. It is dependent upon my identity, finding out who I am, what makes me work, what makes me function and what fuels me, what I'm attracted to, what's attractive about me. You know, those are really important things, especially when it comes into social interactions. I need to know what I want, I need to know who I am. That is going to define my application. If I'm somebody that doesn't like dressing up and staying up late or whatever, or being in nightclubs and I'm not going to pick applications that move in that direction, I'm going to pick applications that are tailored towards me and then my technique is going to be based on that. The results of my technique is going to feed back into my identity. Okay, same thing for fighting, same thing for application in terms of sparring, boxing, whatever it is, kickboxing is a lot, yada, yada, yada. It's going to be dependent on who I am, my speed, my strength, my stamina. If I have, you know, if I'm more of a cognitive fighter, if I'm somebody that likes to feel things out more, it's going to define how I put out my application, how I approach, how I engage, you know, how I even pick my opponents. And then my techniques are going to be applied. The execution and the results of that, whether they're failure or their success, is going to feed back to who I am and the evolution can take place. We'll have constant growth if we move in this direction. You can apply it to any single one of your goals, whether that's business, God man. If it's some of the fitness stuff that we've heard about and do the same thing in terms of diet. Also it's very important that to know every single technique you do needs to serve this, okay? Self-expression, it is huge. We are not serving a result. Of course results are good, man. Results are great things. They motivate us, they get us to believe and push forth in so many different things. But every single technique that we learn, all right, whether that is to be bold, be direct, be passive, be more aggressive, be sexual, start yanking girls around, start grabbing people by the neck, pulling hair, all that sort of stuff, that is an outlet of self-expression. If I'm focusing on my diet, if I'm changing my diet, if I'm being inspired by whatever it is, being a vegan, being paleo, eating grass-fed stuff, yada, yada, yada, that is an outlet of my self-expression. When I get results on that, whether they're a failure or they're a success, I'm going to then self-explore. Through sex and seduction, I found out so much about myself. I realized when I got rejected, I got angry. I got sad, I got depressed. I could do the same outlet of self-expression, be the same person, right? Same application, same technique and get success and I could get failure. I could get both of those things.  When I failed, I hated myself.  Why am I so angry? Why am I so upset? And thus gave me an opportunity to explore who I am. This is why I think socializing and sexuality are such important fundamentals of who we are. Through that, I then had to learn how to accept myself, take a look at myself, all right.  I could talk to so many different people about this, even my trainer, Ed.  You have to realize that. The only chance that you have about through transitioning through that is accepting who you are. It's the same thing that he would talk to me about in terms of fighting.  You don't have reach. I'm not James Marshall. He was like, so am I gonna have to spar with you up there? I'm like, fuck, I don't want to, man. I couldn't even get close. If he just keeps me away with his long limbs. So I need to learn different ways of self-acceptance of how to use that. If I'm an angry person, that's okay. I need to first say, all right, this is who I am. This is how I'm gonna accept who I am and live my life, right? Once I can come to terms with that, a level of evolution can take place. And this is where we get into self-love, which is the ultimate thing. The only way that I can truly seduce, because it's a process, we're gonna make mistakes. The only way that I can truly put myself into action is.


The following video illustrates the work that was submitted to clinical anatomy as an original communication in fall 2014. We present a novel three-dimensional model of Lambert spinal structures of anaesthetic interest. In the article we describe how the anatomical 3D model was reconstructed and provide a hyperlink from which the model can be downloaded in PDF format. The web page that opens contains a short description of the project and its versions in different languages. By scrolling down we can access the PDF file with a 3D model. It is very important to point out that the file should not be open in the internet browser but rather downloaded on the user's computer. Apart from the 3D file, the instructions and the license file are available. They should all be downloaded and saved in the same folder. After locating the folder with the downloaded documents on the user's computer, the 3D PDF file should be opened by either Adobe Acrobat if one is installed on a computer or by freely available Adobe Reader. After opening the document, in the middle we can see the 3D space containing the anatomical model. The model is rotated by holding down the left mouse button and moving the mouse. The 3D space contains anatomical structures of which at this moment the three vertebrae are visible. The L3, L4 and L5 together with the 2D MRI slices that will serve us as a reference. On the left of the document, the predefined views of the model are available. The default view, the anterior, lateral, posterior and superior view. The model can be zoomed in and out by right mouse button or the scroll wheel and translated in space by holding both right and left mouse button. If we click on one structure, it is highlighted and its name appears in the drop-down menu on the left. The structure can be hidden or made partially transparent in order to make adjacent structures visible. By button show all, we visualize all structures available and observe how to partially transparent vertebrae L4, the dual sac and epidural fat are visible. Next, let's hide all the structures and visualize L3 vertebrae and dual sac in order to demonstrate how the MRI slices functionality works. By selecting the axial option, a T2 weighted magnetic resonance image with axial orientations appears in the 3D space alongside the anatomical model. It is possible to navigate along successive images in each orientation. If we make dual sac partially transparent, we can observe how it corresponds to the lighter area on the MRI image. The reason being the cerebrospinal fluid contained within its walls. On both sides, the dual sac has extensions known as dual sleeves containing the nerve roots of caudeachina corresponding to the darker oval area in axial MRI slice. The images in different orientations can be shown independently or in combination. In sagittal option, we move along the sections from the left to the right and again observe the correspondence of the 3D structures and the anatomical sections. In coronal option, we move between the anterior and posterior sections. Starting again from the default view, we will show another available feature, the clipping. The model is cut by a clipping plane in a selected orientation which allows us to see the structures from the inside. The offset can be changed in order to move the clipping plane along the successive cuts. Clipping is available in all three axes and if we show all the structures together, we can see how they overlap from the inside. Apart from these buttons on the left that serve to facilitate the interaction of the user with the model, the document also contains an additional functionality, an educative presentation that consists of predefined views and their short descriptions. The presentation is reproduced by clicking on the number buttons at the bottom. The presentation starts with the general view of the lumbar spine and moves to the anatomy of the vertebra, the body, the pedicles, laminar and transverse processes. Next we observe the trajectory of the needle during an epidural block, medial approach to the vertebra canal. After the needle is inserted through the skin and passes subcutaneous tissue, it will cross various ligaments, first the supraspinous ligament, then the interspinous ligament and after this the ligamenta flava or yellow ligaments, finally reaching posterior epidural fat. Now we can observe the dural sac and sleeves, inside of which the nerve roots of caudaicina or horse's tail are located. In blue the sensory roots and in red the motor roots. The detailed instruction on how to use this document can be accessed by clicking on the question mark button on the top, which will open the instructions file offline in the internet browser. The main information about the authors is given as well as the short introduction to the project, after which the image is provided containing the interactive buttons that lead to different chapters explaining each particular section of the 3D file. Thank you very much for watching and do not hesitate to download the files and try them out yourselves.


Hello and welcome to NewsClick's daily roundup. I am Praveen Purkayashta and we are going to look at the headlines of the day. Unprecedented, disturbing says former chief election commissioner on the rift within the election commission. A quick overview of the eight states that are going to polls in the latest phase of the 2019 general elections. A look at our field report from Punjab and how this state has been reeling under the problem of severe drug abuse. In our international section today, we will discuss US Secretary of State's recent visit to Russia. Former chief election commissioner, Naveen Chawla, told NewsClick in an exclusive interview that we have never seen such a crisis in the election commission before. This is unprecedented that an election commissioner has recused himself from the meetings of the election commission because his views are not recorded. A look at his interview, which he did with Paranjaya Gautha Kutta of NewsClick today. I find this disturbing because from the time that I joined the commission, which was when Mr. Tandon, chief election commissioner, we had a norm of meeting every day and it wasn't just the three commissioners who made every day. It was all the officers, the deputy election commissioners as well as our two legal officers. So there were always at least eight or ten other senior officials who were always there in the room and we met Monday to Friday every day barring the odd day when somebody was traveling. So I can clearly see from this that everybody is not meeting every day and they're not meeting with the officers. This is not throughout the year but you're in the period of the elections. No, I would say that this was a very good practice throughout the year, all the time, irrespective of whether elections were on or not because we were constantly going into one election or the other but even otherwise. So I am disturbed by the fact that that very good practice and it is there cast in stone in my book because it's very important to say that all the officials of the election commission, the senior most officials were always there and participated in the decisions and any other, if there was a dissenting, let us say, position that I take, it was there before all to see. Chalaji, it's like this, according to media reports, Mr. Sunil Arora called Mr. Lavasa, they had a meeting and according to the chief election commissioner, only the minority views are recorded only when there are quasi-judicial proceedings and these need to be recorded and decisions pertaining to alleged violations of the model code of conduct, since they are not considered to be quasi-judicial proceedings, they need not be recorded. Let me just say that the election commission, the commissioners and the officials must all meet every day in my view. That was a healthy tradition started by Tandon, continued by Kupala Swami, continued by me in my time and I think continued by Mr. Sampath thereafter and possibly Mr. Koreshi thereafter. Now what legal recourse does somebody like Mr. Lavasa have under the circumstances? I do not know, this seems to be an unprecedented situation for me, I don't know. Tomorrow is the last phase of this time's general elections. Eight states are going into elections. Let's have a quick look at which are the seats which are going into the polls and what were the seats that were held by the respective parties. Just one more step, one last step. Yes, this is the last step of the 2019 elections. In this last step, eight states will vote on those six seats. The most important of these is Uttar Pradesh. Yes, Uttar Pradesh, from where Delhi leads. In the last step, 13 seats will be voted on. One of them is the Prime Minister Narendra Modi Omidwar from Varanasi. Last time, all these 13 seats were with BJP. Apart from this, 8 of Bihar, 3 of Charkhand, 4 of Himachal Pradesh, 8 of Madhya Pradesh, 9 of Pashimbongal and 13 of Punjab will be voted. Ravivar will also be a member of the Kedrashashit Pradesh Chandigarh's Iklavati seat. These seats are very important for NDA, especially for BJP. In the 2014 elections, NDA got 41 seats out of these 19 seats. Whereas, Kulpas were the seats in the UPA. And Anand won 13 seats. Stake with election coverage, Punjab is among the 8 states which is going to elections tomorrow. The drug problem that has been there in Punjab has claimed a number of lives including among the young people. This is a problem that has been looming in the state under both the ruling parties, Congress and the Akali Dal. To have a look at this problem, we have Ravi Kaushal, news click reporter who has gone to Jainpur village in Shahid Bhagat Singh Nagar which lost 19 lives in a single year. Let's take a look at this story. During the election coverage of Punjab, we have reached the Jainpur village of Shahid Bhagat Singh Nagar. Why have we brought you to this village? There is a special reason for this. The reason for this is that in the last one year, 19 children have lost their lives due to drugs. To discuss this issue with us, some people will tell us how the problem has been solved. And what do they think about it? There was a lot of intoxication in our village. This caused the death of 10-12 children in our village. Some of the children were like this. They were not wearing the clothes of their parents. Tell us, how much intoxication is there in this village? There is a lot of intoxication in this village. There is a lot of intoxication in this village. In every village. Wherever it is, it is also in our village. And all the other villages are like this. This is not the case today. This is the problem of our village for the past 7-8 years. That is why the government has been doing this for 5 years. The government has also changed this. That is why we are bringing children like this. Moving on to our international section of the roundup, I am going to hand this over to Abdul. In our international section today, we are discussing US Secretary of State's recent visit to Russia. American Secretary of State Mike Pompeo visited Shokhi, Russia and met Foreign Minister Sergei Lavrov and President Vladimir Putin on May 14. This is a significant meeting considering the publication of Robert Munner's report in April this year, which unleashed Russian interference in the American presidential election. This was Pompeo's first visit to Russia since he became Secretary of State. This was also the first meeting between the high officials of two states in more than a year. Pompeo also stopped at Brussels and met European leaders and discussed Iran. To discuss this, we have Pravir with us. Pravir, what do you think is the meaning of this particular visit at this particular juncture? See, there are two issues really, I think, which makes this visit important. Whether it has achieved anything or not is not clear. One is that with the Mueller report having more or less absolved Trump of any collusion with Russia and Russian government in his election, which was the charge with the Democrats have been levelling against him. I think the issue is that it is possible for Trump now to take some measures to normalize relations with Russia. As you know, the relations have been strained, sanctions have been imposed and though Trump did indicate that he wanted to normalize relations with Russia, a better relationship that has not transpired because he's been isolated with the pressure that he has been colluding with the Russians for his own elections. So, I think that has it really moved far enough for him to be able to have a quote-unquote reset of the relationship. It's an open question because the pressure of the Democrats and Trump is still great. They have said, Mueller report is not complete. There are sections which need to be reexamined. There are redactions. This sort of the drama of the so-called shall we say Russia hacking US elections still goes on. For all of us who have been studying all this, it seems rather dubious, given the fact that the US has hacked nearly every elections in the world and it's also on record having stated that they basically helped Yeltsin win. So, you know, if all of this is taken into account, the point is that how long can this sharan of Russia hacking US elections really go on to believe that the NSA and the CI with all the positive shall be surveillance capabilities and the disposal could not stop this. It seems to be, shall we say, make a mockery of what their capabilities themselves are. So, I think this recent can it happen? I don't think this has yet happened or this visit has accelerated that when Trump meets the sidelines of G20 Putin or if he does, then we will have to think whether a reset might be possible. Thank you for that. With this, we come to an end of our daily roundup today. Do keep watching news click and do visit our website.


Dana Stevens two goals four assists on senior day today at one point in the first half We're talking about the fact that the single-game assist record was seven. You didn't get there. I'm so sorry But otherwise a pretty perfect senior day, huh? Yeah, I was actually a lot of fun all around For you again I know that you might be in danger of crying when you start thinking about it, right? But everything you've been through the coach, you know talked about the bumps The bruises along the way to get to this point now to be able to celebrate enjoy your senior day like this And get ready for you know, like one of the best games ever coming up on Wednesday night What is this entire ride meant to you? Oh everything I mean, I've learned something new every year every day with all my teammates on and off the field So to finally be here, I think it's like a good way to go out. We're gonna give it all and we're gonna take it We've asked you about this before but Dana you are the oldest. I'm sorry the most senior player In that attacking end. Yes surrounded by a lot of young Underclassmen, how has it been for you to step up and assume that role of leadership? Well, they've actually done really well like they listen to everything I give advice for they give me advice too Like it's even on the oldest one. We all listen to each other. We all work as a group So it helps a lot to know that I have even though they're all young and they're freshmen They listen very well and I listen to them So it makes it a lot easier when you have a group that works really well together. He's shouting out on senior day. Oh My mom It's always the right call congratulations. Thank you very much. Thank you very much


Let me now address the situations where there is no conflict rule in any of the conflicting treaties. Which treaties should prevail? Absent any rule governing the conflict between obligations, the crucial distinction to be made is whether the two successive and conflicting treaties are binding on exactly all the same parties or not. Let me explain this, it's fairly technical. In case of successive treaties that are binding on all the same parties, article 30 paragraph 3 of the Vienna Convention gives preference to the later treaty by saying that I quote, the earlier treaty applies only to the extent that its provisions are compatible with those of the later treaty. And of course, in other words, and to use again a Latin phrase, lex posterior derogat priori. The later treaty prevails between the parties and the earlier treaty, which has not been terminated, only applies to the extent it is compatible with the obligations under the new treaty. Giving preference to the obligations arising from the more recent treaty is a sensible solution because one can presume that states have concluded the new treaty knowing what their prior obligations are. And that if they decided to have new obligations conflicting with the old ones, it was precisely in order to replace the old ones by the new ones. As all the parties to the earlier and the later treaties are the same, there is no risk that any of them concluded the new treaty in order to escape prior commitments. But what happens if the parties to the later treaty do not include all the parties to the earlier one? What happens if the earlier treaty was concluded between A, B, C and D, but that only A, B and C have concluded the later treaty leaving D out of it? In such a case, if preference is given to the later treaty, then D would be deprived of its rights under the earlier treaty. Applying lexposteriori in such a case would amount to lawfully permit to circumvent commitments made under the old treaty, and indirectly encourage states to conclude a new treaty in order to deprive some parties to the old treaty of their rights under that treaty. However, as a matter of treaty law, such deprivation cannot occur without the consent of the parties to the earlier treaty, which are not bound by the new treaty. Then what should be done when the parties to the later treaty do not include all the parties to the earlier one? Article 30, paragraph 4 of the Vienna Convention does not provide for a uniform solution and requires to make distinctions according to the specific relations that are at stake. In the relations between the parties that are bound by both treaties, the same solution applies as when the parties to the earlier treaty and the later treaty are identical. So in the example I gave earlier, between A, B and C, the later treaty applies and the earlier treaty will only apply between them to the extent that its provisions are compatible with those of the later treaty. However, in the relations between a state party to both treaties and a state party to only one of the treaties, the treaty to which both states are parties governs their mutual rights and obligations under article 30, paragraph 4, B. This means in my earlier example that between D and any other states A, B or C, the early treaty is the only treaty common to all of them and therefore the only to apply between them. In other words, D can require from A, B or C that they continue to perform the earlier treaty in its favor even at the cost of a breach of the later treaty between them. And if A, B or C choose not to perform the earlier treaty in favor of D, then any of them would be responsible vis-à-vis that state. In other words, an issue of responsibility for the breach of either of the conflicting treaties will be unavoidable. And if the breach is a material breach within the meaning of article 60 that we studied before, then the issue of the suspension of or determination of the breach treaty may occur. Article 30, paragraph 5 of the Vienna Convention recognizes that. In other words, there is no perfect harmonious solution to all cases of conflicting treaties. And a state will sometimes have to make a choice between its various treaty obligations. The choice between preferring one obligation over another one will be unavoidable because performing one treaty will necessarily entail the breach of the other treaty. And that choice is not controlled by pre-existing legal rules on the basis of the nature of the treaty at stake. Is it, for instance, a human rights treaty or a trade agreement? Or on the basis of the special or general character of the respective treaties? Is it a humanitarian law treaty or a human rights treaty? Or on the basis of the nature of the parties at stake? Is it a treaty owed to another state or to another international organizations? At the end of the day, the choice to be made by the state will be a political choice rather than a legal choice because it will not be directed by legal rules. But of course the state will also make its choice in light of the respective consequences and costs resulting from each of the potential breaches. And those costs are issues of responsibility under international law.


printed hello world on its screen and it gave me I did it with either Java, Python, Hadoop or Ruby on Rails recently and there's one more thing I want you to know about me recently I applied for a deal I was damn sure I would be getting the deal but it so happened that they rejected my application I realized one thing even after a lot of preparation and a lot of confidence sometimes things can go wrong even though I've been practicing speaking at Toastmasters this is my first tech talk at a tech conference so please don't shoot me if at all I paint or I freeze in between the talk. Talk is a series of incidents that made me go that definitely this is not my style of presentation for the talk this style of presentation is taken from this awesome talk given by Giri Ben Hadid if you have already watched it please don't kill me if I'm not doing justice to the presentation and if you haven't actually watched it please do watch it it's because definitely you will have team runs of loads of laughter okay moving on how many of you know Rails please be humble to raise the hands how many of you know ActiveRecord how many of you know ActiveRecord callbacks the thing is I was told I must be asking the questions to include the to get the audience focused and to get their attention I hope I did it and then okay there was my my friend he called me and then he asked me can you can you see any difference in this code I was like dude I know I wear specs but still I can make a difference that is custom customer control controller and another is comments controller is like no can you tell me which model is using callbacks and which model is not using callbacks I thought for a moment and then I gave him an awesome game I was like dude you don't have to think so much to use callbacks all that you have to do is just use it and forget it and that awesome is come back and I just love it and moving on I was made believable and that was my first and it was the spring time in the year I was able to do my first production code and we got this requirement for this class account to activate the account only when the password matches like any good developer I don't expect to test it should activate the account only when the password matches and then I went to my code and then I added this method which returns either true or false and then was that awesome moment of adding the callback to the code first I callback I was adding to the production code I just did do activate the account when the password matches like before you create you make sure that you're activating the account whenever the password matches I went and then I ran the spec bingo it ran successfully intelligent as I consider myself to be and I added another test to test it should not activate the account when the password doesn't matches simple and as each and every one of you I was expecting the co-test to did not the test did not pass or that should be my setup error I thought that should be some error in the world but that definitely not my code definitely not my code which is like rock and even after you come out of that moment of your like my code is the perfect time took a lot of time like it actually took me a couple of hours to figure out it was that callback which was making which was making that test to fail if you already got the reason why it is failing please help please please leave me do that hundred of telling the reason why the spec was failing due to that active record callback it was failing because as each and every one of us know Ruby method returns the value of the last statement and though I have read it I've ignored the point that before callbacks fails and rolls back the transaction if it returns false so the assignment I was assigning false to a way people and it so happened that it was returning false from the before callback and it was making the road a transaction to fail and so was my test was failing I was like okay one error can happen but still contacts and it was like the summertime and I was on another project and and in that project what happened was the test sweet time it suddenly got spiked up by 10 minutes frankly speaking we did not know why was happening and honestly speaking will live with it for a month we ignore it because we did not know where to look at and up but like if you're like waiting 10 extra minutes for your test you to run every time definitely it will irritates you and when we found that commit which actually made the spike to happen we were like like the person who found like I found it and we were like we want to see it and he was like this innocent looking code which is what caused your test youth time to spike up by 10 minutes we were like what dude do you make sense that is this don't don't play pranks like this and then and then he explained see the user object is is object which is mostly used in our test here it's like you know of a the login and other stuff this is a most usually used object and it's usually created in each and every testing your test you and when you are creating your user object it's also calling your after callback and it's also creating your delayed job added in that creating one delayed job a synchronous job really doesn't hams you but if you're creating if you're calling after callback thousand time like it's just a number like that many number of tests that you have that many delayed jobs you're creating and then that when that time multiplies that would cost you we actually knew it we actually knew it but we did not realize that after callback would not after callbacks the callbacks would harm us like this and after all this definitely the time moved on and then it was the autumn time and I was like very I became more little more of discipline and discipline discipline and then I went through the documentation and I write that after commit suppresses the exceptions I was like okay like I haven't seen any dev who has written a code which doesn't have work like if at all you write a buggy code and then it doesn't throw exceptions where to go and then when I was googling like where to use the after commit I found this great best practices use the after commit instead of the after create to create your notifications or to create batch process or to create anything you want to create after the transaction how does it make sense like if there is a exception thrown in your after commit and there is some notification not sent to your user your user is not getting amazed but you're not notified about it your cash is not updating but you're not notified about it you would you would know it only when it's like too late so please be careful if at all you are thinking of using after commit after seeing such kind of a reference or you should be aware that after the commit suppresses the exceptions but the good the good news is but the good news is after race 4.2 after commit and also after rollback would be throwing the exceptions instead of suppressing the exceptions like that's a good news actually like yeah after all this I was I was thinking like okay like when the spring was started I was like okay by the time of the winter I would be like the master of the callback and I would be like this no one smiling all the time but it so happened that I was like I don't know I don't know when to use callbacks now everywhere it's troubling me everywhere it's cooking it's not and then I asked a lot of people and I did a lot and boom I found that secret sauce when to use the callback like before I give you the secret sauce let me ask you one question can you send parameters to callbacks now please don't tell me there are a lot of hacky ways to send parameters to callback I know you're all very very smart but this was never designed or never meant to be used like that you can actually send the parameters because your of the callbacks should deal with okay let me give the secret sauce like callbacks like should deal with it callbacks should be used only when the logic refers to the internal state of the object so now it makes sense like you want actually send the parameter like some something something from outside because callbacks they think that they already have everything that a callback should know the internal state of the object so yes like if at all you're using a callbacks use it only when it's referring to the internal state of the object the the problem with the callbacks is like it is like very easy to use and then it will it will make you couple a lot of things a couple of couple multiple things to get out and when this becomes like when you couple a lot of things like you definitely know what would happen if you have not listened to my talk till now it's okay but if at all if your codebacks has the callbacks and you are thinking of running some migrations please do take care of migrations because there's a lot of scenarios where it has just sent a mail and then a dev is not even like knowing that it's sending the mail


Hey traders, this is T Bradley 90 from the my investing club chat I'm one of the top mentors and moderators in chat as a special gift to our viewers on YouTube We have created a free two-hour course to help teach you how to start a consistently profitable trading business and Identify high-paying setups in just 30 days. There will be limited seating every week So register for the course and reserve your spot now Using the link in the description as a special bonus for everyone that watches the entire video We will give you the link to a free 10-hour additional mini course that has never been released to the public Register now before all slots completely fill up All right All right, so today I'm gonna go over the key traders of the week. I got some good trades on I got some good trades On them this week. So happy about that. I'm gonna be going over the the market sentiment I Do that every single week and if this is your first webinar welcome. This is kind of basically what I do every single week I'm I'm gonna actually skip the trader topics and fallacies that I normally do because I'm I think I'm gonna have to Spend most of the time on this on this topic just straight up adding to it So all right Cody and then we're gonna end the the session Q&A and so this is your first webinar the way it works is You can throw out a question at any time during the webinar and if it's pertinent to what I'm talking about and if I see it I will try to incorporate it into kind of what I'm talking about and try to work house This is a trade that happened. I think I've tried it You know probably I've tried it But I didn't get to go over it because it was like and yeah, like after the last webinar I think this is just a basic parabolic short trade. I actually haven't done this one in a little bit But I haven't done this trade in a little bit and I actually caught this trade live But think I think Alex like I haven't released it just because it's not my typical trade And so like I you know like and I already have a couple videos like that still need to come out And so like I might want to release this one as like a bonus one later Just, you know, like on it during a slow week or something But I luckily I got this one on paper. It's kind of fun to get parabolic shorts on paper But anyway for those who don't like you should know this already, but parabolic shorts. They're more of an advanced trade right And normally I only take them I only take parabolic shorts when it's really over extended on the one minute chart And this was essentially just an overreaction to news and this is often what a lot of like most of the parabolic shorts I do is is when news immediately comes out or if we're like super going parabolic after like a high day break In the middle of the day when like oh, it seems like the last of the shorts being squeezed out that's also another time but most of the time it's going to be on like stuff like overreaction to news and I Actually didn't say like I just say this and like this was right near the end of the day I saw this grade. I took it took the screenshot left. So I didn't actually see the rest of the I know what happened, but I didn't capture the rest of the chart This ended up like closing at around 320 or something It went all the way back up and this is the reason why you short on the front side of the move like this And you need to have the front side covered because like if this wasn't near the end of the day It's gonna be just like that's going right just gonna made a secondary push up the 330 just to see like You know like hey, are we going to go higher than this and this is just a temporary top So especially when I take parabolic shorts, I am 100% covering on that full deck. There's like I'm never ever shorting a parabolic hoping to cover the fade it right ever so um Disney what it's funny like so last webinar like what we talked about with large cats when Brian came on and that was That was a super fun one But I talked about how one of my setups in Large cat land One of the only reliable ones that I have for me Is a continuing a continuation of the gap basically if a stock gaps up I think there's a good long opportunity if it dips it if a stock gaps down I think there's a good short opportunity if it pops right so this is just you know the you know the long version Right, this is the gap of continuation right it's a setup I outlined in the last webinar Basically the way it goes is if it gaps up and dips you buy for the bounce right and the opposite And in this case, you know, this really wasn't a big win because like it's hard to size into this kind of trade I know I had one more ad under 37, but I didn't get it so You know That's just you know, this is more of a partial size or half size trade Um, but because there's no good chart level all I have to go off of is a whole dollar as a guide or And using like an estimation of what I think is possible for the range, right? You know and this and this just ultimately I can't say anymore But this just comes down to experience like, you know, you see charts and price act all the time You get a feel for what the range should be on the stock and you guys all have an idea, right? You don't really expect a stock that's trading from one dollar You know to one dollar and 50 cents to go off the floor, right? And so you can kind of work your way down and like well, can it go to 160 170 like what would be You know, you kind of estimate the range a little bit and side note This is why I don't like cheap stocks because it's so easy to underestimate the range And I've gone over that before and I'll probably go over it many more times, but TRNX so this is a trade. I don't know if this one's come out. Yeah Um You guys can let me know because sometimes I miss the notification, but TRNX I did a video on this did that video come out yet any with any annual or lifetime that saw it like Um, I don't know if this came came out yet, but I did a live trading video on this one But for those who aren't um, and okay, so this one should be coming out Um And also I think he's behind. There's another one that he needs to do Anyway, I don't know yet Anyway, so this is a continuation long and like I always say normally I suck Normally I suck With these right I just absolutely suck the continuation long and this is more of a airy trade right he's or I like I don't want to say that this is this setup, but continuation trades like carries a lot better at the money But nonetheless my idea for this trade was that 235 was holding right So what I did was I basically watched this do its first bounce and so this is where the first bounce trade ends for me Right, this is where the first bounce trade will end for me or at least for half of my size If this is the first bounce buy, I'm getting you know, roughly half hop here And I'm you know, now I'm just seeing if I want to sell like the rest on a hop over if I'm gonna stop out break even So this is where like the first bounce trade would end now. I didn't get the first bounce on this because I I know it's probably looking something else But um, I can't remember what I was doing at the time, but I didn't get the first bounce trade on this um But what I was watching was it consolidating here and what I was hoping to see was that like I was really interested in this pop over Right this and you can see the volume. So everyone else was interested right volume's kind of like the key here to let me know Like what level is important? Um, and I think I talked about in the very first Um video I ever did I really like to see like when a stock pops over or under a level with volume It normally means that was a very significant volume because a whole bunch of people paying attention So I look to see what's an important level to break and that was 235 And you you don't have to be a rocket science. It's a pop up here and fail pop up here and fail And then when we break over there's a volume panel So what I wanted to see was to you know, if what I was now looking for the second this happened was if You know, we were going to hold a higher low and like I just guessed it would be 230 because that's just the The next natural number And that's why yes, this was yesterday um, so I traded this one two three four times Um, I I shorted this in the morning for like a quick little break even scalp Right, I shorted here out of there and like, you know covered up like I got a baby covered and covered the rest breaking late Not not a money-making trade um But yeah, I tried to scalp it short in the morning and like it just was holding up more than I wanted and oh My tags are in the way But like I'm really glad I covered because it eventually did spike all the way back up to 40 after I got out I'm like I knew like I would have been covering up there So I'm like I wanted to get this off right even because it didn't it didn't immediately like pull off the $7 emotional stuff kind of like the workhouse parade. I just went over This is where it kind of like pulls kind of immediately after we had a little bit too much Uh consolidation up here for my lighting. So I just took it off um Okay, then I tried to buy it for a replay and I might have been reaching here But I really liked the volume and the float was like like a million shared or less And so like, you know, I thought it worth it to give this one a chance Um, and it and I and I lost on it, right? Uh, what's up, Brian? Um I thought it weren't the chance um and like this one just didn't work and Like I had some slippage here.  I just slipped I mean it'll just work wonders for for your trading Yeah, and that's obviously It's easier said than done because there's just the psychology Especially if you're on like a nice streak and you just can't take the loss like you refuse to take the loss That's how it turns into a big loss So I think like sizing is just a huge part of it and and like you said, you know waiting for that confirmation to add That's just that's huge for for like newer traders or just anyone in general Yeah, it's just So the thing is like and that's why I had that quote up there Your account only cares about the trade you take you might care about the trades you miss but your account doesn't ever see it Right, but everyone's afraid that like, you know, like if I lower my risk and I stop out and then it works like You know, like that's super super bad and it's not good but it's As long as all of your trades fit within those like in your game That's that's that's what you need to focus on like I'll take a small cut On a other trade that even if it works after I'll take that small cut because why It's not gonna I'm not gonna end up with a small cut every time and that big win is going to cover like three or four small cuts Yeah, exactly Maybe more because if you can get really good at it like CRC, I was like five cents on that trade I was going to make like 60 cents on that trade like 50 cents like That's like 12 times To eat and drive Sorry, I did not I think I cut there. What's up? Oh, no, I was reading a famous comment. He said is it an offense to eat and drive I don't have any like questions. Yeah I had a uh, I had a short on uh, cgc today um, and Man, I covered that so early. I shorted at uh 1625 I wasn't pretty small but um Yeah, I took it off at 16 and then I was joking with uh, Joe and brian that like all right now It's thank you the low of day. Sure enough that she went to like 15 20 and um Yeah, I feel like recently uh this week just uh, taking things slow. Um, I've been uh covering my trades pretty early but You know, like you said with adding to the winner Uh, I like sometimes to just take that initial scalp To pay myself and then this way if it does pop up, you know, I could re add Uh, a lot of times what I'll do is like I'll cover half and then I'll re add more but then keep that same risk intact Um, I wanted like 1650 line on it, but I hit 1625 because I was going to scale up to it So like there's pretty much starter size, but And bro, that's a recycle. That's a form of adding right that's and that's literally a form of adding And oh my god, dude, like how did I not see this today? Like this is literally like the the gap down Tray bro. Yeah, exactly You are you uh, you mentioned that in the last webinar. Yeah, I love this strategy I've been tracking it a lot and so I just made a new all-time low Just completely dumped into uh, all player like yearly low whatever it was from the uh, the yearly chart you can see and um yeah, so yearly low and uh Just pre market like it was just getting hammered so I was praying for a pop I missed like the initial short. I want to say I can't really see some of my phone So I don't remember like the exact levels, but I remember after it uh tanked in the morning Oh, yeah, that's better. It's like right after a tank in the morning I wanted 1650 line and then you know, I saw 1625 just sort of that push And I started there and then I was going to scale My original line was like 17 But so that's why I was in small because I sort of let the stock come to me if it didn't hit my line You know, I'll sort of play that emotion given that like tank in the open I was like, you know, these everyone's just going to be pressured to sell the yearly low that kind of thing Hey traders, this is tosh. I go by t bradley 90 in the my investing club chat Just wanted to reach out and say if you have any questions about m i c joining m i c Maybe you're a member already. You have three ways to contact myself personally and through m i c You can hit our social media You can hit me through pms in chat or you can contact us through my email at tosh at my investing club.com That's tosh at my investing club.com I will get back to you in a timely manner and I'm saying this because I'm here to help And I don't want anybody to be afraid to reach out and ask any question that they have We are here for you guys. All right. See you guys


Thank you, so I'm First of all, let me ask just by a quick show of hands. Who's an engineer? Who's a programmer developer? All right. All right. This is my my kind of people. All right, so So I'm going to switch gears a little bit here Joe's been talking primarily about the the left-hand side of Big data that the analytical side. I've got lots of data from different sensors or from Users contributing things I'm going to crunch through that and spit out some recommendations or you know action items for me to work on and I'm the no sequel side of things is more about you know, I've got this web application or software as a service And I need to scale that from you know running inside one company to Running for a whole country of users so so that that's that's the the space that Cassandra plays in and that I think is interesting about no sequel So what I'm going to do is I'm going to talk about five questions to ask as you think about And evaluate different no sequel solutions that will let you Make sense of the different Offerings out there because there's there's a lot of things the problem with no sequel as a term is that it's it's incredibly broad and you have things from Cassandra as a scalable system of record to Neo4j, which is a graph database that is mostly interested about data sets that fit on one machine So very very different kinds of products there So I wanted to kind of break it down into some questions. You can ask to think about the differences between these solutions and And what they are good at and and if as I go through you start to think wow Cassandra is good at a lot of these things then then I'm doing my job, right? but because I actually come to Cassandra by the way as Kind of a second generation of people working on it. So it was open sourced by Facebook back in 2008 and I came to it from Rackspace and Became the first Committer to it in the Apache Foundation outside of Facebook. So I had the opportunity to evaluate Cassandra Against things like H base and Voldemort and MongoDB so I was able to to do this evaluation myself and and Chose to get involved with Cassandra Because of some of the the reasons that I'm going to discuss today So the first question I wanted to talk about is this one. How do I model my application? What does? Building an application on different no sequel databases look like So there's a bunch of different options of which I think the most interesting are the document databases and The tabular ones the ones that have tables of rows and columns key value databases. Those are out there Some of them are reasonably popular such as Voldemort but a key value you know a key value is kind of like a very simplistic Tabular database, you know where you can have a row with a single column. That's that's my my value, right? So I'm going to focus on those to the document and the tabular models So the document model says I'm going to let you throw in balls of JSON you know JavaScript object notation where I have Fields that are named and have values in there and those can be strings It turns out all my data types here are strings, but they can also be integers At the bottom here. We have a list of email addresses. You can have Documents that contain other documents if they can be nested that way so very Nice to use when you're prototyping something because you don't have to go in and say altar table Add column or anything like that. You just start you know You just throw in a new field to the JSON that you're handing to the server Now Cassandra kind of started off with this kind of Schemeless design, but what we found was as applications evolve you start with you typically start with one You know kind of customer of the database one one code base. That's interact interacting with that database But as as you evolve that you start adding on different parts That are often authored by different teams other than the original one so you might have some Python to go with your Ruby add in some analytics with maybe hive You add in a Java component and so and the database is shared between all of these and so what what you have is You know with with the schema list approach all of those Teams Besides your original one try to have to go back to that code base to figure out what it's doing with the database So I might claim is that having a schema that lets you ask things like you know What does this user's table look like is actually a good thing? So that's the direction we've moved with Cassandra actually to towards Allowing and encouraging you to Tell the database what is that what you are actually putting in it so that that can be the source of truth for everyone Who touches that data? so We've also found that SQL as much as it gets There's some people who came to know sequel because they don't like SQL And that's not me. You know, I think SQL is actually very good at what it's supposed to do Which is giving you a domain specific language for defining and accessing data So what we've done with Cassandra is We've actually created a subset of SQL And all of these all of these statements on this slide here are valid cql valid Cassandra query language create table create index Select star And give it some where predicates those are all valid cql now an interesting Kind of mismatch between SQL and what we're doing with Cassandra and other no sequel databases is that SQL is very much Organized towards thinking of your data as normalized Tables what so if I wanted to create a Relation in the relational world between users and email addresses I want to allow users to have multiple email addresses I would do something like this where I have a Table of email addresses. It has a many-to-one relationship with my users table And then when I access it I access it by saying select Natural join or no left outer join something like that to get those email addresses out and So this is this is a non starter in the no sequel world Join joins our dirty word for us because We are we're targeting a space where we're scaling across multiple machines We don't want to have to fetch data from machines across across the cluster to join them together That's going to kill our performance. So what we do instead is we denormalize So in the document model that I showed you earlier the denormalization looks like looks like this where in the red here I have email addresses as a list and I can just put that into the document like that with with Cassandra We're taking a more schema oriented approach And so we we have this Syntax here for the create table in the red again. We have email addresses is a set of Text and so we're telling the database that this is what that's going to be and then I can write an update statement like the one below that that says Append or or create a union of email addresses with this new set that I'm giving you So The Cassandra query language It does away with joins as well as sub queries and then a little bit maybe a little bit less intuitively We also don't give you Aggregation or Any of that kind of nature because what we're saying is Cassandra is strictly about Being the system of record for your for serving your application if you want to go analyze it later and say You know, who are my top top 10 users in contributing new content? You go ahead and do that offline With with our hive integration that let you run Hadoop Map reduce jobs against it and come back with that data So we're not we're not encouraging you to do this kind of analysis analytical query Against your live database And I'll show you how we split that up in a towards the end of my presentation The last thing though that's interesting is is how we deal with order by It's kind of like What Henry Ford said about his cars you can have any ordering you want in Cassandra as long as you pick it up front So what that what that means is I'll give you I'll give you an example so in in the relational world Here is here is what a Toy Twitter application might look like I have users users make tweets and users follow other users So what I might the main query that I'm concerned with In this Twitter application is what tweets have my friends made So so here we are looking up the tweets for a username drift X We're saying what tweets have his friends made so what we first need to do is look up in the red who his friends are and Then for each of those friends we look up in the blue what tweets they've made right? So so here we're doing a join through a through a sub query So I've already said that we don't do joins In Cassandra, so the way we would do this in Cassandra would be I would I would create a separate table In which I will put the tweets of every user's friends If that makes sense, so what I'm going to do here So the I've got create table timeline user ID is Going to be the user whose friends tweets we're trying to ask about so drift X in this example And then each of those next four fields the tweet ID the tweet author and tweet body Those are that's going to be the tweet data That we're going to denormalize into this new table. So every time someone makes a tweet We're not just going to insert one row into the tweets table We're going to insert potentially dozens or hundreds of rows Into the timeline table one for each person who's following him and Then the interesting part about this is you can see that I've created a compound primary key at the bottom of the table here That I have a compound primary key on user ID and tweet ID so When when you give Cassandra a compound primary key it breaks that up and says the first part the user ID That's going to be the partition key. That's going to determine what servers this row gets replicated on the remaining parts of that Primary key the user ID. Sorry the tweet ID here I'm going to cluster the data within that partition on On that tweet ID, so I'm going to sort or order that data by tweet ID So that's what what I've got with the orange arrow here That's what I'm trying to indicate here is that each of these orange groups is a partition They have the same user ID and Then the orange arrow is denoting that I'm sorting those rows within that partition by tweet ID So that when I do this query at the bottom here in Cassandra, and I say select star from timeline where user ID equals drift x I Can say order by tweet ID if I want It's redundant because it's doing that automatically. I can say that I can also say order by tweet ID Descending so Cassandra will get can do that efficiently either forwards or backwards ascending or descending But I can't I can't say select Order by author. I can't Cassandra will say no I can't do that I would have to do I would have to sort potentially thousands or hundreds of thousands of rows at runtime And I might not be able to do that Performantly so if you want if you want another ordering you should denormalize that into another table ordered in the in that in that way if that's what you want so Then the next natural question then in our progression is to ask how do these different no sequel solutions perform So one one way to think about that is is well, okay. I I'll run a benchmark so a group of academics at the University of Ottawa in Canada presented a paper at the very large databases conference this year and They they ran and they ran about half a dozen different workloads And then and they measured that as you scale the cluster how does the performance look and And this is this is just one of the workloads Cassandra Did very well in performance but We actually want to look a little bit deeper than a graph like this Because what what you have to do to create a graph like this. They're comparing Cassandra and H base which are tabular databases with Redis, which is Sort of a key value database with my sequel, which is obviously a relational database So you actually have to make a graph like this They used a benchmark suite called YCSB the Yahoo cloud serving benchmark Which actually takes a lowest common denominator approach and says We're just gonna give everyone key values pairs To read and write so It's a very limited Kind of test when you're comparing systems as different as these which is why just looking at a graph You know, I like this graph because Cassandra is winning But but you'd want you want to look deeper and you want to understand as I move beyond keys and values and try to use the database the way it's meant to be used what kinds of Performance can I expect? What is it good at? What is it not so good at? so one of the things that that One of the most important aspects In a scalable database is what is it? What is its approach to locking? You know as as you start scaling across more and more machines as you have more and more Clients hitting it What is the approach to locking and concurrency? Cassandra's approach is to use what are called persistent collections Rather than having rather than locking rows explicitly for reads and writes We use what are called put persistent collections, which means that I have my row my copy of a row that I that I know about is actually immutable and When I go to change it, I actually clone that row and make the changes in the clone which then becomes the new Find the new row of record once my changes are complete And so what what what this what this diagram is showing is how these persistent data structures You can actually when I clone that row It's not an expensive operation because my new copy of that row actually shares Most of the information with the old one. It's a copy on right design is basically what it is we're using a Library called snap tree map is is the actual specific implementation. We're using there Which is very it's very useful because not only does it give us this copy on right? performance, but it also preserves ordering Within a partition, which is one of the the things we want to give users was within your partition key Everything is clustered on the rest of your primary key Another important part of performance is efficiency and this is what I mean by efficiency if I go through and If and say update users append this new email address Do I do I rewrite that entire user record? Which a lot of no sequel databases do or do I just append that new data? So obviously that that's that's going to affect how many Operations per second of this type that I can do if I'm having to rewrite everything that was in that in that row or in that document Another important question that's related to performance. It's not about performance specifically, but it it impacts your performance is Durability so this is the same durability as in acid in relational databases if I give you my data and say Write this data and you tell me yes, I have written your data and then You lose power is my data still there? That's durability So so to answer these questions for Cassandra Cassandra uses what's called a log structured storage engine So what we're going to do is when when a right comes in in the upper left We're what the first thing we do is we append that right to the commit log So that's the thing that's in the left here in the middle. That's that's my commit log I'm going to just append append append append to that commit log similar design that Oracle postgresql etc all of these use commit log like this They might call it a transaction log or write a head log is the same thing So so that's what gives Cassandra durability is we always put your data in a commit log first So that it's on disk And then the next thing we do is we we put it in this thing You might not be able to see the gray on gray there, but it's a structure called a mem table And on the upper part of the screen So I'm I'm going to as rights come in I'm going to batch them up in this mem table I'm not I'm not doing any random IO You know, I might be changing data that already exists somewhere, but I'm just appending that I'm appending to the commit log and writing to the mem table I'm I'm not doing any random IO on disk when the mem table gets full Then I will write it to disk and I will I will write out those rows in sorted order and at which point it becomes What we call an SS table file on disk and can be Quarried on disk Whereas before we were just querying the memory so The the importance of this is that we're never doing random rights Which actually turns out to be the right thing to do both for rotational disks and for solid-state disks Rotational disks is the right thing to do because seeks are expensive So we don't want to do random rights for that reason on solid-state disks They're not expensive for performance so much as they're expensive for your disks lifespan So there's a concept called right amplification with solid-state disks I don't have time to go into that today, but if you Google for Cassandra solid-state disks This is a presentation that a fellow named Rick Branson gave and he'll he goes into the gory details of how right amplification affects SSDs and Why that makes log-structured storage engines a good fit The last thing I wanted to mention with respect to performance is that it's important to know How a database deals with larger-than-memory data sets? This is a graph from a company called urban airship where they were using a Non-Cassandra no sequel database. I've blacked out the name of the database because that's that's not really I'm not I don't really want to Call anyone out by name here, but I do want to Point out what happened here when their data set got larger than RAM the performance went through the floor and so you want to be careful about This and and and ask how does this database deal with data sets larger than memory because if If your data set fit in memory then you might as well be using Oracle You might as well be using my sequel, right What then the interesting part about no sequel to me is not about getting rid of the relational data model. It's about Going beyond the relational data model to scale. That's the important part So if we don't need to scale, you know, who cares if you do need to scale then you need to know You know, how did how does the database deal with this situation? Another thing you want you need to know about is how do you deal? How do you handle failure? Because Once we've spread our data across multiple machines in a cluster It's not as simple anymore as when my database is down. I can't get to my data, right? Hopefully we're in a situation where if I lose one machine The rest of the cluster can deal with that and I still have my data. That's what we want so there's there's a couple ways to scale out and Design for this Kind of the classic model that you would probably end up with if you were if you started with My sequel and then needed to shard across Multiple my sequel machines. You'd probably end up with something like this where you have here I have four partitions or shards each of which has a light blue machine Which is my master and then the master replicates to the dark blue machines that are that are just read-only replicas They don't handle rights. You know, they're they're just They're as backups basically so in in this situation if if the master node goes down Then I need to have a new master election. I promote one of the replicas to be master and I carry on from there There's a couple problems with this Which philosophically I think this is the wrong approach first of all because While you're doing that master election and and failing and doing the failover To a to a new replica You have unavailability you can't handle new rights while you're doing the failover Maybe your failover is super quick. You know, that's what you that's hopefully what you're shooting for but you still have a Small amount of downtime The second problem is kind of what what rick's referring to in this in this second quote here Excuse me Which is that in In a master slave design Failover is a rare occurrence If it's not rare then you have lots of downtime during failover so but but since it is rare It's relatively untested and you have lots of corner cases that you need to deal with for instance What if my my blue my light blue master? It's not really down, but it lost network connectivity. So it still thinks that it's the master So I fail over to a new master the first master regains connectivity now. I have two masters So not not a good situation. So dealing with that kind of corner case is is where the Pain comes in with this kind of scenario Google App Engine that where they run kind of a data store as a service as part of App Engine they've had Two day-long outages because of master failover With this kind of scenario so even Google with you know six years more experience with this than most of us Still struggles with this and I think that's inherent to the design So What does Cassandra do instead after I've explained why I think this this master design is bad What do what does Cassandra do instead? We have a fully distributed system by which I mean Every node Is a master in the sense that I can always accept rights for any replica and and forward that data where it needs to go So in this diagram, I have the client talking to a node in the upper left for data that's on these other three nodes so the the The machine the client is talking to Does not own the data Which which is a good thing because if that node fails I can reconnect to any other node in the cluster and it will also be able to route it to the right place So one of the things that this gives me by having every node be a master in this sense is I can actually have clusters that span multiple data centers and Clients in each data center can Talk to a Cassandra node locally which will then forward it where it needs to go Anywhere in the cluster by the way what I've tried to do with this diagram here is show two data centers that are on-premise And two data centers in the cloud We actually have customers with this exact scenario where they have It's spread between their machines and Amazon's machines and Cluster Cassandra connects all that together in a single cluster We do this efficiently by the way where if I'm forwarding a right to a new data center and that new data center has Three copies of the data. I'll just send one copy over the WAN link and have that One of those replicas forwarded to the others locally, so it's efficient like that Cassandra also takes care of Healing itself I in the in the situation I mentioned earlier where you know one of my replicas goes down and it starts to miss Updates so in a in a completely healthy system the risk the request Life cycle will go something like this where the client will make a request to the coordinator node Which will send that data to the replica node Which will respond to the coordinator node that everything went fine, which will then send the response to the client Now what no when things don't go right if the replica fails Then the coordinator will have to reply to the client that hey Something went wrong that the replica didn't acknowledge the right, so I'm good I Waited for a while it never got back to me, so I'm gonna have to say that I'm gonna have to tell you that it timed out But what I also do before I tell the client that it timed out is I store a hint And a hint means that I'm going to To store a copy of the the update that the client gave me and so when that replica Regains health or connectivity. I will then forward to that replica the update that it missed So that's that's one way that that we deal with Self-healing in Cassandra We also have a more heavyweight repair, which is called anti-entropy repair And what what that's useful for is you know in our in our diagram here where the coordinator has hints on it Well, what what happens if the coordinator dies to? Before the replica comes back up and it wasn't able to send those hints to it then we have to do what we call Anti-entropy repair with one of the other replicas. It's basically our sink for databases Where we go through and we say what data do you already have here is the data that you don't have? Maybe more interesting is How do you deal with partial failures? so here's a situation where I have three replicas of this data and The node in the upper right is 90% busy. So it's going to be slower Responding to my requests and so what Cassandra does is it actually tracks how each replica is performing and Will route requests to the replica that's least busy so often what what you'll see happen Is that you know disc failure will often if the disc won't just die it will get really slow first and so what you want to be able to do is Handle the scenario where the the node is nominally alive, but it's it's you know, it's slowed down It's sick and and route requests away from that. So Cassandra does that As part of its normal operation so that no matter what it is that's making the node slow We deal with that situation naturally So, you know, I kind of talked a little bit and waved my hands about Cassandra architecture and why that makes it good but the the proof is in You know what what the boots on the ground see what What people running Cassandra actually experience So I really I like Bills quote At the top here that Cassandra is kind of indestructible You know that that's really the design that we're shooting for that. There's no single points of failure You lose machines. It keeps on going The middle quote here is is about a an Amazon outage You may have noticed that US West if you're deployed across American data centers US West US East keeps going down for Amazon So when Netflix Uses Cassandra extensively When US East went down no problem, you know, the other data centers kept going so related to this Designing for for failure is the scalability question. How does it scale? What's the design for scale? Again coming back to this slide that I showed you earlier You want as as the as the number of nodes grows You want the performance to keep growing and ideally you want that performance to keep growing in a straight line Now 12 nodes isn't a whole lot. That's as far as the the VLDB Benchmark went so Netflix actually did a benchmark scaling up to 288 nodes At that point they were doing about 1.1 million writes per second so again, we see that the The line is nice and straight. You know that that's what we want to see and interestingly this this was They were doing three replicas for each of these rights, so this cluster is actually doing 3.3 million physical rights per second To handle to handle this workload So I'm not going to spend too much time on scaling because if if you have a fully distributed system Then scaling is mostly a matter of not doing the wrong things You know, you don't want to have you don't want to have a metadata server that clients have to connect to to find out Where their data is You you don't want to have Router nodes that that become a bottleneck What about when you're adding capacity? This is actually a tough one. The third one here is actually tough when you add capacity To your cluster that means we have to move data to the new nodes How do we do that while creating the least impact possible on the existing nodes in the cluster? This is something that that we we worked on for a while with Cassandra. It took us a while to get it right So the last thing I wanted to talk about is flexibility and and there's a lot of Ways you can look at flexibility but One of the ways that that we tackle this with with Cassandra and at data stacks specifically What we do is we allow you to Do what I was talking about earlier and and run analytical queries against your Cassandra data In the same in a single cluster and the way we do that is In this diagram my blue nodes. Those are my my live Application real-time ish nodes and we're going to keep a copy of the data on these green nodes So you may not be able to read it that says analytics for Hadoop on those green nodes So those are going to have their own copy of all my data. I don't need to have multiple copies I'll just put a I'll put I'll just put a single copy on those They'll probably be machines with more disk Than than the blue nodes Because you know, all I'm going to be doing is basically doing sequential scans doing Doing my analysis against those So as an example, we have a demo application That we ship called the portfolio manager demo and what this is is for for each of these Each of these boxes represents a user's stock portfolio So he has a certain allocation of each stock in his portfolio and we we know how much the portfolio is worth It's gain or loss for the day, but what we don't know Because it's it's something we can't compute without doing a bunch of joins and sub queries What we don't know is the largest historical 10-day loss So what we do is we actually use The hadoop integration to calculate that the largest historical 10-day loss and replicate that back to the real-time side For presentation in this manager view So the way we do this is we have three tables in in the Application that we're going to deal with here. We have a live stocks table that says what is the Price of a stock at this exact point in time right now Then we have the portfolios table that says this is how many shares User x owns of stock y And then we have a historical table of what was the stock's closing price For for these Prior dates So what we're going to do Is we want to compute Historical 10-day loss that's going to look something like this for every portfolio What was its largest 10-day loss and when was it? So we're actually going to compute that in in several steps first. We're going to compute for each stock what was its 10-day return on each closing date And so we're we're going to do that with this is this is a hive query That that you can run against Cassandra So it's a dialect of SQL. We're going to be doing a self-join from the stock history table to itself Across across 10 days worth of data and then we're going to we're going to sum that up Uh The next thing we're going to the next step in our computation is going to be for each portfolio What was its 10-day what was its 10-day return on each date So here we're going we're going to join that 10 days return that we just computed We're going to join that with portfolios and and query that Then the the final step is to take that portfolio and Portfolio returns table that we computed and join those together to get a single row for each portfolio with the largest 10-day loss So this this is what we bring to Cassandra at data stacks is integrating the Real-time system of record side with the hadoop analytical side with management tools And I don't have time to talk about today, but we also integrate it with solar search To to give you a full text search against your Cassandra data Today my best guess is that there are over a thousand Cassandra deployments in put production out there These are a few of them You know, we're we're really seeing A ton of adoption from companies that you know need to move beyond You know, they're they're my sequel or their Oracle installation and make that scale So I think I have time for one or two questions He's not glaring at me. So yeah, I'll take I can repeat your question So by replicating the data over So many master nodes and yeah, I'm not having any slave nodes. Aren't you just moving the Memory issue from one side to another side So now I got great indexes and I can go and look up my data faster But I have to process more data on the back. Yeah, so the question is Well, let me let me ask a slightly different question. The slightly different question would be This is the question he meant to ask Does does Cassandra replicate all your data to each node? And the answer is no You you tell Cassandra how many copies of your data you want in each data center So I didn't make this clear that that was my fault I said that each node is a master and by that I don't mean that it needs all of the data replicated to it I just mean that it's able to handle and route Queries for any data and send it to the right nodes. So I could have Frequently people have clusters of dozens or hundreds of nodes and they will have Three copies of their data or or sometimes three copies in each of two data centers for a total of six copies So that that's a more common way to do that One more question Yes, I didn't understand how do you avoid Random iOS. Could you explain me the game, please? Catch me outside Yeah, I don't I don't really have time right now, but the basic idea is that We group we group your updates In memory before we write them out as data files So we're not actually if I have user jbls with Password x and I change my password to password y I don't actually go to that old row and overwrite it. What I do is is that new Password becomes part of a new data file that I that is that I write out sequentially And then what I do is in the background If I have older data files in the background I go through and I merge those data files together also sequentially Which I can do because I've written them out in sorted order and so And that background process is called compaction. So that lets me avoid doing the random writes And if that doesn't make sense catch me outside


You're welcome back to the Breakfast on Plus TV Africa. Our final conversation today is about restructuring. There's been lots of calls about restructuring and most importantly different perspectives you know from different quarters about what restructuring is and should be. All right we've invited Victor Orkai, he's a public affairs analyst and the president of the Doctors Director's Guild of Nigeria. Good morning Mr Orkai, thanks for joining us. All right so the talks and comments for restructuring seems you know very broad and open to interpretation from different people. Mr Orkai can you hear me? I think we're trying to reconnect with him again. Like you had said restructuring means a lot of different things to different people. Some people have talked about resource control, some people have talked about state policing rather and others have said restructuring should also mean devolution of power. You know David Ormai, I was also in the government of Eboni state and he's talked about having six vice presidents. We have Mr Orkai back online. Mr Orkai can you hear me? Yes I can hear you. Okay so I'm saying this right based on the different opinion people have about restructuring and what it should be. Do you think we should have like a national education you know to enlighten people on what restructuring is and what it should be? But then again I'd also like to hear your own opinion of restructuring. Actually there appears to be a loose term that means different things to different people. Having an education, the only kind of education that is required right now is if you like regional education for people in various regions to decide for themselves what it is that they want to the Nigerian state. Because the truth is what restructuring means to the Saldana may be different from what it means to the Northerner. Restructuring what it also means for probably a northern Christian may be different from what it means to a northern Muslim. You know there are so many factors and so many interests. You know the constitution as is presently why not necessarily saying that there are flaws in it. The problem is the way the operators have implemented it has created such satisfaction among the component segments of the Nigerian state and so people restructuring may just be resource control for others. It may just be like another Christian for instance would he want to be bound by Sharia law. There is a physical restructuring which I guess it is you are trying to ask me about which means should we restructure along geopolitical zones? Should we restructure along the structures we had in the 1963 constitution as many have advocated. So the thing about it is it's not so much education as much as saying what do the component parts want and so you know they have to first decide it at the local level and have a proper position before they can articulate it effectively at essential table. Alright Mr. Ohai the governor of Eboni state seems to have the issue of devolution of powers in mind that when he mentioned that there should be six vice presidents to you know represent the six geopolitical zone. Now this is in the wake of you know calls for self-determination by some ethnic groups in Nigeria. Specifically is that what we should be looking at at this particular time in our nation's history? I'm not a part of security I'm not I mean in terms of structuring it is more about how the how the national case is shared. Those values were shared equitably we probably would not have any problems. Frankly when we had 12 states nobody complied. When we grew to 19 maybe because we were under military rule at the time but again with the 19 we moved into civilian rule. So we got back to their batch era and then the states were more disliked. People didn't really complain. Where the complaint started was when you know in sharing resources it seemed like you know resources would come from one part to finance another and then the people who are who are you know from where these resources are coming from are not getting any benefits from it. I'll give you a small example. Look at what's happening. The gold in Zampara alone the gold you have in Zampara if the federal government decides today to tap it for the benefit of the state of Nigeria. What we have in Zampara is probably more than what is sustaining South Africa and probably more than what is sustaining Ghana but no one is talking about it. All they're talking about is using this model product which is crude oil and then you go there there's an environmental degree. Oh seems to lost Mr. Okai there. But here as I said the bulk of it most of our national leaders are just actually about you know sharing of the national case and they have economics on mind when it comes to restructuring and of course what the nation should be doing. Yes and you know he mentioned that you know security is the first you know major issue and one of my questions would be if we're talking about devolution of powers we're talking about restructuring why then are states you know opposing a president's statement when he said that his hands on of security to state. I mean isn't that the restructuring they want to control state of security in their state. Do you understand the regional security network that they have in Amoteca.  Now the president is saying okay I'm taking my hands off you control that and make sure your states are secure and states are really opposing that. So it makes you really wonder what exactly do they mean when they say restructuring. But a whole lot still needs to be done if you talk about your hands just leaving security to the state level. If you look at our constitution the policing in Nigeria is actually at the federal level. So a whole lot needs to be done to even just not just use a word just to show what's the best way of everything. So verbally you know pass the ball. You know you just don't do that in my opinion. Wow so really restructuring is a very big issue different different sides. I think you should study that as a course in school. Just saying. Exactly also also another very interesting issue that David Umaye raised in addition to saying that Nigeria should have six vice presidents. What first of all I wonder how exactly how would that work six vice presidents. So the vice president would just handle issues that have to do with you know their particular zone or how. Don't you think that would even raise more conflict because how would each zone decide who exactly should rule or become vice president. There will be more talk of marginalizations you know amongst me for instance people would really be you know would it be a number of your email or even a bonus itself. And in a time we were talking about the need for more development of the grassroots you know you're looking at states in the rural areas and how bad they develop they are. Umaye is also saying that local governments should be scrapped and you're wondering you know so that's what restructuring means to him. That's also another aspect of restructuring that you know the third tier of government because most times they seem to be like you know an appendage of the state government and that the state government just pushes whatever you know they want you know to those particular arms of government. So so so so so so much. So really this this is a conversation that wouldn't end in a short while. Hopefully we can get started in school. Yes hopefully we can get Miss Hawkeye back on this issue once more in future. But thank you very much for tuning in to the breakfast and plus CV Africa this morning. We've been talking about security in Plateau state restructuring of the entire country. I gave you some top training issues regarding Chimamanda Ungozia Diche versus an upcoming writer.  Yes of course I would switch your you know your citizenship for maybe Swiss citizenship or United States citizenship. For Nigerians. Yes of course again the beauty pageant of the lady who had done the bloodstained Nigerian flag. Yes maybe we should put a poll you know if you had a sweet citizenship would you would you you know just live that for Nigerians. So let's know how many Nigerians are really patriotic. All right let's get the conversation flowing over to social media platforms. It is at plus TV Africa. Yes at Facebook and Instagram and it's also at plus TV Africa on our YouTube channel. Do subscribe to that. I am Neto Felix thanking you for being a part of our day. And I'm Justin Akademi. Many thanks for being a part of the show. We'll return again tomorrow. The news is up next. Stay with us.


Remember, I'm like you're not a sports guy. I think he is so we're gonna do a Wallow Joe Montana Patrick Mahomes. Well, Joe's from Pennsylvania 49 is my team back in the day. I'm gonna go with Joe.  It was good My team back Travis Kelsey or Jason Kelsey.  He's a big game player. You're in your swiftly tell us with a Beyoncé Beyoncé e40 or tech nine Both of my guys, but I gotta go with e40 simple boy winner. I truly believe man. It's all about business tell us with Swifties it's just like that


� uncounting the purpose ੰ quieren ത想 يد job ത ത Princy the year ത how it looks  Registered ത how it may take time ത everytime it's� ത when people leave sava � sill need法лаг ത I seek policy saying '' అనే స్ఢచి మattformనుషిలిన amplifyముొ ప్పిసకాంపై catch సెరనోఽొమ సేసిలై was a privilegedgar Vegas बादेनो भी पुल जांदेने


Studying at SOAS and at CISD is a great and unforgettable experience. For anybody who wants to work with global issues or work globally, I would recommend them to apply to SOAS and to CISD. I think the thing that I love the most was that you, through CISD, you were able to engage with the whole world in one classroom and you had lecturers coming with wide experience from their different fields. I think I'd say CISD is great for those who wish to pursue an international career or those who wish to broaden their knowledge in international affairs or contemporary international policy issues, for example. Today I work as a program officer with the UN Joint Program on HIV and AIDS in Zimbabwe. It's also known as UN AIDS. I love my position and I think I can safely say that I wouldn't have applied for the UN had I not been confident enough in my knowledge base and the skill sets and the practical skills that I gained during my time at CISD. So thank you for that CISD.