Author Archives:

Sprint 3 Retrospective

 Links to evidence of activity on GitLab.

This is my frontend user interface for the report team

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/generatewcfbreportfrontend

I updated my frontend from sprint 2 in my local service which I used the sample frontend example from the professor. I have changed the background and move the start date and end date in the middle same as the common website let the user input the login information. 

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/reportingbackend

Austin and I connected the backend API to my frontend API, which can let customers download the report for the inventory. It got succeed download the report for the inventory when we connect the API together.

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/community/-/issues/35

My frontend design idea is based on the Worcester State University style of design. For the background picture and the color use, I followed the handbook of WSU style of design.

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/community/-/issues/67

I implemented FrontEnd for reporting with the most recent version.

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/community/-/issues/55

We Made some OpenAPI.yaml files for our FrontEnd and BackEnd.

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/community/-/issues/66

We looked over TheasPantryReport.

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/community/-/issues/71

We looked at the new architecture and plan accordingly.

Reflection on what worked well?

In Sprint 3, in terms of what worked well, the second phase was more efficient when team members worked together than ever before in completing the project plan. After a semester of teamwork, we have a deeper understanding of our ultimate goal and become more accustomed to each other’s habits. There will be a relaxed working atmosphere, and the team chemistry will encourage each other to push the project forward. The project progressed more smoothly, and the ZOOM meetings of the team were relatively frequent.

Reflection on what didn’t work well?

As for why it didn’t work out, there is a longer-term vision of the end product and the project’s future goals. Unfortunately, we failed to get the data of other groups. We made test data to run our report program. In addition, the team members were busy with other courses at the end of the semester, so there were some deficiencies in the adjustment of time in the later period. We had some confusion in the front end and back end docking. Through learning external materials and teamwork, we successfully solved the docking problem. Fortunately, we made timely adjustments and promoted the project objectives, and completed the group project.

Reflection on what changes could be made to improve as a team?

As a team with cooperation, smooth communication, and tacit understanding among team members are the basis and key to improving our team’s cooperation level. We would discuss the project after class and give some constructive suggestions about each other’s tasks. Good communication makes our team have chemistry. Through communication and cooperation, we have a thorough understanding of the team members’ tasks. Each knew the other’s project progress would be conducive to the overall advancement of the project. When a team member encounters a bottleneck in a task, we will appropriately slow down the overall progress and communicate with him to buffer his time to complete and push forward the overall task progress.

Reflection on what changes could be made to improve as an individual?

As an individual, I have watched and learned a lot about front-end production after class. It improves my front-end understanding and production skills, which helps my team better connect the front-end to the back-end. In this project, I learned and improved some problems encountered in team cooperation and realized the power of the team in finding and solving problems. In a team, the mutual understanding and tacit understanding among team members is the basic condition for the smooth operation of a team. It was a great honor for me to meet every team member in my last year of university, and I learned a lot of valuable experience from them in ZOOM meetings. At the same time, I am also very grateful to the professor for giving us an opportunity for a big team project, which benefited me greatly. I believe that I will bring my learning experience to my team in future team cooperation projects. Finally, I’d like to thank Worcester State University. It’s my great honor to be a member of the computer major.

From the blog haorusong by and used with permission of the author. All other rights reserved by the author.

Sprint 3 Retrospective

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem

Here is the Link to the repositories that contains everything we worked on Sprint-3. Backend, Frontend, Event system, and Keycloak.

Connect RabbitMQ receive file to DB: Connected the MongoDB database on the received file.

Implement Event System components: Implemented RabbitMq components for Event System.

Meet with other Event System Teams.: Met with other teams to finalize everything about messages.

New TheasPantryReport: The new Theas Pantry Report

Create two channels for both teams: Created two channels for both teams on the send and receive files.

 

For this Sprint, I worked mainly with Austin on the backend components such as implanting the rabbbitMQ, making API, and trying to get out system working.

What worked well / did not work well

For this sprint, what worked best was that we got our reporting system functioning. We have a system where the Rabbitmq receives the message from the queue and saves it in a database. From there the backend takes the data and converts it into a CSV so when the Frontend requests for a report the backend can send that CSV file to the user. One of the key things that I noticed that our group works well under pressure. We are always calm and composed. I don’t think there is something that did not work well, however, we should have managed our time wisely since the end of the semester was filled with many assignments.

