Well, hello and welcome everybody back again to another open shift commons briefing today We are very pleased to have with us a ring who is the director of developer advocacy at red hat And he's going to give us a presentation that he's given once before On Java EE workflows on open shift, and we're delighted to have him here He's a great and very active developer advocate and does some wonderful work with devox and devox for kids So I'm going to let Arun introduce himself and Set us off on our Java EE workflow path today. Thank you again Arun All right, let's go. So, yeah, my name is Arun Gupta. I work for red hat Responsible for all of the developer outreach efforts for jboss middleware at red hat Very fortunate to work at red hat. It's quite a cool company So if you guys are always looking out to work at red hat look at jobs dot red hat calm now I would love to have you as my colleague So, yeah today the talk is going to be about Java EE workflows on open shift So if I can go into the full presentation more than here you go I've given a very high a variation of this presentation earlier on but I thought today What I'll show is what all is possible if you are a java EE developer What all you can do on open shift? Okay, so let's start with that So first thing first what is java EE now java EE is the standard way of building enterprise Java applications Java EE 7 which is the latest release of the platform was released June of 2013 So about year and a half ago and there were five three main themes for the platform And the first one was developer productivity on how we want you to be highly productive with the java EE 7 platform you write less boilerplate code and Lot more annotations where the platform defines the meaning of those annotations The second big theme for the java EE 7 platform was HTML 5 You know web sockets are often confused to be part of HTML 5 Initially they were but then the spec got pulled out and so web sockets is generally kind of clubbed into that HTML 5 bucket But what it gives you is the ability To do bi-directional full-duplex communication over a single TCP connection Jay's on processing is an inherent part of any website these days It is a support for Jay's on processing right there in the platform itself and then a lot of a synchronity a Synchronous API is added to serve let and rest To give you more scalable scalable applications And then the last team for java EE 7 was something which has been really good is you know meeting your enterprise demands is Adding two new specifications one is to do Standard batch processing now which used to be called a spring batch and now there's a standard way of doing it And then there is ability to spin up new threads Which can run in the user context and of course the jms specification which has been heavily used for You know m2m messaging as extremely simplified So this is not a java EE tutorial. So there are a lot of good content available on java EE So I would recommend you to read that but if you were to start with a Simple java EE 7 application and there are maybe not stripes that are available You know, so you here is a simple sample You just say maybe not stripe generate batch mode blah blah You know you give the art artifact ID group ID package ID and all those things and then it generates a simple java EE 7 application well, I mean you can of course use jbos developer studio as well and Using jbos developer studio and we'll talk about that in a second, but essentially it's a Eclipse with a bunch of jbos tools plugins installed over there all known to work very well with each other So using that jbos developer studio, you can create a simple java EE application as well So couple of easy ways by which you can start and there is support for java EE 7 in net beans and intelligence as well So it's pretty ID agnostic in that sense Now if you want to learn about java EE 7 though There is this github project You know java EE samples organization and in there there's java EE 7 samples project There are about 200 plus samples slash tests that are available by which you can learn about different java EE 7 technologies over there So that's the important part where you want to learn everything about java EE 7 refer to these samples Now if you are building your java EE 7 application What is the tool chain that you need to remember and that's what I'm gonna show today So for example while flight is the community project from red hat This is where the java EE 7 implementation is being done. Now. This is only a community project But what that means is there is no support. There is no Buying production support on it. There are no security updates patches that are available on it Eventually while fly will be available as jboss EAP 7 and that's where commercial support can be purchased But today if you are looking at java EE 7 support Then while fly is your primary source where you can try and build an application on while fly itself And of course jboss developer studio net beans and intelligence all three ID support while fly now We talked about jboss developer studio, but essentially it is eclipse Plus jboss tools now jboss tools itself is a set of eclipse plugins that are bundled together that provides a Lot of capabilities around jboss to jboss technologies basically You can use it with jboss EAP which is our commercial product or with our community project like while fly both of those would work Um jboss forge. Yes yet another community project from red hat. This allows you to Declareatively you know in an IDE independent manner generate your java EE 7 application or java EE 6 for that sake You don't necessarily have to know which menu item to click on and it's a very intuitive command line driven interface Which basically focuses on what your domain knowledge is and builds upon that Open shift is what brings us here today Now you may download while fly jboss tools for all on your local machine So that's one way to go around it where you build your application But eventually you want to deploy this application somewhere now you could do that on the while fly on your local server Or EAP for that sake, but open shift and I'll give a bit more detail introduction later but open shift is that has open source pass platform and What it gives you is the ability by which you know, there is a cartridge available on open shift And you can say deploy my application on while fly on open shift and we'll see a sample of that So don't get confused if you're not getting all the points together And last but not the least another important piece for your java EE story or workflow that you need to be aware of is Arcillion now Arcillion is a tool that gives you the ability to do container independent testing very easily Okay, so let's look at each of these tools and understand a little bit more of them And then at the end I'll be able to show hopefully a demo which puts all these pieces together Like I said, right now while fly is that has open source Java E7 compliant application server There is reference implementation Glassfish, but that's only for reference. There is no commercial support on it by Oracle so while fly is your good choice because Today you start building your applications on while fly and when J bus EAP is available You know, you just seamlessly migrate over to J bus EAP because the code is 99.9% 99% rather same. So the migration is rather seamless So start with while fly today jump over to J bus EAP, you know when the commercial support is available One of the cool things about while fly is you know, it maintains a regular cadence So for example a dot o was released in February of this year 8.1 was released in May 8.2 in like literally last month and 9.0 is already being planned for next year. So You know, there is a active set of developers in red hat and outside red hat who are working on while fly to do these releases A very important part to understand is you know, the commercial support will be coming in from while for while fly in J bus EAP 7 So, you know start your applications today on while fly and then migrate over to J bus EAP 7 when it's ready So J bus tools, you know, we talked briefly about it, but basically it is eclipse plugins for J bus technology Anything and everything that you can think of, you know around J bus technology. It has support in the J bus tools So aerogear gives you a mobile framework to build your application rest easy is your way of doing standard rest and and and points support for Apache camel and our support for multiple Multiple mobile phones Support for while fly of course support for Ford hibernate and of course open shift, you know so you can literally create an open shift application and it provides a very seamless workflow from within J bus developer studio on how you can take it and How you can take an existing application and deploy it an open shift or create a brand new application and deploy it and open shifts Both the flows are there. So that's pretty cool. So that was about J bus tools now There are a couple of ways by which you get started with J bus tools You may have an existing eclipse version say Luna then on Luna you install the J bus tools plugins Alternatively, there is something called as J bus developer studio where you download integrated bundle Which has eclipse and J bus tools plugged in together and that's just one bundle and you get started with that right away Food now J bus food as I said is yet another project from red hat Is the fastest way to build your java e applications using Maven? one of the hairy things about Maven typically is you know, you need to remember all the dependencies and What plugins need to go in there? How do I build my application? You pretty much end end up copy pasting your palm dot XML from project to project now here We take care of that So we just say you know what you tell us what your dependencies are, you know or you tell us on an abstract way what your dependencies are So JPA is my independence Forge automatically goes and figures out what's the right actual dependency that needs to get added into palm dot XML and it does that for you The concept here is where I or Right once run in any IDE That's what we call it for for Because it's using Maven and because eclipse intelligent and that means all three ideas support Maven. So essentially that's what it gives you Another advantage is with javas developer studio or javas tools You have integration with force. So within the IDE you can invoke forge Now do your code generation from that and watch the code in the IDE as it was. That's pretty cool It really helps you in automation of repetitive tasks. So let's say you want to generate a boilerplate code You want to have a certain set of dependencies now instead of hard coding them you can provide a ford script and Run the ford script to generate the project. So all your boilerplate palm dot XMLs, etc. Can be very easily generated Yep There is inbuilt support in ford for java e6 and 7 So that's pretty cool as well And one of the cool things also about forges is extensible by design So you can have ford add-ons which you can easily write by yourself Let's say if you like a particular functionality or don't like a particular functionality Or you find something that is missing then you write a Plug-in or add-on actually, which is a new terminology. You write a new add-on and say, okay You know this is how I'm extending ford functionality It also encourages test-driven development, which is very very critical No test means no push back no commit. No push should be allowed for any application And really that should be the standard rule And we're seeing that becoming more prominent anyway these days Now this is OpenShift Commons briefing so you all know about OpenShift, but no just for kind of quick introduction OpenShift is Red Hat's open source pass platform Comes in three varieties. So there is OpenShift Origin Online and Enterprise Which is a very classic red hat way Any first feature in OpenShift goes into OpenShift Origin Which is you know where you can go to GitHub check out the workspace build it yourself and run a full version of OpenShift So that's sort of our Community pass then there is online OpenShift Online, which is go to OpenShift.com which is our public pass and in case of public pass You know you can sign up for an OpenShift account, you know and avail some services We'll talk about that in a second and then finally there is OpenShift Enterprise, which is our private pass Where you can say hey, you know I have I'm running my own company. I have my own data center I want that pass like functionality based upon that data center where everything is confined within my firewall So then you know you work with Red Hat and we help you install OpenShift Enterprise over there and get it going The advantage of OpenShift, you know one of the biggest advantages that I've heard and I've realized myself is Plugable cartridges. Well, OpenShift works on the mechanism of cartridges. You have a variety of cartridges Anything from it's a truly polyglot poly database environment Where you have support for Java, Ruby, PHP, Python, Go, and much further languages Even even in terms of databases, you know like your traditional RDBMS or Mongo or name it, you know all those can be supported And then just like forged, you know the concept of Extensibility is here if you don't like something for example, you know or if you Want to extend the functionality like you know you some new database comes up tomorrow and you want to add that functionality Yeah, you can write your own cartridge what we call it as a DIY cartridge For example, and the functionality that you can add to OpenShift could be extreme For example, my son and I were looking at how we can run a Minecraft server on OpenShift and we could write a DIY Cartridge where we were running a simple Minecraft server. So that's pretty cool We talked about multiple languages databases app servers. We didn't touch but the point is on OpenShift you can have you know your Jbos EAP, which is a commercial version of Jbos You know you can have a Jbos EAP as running as a cartridge over there You can have all the community projects like Wildfly, Setfra can be running as an application server over there Somebody in the community even wrote cartridges from IBM Liberty Profile or Glassfish and other application servers Tomcat of course is supported over there. So what idea of app servers? You can see truly is very rich and overall pass environment Now the way OpenShift works is the concept of Gears now you can go sign up on OpenShift Like OpenShift.com or say public pass and there you get a gear Now gear is the capacity gear is what we call it is a compute capacity or a disk capacity that you get There are three kinds of gears in OpenShift small, medium and large That's generally known, but you know you can customize those if you have an OpenShift Enterprise But if you sign up for a free gear or a free account rather on OpenShift.com what you get is three gears and Each gear is literally one gig of disk space and half a gig of RAM. So For example on one gear you can install an app server on one gear You can install a database server and one gear you can run your continuous integration tool like Jenkins or whatever you care about So that's about OpenShift Now the last tool that pretty much we'll talk about is Arcillion and Arcillion is a highly Extensible and then you see the extensibility is a key theme here. So it's a testing platform for the JBM That really allows you to run your tests in a container agnostic manner. Okay?  We bring the container to you So and let's take a look at the workflow within Arcillion itself. So you choose a container for example the container could be Wildfly container could be glassfish could be EAP running on OpenShift for example You tell or you ask Arcillion to start or connect to a container So let's say we start with Wildfly remember I'm using Wildfly here because we are talking about Java EE7 But if you were using Java EE6, you would be using JBas EAP. So you connect to a container Then you ask Arcillion to package your test archive the way you want to do it and deploy it to the container You run the test in the container You know, so the you can see that tests are running the results are captured and reported You know, it's a very standard unit test We just have to add a couple of methods to make sure that the tests are can be run by Arcillion And finally the test archive is undeployed and you disconnect from the container So very simple workflow if you are want to test your Java EE applications In a very container agnostic manner that container could run locally in your laptop or your private pads or an OpenShift as a matter of So how do you get started with Arcillion? You know, well, typically we Talk about may well So there is an arch type you can use that arch type and you can say fire up my application or create my application It will pull in all the right set of dependencies for you In that form XML you will this is like a testable Java EE application It will generate four different profiles And in each of those profiles effectively it says it tells you What is it that the app should be tested against? So for example, I could have my app running against wildfly so it will start up wildfly for you and Each container could run in two modes. It could be a remote mode or a managed mode Remote mode is somebody else is controlling the life cycle of the container and the managed mode is where You asking Arcillion to control the life cycle of container. So in remote mode, you may have started your container outside Arcillion You just deploy the test run the test. Well deploy the archive run the test and then deploy the archive And in managed mode, you start the container deploy the test Deploy the archive run the test and deploy the archive and stop the container So depending upon which mode you want there is a remote and a managed mode It generates four profiles you know two for wildfly two for glassfish Because those are the two javae seven application servers But you can very easily extend this to add support for jba cp as well So how would you test for example, you know, if you generate a testable javae seven application So while you will download wildfly 8.1 now actually 8.2 from wildfly.org It's pretty straightforward. You unzip start now using bin standalone show script and you run the test That's it out of the box just works very well. Okay, and you of course specify the right profile Now you may say hey, by the way, I have an existing javae project and on that project I want to make it testable because testability is a key aspect for you know any project not just javae But that's where you use forge So forge not only allows you to add capabilities to your project But you can enable arcillion on an existing javae project As I said forge is an extensible architecture. So you use this command add on install from git Now there is a arcillion add on you install that add on and then you set up the arcillion container You specify what test framework you're using in this case We're using j unit and you specify the container adapter Now i'm saying wildfly remote here But there is a variety of 30 plus containers that are available to you including jbos eap and whatever you care about All those are there. So you can very easily set up arcillion on an existing java project So let's say you have a javae 6 Application that is currently deployed on jbos eap and you want to make it run or test using arcillion Then you will use this command Set up the arcillion adapter for eap in your palm dot xml and run the test using that profile So let's see, you know, we have looked at all the tools So what's sort of the methodology that we recommend, you know for workflow that we recommend specifically if you're working on open shift Well, the first step before you even jump on open shift is your test driven development Okay, and let's say you have jbos developer studio on your machine with wildfly configured in there or eap configured in there um You're building your application and you're you know deploying it on wildfly. You look good. Okay um Pretty much with the first comment We recommend highly recommend to have your unit test and you write your unit test Well, j unit test and you doesn't matter but pick a framework of your choice and then write your unit test Um now when you get to integration test where you want to run the test against the container That's where arcillion comes in so and we won't go into the tutorial of arcillion itself But the idea being you can easily run an arcillion test write an arcillion test And then run it against the container directly. Okay, so that's your first step So you should have a test driven development really um We are not even talking about here Aspects like code review code coverage application performance monitoring and all of those finer aspects Which are again very very important before you go to production Well, the second stage in that case is what we call as continuous integration. Okay, and the way continuous integration works is so Yeah, you got your development environment all set up Um, you can easily spin up jenkins instance on open shift And what you will tell is every time I do a good push I want jenkins to run these tests against my container automatically. Okay Um, so you do a good push here now jenkins running on open shift understand this your workspace Um, it builds checks out the whole workspace runs the builds the workspace runs the test Against a wild fly instance running on the same instance. Okay, so that's the second step The third step is where you make it a lot more automated because right now what you have not done is You are not pushing your actual war file or the actual archive that is being generated to the production website So in which case we take you to the next level where we say Every time you do a good push the changes go to jenkins. Yes, that's one part of it The second part of it is where you want to run the test Not on the production machine, but on a test machine. So you spin up a new wild fly instance say on open shift You configure jenkins that Run the test on the test environment. So it runs the test on the test environment And you aggregate the results back on jenkins And if the tests have succeeded Then you actually push the code to the production And if the tests have fail, then of course you don't run anything, you know, you don't push anything on the production Or the deployment is actually halted Um, well now this is a very simplistic use case, but at least it tells you how you can easily set up everything As part of the entire environment Okay, so what I'm going to do is now Um, I am going to switch to My browser here Okay, so what I have here is if I refresh my applications here Um, I have a my wild fly Well, okay. First of all, this is open shift console In the open shift console, you're looking at two domains j boss devs and miles to go. This is the domain that we're going to focus on In this domain, uh, I got a jenkins instance running I got a wild fly instance running and this is wild fly server 820 final And the jenkins client is enabled over here. So which is the jenkins client here. Okay. Well, it automatically redirects me there So go back So this is my wild fly instance, which is the production instance. Now if I look at my production instance here Um, if I say my wild fly dash miles to go Dot or hcloud.com it shows what all is running over here. Now if I run On this it shows me the list of names. So it's a it's a simple rest endpoint, but it's a java e application Okay Back in open shift here. Now, this is my wild fly test instance over here, uh, which is where I want to run the test So I don't want to run the test against my production Instance I want to run the test against my test instance and then then if the test succeed Publish the war file on the production instance. Okay. Now, let's see how this whole Setup is being done. So if I go to my net beans It is my palm dot xml Okay, so in my palm dot xml what you see first of all is this arkelyon wild fly remote profile. Okay Um, and all it's doing is is using well, it's of course building my war file. So that's nothing fancy Uh, it's saying a referring to a arkelyon launch variable called as wild fly remote This is actually configured in my arkelyon dot xml If I look at it here So this is wild fly remote. It's not specifying any properties. That means takes everything as a default. Okay And what that means is um, local host 88 or host prop host port, whatever it is Local host or other and port 8080 So I would use this profile To begin with when I'm supposed to run my test against my local wild fly Okay, this is purely local but the remote mode says somebody else is managing the lifecycle.  No, okay.  It's pretty straightforward. So You go to open shift here You log in And you say add an application Now here is a variety of uh, java applications that can be easily configured Um, if you are looking for a supported version for java EE Then you are looking at the red hat product, which is jba's enterprise application platform six That's the one that you're looking for the entire product portfolio is over here So you can configure any one of those but today we are talking about java EE so we'll focus on eap today Uh, these are all the community projects. So if you are looking for wild fly, um, which is Our java EE7 compliant app server So you click here And you type the name Okay, whatever the name is going to be then that name. So here for example, I say I'll fly Eight, okay, if I give that as a name Then my url will be wildfly eight miles to go or hcloud.com Important to understand this does not receive any security updates. That's only for the product product cartridge Um, choose a gear typically small is pretty good for me. I'm okay with that Um, I don't want any scaling We're not gonna cover scaling here, but then you create the application just literally one word and you have created your simple application over here. Okay So go back to the scenario again. Okay, so You've deployed your application and now you are saying, okay, I want to try it out on open shift so you have created a new instance on open shift and then you say I'm gonna test my run my tests against that instance of wildfly running on open shift That's where you use this profile and in this profile You can see in the arcillion property or the arcillion launch variable that we are referring to is wildfly open shift So if I go here Wildfly open shift here. Okay. So if I were to run it, I will specify my configuration properties um So this is my application name. This is our hcloud. This is the domain name This is got to be the ssh username for that domain and so you specify the configuration properties here So the same tests that were running against your local wildfly would now run against the wildfly instance on open shift. That's pretty cool, too Okay Now the third profile now if you build if you build your application or if you provision a wildfly cartridge on open shift Then You know, it generates a default git repo for you Now that git repo need not necessarily be where your application code could live You can set up remotes and you know code could still live very much on github But that git repo is sort of the point What open shift refers to is purely for management. You can set up your remotes and syncs accordingly But in that palm dot xml that is generated for you There is a open shift profile and that's the profile that open shift uses every time And in this case all it says is i'm gonna create a war file for the existing git repo and name it as root dot war file and deploy it. Okay, so that's what it's doing. Um, so Well, okay, so that that's well, that's how the applications Are deployed to the open shift using the open shift profile Uh, now notice here, we are not have a arkelyon profile because this is our production. We don't want to disturb it with testing Now here we have created a new profile. So if I can minimize this guy here as well So now here I have a new profile called as jenkins open shift In this, uh, I have a jenkins open shift profile. Okay, then this is referring to the arkelyon open shift container first of all And then the jenkins open shift profile or the arkelyon launch and in jenkins open shift. I'm specifying certain variables Env dot orc domain orc application orc ssh username and everything else is pretty standard Okay, so let's see. What did we do over here exactly? Where are these properties defined? So now if I go in my browser Well, this is my jenkins instance. So if I can go back At this well, this is my wild flight build project, which is automatically created for me I had to do nothing for that. But if I look at the configuration part of it now I added these this code over there, but everything else was pre-generated for me Uh, it's very convenient. It says run test here. So this is a placeholder for you automatically But essentially this is where I'm defining Those properties that are used in my arkelyon profile. Okay And then I say run the test using the jenkins open shift profile So I define the properties then using jenkins open shift profile I guide it to run the test on the test environment and The rest of this over here automatically, you know, works very well if the test succeed if the test don't succeed The production is halted. Okay So let's take a look at this now. This is where my application looks like So if I go to my command prompt here Okay So here is my index.jsp. Okay, um happen if you have made a change. So I am gonna Okay undo the change. All right. So, uh, here is my simple test here This is a test that is running with arkelyon and I define how my custom archive is going to get created Okay So here is my one test which basically gets a list of Well, it pings the endpoint gets the list of names Asserts all of them and then it gets one by one as well. So it verifies those. Okay. So for now the tests are all passing Okay So all I'm going to do is I'm going to make one test fail. Okay. Here you go. So one test is failing and I'll change this to say failing test. Okay. So I did I did that now If I go back here If I do a git status I change the test to fail and I change index.jsp. Okay So all I'm going to do is I'm going to commit this and I'm going to say failing test And now when I do git push My entire cycle of Jenkins running the test on the test environment. All of that is going to get ticked off It gives me you can track your build here. So if I go to the browser here Okay So if I look at my wild flight build here, it says waiting for the next available executor So it's waiting for executor here in the meanwhile if I look at my open shipped instances here or applications here If I refresh it You can see here a new my file flight builder is automatically created for you. So essentially, you know, it's using Jenkins and Jenkins create a new Instance of the slave where it runs the test and it does the job for you. Okay So if I look back here in Jenkins, I'm still waiting for next available executor But sometimes it could take a little bit longer So we'll see how it goes. But in the meanwhile If I go back here, so here again is very patiently waiting that, you know, whenever the executor is provisioned for us Then it's going to do the job. Well, another thing that you can do also is If I can go here if I can stop it here, I can say RSC tail Jenkins And now I can actually start monitoring what's happening in the background. So here it's saying creating slave with 15 minutes time to live And so it's apparently the stave has been created And the response code is 200, which is good Okay And now it's asking the broker Let's see here It's asking the broker to list something. Okay So it established the connection with the slave now where the class name says that All right, so connected via SSH. You can see all that stuff that's happening in the background Here is still waiting for the executor to be connected. Now the slave has been connected here Okay, so slave has been connected. So if I go back here now in my Jenkins I can say show me the console output Well, first of all, you can see that my commit is automatically picked up here Failing test that's the one that we made And if I look at console output is Running through checking out the workspace building the workspace War is created, but now it's running the test and see these are the properties that we set up earlier Arc SSH username Yeah, it's running the test against the Jenkins OpenShift profile. So it's running the test now It's preparing the container and this container is actually on my wildfire test dash miles to go.org cloud.com Okay, so is Pushing my running. Well, actually it's running the test is pushing the archive the war file to the remote repo or the remote wildfire instance And next is going to run the test And again, we can go back if you want to we can look at it It still says slave connected because now it's all the Jenkins output that's coming over here We'll give it a minute. Give it a few seconds It's gonna report the results soon I've seen this time varying Over a few seconds to up to like a couple of minutes sometimes Purely depends upon the network traffic at that point of the time The key point that I wanted to kind of explain here is now you will see the test failing Um, and if the test do fail then the deployment is actually halted Um, so if I go back here, for example Now it's still saying waiting for build to schedule that's been done Now it's saying waiting for job to complete Um, and if the tests are fail then it says deployment halted and it asks you to go look back at the Jenkins log to show that the know that the tests are failure and you can look at the analyze the failures more over there And the errors are very clearly marked. Okay. What was the error really? Yeah, I still waiting Let's see if I try to refresh it here in the meanwhile Yeah, this this is my production app. So this is completely untouched Um, the tests are running completely on a separate test instance He has been running for about three minutes now This this is a fun part of doing a live demo. Um, yeah, which is all right. Which is all right. Yeah, you know, it's funny because this morning somehow Jenkins was not even um pushing the changes and it was not able to spin up the while the builder And the happy cases are always good. But what we need is more Debugging information like okay, for example, what happened now in the background, you know, and how do I debug it? um and unfortunately my RTC tail Jenkins is not giving me any more information But well, you understand the concept though, you know that, um, um There is a recording on my blog which talks about exactly, you know, how this whole thing should have looked like Now while this is happening, uh, I want to show you some other pointers Um, if you want to get started with wildfly or jbas eap Are you in open shift with jbas developer studio? I created a recording over here, you know, and this is my blog URL and we can include this in the show notes Um, it's a video recording about 13 minute long. It tells you exactly. How do you do the flow? On my blog, um, if you go to blog dot arun gupta dot me slash tag slash open shift There are tons of articles Focus on open shift the one that i'm talking about just now is this deployment pipeline article Now this is a video which I was talking about Um, it tells you how the whole thing can be set up Um, if we look at more details here Um, how do you run or gillian tests on a wildfly instance or hosted on open shift? We explained that scenario earlier, but you know, that is also explained here how you can do that um You can also create open shift applications using command line tools. I use them pretty heavily using rhc tool So there's a note about that Something else you need to understand if you are as part of java e7 creating Web socket applications Then they behave a little bit differently. I mean one of the value ads of web socket is they operate on the same port But for now on open shift, they do Work on a separate port that's I won't get into the details, but This particular blog talks about how you can have a web socket sample on a wildfly and open shift. So that's there um, if you are running a jbos eap or Um wildfly in open shift, then you can run it with a custom configuration. You can completely change how the configuration file looks like There are details on that Open shift online, you know, you can run it very simply in a virtual box image. So this blog talks about that Um, so yeah, I mean you can look at you know, there is tons of content here on the open shift tag Let's look at how our thing is doing here and it is still waiting So Just just having a uh a larger gear. Would that have helped you? Yeah, I was wondering about that, but every time I've done this I've done this using Uh small gear and it has always worked and it worked like a few times in the morning. So if you see here um, if I go back to my project If I look at the log output here and I say show me the console output. Now, this is the run from earlier this morning so here basically, um Well, we are stuck at this point right now. Okay um We are not seeing anything after this So otherwise you would have seen, you know test run how many failures how many success so on so forth Now this is a happy scenario again using small gear Or you can say show me the previous build which is build number two And this is why I was expecting to see just now They're saying oh the test is failing and if the test is failing um Nothing actually proceeds after that and as a matter of fact it says finished failure Uh and none of the steps in the Jenkins, which is basically deploying your war file to the production instance are Executed so the deployment gets halted. So the point being if at any point of time your tests are passing the war file is deployed to production If the tests are failing The deployment is not gone through. It is not gone through So your tests could be your unit test your functional test. That's where you can add your jack-o-co like code coverage That's where you can add your performance monitoring using new relic or whatever plugin So arcillion has a very rich ecosystem of plugins that you can use to do all those fancy things And that's what I was hoping I could show but if I go back here and try one last time No is still happily chugging along Oh, there you go Doesn't look like a good Thing following password not reachable within 300 seconds after a good push. Yeah There's some sort of an internal network thing. It's not able to connect with the Test server After 300 seconds and well, this is network. You know, this is a very real life problem These things could happen, you know in your real life as well. So I think what it shows is the demo is real It's not a fake So and always be prepared with prior prior nodes and log files Yeah, yeah, and then one last thing I want to show here is so this is jboss developer studio How easy it is to get started with a simple open shift application here so I can say a new I can say other and I can say sure search on open shift So here, um, I go to open shift. It asks me for my password credentials All right, so it shows me The credentials that already exists. Well the cartridges that already exist. So I can say browse And if I look at my three different domains, it shows me the different domain the applications that were created um Either I can choose that or I can say create a new open shift application And I can say show me basic cartridges And here for example, I could say show me jboss cartridges only Okay So Yeah I can say jboss. I don't know why my jboss eap cartridge is not visible here and that seems like a bug. So I'll look at that but anyway, um In absence of that, I'll just use this wildfire cartridge And then I can go through my normal eclipse workflow here to create my java e application And then once you have your application created once you right click on it and you say Get commit publish or push the change again. It triggers the whole thing automatically for you where the tests are run and Everything that we talked about earlier All right, so that's pretty much what I had to say what else um questions Yeah, so if there's any questions, um, raise your hand and chat and I'll unmute you Actually one point. I want to say here. So now it says now for some reason the test failed Okay, so if I go back to my production instance here If I refresh it it still says with the test remember, we changed this to failing test um, so this says with test um, so that means the tests have failed for whatever reason for network not reachable, uh, but The tests have failed and so the production is not disturbed in that case, right I can go back here. Yeah pushes all right I'm not seeing anybody raise their hands and we've gone um quite a long time here. So I think We probably can come to close here and I can say thank you very much for this incredible, um session and I'm going to make the recording available shortly and I'll look forward to um Getting this workflow into the hands of lots of folks in the commons groups as well as into the accelerator groups soon So um a room as always. It's a pleasure and thank you for your time today Thank you Diane for the opportunity and I look forward to hearing any comments on that. Take care


