This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@RestController | |
@RequestMapping("/crq") | |
public class ChgRequestController { | |
private final ChgRequestService chgRequestService; | |
@Autowired | |
public ChgRequestController(ChgRequestService chgRequestService) { | |
this.chgRequestService = chgRequestService; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class CassandraDbChgRequestRepositoryTest { | |
@Autowired | |
private SpringDataCassandraChgRequestRepository cassandraChgRequestRepository; | |
@Autowired | |
private ChgRequestRepository chgRequestRepository; | |
@AfterEach | |
void tearDown() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class CassandraDbChgRequestRepository implements ChgRequestRepository { | |
private final SpringDataCassandraChgRequestRepository chgRequestRepository; | |
@Autowired | |
public CassandraDbChgRequestRepository(SpringDataCassandraChgRequestRepository chgRequestRepository) { | |
this.chgRequestRepository = chgRequestRepository; | |
} | |
@Override |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class ChgRequestServiceImplTest { | |
private ChgRequestServiceImpl chgRequestService; | |
@Mock | |
private ChgRequestRepository chgRequestRepository; | |
@BeforeEach | |
void setUp() { | |
MockitoAnnotations.initMocks(this); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class ChgRequestServiceImpl implements ChgRequestService { | |
private final ChgRequestRepository chgRequestRepository; | |
public ChgRequestServiceImpl(ChgRequestRepository chgRequestRepository) { | |
this.chgRequestRepository = chgRequestRepository; | |
} | |
@Override | |
public List<ChgRequest> findAll() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public interface ChgRequestRepository { | |
List<ChgRequest> findAll(); | |
Optional<ChgRequest> findById(UUID id); | |
void save(ChgRequest chgRequest); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class ChgRequest { | |
private UUID id; | |
private String app; | |
private String build; | |
private String jira; | |
private String environment; | |
private String releaseNotes; | |
private String status; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Reference: http://lea.verou.me/2011/10/easily-keep-gh-pages-in-sync-with-master/ | |
$ git add . | |
$ git status // to see what changes are going to be commited | |
$ git commit -m 'Some descriptive commit message' | |
$ git push origin master | |
$ git checkout gh-pages // go to the gh-pages branch | |
$ git rebase master // bring gh-pages up to date with master | |
$ git push origin gh-pages // commit the changes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* package whatever; // don't place package name! */ | |
import java.util.*; | |
import java.lang.*; | |
import java.io.*; | |
/* Name of the class has to be "Main" only if the class is public. */ | |
class PositiveNegativeSeperateUsingDNF | |
{ | |
public static void main (String[] args) throws java.lang.Exception |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Given a String of length N reverse the words in it. Words are separated by dots. | |
By : Varun Thakur | |
Date : 31/07/2017 | |
*/ | |
#include <stdio.h> | |
void reverse(char *begin, char *end) | |
{ |
NewerOlder