What changes could be made to improve as a team?

As a team, this was our final sprint for the semester. In the future, if we work on this, I think it Is important to use the time wisely as we were up on zoom every night to make little progress towards the project. Also, whenever we had a question, we should have posted more on the issue board or could have asked the professor for more help but as a team, I’m so proud and happy with the way everything turned out towards the end.

 What changes could be made to improve as an Individual?

As an Individual, I should be communicating with my team more rather than just doing the issues that are assigned to me. I should try to manage my time wisely too. The end of the semester was a struggle since there were exams and projects from every class. I believe that we could have made our system more efficient and functional, but it turns out to be what I imagined from the starting. Working together as a team doing one task at a time was efficient for me and as a group.

Overall, this was a great learning experience. I will never forget this class or the reporting team. It was a pleasure working with amazing teammates who pushed me to move forward whenever I was struggling on an issue. I hope that the experience I got from the capstone will be a highlight for my future career in the field of technology. I wish all of you the best of luck and congrats on your graduation. Hopefully one day we can look back and enjoy these moments.  

From the blog Derin's CS Journey by and used with permission of the author. All other rights reserved by the author.

Apprenticeship Patterns Blog – Retreat into Competence

For the last and final blog post in my capstone class, I focused on the apprenticeship pattern of “Retreat into Competence” from chapter two of the book Apprenticeship Patterns by Dave Hoover and Adewale Oshineye. The section talked about perhaps how you are overwhelmed or beginning to realize how little you know, or perhaps you have taken on a new challenge and things are not working out so well. However, getting back into something you are good at is a nice way of regaining your composure. I completely agree with this statement, sometimes all we need a just a pullback to launch forward towards the goal. The quote provided at the beginning of the section is what stood out to me the most. It states that “You look at where you’re going and where you are and it never makes sense, but then you look back at where you’ve been, and a pattern seems to emerge. And if you project forward from that pattern, then sometimes you can come up with something.” This got me thinking very deeply about the past four years of college and my CS Journey. I have no idea what the future hold, but one day I will look back to see where I have been and possibly see a pattern emerge.

The author also mentioned how apprenticeship is a roller-coaster ride, you will experience the thrill of new technologies, but you will also experience struggles as just how little you know compared to the craftsmen and experts you meet along the way. It is important that Sometimes you need to take one step back to take two steps forward. But it is essential to move forwards as quickly as possible because the forward momentum is revealed in your possession of more knowledge and greater skill than you had yesterday. Another important aspect the author mentioned is how to seek support from your mentors, with their support and boost you can be on the right track again and display competence. In this way, you will be more equipped for future challenges. The patterns displayed a lot of insights towards my career and on a personal level. I will certainly be reading more patterns from this book even though this is my last and final blog post for the CS-448 class.

 

From the blog Derin's CS Journey by and used with permission of the author. All other rights reserved by the author.

Reading list

The most valuable thing you can get out of any book is a list of other books worth reading. Over time, you will find that certain books keep popping up from the “bibliography”, and you should move those books to the top of the reading list. Other books will sink. Since the reading list is essentially a priority queue, you’ll eventually find that some books sink so far down the queue that you may never read them again.

Start by picking a broad book to give you a general idea of the subject you are aiming for. Then choose a few specific books to master the aspects of the topic that interest you.

Reading the right book at the right time will have a better effect. A lot of reading can improve your reading ability. You will also improve your knowledge of the outside world through reading. For computer science, reading a lot of the latest information will be of great help to your future work and research. Reading will improve your horizon and enrich your spare time.

Even if you read a good book on programming every two months, which is about 35 pages a week, it won’t take long for you to gain a deep understanding of our industry and differentiate yourself from everyone around you. — Steve McConnell, Code Complete

Focusing on the classics also carries a risk: you devote too much energy to them, at the expense of more pragmatic knowledge and information that would improve your everyday skills. Make sure to mix classics with modern, more pragmatic books and articles on your reading list.

In practice, algorithmic problems do not appear at the beginning of a large project. Then, all of a sudden, they appear as subproblems when the programmer doesn’t know how to proceed or when the current program is clearly inappropriate. — Steven S.Skiena, Scenario Analysis of The Algorithm Design Manual