So good afternoon all So we call ourself as a pick team So pick basically, you know, it's an alphabet for three of us Patel Iyer and Kumar myself Patel Kumar and Iyer Yeah, so we you know, we had an idea like in a cloud foundry So know what you have and view where they are, right? So in a multi cloud foundry environment That's what our idea is So my problem statement like you know currently in any enterprise big organization we have thousands of applications running across multi cloud foundry sites like you know six seven sites and My challenge in the operational or a or a you know on a command level center where an application desk sees Like if if my one of the DC or cloud foundry side is broken in due to whatever reason the Statement here is you know, I wouldn't know that my application is present in which all other DCs which are live Okay, so here we idea is like a small GUI where I can type an Application name and it can show me the status of what whatever the health status or availability changes in other DCs So that that's the whole idea behind what you're doing, you know, we have done so far and Challenges like, you know, we don't know like what are the applications impacted if one CF goes down one one cloud foundry sites You know side go down so in that perspective we we you know, we have collated an idea and And more little how we did you know, I want my colleague Kumar to you know take it forward. So this is our idea and basically this our prototype Thanks for tell so I'll go to the So proposed solution. So so one one way of doing this is we came with this Problem, so we are facing currently like we can only log into one particular Site or data center and to get the health information or any stats, right? So to have that we can we thought of building a UI or a And it has an agent which gathers all the application stats and other health check information from various sites or availability zone and it will Probably share that across the agents which is being deployed in individual sites from there We'll be pulling that information into our UI UI or it could be integrated. It's just like a Custom UI and can be later integrated with Shatters UI or we can do many things So this this will be like a simple search by just Giving an application name. It's going to search across all the multiple Sites available and it's going to give us the health and and for current MVP so since we have like a Limited time constraint, so we have came up with this prototype of a simple UI which basically which queries and Gathers all the information from across the multiple availability zone by executing some commands and It it's going to be available. So I'll quickly show a quick demo and we have developed this particular UI and with the Taking considering the IBM cloud so we made this of IBM public cloud and we created Yeah, so in so we are new to IBM Public cloud so what we did is we created like three sites like three different data centers So one is each one of us has like different Different sites so one will be from Washington DC. The other one will be from Dallas other other location is from Germany so right now we created like this app called PAK app and we deployed in three three different Centers and and also the UI which we built and we have deployed it Okay, so let me get that I have we have the both So we have both the UI as well as The script so I can show both of them. So this is just a simple UI which gets the App name. So I'm just giving here PAK and this is the app which is deployed So what it does is it goes and searches all the availability zone or sites and pulls out the information and it displays So this is for like a phase one or a current MEP later. I think I just going to explain Explain about it. So this is it gives in the app name with the current status of it whether it's started or stopped and and also the instance how many instances there and How many are running also the usage of the each app what's the route and basic app related stats? so this this is kind of Like a basic information with this we can enhance by adding more functionalities Like further future MEPs like I like restart or doing everything like I will be talking about in detail and also last thing I would like to show the The scripts which it can be also be done by the scripts. So I can show that quickly so So this is this is a script which we also have so initially we start with the script and we enhance to a UI Later we can also integrate this with any other UI or it could be like a custom UI which talks to all the availability zone So what this does is it looks for this particular app called PAK app across all the Availability zone. So first it's logging in. So as I mentioned earlier, we have three data centers. So first it goes through Data center one it like it logs in and it searches. This is like behind this in logs I'm just showing for you. So what happens when when the UI interact and looks for that particular app. It says, okay, this app is running at Only one instance and this is the status of it Then after that it it goes and logs into the second data center and checks for this particular app and pulls out Metruses like okay. Where is this particular same app name? For this particular Availability zone. So what's the information? So they are like two instance running and and the for the next that's that's no app deployed So it's not been there. So this is this how this is like behind the behind the scene We initially start with this script and then we enhance to the UI and we can do many many things So I'll just pass on to the next future use cases To ire so that he can explain about the future use cases Thanks Kumar. Thanks Kumar. So we started with the initial trial on our prototype for the Available current sites. So in any enterprise environment, you have some multiple sites. So To make it more production. So what we can do is we can gather this data gathering as actually a scheduled or Automated or by way of a separating it from a UI to an Agent so that it will be doing a local gathering and then sharing it across the different Availability zone agents To enhance the user experience you can actually MVP 3 we can actually do it with a maybe another UI any UI we can integrate it like maybe stratoes or something like that and We can also in MVP for we can actually store and retrieve the application status and Improve the performance by caching it locally And persisting across a data store. So if one site is completely down Even if connected to another UI in another cloud foundry instance, I will be able to get all the information about the application running on that site and We can actually also make this agent based tool as an Enhancement to do a do all actions Routine mundane actions or something like that doing a health checks or restart all these things can be done at a single console So These are the proposed enhancements, which we can visualize at this point of time. That's it From outside any questions we can take if you have thank you all


