Zubaidullo's Blog
Inside Guice transaction session, when Object is loaded it's LAZY loading joined Objects are loaded once inside that session context. So, when transaction is rolled back LAZY loaded objects will be lost.
We can think this case: void distributeSMS( List<User> users ) { for ( User user: users ) { for ( Phone phone: user.getPhones() ) //here getPhones are Lazy loaded { try { sendSMS( phone ); } catch( Exception e ) { log.error( e.getMessage() ); } } } } @Transactional void sendSMS( Phone phone ) { //here some SMS sending operations } In this example we see that, user's phone numbers are Lazy loaded and given to transaction. In RuntimeException case, sentSMS() method will be rolled back and catches inside sendSMSToAll(). In normal view, we see that it throws exception for one Phone and it should continue next job. But! Here we will see Exception : org.hibernate.LazyInitializationException: could not initialize proxy - no Session Here we can clearly understand how Guice transaction works with Lazy loading. Reason why we get above exception, because Transaction is rolled back and that session is closed. So, in next loop when tries to load user.getPhone() it will throw exception. Here we can use multiple solutions by changing joins or on JPA level. Let's see quicker way to solve above problem and understand well how transaction session works with Lazy load. Before looping user phone numbers, we can just get list of Phones without lazy load. Ex: List<Phone> phones = getUserPhones( user ); ......continue for loop. We get phone numbers with other session and in transaction roll back case this session will be alive.
Click to set custom HTML
0 Comments
Optimal Dynamics, creators of the Subutai decentralized, peer-to-peer Cloud computing platform, today announced that it has appointed Jon "maddog" Hall as Chief Executive Officer. Mr. Hall has served as an advisor to the company since 2015.
"We are so pleased to welcome Jon to lead Optimal Dynamics," said Alex Karasulu, Founder and Chief Technology Officer of Optimal Dynamics. "Jon's background and understanding of transformative technology shifts are a perfect fit for us as we enter our next phase of growth." Since beginning his career in computing in 1969, Hall has been a programmer, systems designer, systems administrator, product manager, technical marketing manager, educator and consultant. He has worked for Western Electric Corporation, Aetna Life and Casualty, Bell Laboratories, Digital Equipment Corporation, SGI, among other companies. His involvement with Linaro brings environmentally friendly computing to emerging marketplaces, as well as working on performance and educational issues with Free and Open Source Software and Hardware (FOSSH). Hall currently serves as Chairman of the Board for The Linux Professional Institute. "I consulted with Open Source giants such as Red Hat, Digium, IBM and others as they were determining their strategies for Open Source. I will lend this expertise to Optimal Dynamics," said Jon "maddog" Hall. "I am excited to be named the company's Chief Executive Officer." A passionate FOSS advocate, Hall has been involved with Linux since May of 1994, when he first met Linus Torvalds and correctly recognized the commercial importance of Linux and Free and Open Source Software. He formulated the first commercial association for the promotion of GNU/Linux, Linux International, and later helped others to see the use of Open Source as business solutions, and is further credited as one of the people who helped to coin the term "Open Source". Hall is the author of numerous articles, including a monthly article for Linux Pro Magazine, and is the original author of the popular book, "Linux for Dummies". He has taught at Merrimack College, Daniel Webster College, and Hartford State Technical College, where, as Department Head of Computer Science, was given the nickname "maddog" by his students. Hall has consulted on the use of Free and Open Source Software for the United Nations, the governments of China, Malaysia, and Brazil, as well as many local and state governments. He has presented at countless events in over a hundred different countries around the world. Both Hall and Karasulu will be presenting at numerous upcoming events, including FutureCOM, Latinoware, UBATUX, and LISA conferences. "Optimal Dynamics is positioned to revolutionize the world through truly innovative technology. I look forward to working with the team to bring Subutai's features and functionality to the greater marketplace," added Hall. Optimal Dynamics' Subutai platform includes: 1) Subutai —container-based P2P Cloud computing platform that allows anyone to share, barter, or rent computer resources using Subutai’s cryptocurrency; 2) Subutai Hub —Cloud commerce platform, reputation system, and search engine for tracking peers and resources; and 3) Subutai Liquid Router —hardware optimized Subutai appliance, dynamically reconfigurable WiFi Router and IoT gateway device that also mines for Subutai Coin. The company also announced that Sally Khudairi will assume a new role as Director of Marketing and Media, and will be working with Hall and Karasulu in shaping corporate and product marketing strategy. Khudairi is recognized for her work with pioneering innovations as the founding Head of Communications alongside World Wide Web inventor Sir Tim Berners-Lee at the World Wide Web Consortium, and her current role as Vice President of Marketing & Publicity at The Apache Software Foundation, which she helped launch in 1999. Optimal Dynamics is also expanding its technical leadership with the hire of Niclas Hedhman as Director of FinTech. He joins the company from Morgan Stanley, where he was Vice President in the Equity Risk Technology and Enterprise Application Infrastructure teams. He is CEO of CodeDragons, a FinTech-focused consultancy based in Malaysia, and has been an active contributor to Open Source for more than 20 years, most notably at The Apache Software Foundation. In addition, the company will be expanding its distributed engineering team with a new development center in South America. "'Maddog' has been my mentor and friend over the past 6 years, and has influenced many successful companies through the years," added Karasulu. "With our market-proven product line, the opportunity ahead for us is tremendous, and we're ready to accelerate our reach to new customers more quickly with the right leadership." About Optimal Dynamics, LLC Founded in 2013, Optimal Dynamics is the company behind the Subutai suite of solutions —the world’s first secure Peer-to-Peer Cloud computing platform enabling dynamic Cloud environments across Cloud infrastructures and devices on the edge. Optimal Dynamics is based in New York with distributed teams located in Europe, Asia, and South America. For more information, visit https://optimal-dynamics.com and follow @optdyn on Twitter. Note to editors: Optimal Dynamics executive bios are available at https://optimal-dynamics.com/management.html © Optimal Dynamics, 2017. "Subutai", "Subutai Hub", and "Subutai Liquid Router" are trademarks of Optimal Dynamics, LLC. All other company and product names may be trademarks of the respective companies with which they are associated. NEW YORK, NY (PRWEB) AUGUST 09, 2017 New York, NY, April 11, 2016 (GLOBE NEWSWIRE) -- Optimal Dynamics announced today the integration of Subutai Social, its flagship Peer-to-Peer (P2P) infrastructure Cloud computing product, with AppScale, makers of the popular Open Source implementation of Google App Engine (GAE).
The integration will promote the development and proliferation of P2P GAE/AppScale based Cloud applications on Subutai Social, the world’s first Linux container-based P2P Cloud infrastructure platform that allows anyone to share, barter, or rent compute resources. With Subutai Social, users can instantly create and manage virtual data centers using peer resources on local area networks and across the Internet. Any computer or group of computers running Subutai Social software may choose to expose and share resources to support P2P Cloud environments, with service redundancy built into the platform. In turn, this enables cheap commodity computers and even residential Internet lines to be used to host stable yet extremely adaptive P2P Cloud environments that can change shape and move across the Internet adapting to any global load distribution. Together, Subutai Social and AppScale empowers developers by automatically making any GAE application a P2P distributed Cloud application. In addition to the convenience of forming P2P Cloud environments on demand to develop GAE applications, new opportunities arise for the consumption of applications where end users may simply drag and drop GAE applications into their own P2P Cloud environments. "AppScale integration with Subutai Social adds a new dimension to our platform," said Woody Rollins, CEO of AppScale Systems. "P2P Cloud computing blends the lines between public, private, and hybrid Cloud computing. AppScale's customers come to us because they love the Google model but their business requires a more flexible deployment solution. Subutai provides a whole new avenue of options. We are very excited about this collaboration and the potential of Subutai." Subutai Social users connect from all over the globe to share resources and create secure Cloud environments across their peers. Just as a cloud can float down onto land and is thus called fog, IoT devices attach to a Cloud when available and needed as it floats onto the periphery (a.k.a. "Fog computing"). "With Subutai Social P2P Cloud computing, the term 'elasticity' has a whole new meaning by freeing the Cloud from the confines of the datacenter," added Karasulu. "Your next personal computer won't be just another laptop, tablet, or wearable device: it will be EVERYTHING surrounding you, connected fluidly by adaptive P2P Clouds driven by social interaction. We're very excited about the opportunities ahead." The complete Subutai system, including AppScale, is rooted in Open Source, and leverages the power of dozens of ubiquitous enterprise-quality projects that include: Apache Cassandra, Apache Hadoop, Linux, OpenGPG, Apache Solr, Apache Spark, Ubuntu Snappy, among many others. Subutai software (excluding code for The Hub) is Open Source under Apache License v2, and available at Optimal Dynamics will soon be broadening its beta program for Subutai Social. Users interested in applying for the beta program can register at . The company anticipates formal launch of the full Subutai system mid-2016. AppScale, based in California, is an open source implementation of Google App Engine, the most popular application development platform in the world. With AppScale, developers can rapidly prototype and create apps quickly and efficiently, with the freedom to run their applications wherever it makes the most sense for their business. Some of AppScale's customers include The World Wildlife Fund (WWF), Natixis Global Asset Management, Chico's FAS and BetterCloud. AppScale Systems is endorsed by Google and is a Google Cloud Technology Partner. AppScale CEO Woody Rollins was also co-founder and founding CEO of Eucalyptus, the the private cloud pioneer acquired by HP. For more information, please visit: Established in 2013, Optimal Dynamics provides the world’s first secure social Peer-to-Peer computing solutions across dynamic Cloud infrastructures and the Internet of Things. The company’s easy-to-deploy Subutai system includes: Subutai Social (container-based P2P Cloud infrastructure platform that allows anyone to share, barter, or rent compute resources); Subutai Social Hub (social Cloud computing exchange, reputation system, and search engine for finding peers and resources); and Subutai Liquid Router (hardware optimized, dynamically reconfigurable WiFi Router and IoT gateway device that accelerates propagation across unstable residential Internet lines). Optimal Dynamics is based in New York with a distributed team located in Europe and Asia. For more information, visit and follow . "Subutai", "Subutai Social", "Subutai Social Hub", and "Subutai Liquid Router" are trademarks of Optimal Dynamics, LLC. "AppScale" is a trademark of AppScale Systems, Inc. "Google" and "Google App Engine" are trademarks of Google Inc. All other company and product names may be trademarks of the respective companies with which they are associated. # # # Sally Khudairi Optimal Dynamics [email protected] +1 617 921 8656 чтобы отредактировать. Every self-respecting company getting good quality projects uses quality management platform like SonarQube, MetrixWare, Squale, etc.
Today, I'm going to share my knowledge about using SonarQube. SonarQube is an open source code quality management platform. Other definitions you can find from wiki. I'm going to share about how to work with SonarQube metrics, how to get metrics for your application. You can use some ways for getting metrics from SonarQube server. The easy way is using Java Sonar-ws-Client or using REST API. Java Sonar-ws-client Maven dependency: <dependency> <groupId>com.atlassian.jira</groupId> <artifactId>jira-rest-java-client</artifactId> <!--Put the version of SonarQube, which you're using--> <version>4.5.1</version> </dependency> Creating Sonar Client: Sonar sonarClient = Sonar.create("http://sonar.example.com", "user", "password"); Finding metrics by request: Resource blogProject = sonar.find (ResourceQuery.createForMetrics(project_name, "coverage", "tests", etc.. )) //here you will add metrics Getting metrics for use: String coverage = blogProject.getMeasure("coverage").getFormattedValue(); //here we can get on different format our metrics I wanted to work with JIRA with making my own App. Searched how to use it with best way. Finally, stopped on JIRA REST Java Client. It's easy for use for Java users.
Maven dependency: <dependency> <groupId>com.atlassian.jira</groupId> <artifactId>jira-rest-java-client</artifactId> <version>0.6-m8</version> </dependency> Simple starting code: SearchResult searchResult = null; JerseyJiraRestClientFactory() factory = new JerseyJiraRestClientFactory(); URI jiraUri = new URI("http://example.com"); JiraRestClient restClient = factory.createWithBasicHttpAuthentication(jiraUri, user,password); SearchResult searchResult = restClient.getSearchClient().searchJql(jql_filte, progressMonitor); //Here you can get Issues, Projects, etc. Iterable<BasicIssue> issues = searchResult.getIssues(); //Then you will take every issue from issues and get anything about issue..... After the long time of searching (there is no about getting full user list in JIRA REST API Documentation) how to get JIRA Project users list, finally got answer. And wanted to share it.
For now, getting list of users in one request it's not possible, because it's in progress of developing. https://jira.atlassian.com/browse/JRA-29069 Solution: You can get list of projects in JIRA. By key of projects we can get users list. List of project by REST API: http://jira.your.address/rest/api/2/project List of users: https://jira.your.address/rest/api/2/user/assignable/search?project=YOUR_PROJECT |
AuthorJava developer and experienced Designer, Flash animator. Very good algorithmic programming skills. Participant of International Olympiads. Very good skilled in designing. Archives
September 2017
Categories |