From the blog haorusong by and used with permission of the author. All other rights reserved by the author.

Apprenticeship Patterns Blog – Learn How you Fail

For this week’s blog post, I read the section “Learn How You Fail” from chapter five of the book Apprenticeship Patterns by Dave Hoover and Adewale Oshineye. The quote beginning of the section is what stood out to me the most. It says, “Ingenuity is often misunderstood. It is not a matter of superior intelligence but of character. It demands more than anything a willingness to recognize failure, to not paper over the cracks, and to change.” The section talked about how sooner or later you may face failures but the right thing to do is push forward at the boundaries and learn to overlook the mistakes you have faced. In our field, we face many failures but that is not holding us back to accomplish the goals we have set for ourselves. The author mainly talked about becoming conscious of the things that trip you but allow yourself the choice of working to fix the problems that are cutting the losses.

One of the most important things to do when you face failure is to accept it and investment of time and effort to make a small improvement. Allow yourself some time and the “goal is to gain self-knowledge about the patterns, conditions, habits, and behaviors that lead you to failure.” I liked the example the author provided regarding Ade. Ade keeps a set of private wikis listing all his current skill set and limitations, this enables him to pick challenges to push outwards and to stop wasting effort on the wrong things which can lead to failures. This is a great example of something that I need to do for myself. Especially keeping a diary or a blog is helpful as I mentioned in the previous blog post that talked about the “Record What You Learn” apprenticeship pattern. This pattern was very true to me. Leaning from failures is important and you cannot excel at everything but accepting these limitations and learning from the failures or mistakes forces you to acknowledge them and focus on improving them so you do not make the same mistakes again.

From the blog Derin's CS Journey by and used with permission of the author. All other rights reserved by the author.

Automation Testing

For the last and final blog for the CS 433 class, I want to focus on an interesting topic that is automation testing. Nowadays, most companies have implemented automated testing environments. It is the best way to increase effectiveness, test coverage, and the execution speed of software testing. Before I get started, what exactly is automation testing? Well, automation testing or Test automation is a software testing technique that performs using various software tools to execute a test case suite. The automation testing software can enter test data into the system and compare expected and actual results with the generated details test reports. There several benefits of using test automation, it is the best way to increase effectiveness and save money. Other factors include manual testing, which is time-consuming, Test automation does not require human intervention and can run automated tests unattended or even overnight, it is reliable in results, improve accuracy, better speed, and lastly, you can test frequently and thoroughly.

Now let us talk about the different types of test cases that use in automation. While researching a few of them once that I found are High-Risk Business test cases, Test cases that are repeatedly executed, Test Cases that are very difficult to perform manually, and finally, Test Cases that are time-consuming. The way automation testing works is using the pyramid strategy which consists of three levels. According to the blog, the base represents unit testing, then the integration/service layer, the next API testing, and finally the GUI test sits at the top of the pyramid. There are many types of automated testing some of which we learned in class, for example, unit testing, black box testing, regression testing, and even data-driven testing. Automated testing is becoming a popular strategy among many companies, I believe that majority of the companies will implement fully on this technology.

https://www.guru99.com/automation-testing.html

https://smartbear.com/learn/automated-testing/what-is-automated-testing/

From the blog Derin's CS Journey by and used with permission of the author. All other rights reserved by the author.

Testing with Mockito

During class, we have been doing many testing methods including Junit 5 and for the past two weeks we have been using Mockito, so for today’s blog, I want to focus more on the framework and testing with Mockito. Before we get started let us talk about what is mocking. Mocking is a process of developing the objects that act as the mock or clone of the real objects. In another word, mocking is a technique where mock objects are used instead of real objects. The purpose is to isolate and focus on the code being tested. Mock uses objects such as Fakes, Stubs, and mocks. A fake object has working implementation but takes shortcuts which makes them not suitable for production. Stub object usually does not respond to anything outside that is programmed in for the test. Mocks are objects that are preprogrammed with expectations which form a specification of the call that is called to receive.