So I'm here at the Eden conference in Bruges and I've got two great colleagues with me here. I've got arena who's our Current president who's out going and also Sander who is our president-elect. Can I ask you first? I'll come to you arena. Can I ask you about your? retrospective Views on what you've achieved in the last three years as president So first of all when my Term of presidency started. I Had the perfect example and initiative That was started by previous presidents To Unbundle a little bit governance structures To reshape rethink revision The ways how we could consolidate better the community During my introductory Speech in Budapest in 2016. I addressed the community asking To support me in this matter and of course we started with the board with the executive committee thinking about new internal structures that would facilitate this development and this Reshaping a little bit of consolidated actions and I think that was successful because we agreed that We do it collaboratively Thoughtfully as always in Eden but always taking risks and In order to make the final decision we would Recheck Revisit the opinion of the community And first of all fellows and senior fellows so following these processes, I think one of the Best establishment during the last three years was consolidation of Eden Fellowship Now we have the Council of Eden Fellows. We have the board who actually Leads the ideas into projects and then calls out For community members to join The second thing is we Wanted to investigate what works in terms of application of technologies in education Which innovations that come from European and global scope Might be experimented piloted and then which experts from Eden community should be addressed in order to provide Opinion consultation remarks So we selected several of them that were in line actually we were happy enough to be a member of ET2020 education policy framework So we were in line to see how these initiatives develop like new formats of recognition credentialization of learning and how Eden Should position itself as the community of experts a network of academics and professionals to facilitate these movements So I would highlight these two Main streams of activities. I think that were the focus during my presidency and Collaboratively we did this I think in a quite successful step forward So Sandra you have some big shoes to fill now because you have to take over as president now of Eden And for the next three years, I'd like to know what you think Eden will achieve. What what what are your plans for the organization? Well, I've been happy to be able to continue what Irina has started because You cannot finish everything in a short period of time So we set really good path and I plan to continue with this But only and also to see as you know times are changing quite rapidly and What we are talking about today, it may be not be tomorrow, but with such a large community I think we have enough to see what's going to be and what's going on and even is quite solid And I think it can stay solid in a way that it takes what's the best and appropriate and Put it on the market, you know as advice as as opportunity together So I'm going to see that we continue with these initiatives We have been started and also to see how we can enhance the visibility of Eden in a way that What we produce what we gather what we collect is more available to everyone because today information is very much present if you have information you have the power and But what kind of information which information is good? We a lot have a fake news and things like that So even as a community can contribute to that because when you come to Eden You know that you will get good information from the professionals and in that way I want even to be a place where you can come to and Find the right information and we are able to collect these informations So Eden the dean Eden stands for distance But there is this possibility that maybe distance doesn't exist anymore because of technology What would be your views on the idea of distance education? Is it something that is no past? In my opinion it exists. I think the concept of a distance Transformed and Michael more I think was also talking about that some time ago now. We have other Dimensions of distance not geographical dimensions, but time occupation attention depth and different different other things that Help us to understand diversification which happens in the society and if we Support education organizations and education providers in terms of walking with the unbounded unbounded society members and Walking in the networks that are expanding self-expanding can the atoning into new structures I think distance is the right word. I would keep it So would you agree with that or would you disagree with that Sandra? Well, I think that we have to look today as a distance as something very present and part of our everyday life It's not any more something exotic. We have been talking about before It's like you are talking learning and e-learning. What's the difference?  So This education is becoming the part part of net normal way of learning We do not tend anymore to go to the campus for example to study We like to do it from the home or wherever we want. So Distance is it is a name that will stay as a name not as as a way of learning Irina Sandra, thank you very much for your time


