DELETE products
PUT products
{
"settings": {
"number_of_shards": 1,
"number_of_replicas": 0
},
"mappings": {
DELETE products
PUT products
{
"settings": {
"number_of_shards": 1,
"number_of_replicas": 0
},
"mappings": {
This file contains hidden or 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
<?php | |
class Container | |
{ | |
protected $container = []; | |
public function add($a) | |
{ | |
$this->container[] = $a; | |
} |
This file contains hidden or 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
<?php | |
interface Container | |
{ | |
public function add(); | |
public function show(); | |
} | |
class Container1 implements Container | |
{ |
DELETE cities
PUT cities
{
"settings": {
"number_of_shards": 1,
"number_of_replicas": 0,
This file contains hidden or 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
<?php | |
declare(strict_types=1); | |
namespace Apisearch\Model; | |
use Apisearch\Exception\InvalidFormatException; | |
/** | |
* Class Coordinate. |
This file contains hidden or 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
from django.contrib import admin | |
from django.urls import reverse | |
from django.utils.datetime_safe import new_datetime | |
from django.utils.safestring import mark_safe | |
from report_project.rest_api.models import Question, Choice | |
class ChoiceAdmin(admin.ModelAdmin): | |
model = Choice |
This file contains hidden or 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
Unhandled exception in thread started by <function check_errors.<locals>.wrapper at 0x10b5cf9d8> | |
Traceback (most recent call last): | |
File "/Volumes/webroot/python/django-test-with-python36/lib/python3.6/site-packages/django/apps/config.py", line 143, in create | |
app_module = import_module(app_name) | |
File "/Volumes/webroot/python/django-test-with-python36/lib/python3.6/importlib/__init__.py", line 126, in import_module | |
return _bootstrap._gcd_import(name[level:], package, level) | |
File "<frozen importlib._bootstrap>", line 994, in _gcd_import | |
File "<frozen importlib._bootstrap>", line 971, in _find_and_load | |
File "<frozen importlib._bootstrap>", line 953, in _find_and_load_unlocked | |
ModuleNotFoundError: No module named 'app_name' |
ES Requests :
DELETE msm_test
PUT msm_test
{
"settings": {
"number_of_shards": 1,
"number_of_replicas": 0
This file contains hidden or 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
<?php | |
function get_tls_version($sslversion = null) | |
{ | |
$c = curl_init(); | |
curl_setopt($c, CURLOPT_URL, "https://www.howsmyssl.com/a/check"); | |
curl_setopt($c, CURLOPT_RETURNTRANSFER, true); | |
if ($sslversion !== null) { | |
curl_setopt($c, CURLOPT_SSLVERSION, $sslversion); | |
} |