Now let us move on to what Mockito is, Mockito is a java based mocking framework that internally uses the Java Reflection API to generate mock objects for a specific interface. Mock objects as I explained previously are used as dummy objects. The main purpose of using the Mockito framework is to simplify the development by using mocking external dependencies and use them in the test code. Few benefits of Mockito include writing beautiful tests with a clean & simple API, it creates mock objects using annotations like for example @Mock, and In Mockito, there is no requirement for writing your mock objects. The first link I have provided gives a lot of detailed examples of Mockito. It has helped me to learn the framework fully. I highly recommend to check it out and follow the example.

https://www.vogella.com/tutorials/Mockito/article.html

https://site.mockito.org/

https://www.javatpoint.com/mockito

From the blog Derin's CS Journey by and used with permission of the author. All other rights reserved by the author.

Detailed and basic usage of Mockito

 Mockito is a Mock framework for Java single-testing, but it can also be used with other single-testing frameworks in addition to JUnit. Mockito changes the behavior of a class or object, allowing us to focus more on testing the code logic without the effort of constructing the data.

The basic concept

Mocks can be of two types, Class and Partial,so Mockito is called spy. The behavior of changing methods on mock objects is called Stub.

A Mock process is called a Mock Session, and it records all the Stubbing. It consists of three steps:

+———-+ +——+ +——–+ | Mock/Spy | ===> | Stub | ===> | Verify | +———-+ +——+ +——–+

Class Mock

A Class Mock changes the behavior of a Class so that the object it mocks completely loses its original behavior.

Method returns default values (null, false, 0, etc.) if it is not pegged.

The most basic usage is as follows:

1
2
3
4
5
6
7
8
9
10
11
12
import static org.mockito.Mockito.*;

// use List.class to creat a mock subject --- mockedList

List mockedList = mock(List.class);

//operation of mockedList

mockedList.add("one");
mockedList.clear();

//validation

verify(mockedList).add("one");
verify(mockedList).clear();

Partial Mock(spy)

If we only want to change the behavior of an instance, we need to use spy:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
List list = new LinkedList();
List spy = spy(list);

// optionally, you can stub out some methods:
when(spy.size()).thenReturn(100);

// using the spy calls *real* methods
spy.add("one");
spy.add("two");

// prints "one" - the first element of a list
System.out.println(spy.get(0));

// size() method was stubbed - 100 is printed
System.out.println(spy.size());

// optionally, you can verify
verify(spy).add("one");
verify(spy).add("two");

As you can see from the code, the main difference between a Spy and a MockSettings is that the MockSettings for a Spy needs to be passed in a SpiedInstance.

The default Answer to a spy is CALLS_REAL_METHODS, which means that if a method is not stub, it performs its real behavior.

The default Answer to a mock is RETURNS_DEFAULTS. Methods that are not stub return a default value.

source:

https://www.vogella.com/tutorials/Mockito/article.html

https://howtodoinjava.com/mockito/junit-mockito-example/

From the blog haorusong by and used with permission of the author. All other rights reserved by the author.

Use the Source

 When working on an open-source project, please get in the habit of downloading the latest version of the code (preferably from their source control system), so you can review its history and track future developments. Please take a look at the codebase structure and think about why it is organized the way it is. Look at how developers manage their code modules to see if it makes sense and compare them to how they might have used them. Try to refactor the code to understand why its coders made the decisions they did, and think about what the code would look like if you were the one coding it. It will give you a better understanding of the projects; Also, make sure you can build those projects. If you’ve found a better way to do something, you’re ready to contribute code to the project. Inevitably, as you go through the code, you’ll come across decisions you completely disagree with it. Ask yourself if the developers of the project might know something you don’t or vice versa. Consider whether this is a legacy design that needs to be refactored; consider whether making a toy implementation for the relevant feature would help clarify the issue.

You end up with a toolbox filled with all sorts of quirks that you’ve collected from other people’s code. This will hone your ability to solve minor problems more quickly and quickly. You’ll be able to tackle issues that others think are impossible to solve because they don’t have access to your toolbox. Take a look at the Git distributed source control system written by Linus Torvalds or any code written by Daniel J. Bernstein (known as DJB). Programmers like Linus and DJB occasionally use data structures and algorithms that most of us have never even heard of. They’re not magicians — they’ve just spent their time building bigger and better toolboxes than most people. The great thing about open source is that you can look at their toolbox and make their tools. One of the problems in software development is the lack of teachers. But thanks to the proliferation of open-source projects on sites such as SourceForge. Net and GitHub, you can learn from relatively representative code examples from the world’s programmer community.