I live in San Francisco where I was told I was going to have the dream California and socially liberal life and community and my reality does not match that dream. I live in a San Francisco where my neighborhood was once home to one of the strongest black populations in the city and now we're decreasing every single day. I live in a San Francisco where my neighborhood is plagued by homelessness where I walk down the street and I see people living in tents because their city cannot find affordable housing for them. I live in a San Francisco where I walk down the street and instead of feeling anger or disgust at the trash on the ground I feel sadness because I think about how people have nowhere else to go. I live in a San Francisco where every day my neighborhood is getting more and more gentrified where 25 years ago it was completely different from how it looks now and how today it doesn't serve the people of San Francisco, the people of my community but rather the people around here serve the transplants, the people coming in who work at Big Tech. I live in a San Francisco where all of my friends are moving out of the city because it's too expensive where I'm having less and less people to hang out and see every day because commuting to the city is too long of a drive. I live in a San Francisco where I was promised a dream California life and that expectation has not been met. I live in a San Francisco where I strive to make my community a better place every day but the city does not put its money where its mouth is. I live in a San Francisco where I don't know what to do at this point because my city is dying and it feels like everything I do is not working. Apparently too much of San Francisco was not there in the first place. This dream requires more condemned Africans or put another way state violence rises down or still life is just getting warmed up. Army life is looking for a new church and ignored all other suggestions or folktale writers have not made up their minds as to who is going to be their friends. You know this is the worst downtown yet and I've brought a cigarette everywhere. I've taken many a walk to the back of a bus that led on out the back of a storyteller's prison sentence then on out the back of slave scars but this is my comeback face. I left my watch on the public bathroom sink and took the toilet with me. Through it at the first bus I saw eating single mothers half alive and they flew through the bus line number then on out the front of the White House that hopefully you find comfort downtown but if not we brought you enough cigarette filters to make a decent winter coat. A special species of handshake, let's all know who's king and what's the lifespan of uniform cloth. This coffin needs to could act like those birds singing. Rusty nails have no wings, have no voice other than that of a white world dying. They're book pages in the gas pump. Catchy isn't it? The way Three Nuses is the rule or the way potato sack masks go so well with radio codes or the way condemned Africans fought their way back to the ocean. Only the fine waves made a 1920s burnt up piano parts, European backdoor deals and red flowers for widows who spent all day in the sun mumbling in San Francisco. Red flowers but what's the color of a doctor visit? You know there are book titles in the streets. Book titles like hero you make a better zero or a fur coat lady the president is dead or pay me back in children or they hung up their bodies in their own museums and other book titles pulled from a drum solo run here hero not at the hiding place all the bullets and 10 precincts know where to go there's no heaven nor any other good idea in the sky politics means that people did it and people do it.


