Flyway 4.0.3., spring boot 1.4 and baseline - spring-boot

I set up boot with flyway:
flyway.baseline-version=2.7.0
flyway.baseline-on-migrate=true
I have 2 sql files in db/migrate: V__2.7.0_base.sql and V__2.8.0_jobs.sql.
When I start the app it fails, because it tries to exec V__2.7.0_base.sql again...
mvn:flyway:info
+---------+-----------------------+---------------------+---------+
| Version | Description | Installed on | State |
+---------+-----------------------+---------------------+---------+
| 2.7.0 | << Flyway Baseline >> | 2016-08-09 12:25:04 | Baselin |
| | 2.7.0 base | | Pending |
| | 2.8.0 jobs | | Pending |
+---------+-----------------------+---------------------+---------+
Why is 2.7.0 base pending? I set it as baseline - so it should be ignored?
Thank you

OK, looking into the sourcecode I found out, that the file naming schema must be like V2_7_0__base.sql.
No idea why there are so many examples out there with naming schema like V__2.7.0_base.sql...

Related

How to use a union operator in SonarQube web services?

I would like to select from all the issues I have all the blocking issues and all the vulnerability issues, which are Blocker, Critical or Major.
How can I do that in one request for SonarQube 6.4?
If I do
http://localhost:9000/api/issues/search
severities=BLOCKER,CRITICAL,MAJOR&type=vulnerability&additionalFields=comments
I will have the vulnerability issues only.
And if I do two requests, one for blocker issues and one for the vulnerabilities, I will have blocking vulnerabilities which are redundant.
api/issues/search does not allow to combine filters. It will "AND" all conditions together.
I assumed that you are asking about how to query for these issues:
CODE_SMELL | BUG | VULNERABILITY
BLOCKER | YES | YES | YES
CRITICAL | no | no | YES
MAJOR | no | no | YES
MINOR | no | no | YES
INFO | no | no | YES
So I suggest:
api/issues/search?severities=BLOCKER&types=CODE_SMELL,BUG
(for to get all BLOCKER issues of CODE_SMELL and BUG)
CODE_SMELL | BUG | VULNERABILITY
BLOCKER | YES | YES | no
CRITICAL | no | no | no
MAJOR | no | no | no
MINOR | no | no | no
INFO | no | no | no
api/issues/search?types=VULNERABILITY
(for to get all issues of VULNERABILITY)
CODE_SMELL | BUG | VULNERABILITY
BLOCKER | no | no | YES
CRITICAL | no | no | YES
MAJOR | no | no | YES
MINOR | no | no | YES
INFO | no | no | YES
So you will not have duplicated issues, but have to do two requests.
There are three types of issues
BUG
CODE_SMELL
VULNERABILITY
All of this issues types can have any severity set. So, if you want all issues (of any type) with Blocker, Critical and Major severity there should be this params in your request.
severities=BLOCKER,CRITICAL,MAJOR&types=CODE_SMELL,BUG,VULNERABILITY&additionalFields=comments

What is the difference between Operational and Config in YANG?

What is the difference between Operational and Config in YANG model? Is it a correct way to supporting GET,PUT,POST and DELETE interfaces both in Operational and Config ?
Config is what represents configuration data, usually what will be writable via the northbound agents (CLI, Netconf, Web, etc.), it is also what will be retrieved in a get-config Netconf operation.
Operational data is status data, data that is not writable via the northbound agents, it will come from a data provider application.
A web client should only be able to do a GET operation on operational data. Because it doesn't make sense to allow a client to change the information about a status.
For config data it makes sense to have all the operations.
NETCONF separates configuration and state (or operational) data:
The information that can be retrieved from a running system is separated into two classes, configuration data and state data. Configuration data is the set of writable data that is required to transform a system from its initial default state into its current state. State data is the additional data on a system that is not configuration data such as read-only status information and collected statistics.
RESTCONF works as NETCONF, but on HTTP: it does map CRUD verbs onto NETCONF operations:
+----------+-------------------------------------------------------+
| RESTCONF | NETCONF |
+----------+-------------------------------------------------------+
| OPTIONS | none |
| | |
| HEAD | <get-config>, <get> |
| | |
| GET | <get-config>, <get> |
| | |
| POST | <edit-config> (nc:operation="create") |
| | |
| POST | invoke an RPC operation |
| | |
| PUT | <copy-config> (PUT on datastore) |
| | |
| PUT | <edit-config> (nc:operation="create/replace") |
| | |
| PATCH | <edit-config> (nc:operation depends on PATCH content) |
| | |
| DELETE | <edit-config> (nc:operation="delete") |
+----------+-------------------------------------------------------+
On supporting GET,PUT,POST and DELETE, if you are reffering to http methods here, you should probably follow RestConf

Google Compute Engine snapshots not displaying actual space used

If I take a snapshot of a persistent disk, then try to see get information about the snapshot in gcutil, the data is always incomplete. I need to see this data since snapshots are differential.:
server$ gcutil getsnapshot snapshot-3
+----------------------+-----------------------------------+
| name | snapshot-3 |
| description | |
| creation-time | 2014-07-30T06:52:56.223-07:00 |
| status | READY |
| disk-size-gb | 200 |
| storage-bytes | |
| storage-bytes-status | |
| source-disk | us-central1-a/disks/app-db-1-data |
+----------------------+-----------------------------------+
Is there a way to determine what this snapshot is actually occupying? gcutil and the web UI are the only resources I know of, and they are both not displaying this information.
unfortunately it's a bug, known by google developers. They are working on that....

compatibility - Browser versions with Selenium webdriver

I want to know the web driver compatibility with browsers. So that I can decide which web driver I can use in my test suites.
|Selenium Webdriver | Firefox | Chrome | IE |
| 2.35 | ? | ? | ? |
| 2.36 | ? | ? | ? |
| 2.37 | ? | ? | ? |
Thanks in advance !
Check this CHANGELOG for
web driver compatibility with browsers.
http://selenium.googlecode.com/git/rb/CHANGES

How to get all projects on a dashboard in multiple columns?

We have a TV displaying our Sonar stats for all our projects, but now that we have 20+ projects, and it doesn't all fit in the screen. We would like our dashboard to look like this (so all the projects fit on one screen):
+----------+----------+ +----------+----------+
| Name | Coverage | | Name | Coverage |
+----------+----------+ +----------+----------+
| Project1 | 45 | | Project5 | 18 |
| Project2 | 15 | | Project6 | 22 |
| Project3 | 45 | | Project7 | 45 |
| Project4 | 15 | | Project8 | 22 |
+----------+----------+ +----------+----------+
Is this possible? Right now we are using the widget "Measure Filter as List", so that we don't have to hard-code the project names into a widget. As new projects get added to Sonar, we don't have to manually add them to any dashboard... they should automatically get added.
Thanks!
This is currently not possible. But you can implement your own widget that displays the list of project using a "fluid" layout in order to meet your needs.
See our sample plugin to learn how to write your own plugin that adds a widget in SonarQube.

Resources