Do not use SPLITALGO with NUMREGION in the same statement. Do not use this parameter with the ADD SALT keyword. You can specify the range-start and range-end values as a number or a string literal value of the first column in the HBase row key. The examples in the Examples section show the use of NUMREGION. DEFAULT COLUMN FAMILY OPTIONS. May 12, 2014 could not write value ConfigArgs to key SYSTEMCurrentControlSetServicesVisualSVNServerParameters. Verify that you have sufficient access to that key, or contact your support personnel. How can i fix that problem, please. We do not store the user open passwords for long-term credentials, for security reasons. Storing only the HMAC key has its own implications - if you change the realm, you will have to update the HMAC keys of all users, because the realm is used for the HMAC key generation. The key must be 32 characters (HEX representation of 16 bytes) for SHA1. Defines if the element is the primary key or part of the primary key for the specified entity. You cannot use the key modifier in the following cases: In combination with a null modifier. The key element is non null by default because NULL cannot be used in the key element. Note Structured elements can be part of the key, too. In this case, all.
This clause adds a column.
When you create a table or alter a table to add a set of columns, the
position that you specify for a column must be either less than or equal to
the number of columns that you have listed up to that point in the command.
For example, the following OMBCREATE command does not add the specified
columns to the table:
OMBCREATE TABLE 'MY_TABLE'
SET PROPERTIES (DESCRIPTION) VALUES ('TRIAL TABLE')
ADD COLUMN 'C1'
SET PROPERTIES (DATATYPE, PRECISION) VALUES ('NUMBER',10)
ADD COLUMN 'C2' AT POSITION 3
SET PROPERTIES (DATATYPE, PRECISION) VALUES ('NUMBER',10)
ADD COLUMN 'C3' AT POSITION 2
SET PROPERTIES (DATATYPE) VALUES ('VARCHAR2')
This is because at the point when you specify the position of the column
C2 as 3, you have added just two columns to the table.But the following
OMBALTER command adds the specified columns to the table. This is because
at the point when you specify the position of the column C2 as 2, you are
adding the second column to the table.
OMBCREATE TABLE 'MY_TABLE'
SET PROPERTIES (DESCRIPTION) VALUES ('TRIAL TABLE')
ADD COLUMN 'C1'
SET PROPERTIES (DATATYPE, PRECISION) VALUES ('NUMBER',10)
ADD COLUMN 'C2' AT POSITION 2
SET PROPERTIES (DATATYPE) VALUES ('VARCHAR2')
ADD COLUMN 'C3' AT POSITION 1
SET PROPERTIES (DATATYPE, PRECISION) VALUES ('NUMBER',10)
In the above example, the order in which the columns are added are as
follows:
C1
C1, C2
C3, C1, C2
Additionally, there are operatiors that are specific to merging arrays. For more detailsee the array merging documentation:
(( append ))
- Adds the data to the end of the corresponding array in the root document.(( prepend ))
- Inserts the data at the beginning of the corresponding array in the root document.(( insert ))
- Inserts the data before or after a specified index, or object.(( merge ))
- Merges the data on top of an existing array based on a common key. Thisrequires each element to be an object, all with the common key used for merging.(( inline ))
- Merges the data ontop of an existing array, based on the indices of thearray.(( replace ))
- Removes the existing array, and replaces it with the new one.(( delete ))
- Deletes data at a specific index, or objects identified by the valueof a specified key.Please note: You cannot use the convenient Spruce path syntax(path.to.your.property
) in case one of the elements (e.g. named entryelement) contains a dot as part of the actual key. The dot is in line with theYAML syntax, however it cannot be used since Spruce uses it as a separatorinternally. This also applies to operators, where it is not immediately obviousthat a path is used like with the (( prune ))
operator. As a workaround,depending on the actual use-case, it is often possible to replace the Spruceoperator with a equivalent go-patch operator file.
Most spruce
operators have arguments. There are three basic types to the arguments -literal values (strings/numbers/booleans), references (paths defining a datastructure inthe root document), and environment variables. Arguments can also make use of a logical-or() to failover to other values. See our notes on environment variables and default valuesfor more information on environment variables and the logical-or.
Usage: (( calc EXPRESSION ))
The (( calc ))
operator allows you to perform mathematical operations inside your YAML.You can reference other values in the datastructure, as well as literal numerics. If youhave more sophisticated calculations in mind, you can use these built-in functions insideyour expressions: max
, min
, mod
, pow
, sqrt
, floor
, and ceil
.
The expression passed to (( calc ))
must however be a quoted string.
Usage: (( cartesian-product LITERAL REFERENCE .. ))
The (( cartesian-product ))
operator accepts an arbitrary number of arguments, outputtinga list made up of the product of all its inputs. If the input is a literal, it is treated asa one-element set. If it is a reference, it must either be reference a literal type, or anarray filled with only literal types.
Usage: (( concat LITERAL REFERENCE .. ))
The (( concat ))
operator has a role that may shock you. It concatenates values together intoa string. You can pass it any number of arguments, literal or reference, as long as the referenceis not an array/map.
Usage: (( defer .. ))
Ever wanted to use spruce
to generate something with a spruce
operatorin it, or perhaps something that looks like a spruce operator, likea CredHub value? Defer can be used for that. When evaluated, it outputsthe contents of the operator, minus the initial defer operator.
Usage: (( empty hash map array list string ))
This operator empties out the contents of the parent. Due to spruce
's mergingsemantics, it can be a little tricky sometimes to overwrite an array withan empty aray, or a map with an empty map. Use this as a handy shortcut.
Usage: (( file LITERAL REFERENCE ))
Do you have a really long multi-line text file that you want to embed in your YAML?Perhaps it's an SSL cert, or a base64 encoded image? Of course you do! Enter the(( file ))
operator. Instead of having to worry about the proper YAML indenting
spruce
is executed). The path provided can even be a reference to another part of the datastructure, which might concat some values together to dynamically generate where the filewill be.Example:
Usage: (( grab LITERAL REFERENCE ))
Trying to DRY up your config file, so that you don't have to change the same property15 times? (( grab ))
can help! It pulls the contents of whatever reference you giveit, and stores them as the value of the key it's assigned to. You can also passliteral values to (( grab ))
, mostly so you can have default values if desired,but it's entirely possible to simply username: (( grab 'admin' ))
. I have no idea why youmight want to do that though, since it's much more typing than username: admin
..
Usage: (( inject REFERENCE ))
This works a bit like (( grab ))
, except that the contents of what it retrievesare placed at the same level as the key which called the (( inject ))
operator.The key containing the (( inject ))
operator is then removed. In many cases, youprobably want to use (( grab ))
instead, as it is much more intuitive and easyto troubleshoot. However, if you want to inject a bunch of data, but overrideparts of the data being injected on a case by case basis, this operator will be helpful.
Usage: (( join LITERAL REFERENCE .. ))
Sure, (( concat ))
is great, but what if I have a list of strings that I want asa single line? Like a users list, authorities, or similar. Do I have to concat
thatpiece by piece? Nope, you can use join
to concatenate a list into one entry.
Usage: (( keys REFERENCE ))
Do you need to generate a list containing all the keys of part of your datastructure?Enter (( keys ))
. Pass it a reference to part of your datastructure that is a hash/map,and it will return an array of all of the keys inside it.
Usage: (( load LITERAL ))
Similar to the (( file ))
operator, this operator takes the content of anotherfile to insert it into the main tree structure. However, (( load ))
does notuse the content as-is, but expects to parse valid YAML (or JSON). Like the(( file ))
operator, you do not have to worry about indentation as Spruce willcover that for you.
Note: Spruce will not evaluate any Spruce operators that might be inthe file that is loaded, because any path used by grab
or similar would beambigious in respect to the document root to be used. If you need to load afile with Spruce operators in it, you have to run a pre-processing step toevaluate the file first with another Spruce run.
Example:
Usage: (( param LITERAL ))
Sometimes, you may want to start with a good starting-pointtemplate, but require other YAML files to provide certain values.Parameters to the rescue!
Usage: (( prune ))
If you have a need to force the cleanup of data from the final output, but don't wantto rely on the end-user always specifying the necessary --prune
flags, you canmake use (( prune ))
s to clear out the bloated data. Please note: Both the CLIflag as well as the operator will not work if one path element contains a dot as theactual name, e.g. 10.local: (( prune ))
will not work. You have to use thego-patch equivalent instruction instead.
Usage: (( sort [by KEY] ))
This operator enables sorting simple lists like lists of strings, ornumbers as well as lists of maps that follow the known contract of containing anidentifying entry each, like name
, key
, or id
. As always, name
is thedefault for named-entry lists if no sort key is specified. The (( sort ))
operator works similar to the (( prune ))
operator as more of an annotationthan an actual operator that immediately performs an action: The path at whichthe sort operator is used will be marked for evaluation in the post-processingphase. That means the sorting will only take place once after all files aremerged.
Openssl generate pem key pair. I am trying to generate RSA 1024 key pair (public/private) using the following command openssl genrsa -des3 -out server.key 1024 In the server.key file, only RSA private block is there, so where. Openssl rsa -in private.pem -outform PEM -pubout -out public.pem. The -pubout flag is really important. Be sure to include it. Next open the public.pem and ensure that it starts with -BEGIN PUBLIC KEY-. This is how you know that this file is the public key of the pair and not a private key.
The (( sort ))
operator will fail in case of:
Usage: (( static_ips INTEGER .. ))
Even with BOSH Links, and Cloud Config, it's still occsionally necessary to have static IPsin your manifest. This operator makes the IP calculation fairly easy, and should be familiarto anyone who has used spiff
to do this in the past. You give (( static_ips ))
a list ofindexes. spruce
will look through the root document, and find the relevant IP ranges forstatic IPs for the network of a VM, and pull in as many as are needed based on the instancecount. It even supports BOSH AZs fairly well.
Usage: (( ips IP_OR_CIDR INDEX [COUNT] ))
Sometimes you need to reference IP addresses that aren't managed by BOSH, so static_ipsaren't much help. ips
has you covered. It lets you perform simple addition on IPaddresses. Pass it an IP and an index, and it will add INDEX to the IP. If you pass aCIDR instead of an IP, the calculation starts from the start of the network. I.e. (( ips'10.0.0.10/24' 2 )) will yield '10.0.0.2'. (( ips '10.0.0.10' 2 )) will yield '10.0.0.12'.If you also specify COUNT, you get a list of IP's instead.A negative index and an IP will count backwards. A negative index and a CIDR will startfrom the end of the given network.
Usage: (( vault LITERAL REFERENCE .. ))
Have sensitive material in your manifests that you don't want stored in the repo that yourconfigs are in? What do you mean 'No'? Everybody does. The (( vault ))
operator lets youstore that data in Vault, and spruce
will retrieve it at merge time. Simplyspecify a vault path in the secret
backend as the argument, and away it goes. If needed,you can pull in references to concatenate with info, resulting in an easy way to dynamicallylook up Vault paths.
Usage: (( awsparam LITERAL REFERENCE .. ))
The (( awsparam ))
operator will let you pull a value from AWS SSM Parameter Storeat merge time. Specify the parameter store path in one or more arguments that will be joinedto form the whole path and spruce will fetch it for you. Optionally you may pass ?key=..
to extract a sub-key where the parameter store value is valid JSON or YAML.
Usage: (( awssecret LITERAL REFERENCE .. ))
The (( awssecret ))
operator will let you pull a value from AWS Secrets Managerat merge time. Specify the secret name or ARN in one or more arguments that will be joined toform the whole identifier and spruce will fetch it for you. Optionally you may specify a sub-keyto extract with ?key=..
where the secret value is valid JSON or YAML and either a stage orversion with ?stage=..
/ ?version=..
respectively to fetch a specific stage or version.
You may combine these additional arguments with &
; for example secret/name?key=subkey&stage=AWSPREVIOUS
.
Usage: (( base64 LITERAL REFERENCE .. ))
When working with configs that require lots of base64 encoding, it can be quitetedious to manually encode and decode the values when trying to inspect orupdate the existing configuration. The ((base64))
operator allows for mergetime base64 encoding of string literals specified directly, or by reference.