Hello and welcome to the session in which we would look at CPA exam questions that deals with the income statement. The income statement is an important topic on the CPA exam and that's obvious because every and each company will have to prepare an income statement. Now in this session we would look at CPA questions that deals with items that goes on the income statement. You need to know how they are presented, when they are presented and why they are presented in a certain manner. So if you are a CPA candidate or an accounting student or a CMA candidate, I strongly suggest you check out my website farhatlectures.com. No, I don't replace your CPA review course. If you have a course you can keep it. That's not my intent. My intent is to be a useful addition to your CPA review course. I can add 10 to 15 points to your CPA exam score by explaining the material differently. Maybe better, maybe not better, but at least I can show you the material in an alternative fashion, an alternative matter. And it's often time it might click and it might help you understand your CPA review course better, which will help you on the CPA exam. And what I did is I created my courses very similar, mirror image your CPA review course, so it's very easy to follow between my course and your course. Your risk to try me is one month. If you like it, keep it if not cancelled. Your return is potentially passing the exam. And if not for anything, take a look at my website to find out how well your university doing on the CPA exam. As I mentioned, I do have other CPA, other than CPA review courses, I have accounting courses as well. Please connect with me only then if you haven't done so. And you can view only then people that actually used my material to pass the exam, like this recording on YouTube, share it, connect with me on Instagram and Facebook. Let's take a look at the first question. It's better to read the question first. What before tax amount should the company report as a loss on this continued operation in its 2021 income statement? So we are looking for a loss. So that's easy. They're not confusing us between a loss and a gain. And specifically they are asking about this continued operation. So let's see what's happening here. On October 28th, a company committed to plan to sell a division that qualify as a component of an entity according to GAP regarding this continued operation. This continued operation is an important concept that you need to understand very well on the exam and was properly classified as held for sale as of December 31st 2021 at the end of the physical year. So it's a division, discontinued operation and was properly recorded. Okay. The division's loss from operation for 2021 was 2 million. So they're telling us the division loss was 2 million. The division's book value and fair value less cost to sell were 3 million and 2.5 million respectively. So they're asking us how much we need to report as a loss from this discontinued, discontinued operation. Well, obviously it's 2 million. We're going to start with this. And why? Because they operated the business, sorry, they operated the business, they operated the business and they incur 2 million of losses. Therefore, it's 2 million. What else do we have to report? Look what we are told. Let me just highlight this. We are told that the division book value, the division book value was 3 million and the division fair value at the end of the period was 2.5. It seems that the division has an impairment loss because the fair value is less than the book value. Well, based on conservatism, we're going to have to report an additional 500,000 of losses. Why? Because look, their book value and their fair value, their book value is 3 million, the fair value of the division is 2.5. Well, we have to report an impairment loss of half a million. Therefore, all in all, the report the loss from discontinued operation is 2.5 million. So it's very important that you understand how discontinued operation works. And in this example, actually we ignored taxes. So you have to report those figures net of tax. And this is where Farhat Lectures will help you tremendously understanding what does it mean something reported net of tax and specifically something as important as the discontinued operation. A likely method that manager use for classification shifting in its report of operating expenses. So when they're shifting operating expenses, what can they use? Well, can they use revenues? No, it cannot be you're shifting certain expenses. You cannot turn them into revenues. That will be very creative. But that's quite impossible taken an expense and turn it into a revenue. Let's skip the income tax expense. Well, you can shift something into an income tax expense, but that's going to be too obvious. From an auditor's perspective, from a user's perspective, your expenses will be too large. So it's not really shifting to report certain operating expenses. You don't shift them into income tax expense into an asset. You can shift, you can turn an expense into an asset. But for classification shifting, so we're not turning the expense into something else. Something else could be revenue, very difficult to do. But you can turn an expense into an asset. Say it's going to serve me for several years, this expenditure, it's an asset. But here we are shifting classification, not the nature of the expenditure. Therefore, you are likely to report it as non-operating expense. So we have operating expenses and non-operating. Non-operating will be interest, income tax, income tax expense is non-operating. So you might take something that's operating and shift it into non-operating. Now, why would the manager will do that? It's still an expense. So this is an expense and these are expenses. Well, because when you value a company, you are looking at their operating income. Really, when you are looking at a company, what you care about is their operating income. And operating income is computed by taking operating revenues minus operating expenses to get to operating income. So the managers might want to shift some of those expenses to non-operating. So the operating income would look larger, the company will get a higher value, the company would look good, the manager would look good. So this is one potential shifting is going from operating expenses, shifting an expense and say this is a non-operating. Temporary earnings are best characterized as what? So we have temporary earnings and obviously we have permanent earnings. Really, the term is just for there's no strictly accounting terms that says temporary earnings, but temporary earnings are earnings that don't repeat, earnings that don't repeat in the future. Now, why do we want to differentiate between temporary earnings and equal to permanent earnings or earnings likely to occur? Just like expenses, we want to know the nature of the expenses. Whether this expense is operating and usually operating expenses stay with us because it's part of the business, non-operating they have nothing to do with operating the business. For example, interest is financing income taxes has to do with the government. So for revenues, we also have to kind of tell the users on the income statement whether this revenue is temporary or it's going to repeat. Okay. A, an earning that don't have corresponding cash flow. Well, maybe here you're saying a cruel revenue because corresponding cash flow means it wasn't in cash. Well, not really. That doesn't mean anything. You could have earnings. It doesn't have a cash flow yet. So that's not temporary earnings. Earnings from non-operating activities. Not necessary, not necessary earnings from non-operating activities because non-operating, you could have earnings from non-operating activities like interest, interest revenue. Okay. You could have, if you are not a bank, you could have or an investment firm, you could have dividend revenue. Those are non-operating revenue. They are earnings but they're not from your operation. Okay. So that's not the definition of it. Earnings that do not conform to gap.  So that's no. D is by process of elimination is the correct answer. And D says earnings that likely that arise from event that are not likely, notice here, not likely to reoccur in the foreseeable future, not likely to reoccur. So what's the best example I can give you about this? It was at Caterpillar? Was it Caterpillar or John Deere? I'm not sure whether it's Caterpillar or John Deere. In one particular year, this 25% of their sales, I'm not sure what's it, John Deere or Caterpillar please, but I'm going to illustrate the point. 25% of the revenue was a contract with the Brazilian government. It's a one-time deal. So 25% of the revenue was a contract with the Brazilian government. So they have to tell you that this revenue, that's substantial revenue, that's substantial amount of revenue, it's a temporary earning. It means it's not going to reoccur in the foreseeable future. Most likely it's operating revenue. They were selling them, you know, their product, their machinery, their equipment, that's what they sell, but it's a one-time deal. It's not going to reoccur again. So from a user's perspective, you want to tell the user, look, just be careful, this is temporary earnings. That's why our revenue is so large. Don't count on that next year. This is what we mean by temporary earnings, okay? Versus we also have non-operating activities, earnings from non-operating, which is interest and revenue, they do occur again year after year. You might have interest or dividend, but also under non-operating activities, you could have gains and losses. So you might sell an asset, asset you don't use. Those are non-operating, okay? They might occur again, but they're non-operating. So temporary earnings has to do with a specific event, specific event, like a special contract with the government. Let's take a look at this question. A company has decided to discontinue a component of its business and sell the component at the end of the year. Fair enough? The amount that the company would report as income from discontinued operation, ignoring tax is what? Only income from operating for the year. No, you would still report any income or loss from the discontinued operation. Only the income or loss on the disposal of the component. No, not only the disposal, you also want to report the, you also want to report the revenues or revenues and expenses, which is operating loss or operating income, not only the gain or loss on the disposal. Income from operation for the year, and only loss on the disposal of the component. So they're saying report the income for, report the income from the operation and only the loss on the disposal. No, you would report the loss. Or you might have a gain on the disposal. Income from operation for the year, and either a gain or a loss on the disposal. Yes, you would report the income, okay? The income could be again income from operation could be here we can we can say income slash loss but from operation results from operation and either gain or loss on the disposal you have to report both so remember you have to report two things with this continued operation why because okay you classified it you would have one division you know your your car manufacturing you're selling your car money let's be let's assume google is selling youtube which is in a way they would sell alphabet not google alphabet to be more technical let's assume they decided to sell youtube which is they will never do that it's a growing it's a growing division but the point is if they decided to do that they would have to report two things about youtube when they operate youtube for that particular year they're going to have operating loss or gain which is net income or net loss from operation this is what we meant here and when they sell it they might have a gain slash loss so you report two things for discontinued operation because you are still running the operation you'd have to report the gain and loss for the sale and profit or loss for operating the business two items and both of these items have to reported net net of tax once again if you are studying for the CPA exam this topic is extremely important this is what this is what i do on my website explain this topic in detail discontinued operation the principal benefit of separately reporting discontinued operation is to enhance what so simply put why do we report this continued operation separately why well a predictive ability of future profitability and the answer is yes this is the answer because you want to tell the users look i used to have youtube let's assume we're talking about alphabet google i used to have youtube okay but don't count on any youtube profit in the future or don't factor any youtube losses and my companies in the future because i'm listing this separately now i'm getting rude of it and that's why we that we do things certain way that's why we discontinued the operation we take it out we take it out of the operating section and list it separately so it tells the users look in future years take this this company out and base your decision on what we have on operating income so it helps to enhance predictive ability of future profit profitability so you're taking it out reported it separately although it's on the income statement but it's reported separately consistency and reporting now doesn't the here the predictive ability is better than consistency consistency means using the same method which you should but once you have a discontinued operation you have to show it separately intra period continuity not really comprehensive reporting i'm not sure if you know there's comprehensive income you know you would be comprehensive reporting not really a technical term here let's take a look at this question under normal circumstances again ignoring taxes permanent earnings would be computed as what okay here they're giving us a bunch of earnings and they want us to compute permanent earn remember we have permanent earning and transitory earnings earnings that uh they are not permanent they may not stay with us from year to year what could be permanent earnings earnings that should stay with us from year to year okay with sales revenue stay stay with us from year to year yes with selling expenses we would like to get rid of that but that's not going to happen so we're going to take out selling expenses gain on sale of investment would you consider gain on sale of investment as permanent something that you do every year or it happened once in a while i would say it will happen once in a while although well we'll explain this in a moment gain on sale of the investment it's not considered really permanent permanent interest expense interest expense would be considered permanent from a business perspective you would always have a business interest expense and it's normal to have an interest expense okay gain on sale of the investment it's not it's not permanent both of these by the way both of these are non-operating both of these are non-operating the interest expense is an is a non-operating expense gain on sale of investment non-operating revenue but they're both non-operating but the interest expense is considered permanent under normal circumstances because companies incur expense interest expense as part of financing their business but gain on the sale of the investment not necessarily considered permanent okay cost of good sold yeah that's a big one we would like to get rid of that but we can't so if if we're looking at the permanent earnings of this company we're going to take 860 and deduct from it 250 minus 10 minus 520 the permanent earnings if we're looking at permanent earnings will be 80 000 okay permanent earnings is 80 000 again just want to clarify one more time both of these items this item here gain on sale in interest will be non-operating but that's not what they're asking about here if they were asking about operating income let's assume they were asking about operating income it will be 860 minus 520 which is cost of goods sold minus the selling minus 250 this will give us operating income and this is the most important operating income the company is operating their business are they making a profit how much is that profit this is what operating income is all about the questions what was about permanent earnings we do assume that interest expense is part of doing business gain on sale of investments not necessary okay again unless I mean no let's let's be clear unless on regular basis you sell you buy investments and you sell them and that's fine that's the business that you are in but if you are not in that business it doesn't work that way okay basically at the end of this recording I'm going to invite you again to visit farhatlectures.com again I don't replace your CPA review course I don't intend to do so I intend to help you I intend to be a backup an alternative explanation to your CPA review course give me a chance try me for a month that's your risk it might help you pass the exam an investment that's that's that's going to live with you for 30 years good luck study hard and of course stay safe