In ODS, Bill Gates says: “The most subtle test of programming ability is giving the programmer about 30 pages of code and seeing how quickly he can read through it and understand it.” He realized something significant. People who quickly learn directly from the source code will soon become better programmers because their teachers are the lines of code written by every programmer in the world. The best way to learn patterns, idioms, and best practices is to read the open-source. Look at how other people to code. It’s a great way to stay relevant, and it’s free. — Chris Wanstrath at Ruby 2008 [

Pick an open-source project with deep algorithms, such as Subversion, Git, or Mercurial source control system. Browse through the project’s source code and jot down any algorithms, data structures, and design ideas that seem novel to you. Then write a blog post describing the project’s construction and highlighting the new ideas you’ve learned. Can you find a situation in your daily work where the same concept can be applied?

From the blog haorusong by and used with permission of the author. All other rights reserved by the author.

Sprint 2 Retrospective

 Links to evidence of activity on GitLab.

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/generatewcfbreportfrontend

I created a new generate WCFB report frontend which I used the sample frontend example from the professor. I have already had a basic model for the frontend, the one I need to do more is to connect the backend API which can let customers download the report for the inventory.

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/community/-/issues/23

I designed the API for backend endpoints.

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/community/-/issues/34

I met with Marcos and Matt and talked about the difference between each group’s FrontEnd design. Also, for the next sprint, we will be having more meetings to help each other out on the API.

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/community/-/issues/35

I looked for WSU visual standards to use for the frontends.

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/community/-/issues/61

As a team, we created a Docker_compose file for the Integration of all systems.

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/community/-/issues/67

I implemented FrontEnd for Reporting with the most recent version

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/community/-/issues/55

I am stilling mak OpenAPI.yaml fileReflection on what worked well?

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/community/-/issues/71

As a team, we are looking at the new architecture and plan accordingly.

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/community/-/issues/66

As a team, we are looking over TheasPantryReport.

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/community/-/issues/20

I am researching Kubernetes with Migena.

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/community/-/issues/22

We are reviewing Scrum issue boards

https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/community/-/issues/12
We are reviewing LibreFoodPantry Architecture and technologies used.
https://gitlab.com/LibreFoodPantry/client-solutions/theas-pantry/reportingsystem/community/-/issues/58
I am creating a simple frontend to test keycloack with Migena.
Reflection on what worked well?

In terms of what worked well, through the first phase of working together, team members are working together more efficiently to complete the project plan than ever before. After a period of teamwork, we have a deeper understanding of our mission goals and become more accustomed to each other’s habits. There will be a relaxed working atmosphere and the chemistry between the groups will encourage each other to move the project forward.

Reflection on what didn’t work well?

As for why it didn’t work out, there was some confusion about the final product as to the future goals of the project. When faced with unknown challenges, we are still a little confused. As we communicated with the professor, we had some clear goals. Because the front end and the back end are related. Taking charge of every task affects productivity. So we have overlapping project leaders working together to get the job done, which improves efficiency. The task was difficult and challenging, but we encouraged each other through the ZOOM meetings after class.

Reflection on what changes could be made to improve as a team?

As a team with cooperation experience, smooth communication, and tacit understanding among team members are the basis and key to improving our team’s cooperation level. We would discuss the project after class and give some constructive suggestions about each other’s tasks. Good communication makes our team have chemistry. Through communication and cooperation, we have a thorough understanding of the team members’ tasks. Each knew the other’s project progress would be conducive to the overall advancement of the project. When a team member encounters a bottleneck in a task, we will appropriately slow down the overall progress and communicate with him to buffer his time to complete and push forward the overall task progress together.

Reflection on what changes could be made to improve as an individual?

As an individual, I need to improve my understanding of the Frontend more quickly to help my team better connect Frontend and backend. I need to arrange my group tasks more reasonably to help promote the whole group project’s completion. Besides, I also need to make clear my work objectives, continue to follow up on the team’s project, and make my part and the whole develop simultaneously. 

From the blog haorusong by and used with permission of the author. All other rights reserved by the author.