The chief of naval operations joined service chiefs, flag officers and education professionals to speak at a military child education coalition discussion in support of our nation's youth. Mentorship and guidance were two words of advice for the 600 educators in the audience. Other advice came from the heart. But before I give any advice, I want to say thank you to educators, to professional military people and parents. But I think number one, you need to care. When you see that child that has great potential or needs a boost or needs some care, take care of that. Greenert said decreased education is becoming a matter of national security, which emphasizes the importance of organizations like MCEC to help ensure DOD students accomplish their academic goals. Reporting from Grapevine, Texas, I'm Petty Officer Peter Lawler.


One of the things that's great about America is our diversity, and an Indian American sailor came face to face with his roots in a very unique way, Malabar. Malabar is an exercise between the Indian Navy and the United States Navy. It's a fulfilling opportunity to work with the Indian Navy after 26 years in the U.S. Navy. Indian sailors were invited aboard to see things from a different angle, and seeing the CEO from the same country as them made quite an impression. I didn't know that he was an Indian American, but then when I came to know, it was pretty exciting. He's a good man, and seeing the way he was commanding the ship, pretty impressive. This is just one example of how being a diverse Navy makes us a stronger Navy. Seemed with Christina Coffey, reporting aboard USS Shrila.


Internal Revenue Service R.R.S. Tax News, National Tax Security Awareness Week Day 4, choosing a unique identity protection pen as extra safety for taxpayers. Wow, a magical identity protection pen? That sounds great! It'll be like Frodo when he puts on that ring and nobody can see him, except like that one dude. The security protection pen will turn me into like Batman. Once my identity is protected, I can safely strike fear into the hearts of wrongdoers. The first one on my list is that dang IRS. But wait a second, considering the IRS gave me the identity protection pen, is it possible the IRS wrongdoers will still know my identity? The pen ring thing actually having been forged by Sauron himself? Honestly, I feel like I just ordered my custom bat mask from the Joker.  No, what the heck, I'll laugh anyway. That's like TikTok promising to not give my personal data to communists. I mean, honestly, that's like giving the Biden's tax dollars and expecting them not to spend it on crack. It's ridiculous. Not to criticize or anything. I had an Uncle Joe that was the same way.  I mean, talk about a gaslighter, I'll tell you what. Uncle Joe would be like, no, I'm not aware of any decrease in like the silverware supply. Something must have happened to it, man. Maybe it was the silverware supply shop on the corner. It's like, okay, yeah, right, Uncle Joe, something happened. You happen to it. You cracked out.  Like when the dollar becomes worthless, those garbage pail kids will be putting food on this table. Dang it.  Anyways, first to joke, money doesn't grow on trees. It's a tough economy. Money doesn't grow on trees. It grows on trees. Which is good. Because trees grow stuff that actually maintains its value. Luminous being so weak, not this crude matter. Yeah, at least for a few months or so.  The fear of loss is a path to the dark side. Maybe the government is picking the dollars of the proverbial dollar tree too early. Or maybe they're picking the leaves rather than the fruit.  Don't trust them. I'd be like the grocery store saying, hey, we've got some fresh pickings from the orange tree for everyone. Good news, everyone. Tomorrow you'll be making a delivery to Ebola nine, the virus planet. We're just going to hand them out for free. Aren't these great orange tree leaves? Cookie. Not me, sir. Young lady. No, thank you. No, no, I was just offering him a young lady. And it's like, wait a second. Nobody wants the leaves from the orange tree?  Who's scruffy-looking? Where's the fruit? No. President Biden then turns into his angry Biden mode saying, am I going mad?  And you're like, but sir, this can't possibly work. Who's the more foolish fool or the fool of all of us? Biden responding, don't worry. All we have to do is keep outpacing reality indefinitely and we'll be fine. Look, Israel on top of us. Wonder fishes in the same wind we're using. Whoever he is, he's too late. See the cliffs of insanity. And it's like, but how are we going to outpace reality forever? I mean, don't you need to sleep between lies? We first have an IRS YouTube video linked to that here. New security measures help protect against tax-related identity theft. IR 2022-210, December 1, 2022, Washington as part of a broader effort to increase security of the Internal Revenue Service and the Security Summit. Partners today remind the taxpayers they could get extra protection starting in January by joining the agency's Identity Protection Personal Identification Number, the IPPIN program. So this is the program that used to be just there for people that had their identity already stolen and then people filed fraudulent tax returns. And as a response to that, given your identity is already out there, they already have the social security number. They had to come up with a second number in order to protect the identity for the future. Now you can proactively get the IPPIN and hopefully safeguard against somebody filing a fraudulent tax return before it actually happens. So note the IPPIN you can kind of think of as a second social security number. Remember that these days because of increases or in part because of increases and changes to the tax code, increasing refundable credits, it's likely that lower income individuals or any individual, even if the person stealing can only file a low income tax return, are going to be targeted because now you've got more money on the table with these kind of refundable credits. Also note that with the increase in technology, it's kind of silly, it's kind of ridiculous at this point in time that when someone says, well, your identity was stolen, what they got your date of birth, they got even your social security number, how in the world would that happen? Well, that's because the internet is much more fluid these days. It's going to be really difficult to try to safeguard, say like your date of birth when you give it to someone and you celebrate your birthday every year. It's probably, you don't feel bad if someone knows your date of birth. Although they'll say, obviously you don't want to be shooting out all that personal information on all the social media platforms and everything. But again, even the social security number at this point in time, when the social security numbers were put in place, there wasn't an internet going on at this time. So now you've been given your social security number to everybody, the number has not changed, you give it to your employers, you give it to your financial institutions and so on and so forth. It's highly likely that if someone put in a little bit of time, they can gather a lot of social security numbers. So at some point, you would think they might need to kind of change the number from time to time. I know that would be burdensome. I don't know how that would work. But in terms of at least filing a fraudulent tax return, if someone has your social security number and your date of birth and so on and that kind of stuff, they might be able to do that and they're more likely to want to do that now because of all these refundable credits that they might be able to get access to even on the low income side of things. And therefore, you might want to proactively stop that by getting another pin like another social security number, which would only be applicable for basically tax reporting purposes, a little bit more burdensome, but possibly saving time down the road by giving another layer of protection. All right, so anyone who has a social security number SSN or an individual taxpayer identification number an ITIN and is able to verify their identity is eligible to enroll in the IPPIN program. More than 6.6 million taxpayers are now protecting themselves against tax related identity theft by participating in the IPPIN program. Last year, the IRS made changes to the program to make it easier for more taxpayers to join. The fastest and easiest way to receive an IPPIN is by using the get an IPPIN tool. There's a link to that here, which will be available in January. Today's reminder marks the fourth day of the National Tax Security Awareness Week, which runs through December 2nd. The security summit, there's a link to that sponsors this annual observance as part of a larger effort between the IRS, the state tax agencies as well as the nation's tax software and tax professional industries. So they basically get around and talk about, wow, there's a lot of stuff being stolen in terms of identities these days. And then they kind of tell you about it and stuff. So that's what we have here. So the security summit was established in 2015 to protect taxpayers and the nation's tax system against tax related identity theft. This unique collaboration between the public and private sectors has increased mutual defenses against criminals trying to file fraudulent tax returns and steal refunds. One of the critical features of the IRS system involves an IPPIN, which is a six digit number assigned to eligible taxpayers to help prevent the misuse of their social security number or individual taxpayer identification number on fraudulent federal income tax returns. An IPPIN is known only to the taxpayer and the IRS initially designed for confirmed victims of tax related identity theft. The IPPIN program was expanded in 2021. See, I told you, I told you all this before, I told you the news before I read it here. But in any case, to include any taxpayer nationwide who wants the additional protection and security of using an IPPIN to file tax returns with the IRS, quote, preventing someone from filing a tax return under another person's name is the main reason we want people to have this special code, end quote, said IRS Acting Commissioner Doug O'Donnell, quote, we encourage people to apply for the code when the system opens up in January. This step provides an extra line of protection for taxpayers and their tax return, end quote. An IPPIN helps the IRS verify a taxpayer's identity and accept their federal income tax returns, regardless of whether they are filing electronically or on paper, the online get an IPPIN tool at irs.gov forward slash IPPIN. There's a link to that here, displays the taxpayers IPPIN. Any participating taxpayer will use the tool in each subsequent year to obtain a new number. So that's what you would think has to happen. You would think if you want a valid social security number, it's going to have to change periodically, which I know is kind of a pain, but that's what they're doing with the IPPIN. So you don't have the same number for the next 100 years or whatever into whatever you probably not going to live 100 years, but maybe because like medical science is changing and everything. But in any case, a long period of time with ever increasing access and people weaseling into your information and new and creative ways to rob you, you might want to have a changing identification number from time to time, you know, that might help. Any case, the IRS urges any IPPIN applicant previously rejected during the identity authentication process to try applying again in 2023. The authentication process has been refined and improved enabling many taxpayers screened out in the past to have a better chance of passing the authentication process. The Electronic Tax Administration Advisory Committee or the ETAAC, which I know sounds like AA for like extraterrestrials or something. It's an AA club or something, but no, it's actually the Administrative Advisory Committee. There might be some ETs with some alcoholic problems that are also getting together and working those out, but any case, whatever. Earlier this year highlighted the importance of the IPPIN to taxpayers and tax professionals. Quote, the IPPIN is the number one security tool currently available to taxpayers from the IRS and quote, the Independent Advisory Group said in its annual report to Congress quote, this tool is the key to making it more difficult for criminals to file false tax returns in the name of the taxpayer. In our view, the benefits of increased IPPIN use are many end quote problem solved, done the ETAAC extraterrestrial alcoholic anonymous club. No, I'm just joking. That's nothing. They solved the problem though. They've got it. They've got the answer. They also recommended the IRS continue highlight and promote the IPPIN through a public awareness effort. As part of this effort, the IRS is highlighting the IPPIN as part of a nationwide tax security awareness week. The IRS also continues to raise awareness about special items, including publication, five, three, six, seven IPPIN opt-in program for taxpayers. There's a link to that here in English and Spanish. You can read it in Espanol if you prefer so that tax professionals can print and share the IPPIN information with clients. Special posters are also available in English and Spanish. Now the problem solved before they had the posters. I was still, I was still skeptical, but now you can get a poster. Sweet.  Key points about IPPIN program before applying. Keep these key points in mind about the IPPIN program for 2023. They get an IPPIN to a schedule to launch on January 9th, 2023. It's the fastest and easiest way to get an IPPIN. It is also the only option that immediately reveals the IPPIN to taxpayers. So you get it immediately. That immediate gratification of having this new number be sweet. It's like a lottery number except it doesn't really have any likelihood of winning you money or anything. But anyways, therefore the IRS urges everyone to try to get the IPPIN tool before pursuing other options. No identity theft affidavit is required for taxpayers opting and anyone who voluntarily applies for an IPPIN does not need to file form 1439 identity theft affidavit with the IRS. Now this was probably the formal, the former process before they extended the program to having other people use it. So in other words, if someone actually already stole your identity and filed a fraudulent tax return and you have to go through the painful process of trying to fix that and say, hey, it wasn't me IRS.  That was my crazy cracked out Uncle Joe filed a tax return trying to steal my refund. So and you got to fix that. Then you might have to file a form 1439 identity theft affidavit. But if someone hasn't stole your identity and you want to preemptively stop crazy cracked out Uncle Joe from stealing your identity and trying to get your refund, then you could try to get the IPPIN and make sure that that he doesn't get access to it. So an IPPIN is valid for year for one year. This means that each January, any participating taxpayer must obtain a newly generated IPPIN. That's kind of one of the points of the new social security kind of type number, the IPPIN.  So you want to change it fairly often. So be sure to enter the IPPIN on any return, whether it is filed electronically or on paper. This includes any amended returns or returns for prior years doing so will help avoid processing delays or having the return rejected by the IRS. Anyone with a social security number in SSN or individual taxpayer identification number otherwise known as an ITIN who can verify their identity is eligible for an IPPIN opt-in program. Any eligible family member can get an IPPIN. This includes the primary taxpayer, the person listed first on a tax return, the secondary taxpayer, a joint return, the person listed second on the return, or any other dependence. So notice that when you're filing the tax return, all the people that are on one tax return, which means if you file a joint return, you've got us two spouses involved and you have to list one before the other. I know it's possibly sexist, but you could list, you know, the female before or the wife or whatever. You can list them however, one and two. You got to have two spouses on there. One has to be on the top, kind of. And then you might also have dependents and they all have social security numbers. And if anybody steals their social security numbers and files a fraudulent tax return before you file your tax return with them on as a spouse or a dependent, then you're going to run into the same problems. So you can do the same IPPIN thing, you know, to try to safeguard all of the information. So, you know, crazy Uncle Joe could pull together the whole family and, you know, try to file a hundred tax returns based on everyone's stuff or whatever. So never reveal an IPPIN to anyone. The only exception is a taxpayer who uses a trusted tax professional to file their return. Even then, only share the IPPIN with the trusted tax pros when it is time to sign and submit the return. The IRS will never ask for an IPPIN. Remember to watch out phone calls, emails and texts requesting an IPPIN, our scams. Third parties offering to assist taxpayers and establish or regain access to IRS online accounts and asking for the taxpayers personal information, including address, social security number or individual identification number, IT, ITIN and photo identification. Use this information to sell to others or file fraudulent tax returns, open credit accounts and more. So it's painful when someone, you know, kind of steals your stuff like that, violates your trust and whatnot. But that's what people are doing. That's like what 90% of the internet is. So you've got to be aware of that. So identity theft victims should still fill out an ID theft affidavit. Any confirmed tax-related identity theft victim still needs to file form 1439 with the IRS if the agency rejects their e-file tax return due to duplicate social security number filings. So clearly what's going to happen if someone steals your identity, files a fraudulent tax return, Uncle Joe steals the whole family's identity, files like 20 fraudulent tax returns and tries to collect out a bunch of refunds based on the increase in the credits that are refundable portions. Well then when you try to file the tax return, it's going to bounce it back and say, hey look, someone's already used this social security number. That's when you find out Uncle Joe, he's done it again. So the IRS will then investigate their case. Once the fraudulent tax return is removed from their account, the IRS will automatically mail an IPPIN to the confirmed victim at the start of the following calendar year because the security risks confirmed identity theft victims cannot opt in of the IPPIN program. So options for people who can't pass the online authentication process. So two options are available for people who cannot pass the IRS online identity authentication process. One involves filing form 15227 and the other requires a visit to an IRS taxpayer assistance center. So again, you can do like the automatic kind of easy process. If that doesn't work, you can try to file the form 15227 or you can try to talk to someone in person. There's a link to the IRS taxpayer assistance centers, the TACs here. Unlike the online option, both of these options involve for security reasons a delay in receiving an IPPIN. Form 15227, for processing year 2023 individuals with an adjusted gross income of $73,000 or less and those filing jointly with an adjusted gross income AGI of $146,000 or less with access to a telephone can complete form 15227. There's a link to that here and either mail or fax it to the IRS. An IRS representative will then call them to verify their identity with a series of questions. Taxpayers choosing this option who pass the identity authorize the authentication process will generally receive their IPPIN in about a month. IRS taxpayer assistance center, any taxpayer who is ineligible to file form 15227 may make an appointment to visit an IRS taxpayer assistance center at TAC. Anyone using this option must bring two forms of picture identification because this is in person identity verification and IPPIN will be mailed to the taxpayer after their visit. Usually allow three weeks for delivery to find the nearest TAC use the IRS local office locator. There's a link to that here online tool or you can call<PHONE_NUMBER>. I won't say that a hundred times because there'll be a link to this in the description. For more details and to learn more about this year's National Tax Security Awareness Week efforts you can visit IRS.gov forward slash security summit. There's a link to that here. There's a link to all this stuff here. There'll be a link to this in the description.